can you add an “else” to an event listener/function? e.g. i have a function/listener for when the screen is being touched. how can i run some alternative commands for when the screen isn’t being touched? e.g. when it’s being touched, abc = 1. when it’s not, abc = 0. i know you can use event.phase == “finished” for touch events, but maybe for things like whether a certain key is or isn’t held down?
also: can you check the current animation sequence a sprite is playing? as apparently setting a sequence re-triggers it (freezing you on the first frame), so you’d only want to if the sequence isn’t already playing. (turns out it’s guy.sequence)
e.g. if mouse is held down, and the sequence isn’t already flapping, set it to flapping. if mouse isn’t held down, and the sequence is currently flapping, set it to idle.
thanks!
(originally had a different question here but have solved it)