Triggered Looping Animations
Posted: Thu Aug 26, 2010 12:51 pm
Hey,
I've just added an animated object to my age in which the player pushes a button and the object animates and loops endlessly until the button is pushed again. I tried using the Quickscript avatar animations and such, and for the animation script I set loop to 1 because I want it to loop when triggered.
However when I exported, the object had already started moving even though I didn't press the button. I made sure that autostart was off as well. The avatar animation works and the button is pushable, but what's the point if the object is already in motion?
Here's my AlcScripts:
As far as SDL file, I put one variable in. I assumed that although it looped, it would remember whether the object is in motion when the player links in later.
I've just added an animated object to my age in which the player pushes a button and the object animates and loops endlessly until the button is pushed again. I tried using the Quickscript avatar animations and such, and for the animation script I set loop to 1 because I want it to loop when triggered.
However when I exported, the object had already started moving even though I didn't press the button. I made sure that autostart was off as well. The avatar animation works and the button is pushable, but what's the point if the object is already in motion?
Here's my AlcScripts:
- Code: Select all
SirrusToy:
animations:
- name: SirrusRotate
autostart: 0
loop: 1
SirrusButton:
quickscript:
stateanimation:
objectname: SirrusToy
region: SirrusReg
sdlname: SirrusTurn
avatar:
animation: ButtonTouch
animtarget: SirrusTarget
forewards:
animation: SirrusRotate
backwards:
animation: SirrusRotate
As far as SDL file, I put one variable in. I assumed that although it looped, it would remember whether the object is in motion when the player links in later.