Before I confuse myself totally. I would like some advice.
I want to create a state machine and update and assign key actions depending on the state.
Can I use:
@touch.on(touch.CANCEL)
def touch_cancel(channel,event)
if config.disstate==1 :
do some things
if config.distate==2 :
do some other things
Is there a better way? I’m a beginner hobby programmer. I couldn’t find any info on the threads or on other forums.