I was looking over a tutorial and was looking at this event:
from this tut
http://forums.rpgmakerweb.com/index.php?/topic/1790-the-puzzle-tutorial-make-your-own-puzzles-part-1/
(It has a button you must roll a boulder on to open a door. The door opens when you step on it as well,but of course, it closes when you step off!)
I will admit that I am generally one to look with displeasure at commands to break loops, exit event processing, jump to labels, and other "non-structured programming" methods.
But I am looking at this set of nested conditionals and thinking there has got to be a better way --- and all I can come up with is -
Test to see if the player is on the button. If they are - set the switch and jump to the end of the event processing.
If they are not on the button, test for the boulder being on the button and set the switch accordingly.
How important is it to you to keep your event pages tidy and trim?
Do you keep them free of jump to labels? Do you mind long event pages?
Sometimes I use second event pages just to keep the page from becoming unwieldy!
Discuss, please.
http://forums.rpgmakerweb.com/index.php?/topic/1790-the-puzzle-tutorial-make-your-own-puzzles-part-1/
(It has a button you must roll a boulder on to open a door. The door opens when you step on it as well,but of course, it closes when you step off!)
I will admit that I am generally one to look with displeasure at commands to break loops, exit event processing, jump to labels, and other "non-structured programming" methods.
But I am looking at this set of nested conditionals and thinking there has got to be a better way --- and all I can come up with is -
Test to see if the player is on the button. If they are - set the switch and jump to the end of the event processing.
If they are not on the button, test for the boulder being on the button and set the switch accordingly.
How important is it to you to keep your event pages tidy and trim?
Do you keep them free of jump to labels? Do you mind long event pages?
Sometimes I use second event pages just to keep the page from becoming unwieldy!
Discuss, please.