: say ( s -- ) me @ swap notify ; : run_cycle ( -- ) begin trigger @ location "_auto" prop-exists? while trigger @ location "_request" getpropstr dup not if pop trigger @ location "_total" getpropstr atoi random swap % 1 + intostr "_cd" swap strcat trigger @ location swap getpropstr else trigger @ location "_request" remove_prop then dup "/" instr 1 - strcut 1 strcut swap pop swap "'s \"" strcat swap strcat "\" " strcat trigger @ location location "_call" getpropstr trigger @ location location "_freq" getpropstr trigger @ location location "_band" getpropstr 4 rotate random 2 % 3 + 1 swap 1 for 1 = if 4 pick 4 pick 4 pick 4 pick "begins to play" strcat else 4 pick 4 pick 4 pick 4 pick "plays on" strcat then .broadcast 60 sleep loop "fades out" strcat .broadcast 10 sleep loop ; : main ( s -- ) pop trigger @ name "auto on" stringcmp not if trigger @ location "_auto" prop-exists? if trigger @ location name " is already running." strcat say exit else trigger @ location "_auto" "yes" 0 addprop run_cycle "End cycle." say exit then then trigger @ name "auto off" stringcmp not if trigger @ location "_auto" prop-exists? not if trigger @ location name " is off." strcat say exit else trigger @ location "_auto" remove_prop "Kill sequence started." say exit then then ;