Ok, ive made my menu, and for some reason now, whenever i push down, once, twice, how ever many times, then press North, it goes south instead. Then i press north agian and it goes north. Its the same with pressing South, the pressing north, it goes south then north. I dont know why either. Can anyone help, or is this a bug?
client
Northeast(){return}
Northwest(){return}
Southwest(){return}
Southeast(){return}
North()
if(usr.inmenu==1)
if(usr.nomenu==0)
for(var/obj/menu/Curser/c in usr.client.screen)
if(usr.location_in_menu == 0)
return
else
usr.location_in_menu--
usr.currentdir = NORTH
c.screen_loc = "[c.xcoord],[c.ycoord++]"
usr << "[usr.location_in_menu]"
return
else ..()
South()
if (usr.inmenu==1)
if(usr.nomenu==0)
for(var/obj/menu/Curser/c in usr.client.screen)
if(usr.location_in_menu == usr.bottom_max_limit)
return
else
usr.location_in_menu++
usr.currentdir = SOUTH
c.screen_loc = "[c.xcoord],[c.ycoord--]"
usr << "[c.xcoord],[c.ycoord]"
usr << "[usr.location_in_menu]"
return
ID:148697
![]() Nov 6 2002, 12:56 am
|
|
![]() Nov 6 2002, 6:26 am
|
|
The main thing here is that you're using usr in a client proc which is totally wrong. You need to be using src.mob or just mob instead.
|
tenkuu wrote:
The main thing here is that you're using usr in a client proc which is totally wrong. You need to be using src.mob or just mob instead. Actually usr is valid in those, because client.North() and client.South() are really verbs. mob will also be valid however, because it will be the same thing. Lummox JR |