I never wrote an algorithm or defined a function that executed commands; I will ask you then how to write.
In several games I have seen that you can do the action of closing all the screens regardless of what you are doing or where you are, by calling at the beginning of a label a function that has been created on purpose.
EXAMPLE:
Code: Select all
label garage1:
$ hideAllScreen () #### in this way all screens you was before will Hide (something like a reset)
scene 12
"text text text "
jump or return...I know that to start we write something like this:
Code: Select all
init python:
def hideAllScreen():
....... ##### and here starts the commends or the operations and so on....Can anyone help me by writing the function (or algorithm) based on this simple example?
Being able to see an example, I can then understand the logic with which everything is written, and then apply it to my game.
It would save me from an endless series of problems I'm having,
thanks
bye