Check for Highest Stat in First 4 Character Slots

xlucky_rat

They/Them
Veteran
Joined
May 16, 2022
Messages
77
Reaction score
84
First Language
English
Primarily Uses
RMMV
My game will have a D&D-style skill check system where, in the field, certain stats will be called on (STR to move a boulder, AGI to pick a lock, etc.) to determine whether or not an action is a success. I have found a way to set it up so that the FIRST party slot is checked, using that character's stats for the event, but I'd like to know how to set it up so that the first four party members are checked for the highest stat.

For example, maybe the low-INT warrior is leading the party, but the mage is in the fourth slot. Instead of using the fighter's dismal intellect to recall lore, the mage tries it instead, without being moved to the front of the party. I mainly want to avoid having to force the player to keep swapping around the formation.

Does that make sense? I hope it makes sense. Thank you in advance! I've found this to be a very helpful forum!:kaohi:
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
36,278
Reaction score
9,702
First Language
German
Primarily Uses
RMMV
You can check the first eight actors with the control variable command, game data section.

you just have to load all relevant data into several variables, and then use conditional branch to compare the variables and select the highest result.
 

oooNUKEooo

Veteran
Veteran
Joined
Sep 22, 2020
Messages
100
Reaction score
23
First Language
br portuguese
Primarily Uses
RMMV
you could with a control variables event, then use a script to check what you want (or go total event to make the checks. i just find scripting faster).

set variables to get the members order, like v[1] is the leader, v[2] is the 2nd member,...

the perform your checks with conditionals or scripts.

heres a picture of what mine looks like, it was an old project where i used the pages up and down keys to change the party leader "on the fly" in the field map.
 

Attachments

  • Untitled.jpg
    Untitled.jpg
    214.6 KB · Views: 2

Latest Threads

Latest Profile Posts

Messing around with fragment shaders (filters). This thing is HUGE and I'm surprised almost no one makes good use of. Even the number of plugins that do this stuff are limited.
ScreenShot_6_28_2022_3_2_40.png

There's 7 main areas in the game that are all connected. This train get's you from an underground lab to the center of someone's subconscious. inside the train you can talk to some of the passengers. but going to the top of it, there's battles.
Speedrunning all character portraits just so they all have the same quality. Not sure if this was a good idea, but now I'm almost done.
We now have a gameplay video!
DrBuni wrote on Akiritas's profile.
That is a cute Link picture, reminds me of the Samurai Jack artstyle.

Forum statistics

Threads
123,150
Messages
1,154,411
Members
161,498
Latest member
lennonmchugh01
Top