ID:148506
Jan 18 2003, 3:45 pm
|
|
I'm having trouble using get_step() proc...how would I implement this into an attack system, I tried using if(get_step(usr.dir,M)) but, it did nothing. Any help?
|
Goku72 wrote:
I'm having trouble using get_step() proc...how would I implement this into an attack system, I tried using if(get_step(usr.dir,M)) but, it did nothing. Any help? In any of the get_something procs, a direction is not the first argument, so you've done this wrong from the outset. But what I think you're trying to do is get a direction to M, from usr. There are several procs that can do that, depending on what you want. get_step_to(usr,M) -- use built-in pathfinding to approach M get_step_towards(usr,M) -- find the next turf "directly" to M; the same as get_step(usr,get_dir(usr,M)) Lummox JR |
for(var/mob/M in S)
I think this is what your looking for, if not I'll see what I can do.