Multiple dice rolls and choosing the highest result, with diffrent level of success

Hello there. I have an idea for a game where there are no fights and no level ups, and the character progresses in the story through interaction with objects on the map, such as npc or or other things. In this aspect it is similar to a point and click game.

My problem is that i would like to set the difficulty and the success rate of those interactions, basing them on an open source tabletop roleplaying game i really like.

THe rule are kind of simple for a pen and paper game, but i really can't translate them on a videogame

- YOU ONLY HAVE A STAT, WHICH INCREASES OR DECREASES BASED ON THE RESULT OF A SPECIAL DICE. YOU WANT IT LOW.

- ROLL ONE DIE If WHAT YOU’RE DOING IS WITHIN HUMAN CAPABILITIES...

- ONE DIE If IT’S AN ACTION SUITED FOR YOUR "CLASS"

- AND ON SOME SPECIAL OCCASIONS, A THIRD DICE. IT IS A BAD THING, BUT IT DOESN'T IMPLY THE CHANCE OF FAILURE.

- IF FAILURE COULD HAVE AN INTERESTING OUTCOME, ROLL A "FAIL DICE" TOO.

- THEN YOUR HIGHEST DIE SHOWS HOW WELL YOU DID- IF THE WINNING DICE IS THE "SPECIAL DICE", MAKE A SPECIAL ROLL. IF YOU GET A HIGHER RESULT THAN YOUR STAT, RISE YOUR STAT.

- IF THE WINNING DICE IS THE FAIL DICE, YOU FAIL IN A WAY THAT MOVES THE STORY FORWARD.

- ON A 1-3 RESULT YOU DO IT, JUST BARELY

- ON A 4 YOU DO IT IN A COMPETENT WAY

- ON A 5 YOU GET WHAT YOU WANTED AND MORE

- ON A 6 YOU GET WHAT YOU WANTED, AND PAY HEAVY PRICE FOR IT. YOU MIGHT BE FORCED TO THROW AGAIN THE SPECIAL DICE

- YOU CAN RETRY, AS LONG AS YOU ADD THE SPECIAL DICE IN THE ROLL (IF IT ROLLS HIGHEST THEN YOU HAVE TO MAKE THE SPECIAL ROLL)

- wHEN THE STAT REACHES 6 IS GAME OVER. YOU CAN LOWER IT BY SACRIFICING RESOURCES.

Now... I'm completely lost.. how the hell do you do it?

