Problem with atom_OgreBotChangeCampSpotForWho

mistahmikey

Active Member
I am playing around with scripting some things in the Arena of the Gods. I have written a little test script to move a toon to a position relative to "The Prophet of the Gods". To move the toon, I use the following command:

relay all OgreBotAtom atom_OgreBotChangeCampSpotForWho ${Actor[id,${Actor1ID}].Name} ${EndPos.X} ${EndPos.Y} ${EndPos.Z}

For the purposes of this discussion, assume that ${Actor[id,${Actor1ID}].Name} is correct (I have verified that it is) and it is campspotted.

I have written code to calculate a position that is X meters relative to (left,right,front,behind) the position of an actor. In this case, the actor "The Prophet of the Gods" is located at {0,5,0}, heading 180.

When I calculate EndPos to be 5 meters left, I correctly get {5,5,0}, and when I issue the relay, the toon moves to the spot.
When I calculate EndPos to be 5 meters right, I correctly get {-5,5,0}, and when I issue the relay, the toon moves to the spot.
When I calculate EndPos to be 5 meters front, I correctly get {0,5,5}, and when I issue the relay, the toon does not move.
When I calculate EndPos to be 5 meters behind, I correctly get {0,5,-5}, and when I issue the relay, the toon does not move.

I have no idea why the front/behind coordinates are resulting in no movement. Any combination of asking it to move left/right works. If anyone can give me a clue as to why this is happening, I would appreciate it.
 

uiyice

Active Member
{0,5,5}

If memory serves, the routine doesn't like coordinates that start with 0. Probably a quick safety check against the numerous instances where it might get a 0,0,0 inappropriately.

So take a step to the left, and try again.
 

mistahmikey

Active Member
That did the trick. Man, I'd never have figured that out. Thanks so much for the tip - you da man! And bad kannkor! /smacks kannkor on the nose with a rolled up newspaper
 
Top Bottom