Triggering Animations

Hey, I'm a super noob so I apologize if this has been answered already. I searched the forum to no avail.
I'm wondering the best way to trigger an animation when 2 actors collide. Say you're character is a man, and there's a woman standing around, when you walk into her how do I trigger an animation of them dancing. Ideally that would appear overtop of them and then disappear upon completion.
Thanks!!!
I'm wondering the best way to trigger an animation when 2 actors collide. Say you're character is a man, and there's a woman standing around, when you walk into her how do I trigger an animation of them dancing. Ideally that would appear overtop of them and then disappear upon completion.
Thanks!!!
Best Answer
-
MotherHoose Posts: 2,456
are the animation images showing both man and woman?
if so you can have only one actor run the animation
best to pick the actor that has the least number of rules
and to this action from constantly triggering:
a boolean gameAttribute: danceDone
on womanActor:
Rule: when (All)
Event: overlaps/collides with actor man
Attribute: game.danceDone is false
--Animate
--Rule: when
--a Timer or Rule
---changeAttribute: self.Image To: correctImage for woman
---changeAttribute: game.danceDone To: true
on manActor:
Rule: when
Event: overlaps/collides with actor woman
Attribute: game.danceDone is false
--changeAttribute: self.Color.Alpha To: 0
Otherwise: changeAttribute: self.Color.Alpha To: 1
sound like fun! … @HaleyF … Eadweard Muybridge's original movie danceMH
Answers
http://www.youtube.com/user/Tshirtbooth
http://www.youtube.com/user/GameSaladCookbook/featured
Hope this help
(EDIT) oops read the rest if you're question. I saw "how to make animation" and I typed first thing that came to mind. READ BELOW FOR A BETTER ANSWER