Actor not spawing

I am trying to get three actors to spawn on the click of a single actor and then move into location from there. My current implementation is this:
When actor receives touch is released
spawn actor 1
self.Position.x self.Position.y (relative to actor)
spawn actor 2
self.Position.x self.Position.y (relative to actor)
spawn actor 3
self.Position.x self.Position.y (relative to actor)
Right now they are spawning but way on the other half of my scene for all intensive purposes in the middle of no where. I am attempting to use the acceleration action to get them to move across the x axis a little bit but they are moving at a downward angle for some reasons. Any help would be great.
Thanks
When actor receives touch is released
spawn actor 1
self.Position.x self.Position.y (relative to actor)
spawn actor 2
self.Position.x self.Position.y (relative to actor)
spawn actor 3
self.Position.x self.Position.y (relative to actor)
Right now they are spawning but way on the other half of my scene for all intensive purposes in the middle of no where. I am attempting to use the acceleration action to get them to move across the x axis a little bit but they are moving at a downward angle for some reasons. Any help would be great.
Thanks
Best Answer
-
xforce Posts: 187
you can remove those selfposition.X/Y things. having 0 in all the boxes will spawn them all centered in relation to the spawning actor. (so long as relative to actor is selected). if the 3 actors need to all have different co-ordinates then just replace the 0 with what you need.
if the actor that is doing the actual spawning doesnt need to move around at all just change everything to "relative to scene" and put in the exact X/Y spawning positions where you want them to appear on the screen
alternatively you can use interpolate or move (avoid using move to) behaviours to get your actors to their X destination
Answers
Seemed simple enough to me, I know they are stacking on top of each other but I am handling that else where. Either way, I can't see any of them after the click. Any ideas?