RMMV Yanfly's Base Parameter Control and messing with HP

eliaelia123

Veteran
Veteran
Joined
Mar 24, 2023
Messages
59
Reaction score
26
First Language
Deutsch/German
Primarily Uses
RMMV
Hey

I started RPG maker (MV) recently and now I'm trying to learn more about plugins and Javascript.

So I tried to vary, how the HP in YEP base parameter control plugin works.

Original line:
(base + plus) * paramRate * buffRate + flat

My try:
Code:
(base + plus + user.isActor() ? ($gameVariables.value(12) : 0)) * paramRate * buffRate + flat

Somehow my HP always turn to 1 after changing that. When i increased variable 12 and refreshed map, my hp didn't increase. So I'm doing something wrong, but I can't find out what exactly.

Would appreciate a bit of help.

Hey,
this thread is a bit older, but is close to the question I have, so i though I would try my luck here.
I also wanted to alter the formula in Yep Base Parameter Control, in my case to :

(base + plus + user.isActor() ? (gameVariables.value(12) : 0) ) * paramRate * buffRate + flat

what i though it would do is:
1. check if user is actor
2.a when yes, add var(12)
2.b when no, add 0

but it doesent work, any idea what I'm doing wrong with it?

Just to note, we're not supposed to necropost. :wink:


It's $gameVariables, not gameVariables.
 
Last edited:

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
8,896
Reaction score
6,700
First Language
English
Primarily Uses
RMMV
(base + plus + user.isActor() ? ($gameVariables.value(12) : 0)) * paramRate * buffRate + flat
You might want to put code like that into the CODE tag (the </> on the edit bar) - the way your text changes to italics in the middle looks like the forum ate something you typed.

You have incorrect parentheses. The structure of a ternary statement is:
conditional ? true effect : false effect
But you have
conditional ? (true effect : false effect)
which is making the engine...I don't know, probably just spit out a syntax error.

Just get rid of the extra parentheses.
Code:
(base + plus + user.isActor() ? $gameVariables.value(12) : 0) * paramRate * buffRate + flat
 

eliaelia123

Veteran
Veteran
Joined
Mar 24, 2023
Messages
59
Reaction score
26
First Language
Deutsch/German
Primarily Uses
RMMV
So, I just tried it out, but it did not change the outcome of 1HP or that it won't increase.

I tried to deactivate all other plugins and afterward it somewhat works I think.

If I increase v12 my max hp also increases. But it starts as 1, though I'm yet unsure why since it should start higher than that.

I'll try to find the plugin which interferes and see which one it is.
Any idea why it starts as 1 max HP?


Edit: Nevermind, it does not work anymore.. though i did not change anything.
Will update when i know whats going on.
 
Last edited:

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
8,896
Reaction score
6,700
First Language
English
Primarily Uses
RMMV
I have no idea what values you have in your game.

What do you have variable 12 set to at the beginning of the game? What do you have for HP at level 1 in that actor's class?

If it's working in terms of it increases when you change variable 12, then you just need to look at the actual math. Look up each of those individual values.

If you think a plugin is interfering, you simply turn off all plugins except for this one and see if it's any different.
 

eliaelia123

Veteran
Veteran
Joined
Mar 24, 2023
Messages
59
Reaction score
26
First Language
Deutsch/German
Primarily Uses
RMMV
Hey,

V12 starts as 0.
HP starts as 15.
Unbenannt.png

So.. if i only have Yep paramaters on, it works.. but i need to move at least one space for my status in the menu to update i think?

The moment i activate another plugin, it stops working.
Have tried with YEP core and a few others of yep and that problem arises.
With non yep plugins too, for example altmenuscreen.
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
8,896
Reaction score
6,700
First Language
English
Primarily Uses
RMMV
Make sure that all of your Yanfly plugins are in the exact order they're listed on the Yanfly Engine Web site. Any changes to that can cause random errors, and that's the most common cause of bugs.

If that is correct, then make sure you're using the most latest version of all of the plugins and that your MV project is the most latest version (1.6.1+).
 

eliaelia123

Veteran
Veteran
Joined
Mar 24, 2023
Messages
59
Reaction score
26
First Language
Deutsch/German
Primarily Uses
RMMV
Ok, the order was wrong, i corrected that. Still the bug continuous.
RPG Maker is 1.6.2, so that should be ok.
How do i know if all of the plugins are the lastest version?
Just checking each one manually or is there a simpler way?
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
8,896
Reaction score
6,700
First Language
English
Primarily Uses
RMMV
If you bought the bundle from itch, they should all be good. If you have any of them downloaded from Yanfly's site before that, you'll need to check.

The version number displays in the plugin manager, and the bottom section of each plugin's Web page shows the most recent. You should not have problems with this functionality with only Yanfly plugins enabled.

You can also try it in a new project, see if there's any difference.

Just to confirm:
RPG Maker is 1.6.2, so that should be ok.
Did you just create the project? If you have an older project and RPG Maker was updated since, that does not automatically update the code.
 

eliaelia123

Veteran
Veteran
Joined
Mar 24, 2023
Messages
59
Reaction score
26
First Language
Deutsch/German
Primarily Uses
RMMV
Hey, I'm somewhat struggeling right now.
Where do i see what the latest version of rpg mv is?
I have it on steam and though it would update by itself..
Besides, i have RPG maker for like .. 9 days? Though I wouldn't have to worry about that tbh.
 

ATT_Turan

Forewarner of the Black Wind
Veteran
Joined
Jul 2, 2014
Messages
8,896
Reaction score
6,700
First Language
English
Primarily Uses
RMMV
Where do i see what the latest version of rpg mv is?
Besides, i have RPG maker for like .. 9 days?
Did you just create the project? If you have an older project and RPG Maker was updated since...
Then that clearly doesn't apply, right? A quick Google shows 1.6.1 came out in June of 2018.
 

eliaelia123

Veteran
Veteran
Joined
Mar 24, 2023
Messages
59
Reaction score
26
First Language
Deutsch/German
Primarily Uses
RMMV
Yes, but I also saw threads about 1.61 being a stable version and haven't found what exactly that means since.. like are all versions above 1.61 not stable?

After checking all plugins one by one, i noticed some where actually old one.. which was funny, since i only got them through steam and itchio and though all of theirs would be up tp date.
Updated them, which fixed a few other problems i had like enemies not showing up in sv battle, but the issue descriped here didn't change because of it.
 

Latest Threads

Latest Posts

Latest Profile Posts

This could probably be an entire thread, but it’s really interesting how replaying a game several years later can change how you relate to a character. I think Tidus from FFX got such a bad rap. I getchu. Completely different reaction as an adult now.
As you see, I still enjoy writing tutorials. Is there anything specific you want to see? (I know mapping and editing/resource making is usually popular, but those are very broad topics)
Well, I wanted to expand player battlers visually and now have 3 sheets and counting for each of my players party.
1. Regular sheet
2. The character has turned stone sheet.
3. Using potions sheet.

Technically the main hero has 4 since he starts with a wooden sword, and I felt that the battler should reflect that until he gets a metal one.

Right back to the RM game dev grind in about 15 minutes. :LZSexcite:
Days ago I gave someone the sage advice not to steer away from your main project or take up another one to abandon the first. After figuring a way that would save me years of development, I am forced to redo a lot of stuff on my own turf, near to remake half of what I have already made.
Somewhere down the line I must have crossed paths with bad karma.
:kaomad2:

Forum statistics

Threads
131,733
Messages
1,222,756
Members
173,484
Latest member
sewamobilbali
Top