Riddle

gearbox15

Villager
Member
Joined
Sep 4, 2018
Messages
8
Reaction score
1
First Language
English
Primarily Uses
VNM
Hello, I could use some help basically I'm make a puzzle where an NPC ask question six riddles if they get at least three they will be allowed to pass. the issue is that I don't know how to make the game know if the player got enough riddles right or not. I think it might involve variables and increasing them but I don't know how to do that.
 

Wavelength

MSD Strong
Global Mod
Joined
Jul 22, 2014
Messages
5,486
Reaction score
4,958
First Language
English
Primarily Uses
RMVXA
Right. Have a variable called "Riddles Correct", and a variable called "Riddles Answered". When the player answers a riddle correctly, increase both of them by 1 (use "Control Variables" event command to do this). When the players answers incorrectly, increase only the Answered variable by 1.

When the Riddles Correct variable is at least 3, the NPC lets you pass (you can use a "Conditional Branch" event command to check whether Riddles Correct is >= 3).

If the Riddles Answered is 6 and the Riddles Correct is less than 3 (put one Conditional Branch inside the other), you know that they player failed. The NPC might say "You didn't get enough right, I won't move!" If you want to give the player another chance to answer all 6 riddles again, you can set both variables back to 0 ("Control Variables": Set equal to 0) and then ask the riddles again.
 

gearbox15

Villager
Member
Joined
Sep 4, 2018
Messages
8
Reaction score
1
First Language
English
Primarily Uses
VNM
Right. Have a variable called "Riddles Correct", and a variable called "Riddles Answered". When the player answers a riddle correctly, increase both of them by 1 (use "Control Variables" event command to do this). When the players answers incorrectly, increase only the Answered variable by 1.

When the Riddles Correct variable is at least 3, the NPC lets you pass (you can use a "Conditional Branch" event command to check whether Riddles Correct is >= 3).

If the Riddles Answered is 6 and the Riddles Correct is less than 3 (put one Conditional Branch inside the other), you know that they player failed. The NPC might say "You didn't get enough right, I won't move!" If you want to give the player another chance to answer all 6 riddles again, you can set both variables back to 0 ("Control Variables": Set equal to 0) and then ask the riddles again.
It worked thank you!
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

I just saw in a manga an interesting mechanic - setting up a stationary teleport beacon that one can go to no matter where one is in a dungeon. I think it'll work with a similar setup to how I did my airship transition.

Ooh what if you could set up multiple beacons and choose from a list of the beacons you set up?

Hmm...
Actor2_1 added!

Is the running performance of MZ output to Android platform smoother than MV output?
FINALLY GOT ALL 120 STARS IN SUPER MARIO 64!!!

Ok i got the model New and I will develop a little more, I think my SV is not beautiful yet.

Forum statistics

Threads
103,251
Messages
998,358
Members
134,747
Latest member
DanMillerPlays
Top