Find
You are looking at an action called codeon
Toggle target's switch.
Created by
thorn
, last updated 04 Sep 2009
Code
get $target in $loc;
if $target > 0 then checkswitch;
##checkswitch:
if $target's switch eq 1 then turnoff else turnon;
##turnoff:
switch $target off;
say 'msg',"[$target] is now off.";
##turnon:
switch $target on;
say 'msg',"[$target] is now on.";