Switch puzzle gone awry

Discussion in 'RPG Maker VX Ace' started by Nirwanda, May 29, 2016.

Thread Status:
Not open for further replies.
  1. Nirwanda

    Nirwanda Procrastimancer Veteran

    Messages:
    1,278
    Likes Received:
    594
    Location:
    Buenos Aires
    First Language:
    Spanish
    Primarily Uses:
    RMMV
    I've made a simple puzzle where the player has to press colored switches in a specific order to open a gate.


    I used two variables to keep track of everything: the first one tracked how many switches had been pressed, the second one recorded a value for the order in which they where pressed: so if switch1 was pressed first it'll add a 1, if it was pressed second a 2, while if switch 2 was pressed first it'll add a 10, second it'll add a 20 and so on...


    Afterwards the event checks with a conditional branch if the results variable is the correct number (3412) and if so it activates a switch that should open the door, otherwise it plays a buzzer SE, resets both variables and all the switches. Instead all of the switches remain active once pressed no matter the order they were used on.


    I would show you screenshots, but since my Rpgm is in spanish you wouldn't understand them, so I copied the events into a blank project.


    I know I'm doing something wrong, but I have no idea what. Please, help would be very appreciated.


    http://s000.tinyupload.com/index.php?file_id=52583470203962859643


    (the correct solution is supposed to be blue-red-purple-green, BTW)


    EDIT: I was setting the initial variable instead of adding to it. I'm an idiot. This has been solved.
     
    Last edited by a moderator: May 29, 2016
    #1
  2. GreyStone84

    GreyStone84 Sic Gorgiamus Allos Subjectatus Nunc Veteran

    Messages:
    297
    Likes Received:
    95
    First Language:
    English
    Primarily Uses:
    RMVXA
    Glad it has been solved, but here is a link for you.




    I made a reply in there too how I think you can do a switch puzzle much more easily, but Touchfuzzy didn't agree with my methods since he wanted it a different way. Anyways, you should check it out, just in case an idea there could help you with yours.
     
    #2
    Nirwanda likes this.
Thread Status:
Not open for further replies.

Share This Page