Distributed systems120 files · 10K LOC
Project SHD
A hardcore tactical-faction server experience — a force-equipped smart-watch, a bank-hacking heist economy, and the distributed-systems plumbing to keep it consistent.
- Enforce Script
- ScriptRPC
- NetSync
- JSON persistence
- Component UI
In game
What it does
Project SHD turns a DayZ server into a hardcore tactical-faction experience. Every player is bound to a non-removable smart-watch that mirrors their identity, group, and in-game bank balance. Players can scan other watches, decrypt the watches of the dead, and pull off a bank-hacking heist — draining a slice of a rival's account on a cooldown. It layers in a group-hash storage lock, synced safezone music, a custom notification system, and a pack of survival QoL features.
Engineering
How it's built
- Hand-rolled ScriptRPC protocol with NetSync reconciliation (OnVariablesSynchronized) — string payloads pushed over RPC where NetSync vars can't carry them, plus a client→server 'request resend' pattern for late state.
- An eventual-consistency retry loop (ResolvePendingColorPick) that reconciles against a binarized third-party PBO exposing no hooks — polling fallbacks where events aren't available, converging without corrupting state.
- A stateless deterministic scheduler for synced safezone music: the server derives the current track and offset from a fixed start-time via floored-modulo — zero per-tick state, no drift, no broadcasts; clients pull-sync and stay phase-aligned.
- Versioned OnStoreSave/OnStoreLoad persistence, and re-entrancy-safe deferred mutation via CallLater to avoid mutating inventory inside an RPC handler.
- A self-animating, component-based notification UI (SHD_NotificationView, 566 LOC) with a fade/scale widget stack and progress timers.