Switch to edit mode.
Name(s): @thaw1: "Copied from Generic player (#6):@thaw by manta (#7165) Sep 24 09:08:38 1997"
2: "Allows builders to thaw their objects."
3: if (this != player)
4: return $msg:mtell("huh")
5: elseif ($command_utils:object_match_failed(dobj, dobjstr))
6: return
7: elseif (!$perm_utils:controls(this, dobj) && !this:isa($guardian))
8: return player:sub_tell("You have no permission to thaw %d (#%D~#).")
9: endif
10: expires = !(dobj:_get_solidified() || dobj:_get_petrified())
11: usesquota = !(dobj:_get_subsidised() || dobj:_get_petrified())
12: currentstatus = {"petrified", "subsidised", "solidifed", "unfrozen"}[expires + usesquota * 2 + 1]
13: newstatus = "unfrozen"
14: if (currentstatus == "unfrozen")
15: return player:sub_tell("Because %d (#%D~#) is neither petrified, subsidised, nor solidified, it cannot be thawed.")
16: elseif (currentstatus == "petrified")
17: if (!player:isa($guardian))
18: if ($command_utils:yes_or_no(tostr($string_utils:nn(dobj), " is petrified; do you want it to remain subsidised?")))
19: newstatus = "subsidised"
20: endif
21: if ($command_utils:yes_or_no(tostr($string_utils:nn(dobj), " is petrified; do you want it to remain solidified?")))
22: if (newstatus == "subsidised")
23: return player:sub_tell("%D (#%D~#) is still petrified.")
24: else
25: newstatus = "solidified"
26: endif
27: endif
28: endif
29: endif
30: if (newstatus == "unfrozen")
31: dobj:_set_petrified(0)
32: dobj:_set_solidified(0)
33: dobj:_set_subsidised(0)
34: elseif (newstatus == "solidified")
35: dobj:_set_solidified(1)
36: elseif (newstatus == "subsidised")
37: dobj:_set_subsidised(1)
38: endif
39: player:sub_tell("%D (#%D~#), which was %1, is now %2.", currentstatus, newstatus)
40: "Last modified by manta (#7165) on Sat Nov 7 05:48:08 1998 EST."
41: "This verb previously owned by manta (#7165), and chowned to $slacker upon dewizarding (Sat Aug 17 14:50:04 2002 MDT)."
42: "Last modified by Dax (#789) on Sat Aug 17 14:50:04 2002 MDT."