Is there an easy way to reference 'raw" character stats, before equipment bonuses are added?

BlissAuthority

Dang, it feels good to be a Princess
Veteran
Joined
Dec 26, 2013
Messages
146
Reaction score
52
First Language
English
Primarily Uses
RMVXA
Exactly as it says.

For the purposes of some damage/healing formula, or to create "substats", I was wondering if there was an easy way to reference the raw value of a stat like A.Atk before equipment modifiers are considered, either in base MZ or using the free QoL plugins from VisuStella.

Example:

- Damage formula for a spells has it resisted by the sum of "Spirit" (Magic Attack) and "Mind" (Magic Defense) before equipment is considered.

- An event calls for a "roll" of 1-10, plus the raw value of a character's Agility, to see if the character succeeds at a task (parkouring up the inn's roof).

Is this possible?

(If this belongs in Tutorials, I have no problems with moving it there, but this seemed like Deep Magic rather than a basic function.)
 

Tiamat-86

old jrpg gamer
Veteran
Joined
Dec 5, 2017
Messages
970
Reaction score
432
First Language
english
Primarily Uses
RMMV
MZ uses all the same damage formula syntax as MV right?
for MV's damage formulas its a.paramBase(paramId)
ParamIDs
0
- Max HP
1 - Max MP
2 - Attack
3 - Defence
4 - Magic Attack
5 - Magic Defence
6 - Agility
7 - Luck
 

Arctica

Veteran
Veteran
Joined
Jul 19, 2021
Messages
83
Reaction score
102
First Language
English
Primarily Uses
RMMZ
^That is correct.
 

Tiamat-86

old jrpg gamer
Veteran
Joined
Dec 5, 2017
Messages
970
Reaction score
432
First Language
english
Primarily Uses
RMMV
if its all the same syntax then here is a good damage formula reference link
 

gstv87

Veteran
Veteran
Joined
Oct 20, 2015
Messages
2,483
Reaction score
1,492
First Language
Spanish
Primarily Uses
RMVXA
always refer to the database.
you just need to know how to cross IDs and objects to get from one collection to the other, but *everything* refers to the database.
that's simply how the system works, at any given moment: it pulls things from the database and then adds on top of that.

if you want to pull a base value from somewhere, always pull from the database.
for example:

$classes[$actors[$party[index].actor.id].classID].parameter

bring the parameter, from the class, assigned to the actor, at this position within the party.

if you used A.parameter in a damage formula, A could be an enemy.
depending on the parameter you call for, enemies might not have it (like, levels), and that'd cause a crash.
 
Last edited:

Arctica

Veteran
Veteran
Joined
Jul 19, 2021
Messages
83
Reaction score
102
First Language
English
Primarily Uses
RMMZ
In the context of the damage formula, a.x is can suffice.

a.atk is pointing to the current value of the attack parameter, which includes modifications from weapons/armor/buffs, etc.

a.param(2) is the same as atk(since atk just returns param(2)).

a.paramBase returns the base value set by the class.
 

Tiamat-86

old jrpg gamer
Veteran
Joined
Dec 5, 2017
Messages
970
Reaction score
432
First Language
english
Primarily Uses
RMMV
lol, dont forget about a.paramPlus which returns the amount from equipment and buffs but doesnt include the base amount from the class
 

BlissAuthority

Dang, it feels good to be a Princess
Veteran
Joined
Dec 26, 2013
Messages
146
Reaction score
52
First Language
English
Primarily Uses
RMVXA
Oh, of course that's a base functionality.

So that example spell using the syntax I wanted was just
((a.mtk+a.level)*2+20) - ((b.level*2)+b.mtkBase+b.mdfBase)

(and yes, I know that I'll need a plugin to set and refer to battler levels.)

That clears up a tremendous number of headaches, thanks very much!
 

Tiamat-86

old jrpg gamer
Veteran
Joined
Dec 5, 2017
Messages
970
Reaction score
432
First Language
english
Primarily Uses
RMMV
half of those brackets have no reason to exist.
P/E/MD/AS, multiplication and division are done at the same time in order of appearance in the equation.

(not the order of the letter in the acronym, this is the order of operation that schools only teach in passing while only drilling the acronym into peoples heads).

once those are done it will do addition and subtraction at the same time.
you only need brackets when want to break the order of operation.

(a.mat+a.level)*2+20-(b.level*2+b.paramBase(4)+b.paramBase(5))

b.level*2 will get done 1st, because it is P/MD/,
then it will do the a. addition followed by the rest of the b. side, P/AS/,
followed by the *2, /MD/, and finally the /AS/

math is math

edit after eating: ya... seeing weird math is 1 of my triggers.
just picture how bad i get when i see those "9/10 people cant solve" things on facebook and youtube.
at least the equation here wasnt technically wrong (aside from syntax), just weird.
(and dont even get me started on old D&D THAC0)
 
Last edited:

Latest Threads

Latest Posts

Latest Profile Posts

i only have one decent song and i dont even think it fits for a video game
Update: I finished the combat arena! My goodness, it took a while! There were numerous little bugs to squash.
Maldra wrote on stramin's profile.
Hi regarding the 32 bit -> 64 bit
I am running on a 64 bit windows OS and tried doing this conversion. I converted all of the .exe files that I could find in the KADOKAWA\RPGMV folder using the 4gbpatch.exe file. However, after trying to access RPG Maker MV after this conversion, it simply will not load. Do you have any advice or any ideas?
****ing muscle memory: does anyone else habitually quit out of test play when they notice something they """HAVE""" to fix, in spite of the fact that you can now edit DURING test play?

...thousands of times...

...every day?
Does anyone recognize him? :kaocry:
pwkyiDa.jpg

And hi.

Forum statistics

Threads
115,928
Messages
1,094,140
Members
151,188
Latest member
yuangou
Top