Is there any alternate way of getting something to return the turf in front of you? I'm trying to make an action button
verb
Action()
//if(doing_action) return
world << 1
for(var/NPC/N in get_step(src, dir))
world << N
if(N)
doing_action = 1
N.Talk()
doing_action = 0
break
for(var/turf/powerline/bottom/L in step(src, dir))
doing_action = 1
L.Climb()
doing_action = 0
break
for(var/turf/powerline/bottom_right/R in get_step(src, dir))
world << R
doing_action = 1
R.Climb()
doing_action = 0
break
for(var/turf/T in get_step(src, dir))
world << T
if(T && T.jumpable)
locked ++
frozen ++
icon_state = "jump"
pixel_y = 32
loc = locate(T.x, T.y, T.z)
sleep(3)
locked = max(0, locked - 1)
frozen = max(0, frozen - 1)
pixel_y = 0
icon_state = null
I've never really done an action verb like this, but is there a better way to do it? :|
[edit]
Now that I think of it..could something like this work?
atom
verb
Action()
NPC
Action()
mob
Action()
for(var/atom/A in get_step(src, dir))
A.Action()
var/turf/T = get_step(src,dir)