Base Parameter rounding?

Doktor_Q

I'm not a real doktor, but I am a real Q
Veteran
Joined
Aug 1, 2016
Messages
873
Reaction score
562
First Language
English
Primarily Uses
RMMV
How does MV handle rounding on base parameters? Does it truncate it off, or does it actually round to the nearest whole?

For example,
if I have a defense of 1 and I multiply it by 150% with a status (result of 1.5), will the game treat it as a 1 or a 2?
What if I have a defense of 2 and I multiply it by 66% (for a result of ~1.33)?
 

Andar

Veteran
Veteran
Joined
Mar 5, 2013
Messages
31,365
Reaction score
7,674
First Language
German
Primarily Uses
RMMV
integers and similiar numbers are usually truncated, 1.8 -> 1
however, it depends on the exact formula because of the way the function works, especially if using control variable command.
 

MushroomCake28

KAMO Studio
Global Mod
Joined
Nov 18, 2015
Messages
3,729
Reaction score
4,682
First Language
English
Primarily Uses
RMMZ
If I recall correctly, it's an integer, meaning no decimal. However, the way it is calculated does take in consideration decimals, it just rounds it up after calculation. Meaning every level doesn't add something, but will rather result in a new calculation. Something like this:

Physical Attack = Base Stat + Growth * (level - 1)

If base stat = 10
growth = 2.7
level = 15

Then Physical Attack = 10 + 2.7 * 14 = 47.8
which would make it 47 (or 48, depending on if it rounds or it floors the value).
 

Doktor_Q

I'm not a real doktor, but I am a real Q
Veteran
Joined
Aug 1, 2016
Messages
873
Reaction score
562
First Language
English
Primarily Uses
RMMV
integers and similiar numbers are usually truncated, 1.8 -> 1
however, it depends on the exact formula because of the way the function works, especially if using control variable command.
I'm specifically looking at the case of base parameters (stats) being controlled with a trait (from equipment, status effects, class, etc.)
 

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

Latest Threads

Latest Posts

Latest Profile Posts

Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD
How many parameters is 'too many'??

Forum statistics

Threads
105,860
Messages
1,017,040
Members
137,569
Latest member
Shtelsky
Top