Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

Trying to Display Growth Rates in Status Menu

A topic by Keeper98 created Aug 12, 2024 Views: 126 Replies: 3
Viewing posts 1 to 3

Hi there! Big fan of this plugin and it seems to do everything I need it to, I'm just trying to find the best way to display Growth Rates in the menu for each character. I've been attempting to use the script call for "$gameActors.actor(ID).paramGrowthChance(paramId, isCustom, classId)" to do so, but am having little luck so far. I fear I might just be missing something obvious.

I'm attempting to show the number within the menu provided by VisuStella (MZ ElementStatusCore), trying to replace one of the extra parameters shown in the menu (i.e HIT).  This got me to the point where the menu is recognizing that something has been put into it, but leaving the space blank. I have tried multiple variations to try and pull the right variable without luck.

I am also using a Duplicate Actors plugin, so pulling straight from the actor is not really an option - though in attempts to fix it, I found that this isn't an issue tied to this plugin as I get the same errors without it. I just need to be able to pull up the specific instance of the selected character's stats in the menu the same way one might reference their HP or Attack. I did try to turn the paramGrowthChance into a custom parameter in an attempt to reference it that way, but ran into similar issues trying to pull the number at all.

The sample project also does not seem to have any display for these Growth Rates so I didn't really have a good reference to pull from and thought I might just ask here for a step in the right direction. Thank you for the help!

Developer

Hi there! :)

Yes, this script call yu used, will not return the Growth Chance value, it will return the calculation of the Growth Chance, to check if the actor manage to succed to raise a parameter or not.

Below I will explain to you how to get it right. But keep in mind that, an actor does not have a single growth chance. Every actor parameter has a growth chance, so, if you want to show every growth chance value an actor has, you will need to use the below scripts for every parameter.

But you can retrieve the Growth Chance of an actor parameter using this script:

Eli.ClassCurves.getClassCurve(CLASS ID, IS CUSTOM PARAMETER)[PARAMETER ID].growthChance
  • CLASS ID → Replace it with the actor class ID you want to check. For example:
    • $gameActors.actor(ACTOR ID)._classId
  • IS CUSTOM PARAMETER → Replace with true or false. If true, it will get a custom parameter growth chance.
  • PARAMETER ID → Replace with the parameter ID you want to check the growth chance.

Example:

Eli.ClassCurves.getClassCurve(1, false)[0].growthChance

- This will get the HP growth chance of the class ID 1.

Eli.ClassCurves.getClassCurve($gameActors.actor(5)._classId, false)[0].growthChance

- This will get you the HP growth chance of the actor ID 5, for whathever class he is using.

Hope it helps!

(2 edits)

Appreciate the response! This does get me to the point where I can display the Growth Rate for a specific class or actor, and that's great! But I'm having difficulty translating that to the menu where it would need to display the current rate for the selected character.

For example I can set the displayed parameter to my Mage class, but when opening the same menu for my Knight, it will still display the Mage class parameters because the code isn't there to change the parameters to Knight.

Edit: Nevermind! By declaring a constant I was able to replace the actor ID with "user" and it now displays accurately. Thank you for the help and the awesome plugin!

Developer

Nice you manage to make things work!!!

Have fun!! :)