All work

Retired

Plugin hot reload

A developer tool that reloaded individual plugins instead of the whole gamemode. It carried three months of feature work, then was retired.

Role
Design and implementation
Stack
Lua (GLua), NutScript internals
Context
Local development workflow
Status
Retired

The problem

Changing any gamemode file reloaded the entire gamemode, freezing my local server for about ten seconds every time I wanted to test something. Over a day of iteration, that adds up to a lot of waiting.

How it worked

Code excerpt coming soon

The guard function and the reload entry point, with its re-entrancy checks.

assets/excerpts/hot-reload-guard.lua

Adapted from production code, lightly edited for readability.

What it carried

From March to June 2025 it was how I built most new features, including faction events, conflict locks, criminal stashes, gun bags, barricades, lockpicking and the first version of felonies.

Why it was retired

Its weakness was its footprint. Every hot-reloadable file needed that one-line guard, so a convenience for my own workflow became part of the codebase everyone else maintains. After a compatibility issue with one plugin that did unusual things at start-up, the owner and I agreed to retire it.

If I built it again, I’d make it invisible to the code itself: a development-only file watcher that reloads plugins from outside the gamemode, with nothing added to plugin files.