Check for Highest Stat in First 4 Character Slots

xlucky_rat

They/Them
Veteran
Joined
May 16, 2022
Messages
77
Reaction score
83
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,242
Reaction score
9,685
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
89
Reaction score
19
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

Took some trial and error, but I managed to create "visuals" for underground dig path regions.
Couldn't sleep at all so I started working on the topmost deck. I've had to make several deviations from the Imperator/Berengaria's deck-plans to accommodate MV's movement, but 100% accuracy was never my intention.
Still no name for the poor ship...:kaodes:
Screenshot-2022-06-25-053308.png
ScreenShot_6_24_2022_9_20_7.png
Here's Mike when you get a preemptive strike in battle. There's another one for when an enemy sneaks up on you too.
Suddenly, games mean nothing. The money spent was worth it to bring souls towards the light of life. May God bless my path forever. I pray that all are shaken for truth and poured out flat on the table of true understanding, knowledge, and wisdom. Bless you.

Forum statistics

Threads
123,028
Messages
1,153,511
Members
161,370
Latest member
BuiTra
Top