How do I make an actor go back to the start without resetting the timer?

pe6169pe6169 Member Posts: 3
edited August 2012 in Working with GS (PC)
Thanks ... Paul

Best Answer

  • tatiangtatiang Posts: 11,949
    edited August 2012 Accepted Answer
    In your main actor, create two attributes: self.originalX and self.originalY (both real).

    At the top of your main actor's rules, add two behaviors: Change Attribute self.originalX to self.position.X and Change Attribute self.originalY to self.position.Y.

    Then, add a rule When actor collides with [other actor or tag] Change Attribute self.position.X to self.original.X and Change Attribute self.position.Y to self.original.Y.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

Answers

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    You'll have to provide more details than that. How are you moving the actor? Why and how are you using a timer? Do you just need the actor to return to its original position when some condition is true?

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • pe6169pe6169 Member Posts: 3
    Hi, I want the actor to return to the start when it collides with another actor.

    Thanks...paul
  • pe6169pe6169 Member Posts: 3
    Yes, fantastic
Sign In or Register to comment.