Unique copies of same actor?

dotoran

  • Posts: 1
Hey guys. I'm still very new to Stencyl, but I have some programming knowledge in other venues. I must be missing something here:

I'm creating a basic platformer game where a hero has to collect coins, while avoiding bad guys. I'm working on the bad guys right now. I have this ogre actor that I want to make copies of, so I can have one goblin on each of 3 different platforms. I've created some code that allows this goblin to move back and forth across these platforms until they hit a special sensor character at the ends of the platform. This way I can make the platforms any width I want and the ogres would travel the full length of the platform until they hit the boundry actor.

It sort of works, but what's happening is that the ogre that's on the shortest platform hits his boundry ALL the ogres turn and start going the other way, instead of just that one ogre. I'm probably missing something incredibly easy, but I'm stumped.


merrak

  • *
  • Posts: 2738
Can you post a screenshot of your ogre code?

t4u

  • Posts: 418
Why not having a platform as attribute instead of using sensors?  Your goblin could get x of platform and x + width of platform.

+ If you want help post code
USE PICTURES WHEN YOU ASK SOMETHING!
If I helped you be sure to mention it in your game.

Tutorials + downloads:
http://t4upl.blogspot.com/