fuzzball
fuzzball copied to clipboard
Forcing a wiz to @toadplayer (SF Issue)
Attempting to go around the lack of toad player prim via wizz "@toad whomever" force crashes the muck.
This code crashes it:
: cleanupguest
5 sleep
me @ "@/guest" getpropstr strlen 0 = if "You're not a guest,
you almost got recycled, fun, fun, keep up the good work"
abort then
me @ awake? 0 > if "You are misusing this program." abort then
prog "_usercount" getpropval 1 - prog swap "_usercount" swap
setprop
forcewizz "@toad " me @ name strcat force
forcewizz "@recycle #" me @ intostr strcat force
;
Figured out it is actually a bug in recycling the leftover slimy toad left behind.
...
When the command to @toad the player runs, all of that player's programs should be removed from the timequeue, including the one that's currently running. Thus, it should not proceed past the initial @toading.
And if you want the TOADPLAYER primitive, recompile the server with SCARY_MUF_PRIMS set in config.h.
The best thing to do would be to @force the wizard to run a program that would @force him to do the toad, and then the @rec. This would prevent the current program from having issues.
I'm thinking about how this code is structured, and what it's supposed to do... not easy, since I don't know the interpreter that well yet.