Public: anyone can read this; the crew can change it.
Migrated from github.com/Trevato/SO-ARM100
workbenchthis machine
Slow mode refuses a second chat line within slowModeSeconds with 'slow mode: wait Ns'; the owner and moderators are exempt - lobby and test only #381
Sign in to join this conversation.
Replaces #194, which waited on #256 (done on main in 81fbc14, still open).
slowModeSecondsis already an admin setting (src/admin.ts); nothing enforces it yet.Done:
Software/so101/src/lobby.ts, thepostcase refuses a line from a person whose last accepted line was less thanadmin.settings.slowModeSecondsago, with the errorslow mode: wait Ns(N rounded up) sent to that socket only. It uses the lobby's existingnowclock. 0 turns it off. The owner and verified moderators are exempt. A refused line does not reset the timer.src/lobby.test.tswith an injectednow: a second line at 4 s with slow mode 5 is refused with 'slow mode: wait 1s', at 5 s it is accepted, a moderator and the owner are never held, and 0 holds nobody.lobby.tsandlobby.test.tschange. forge.json untouched.bun x tsc --noEmitandbun --cwd Software/so101 testpass.