ID:141497
 
Code:
obj
redspawn
icon = 'icons.dmi'
icon_state = "fdshgsdj"
density = 1

New()
spawn() red1()
obj
guitar1
icon = 'icons.dmi'
icon_state = "guitarp2"
density = 1
Click()
if(src.isplaying == 1)
usr<<"<b>Someone is playing that right now!"
return
else
switch(input("Would you like to play Guitar Hero: BYOND?") in list ("Yes","No"))
if("No")
return
else
src.player = usr
usr.loc = locate(47,86,1)//9 up in the middle for multiplayer locate
usr.density = 0
usr.invisibility = 1
usr.frozen = 1
for(var/obj/redspawn/K in oview(15))
for(var/obj/yellowspawn/L in oview(15))
for(var/obj/greenspawn/M in oview(15))
for(var/obj/bluespawn/N in oview(15))
for(var/obj/darkgreenspawn/O in oview(15))
K.hasbegun = 1
M.hasbegun = 1
N.hasbegun = 1
L.hasbegun = 1
O.hasbegun = 1
L = usr.yellowspawns
M = usr.greenspawns
N = usr.bluespawns
O = usr.darkgreenspawns
obj
var
theowner
proc
red1()
if(hasbegun)
usr<<"1"
for()
usr<<"2"
sleep(round(5 + 5*rand(1,10)))
var/mob/red/K = new(src.loc)
K.owner = src
K.dir = SOUTH
walk(K,SOUTH)
else
usr<<"phail"
return


Problem description: The proc red1() is not being called at all, the code is self explanitory, any ideas?

"No usr in procs. Ugh."
-Lummox JR

You're outputting messages to usr in red1(). There is no "usr" in that context.

The code may be self-explanatory, but that doesn't mean people will spend their time reading through it. :)
You use "src" in half of the proc, but "usr" in the other half. Why?
In response to Spunky_Girl
Could be because there is a difference between the two.