PLease keep in mid th you are talking to someone who just bought rpgmaker for the sole purpose o frealizing this idea, and doesn't know any specific term relating to the software.
Learn eventing. Specifically switches, variables and branches. There's a ton of of tutorials everywhere.
You can recreate literally any rule or any system within a videogame as long as you work hard enough for it. (That doesn't mean it will be an enjoyable system, but in this case I do think it matches your "story with tabletop-style interaction" dynamic well and will be enjoyable.)

I highly recommend you play around with the Event Editor. In particular, get comfortable with the Control Switches, Control Variables, and Conditional Branch commands. You're going to need them a lot.

For example, the player walks up to a wall and tries to climb it.
  • It's within their capabilities, so roll a first die by setting a Variable at random between 1 and 6 (use Control Variables).
  • Check their Class using a Conditional Branch. If the Class is good at climbing a wall, roll a second die by setting another Variable between 1 and 6 randomly. If the Class isn't good at climbing walls, set that Variable to 0 instead.
  • Roll a special third die by setting another Variable between 1 and 6 randomly.
  • For now, show a message to the user (use Show Message) to tell them the results of the rolls. You can add a variable's value into a message box with the escape code \V[n], so if the first die's roll is held in Variable #18, your message would be "Capability Die: \V[18]". Later on, you can use Show Picture to actually show a picture of the die with the correct roll, but for now just use text.
  • Compare the results of all three dice to see which one is the highest. You can do this with Conditional Branches - for example, check whether the first variable is higher than or equal to the second variable, and if that is true, check whether it is also higher than or equal to the third. If both are true, the first die is your highest. You can set a Switch or Variable to indicate this.
  • If you found that the third die was the highest, set another Variable to the Stat, and then make a special roll (1-6) and set THAT to a Variable as well. If the Roll variable is higher than the Stat variable, raise the stat by 1 (either Change Parameters or Control Variables)
  • Find the highest result that was rolled. Do this by setting a "highest roll" Variable to 0, and then having a Conditional Branch compare each Dice Roll variable that was made to the "highest roll" Variable. If the Dice Roll variable is higher, set the Highest Roll variable equal to that dice roll. Then continue to compare it to all the other dice rolls as well. Once you've done this for all rolls, the Highest Roll variable will always be equal to the winning die's value.
  • Finally, use Conditional Branches based on the Highest Roll's value to determine the outcome of the action (for example, "If less than or equal to 3", "You scramble up, fall, catch yourself on a ledge, and barely make it up the wall. Ouch!"). As a starter, just show a message. As you get good at the program, you can make action scenes with the player's model climbing, swinging, falling, complete with special effect animations and multiple characters.
  • Once you've gotten the hang of most of this, you should learn about Common Events (events in the database that can be run from anywhere). This will allow you to put event commands that are "common" across many different events, such as rolling dice and showing their results, in a single place. It saves you a ton of time to write things once instead of a lot of times, and also makes it easier to keep things consistent when you need to make a change that affects a lot of different events.
This sounds complex and a little bit difficult - because it is. Any time you are trying to create stuff that the editor wasn't specifically designed for, you are going to have to abstract things into variables and branches, and jump through a few hoops. That's the nature of game-making. 🙂 Learn a little at a time, try your best to make it work, and feel free to ask questions if you think you've done something right but it doesn't work as you expected.
wow... best answer ever, thank you. Exactly what i was looking for. Im not scared of learning, just i got lost and didn't even know what to to learn and where to start.
- YOU ONLY HAVE A STAT, WHICH INCREASES OR DECREASES BASED ON THE RESULT OF A SPECIAL DICE. YOU WANT IT LOW.
- ROLL ONE DIE If WHAT YOU’RE DOING IS WITHIN HUMAN CAPABILITIES...
- ONE DIE If IT’S AN ACTION SUITED FOR YOUR "CLASS"
- AND ON SOME SPECIAL OCCASIONS, A THIRD DICE. IT IS A BAD THING, BUT IT DOESN'T IMPLY THE CHANCE OF FAILURE.
- IF FAILURE COULD HAVE AN INTERESTING OUTCOME, ROLL A "FAIL DICE" TOO.
- THEN YOUR HIGHEST DIE SHOWS HOW WELL YOU DID- IF THE WINNING DICE IS THE "SPECIAL DICE", MAKE A SPECIAL ROLL. IF YOU GET A HIGHER RESULT THAN YOUR STAT, RISE YOUR STAT.
- IF THE WINNING DICE IS THE FAIL DICE, YOU FAIL IN A WAY THAT MOVES THE STORY FORWARD.
- ON A 1-3 RESULT YOU DO IT, JUST BARELY
- ON A 4 YOU DO IT IN A COMPETENT WAY
- ON A 5 YOU GET WHAT YOU WANTED AND MORE
- ON A 6 YOU GET WHAT YOU WANTED, AND PAY HEAVY PRICE FOR IT. YOU MIGHT BE FORCED TO THROW AGAIN THE SPECIAL DICE
- YOU CAN RETRY, AS LONG AS YOU ADD THE SPECIAL DICE IN THE ROLL (IF IT ROLLS HIGHEST THEN YOU HAVE TO MAKE THE SPECIAL ROLL)
- wHEN THE STAT REACHES 6 IS GAME OVER. YOU CAN LOWER IT BY SACRIFICING RESOURCES.

this reads "manager" all over it.
make a common event with variables open to the outside, control those variables from the outside, call the event, and the event will take care of the rest.
so sorry, @gstv87 . I thank you for your answer, which is most probably correct, but i simply don't undersand what you are saying. As i said i bought the software today and don't really undersand a lot of terminology. I have looked at some tutorials, but they seem to cover only things in which im not that much interested at the moment. I first need to have this little engine working (its coming, thanks to @Wavelength answer), then i will have to write the content of the game, and at that point i could start to find those tutorial useful, and we are talkng about months.
I'm almost finished, it's working and i'm really happy. The only thing i can't understand is... why do I keep getting results between 0 and 6 instead of 1 and 6?

edit: whatever range i choose, my first dice on my first roll is always 0
Just writing again to thank everyone for the useful tips. My dice roller now works exactly as intended. I started making a very long and kind of hard to read code, and then i broke it in a series of simple common events that i can call only when i need them. Now i can concentrate on actually making a game 🙂

Original thread: https://forums.rpgmakerweb.com/threads/multiple-dice-rolls-and-choosing-the-highest-result-with-diffrent-level-of-success.113349/