Fu-ion 0 Posted September 15, 2006 I am using the baracken "green current house" or Stomhaus addon (Mapfact) which has an animated switch. I need to be able to check if it is open or not. I know it will change state using xxx animate ["component2",1] or 0 but does anyone know how to check if the state of the component is 1 or 0 ?? Share this post Link to post Share on other sites
deanosbeano 0 Posted September 15, 2006 i am still noob on addons but i guess this is what you need. Quote[/b] ]object animationPhase animationOperand types: object: Object animation: String Type of returned value: Number Compatibility: Added in version 1.75 Description: Return animation phase of animation on object. Multiplayer notes: See comments on animate above. Might return a different value from different computers, due to desync and lag. Works best on the server. Example: house animationPhase "doors1" i am sure someone will come and say why and if not why. btw i use the comref over at ofpec, its v good. Share this post Link to post Share on other sites
ProfTournesol 956 Posted September 15, 2006 Yep that's it : in a script or trigger : ? nameofobject animationphase "component02" == 1 (true if the door is open) or ? nameofobject animationphase "component02" == 0 (true if the door is closed) Share this post Link to post Share on other sites
Messiah 2 Posted September 15, 2006 if it's a trigger, remove the '?' of course Share this post Link to post Share on other sites
Fu-ion 0 Posted September 15, 2006 wicked stuff, I hadn't gotten round to looking into "animationphase" but I guess the command itself is a clue. Thanks all Share this post Link to post Share on other sites