- Joined
- Dec 27, 2018
- Messages
- 72
- Reaction score
- 26
- First Language
- Français
- Primarily Uses
- N/A
Hello,
I have a new question regarding a formula in javascript.
I need to retrieve the id of the 8 enemies during my fights.
I will explain the context to you.
In my game, my characters can learn group abilities. One of them is being able to see the HP of non-boss enemies.
For this, I use the Yanfly VisualHpGauge plugin.
My problem is that this plugin offers to display enemies' HP "all the time" or "after defeating them at least once". It is not possible to do this according to a switch.
I managed to modify the plugin so that the display is "never" and therefore I have to use a formula to display the HP gauge.
The formula is:
My problem is that I have to replace "id" with the id of ALL enemies in my game.
I can do something that looks like this:
Or I can try to find a solution for the formula to repeat for 1 to 500 (for example, and I will place my bosses after 500 to hide their HP).
Or, so that the calculation is done on the 8 enemies at the start of each fight.
Is it possible to do this?
I have a new question regarding a formula in javascript.
I need to retrieve the id of the 8 enemies during my fights.
I will explain the context to you.
In my game, my characters can learn group abilities. One of them is being able to see the HP of non-boss enemies.
For this, I use the Yanfly VisualHpGauge plugin.
My problem is that this plugin offers to display enemies' HP "all the time" or "after defeating them at least once". It is not possible to do this according to a switch.
I managed to modify the plugin so that the display is "never" and therefore I have to use a formula to display the HP gauge.
The formula is:
Code:
$gameSystem.addHpGaugeEnemy(id);
My problem is that I have to replace "id" with the id of ALL enemies in my game.
I can do something that looks like this:
Code:
$gameSystem.addHpGaugeEnemy(1);
$gameSystem.addHpGaugeEnemy(2);
$gameSystem.addHpGaugeEnemy(3);
...........
$gameSystem.addHpGaugeEnemy(500);
Or I can try to find a solution for the formula to repeat for 1 to 500 (for example, and I will place my bosses after 500 to hide their HP).
Or, so that the calculation is done on the 8 enemies at the start of each fight.
Is it possible to do this?