hey.. i decided to post it because i have been like a whole day trying to calculate the distance between your actor and the targer to get the distance with the formula but then i found out theres an opcode that does it automatically so here it is, just in case someone else needs it
0104: actor $PLAYER_ACTOR near_actor 0@ radius RANGE_X RANGE_Y RANGE_Z sphere 0
so if i want to check if someone is at the distance of 10.0 from me i would do this
hope it is usefull for someone as it was hard to find for me. xd
where 0@ is the actor target
0104: actor $PLAYER_ACTOR near_actor 0@ radius RANGE_X RANGE_Y RANGE_Z sphere 0
so if i want to check if someone is at the distance of 10.0 from me i would do this
Code:
if
0104: actor $PLAYER_ACTOR near_actor 0@ radius 10.0 10.0 10.0 sphere 0
then
...
hope it is usefull for someone as it was hard to find for me. xd
where 0@ is the actor target