One job, three incompatible frameworks
A single codebase running on three host frameworks that disagree, by putting every contact point behind a bridge.
Context & problem
A role-play server runs one of three frameworks, and they do not agree about anything — not identity, not inventory, not how you interact with the world. The usual answer is three forks that drift apart. This is one codebase where every point of contact with the host is a bridge: framework, inventory, targeting and the tablet system each have one, and the business logic never learns which is underneath.
Role
Sole developer.
Constraints
- Part of the code ships escrowed and cannot be edited by the server owner; the bridges must be.
- Server owners run modified stacks, so a bridge has to be replaceable without touching the logic.
- Every action arrives from a client that can lie about it.
Decisions & why
- Bridges live outside the escrowed code; business logic lives inside.
- The part that has to be adapted to a strange server is exactly the part that has to be editable. Escrowing it would make the product unusable on any stack that was not anticipated.
- Every server action goes through one piece of middleware.
- Rate limit, permission check and audit line, in one place. Spread across a hundred handlers, one of them is always missing a check.
- State lives in state bags rather than global mutable tables.
- A global table is shared by everything that can reach it, which in this environment is everything.
What it does now
The architecture is in place; the features land in later phases. Said plainly because the repository says it plainly.
Stack
- Lua 5.4
- React 18
- Vite
- Tailwind
- MySQL