Turning Towards Actor/Actor Type

PressXtoNotDie

  • Posts: 94
Hey there all, I've basically been having trouble with trying to create a behaviour that makes an Actor Type, slowly turn towards another actor type.

For example: An actor is behind another actor, facing the opposite direction, i want the other actor to slowly turn towards the other Actor, and then face/look at the actor.

Ive been trying forever to get this to work, but another problem is, it has to be an actor TYPE, to turn towards to, since that actor wont be on the screen/game in runtime (Actor gets created later, and is not in the scene at the start, so can not select it.)

and no, doing last created actor, doesnt work, since multiple actors will be created at the same time, and i only want it to face towards that certain actor Type.

PressXtoNotDie

  • Posts: 94
Bump...

Is this even possible to do with Stencyl?
All i need is the logic behind it, probably not even exact code/blocks, I just cant think of a way to do it properly.

rob1221

  • *
  • Posts: 9473
Yeah it's possible, but I'm not exactly sure how to do it.  Someone made a thread about slow turning missiles; maybe it will help.  community.stencyl.com/index.php/topic,5698.msg36848.html

Also, there is a block under Scene > Actor called "for each actor of type".

PressXtoNotDie

  • Posts: 94
Thanks for the reply, ill definitely give that a proper look over.

I did end up sort of figuring it out with a lot experimenting, and it seems to work well within what i wanted it to do, but its not exactly the what I wanted. Maybe if i cant figure it out, ill just leave what ive already done. Ill give that a read, see if i can even understand it (too much maths! lol)

I guess if anyone wants an example in what ive done, i can post it here.