MV Srnd HUD maker issue

I made a hud for the combat screen which works perfectly when all the party slots are used, but when there are free spaces I've gotten error messages when in battle, the ones that seem to be the ones causing the most problems are the ailment state icons

Screenshot_1499.png


I'm not sure how to solve this so that the start of the battles don't show the barrage of error windows
I don't know if you can without editing the plugin code, because it's trying to create the elements from an object that doesn't exist yet (party member 1) but it doesn't seem to cause any issues with the game itself. You can set $gameParty.members()[1] as a display condition but it doesn't stop the plugin from trying to create the elements.

You can try this patch plugin to see if it fixes it since it says it stops updates of "invisible children"
Are you using conditions for the other HUD elements?

So all HUD elements for party members 2 would needs it have a condition for Party member 2 to be in party? One of his HUD videos shows what to do in this case.
I don't know if you can without editing the plugin code, because it's trying to create the elements from an object that doesn't exist yet (party member 1) but it doesn't seem to cause any issues with the game itself. You can set $gameParty.members()[1] as a display condition but it doesn't stop the plugin from trying to create the elements.

You can try this patch plugin to see if it fixes it since it says it stops updates of "invisible children"
I downloaded the plugin but sadly it doesn't work
Thanks anyways 😀 <--- wtf, this is terrifiying

Are you using conditions for the other HUD elements?

So all HUD elements for party members 2 would needs it have a condition for Party member 2 to be in party? One of his HUD videos shows what to do in this case.
For now it's just the states icons that are causing issues, the other elements aren't showing any errors
what condition has the state icons?

@AquaEcho that plugin is mostly used for console.log if its for checking purpose
in modulo 2, or it lags, otherwise, it doesn't have much effect, sometimes it does
if the update for every frames isn't equal to 0 (while the console log is open).

it has no performance issue in game otherwise so far I know it.
Ok, but I see the issue this thread is about as a non-issue because it doesn't affect the game. I don't think it can be solved without editing SRD HUDMaker's code and it wouldnt even be worth it for something that's a non-issue.

For now it's just the states icons that are causing issues, the other elements aren't showing any errors
The issue isn't with state icons, it's that it's trying and failing to create a HUD element for GameParty member 1 (the second member, because the first member is actually member 0) and member 1 doesnt exist if only member 0 is in your party.
what condition has the state icons?

@AquaEcho that plugin is mostly used for console.log if its for checking purpose
in modulo 2, or it lags, otherwise, it doesn't have much effect, sometimes it does
if the update for every frames isn't equal to 0 (while the console log is open).

it has no performance issue in game otherwise so far I know it.
$gameParty.members()[1].isStateAffected(9) is what im using for each character and state, it just s up when a party members isn't on the party
Ok, but I see the issue this thread is about as a non-issue because it doesn't affect the game. I don't think it can be solved without editing SRD HUDMaker's code and it wouldnt even be worth it for something that's a non-issue.


The issue isn't with state icons, it's that it's trying and failing to create a HUD element for GameParty member 1 (the second member, because the first member is actually member 0) and member 1 doesnt exist if only member 0 is in your party.
Screenshot_1510.png

every time a battle starts this window shows up, I exported the game to check if it also showed there and it does so I gotta solve this real quick
because this also checks if its inside, you need a condition to it.
because you need to check if the battleMember is isn't the party, similar
JavaScript:
$gameParty.battleMembers()[x] && $gameParty.battleMembers()[x].isStateAffected(9)

this will check if the member is inside the party and continue normally.
if you have more members than 1, you can loop through

using the code: BattleManager.actor().actorId() which can cycle through
your battle members and give the state accordingly.
Then change your if statement to
$gameParty.members()[1] && $gameParty.members()[1].isStateAffected(9)

If party member 1 exists AND party member 1 is affected by state 9

ShadowDragon beat me to it.
because this also checks if its inside, you need a condition to it.
because you need to check if the battleMember is isn't the party, similar
JavaScript:
$gameParty.battleMembers()[x] && $gameParty.battleMembers()[x].isStateAffected(9)

this will check if the member is inside the party and continue normally.
if you have more members than 1, you can loop through

using the code: BattleManager.actor().actorId() which can cycle through
your battle members and give the state accordingly.
Alright, I went and tested it, and it works perfectly
Thanks a lot and also thanks @AquaEcho

​

@AquaEcho for HUDMaker, its better to check Battlemember instead of members.
as both works, battlemembers is specific for battle related 🙂

sometimes easier to loop through them for the actorId, so you dont have to loop
constanstly for each member you have ^^

but both can work, depending where you need it ^^

@Gatox443 glad we could help, good luck with your project.

Original thread: https://forums.rpgmakerweb.com/threads/srnd-hud-maker-issue.167803/