How to have more states?

Hi everyone!

Is it possible to have more than 30 states with python? If no, is there any workaround, or are we actually not encouraged to use states? Thanks!

In python you can have hundreds…You dont even need to use states, I do what I need with multiple functions that run when they are supposed to.

I see…! Seems that i shouldn’t have had used states initially, stupid me! Now i have to rewrite a lot of codes again. (No pain no gain! ---- self comforting :D)

Thanks JohnnyBlack!

If you need more states you should think about a redesign anyway.

The benefits of the build in state system is:

  • it is easy to use
  • helps to organize the logic bricks
  • deactivates/activates sensors

You can mix different finite state machines as long as they are on a different layer of abstraction (e.g. navigation to a target vs. deciding the target)

Thank you, Monster!

As usual, learned! (But now it really confirms the rewrite…:mad:)