SWATsqad-GenerallyLitServerMod icon

GenerallyLitServerMod

Day and night length, stack size, item weight and a smoother network send rate. Independent day/night, server-authoritative, no restart to change.

CHANGELOG

Changelog

1.1.0

  • New: Updates sent per second (default 30, [Network]). A player's game sends what it controls (character, a ship it steers, nearby creatures) to the server at this rate instead of vanilla's fixed 0.05 s timer, and in the same frame the timer fires. Vanilla's send waits for the next frame, so at 70 fps it really sends about 14 times a second; ships visibly step for everyone aboard. The server's value is sent to every player. Only player games are changed, never the server's own sending. If anything in the hook ever fails, it switches itself off and vanilla sending carries on.
  • Fixed: config edits on a dedicated server now apply without a restart. 1.0.x used a FileSystemWatcher, which never fires inside the Linux server container, so server edits silently needed a restart. The file's timestamp is now checked every 2 seconds.
  • Compatible both ways with 1.0.x: the send rate is appended to the server's settings package without changing its wire version, so a 1.0.x client still receives the server's stacks and day length, and a 1.1.0 client on a 1.0.x server keeps its own send rate.

1.0.2

  • Fixed an exception during shutdown. The plugin unpatched itself in OnDestroy, which on quit runs before Game.OnApplicationQuit and left Harmony's wrapper for ZNet.Shutdown dangling, throwing "BadImageFormatException: Method has zero rva" inside the shutdown path that saves the world. The save completed regardless, but nothing of ours belongs near it. The mod no longer unpatches on quit, and the ZNet.Shutdown hook does nothing once teardown has started.

1.0.1

  • The day/night rescale runs once per frame, so it no longer recalculates the dawn and dusk boundaries on every call. They are worked out when the settings change instead. No behaviour change; the per-frame path is now two field reads and one interpolation.
  • The log line for the cycle now prints the dawn and dusk boundaries next to vanilla's, so it is obvious what the split actually is: Cycle length set to 7500s (7200s day + 300s night). Dawn at raw 0.0200, dusk at raw 0.9800 (vanilla is 0.1500 / 0.8500).

1.0.0

First release.

  • Independent day and night lengths. Vanilla splits one cycle length 70/30 in EnvMan.RescaleDayFraction and that split is hard-coded, which is why mods exposing only "day length" cannot give a long day and a short night. This rebuilds the same curve from two values, so a two hour day with a five minute night works. At the defaults (840/360) it reproduces vanilla exactly.
  • Stack size multiplier and item weight multiplier. Only things that already stack are multiplied; weapons and armour never become stackable. Original values are cached, so re-applying never compounds.
  • Server-authoritative. The server sends its values on every join, clients revert to their own on leaving, and a client editing its config mid-session is ignored and told so.
  • Config changes apply without a restart. The file is watched and new values are pushed to everyone connected.
  • A loud warning when the stack multiplier is lowered, because the items above the new cap are destroyed at the next world load rather than when the setting changes.