Hi everyone, this seems like a basic thing to do but i can’t figure out what i’m doing wrong:
i want to an actor to execute an actuator only once when certain conditions are met. for example, i have a ball with a keyboard sensor that triggers a jump (motion actuator). Then, i want the ball to play an animation (squashing) when it hits the floor. this animation would be triggered by a touch\collision sensor, but since this animation makes the ball jump again slightly it would trigger the touch\collision sensor again, so i made a boolean property that will indicated whenever the ball has landed (isLand), so the animation will only happen if the property is true and the touch sensor is fired.
If i make the keyboard sensor set the IsLand property to true and the touch sensor to clear the isLand property then things happen simultaneously and the animation does not play. even more, when i press the keyboard sensor to make the ball jump, it actually still touches the floor so the isLand property doesn’t change.:mad:
In theory, these setting should work, because the isLand property should switch on\off to indicate if the ball has landed or is in the air (about to land).
any ideas on how accomplish this correctly? maybe in python ? (it seems to simple a task to use python…)