Yami's Order Gauge and Halfway Appear Enemies

So I'm using Yami's PCTB battle system with the Order Gauge AddOn, which is part of Yanfly's Ace Battle system.

The related scripts are:

Order Gauge

PCTB

Yanfly Ace Battle

However, if I have an enemy set to halfway appear, they still show up in the order gauge. Their turn gets skipped if they're set to halfway appear, but it makes it look as if an enemy is going to have a turn when they don't, and also kind of ruins the surprise that there's an enemy that hasn't appeared yet.

For example, I have an enemy troop with 5 halfway appear enemies that slowly appear over the course of the battle if you don't kill the ones currently appeared quick enough. However, when only one is alive, it looks like 5-6 enemies have a turn coming up. Then the gauge suddenly skips forward about 5 or 6 places. It's very jarring.

Does anyone have any ideas on how I could set the order gauge to not display enemies who are set to halfway appear that have not appeared yet?
no, I can't give you the script modification myself, because I don't know enough about that to write it.


however, the principle is very easy - the script already contains options to show (or not to show) an actor/enemy in the gauge if it is dead.


So the best way would be to add one more switch similiar to the "show dead", only name it "show hidden", and then add the code where the script decides to show dead battler's icons so that it will also check for "hidden" enemies and only show them if they are not hidden.
It looks like there are already some lines for hidden battlers in the order gauge script, but I can't quite figure out what they're doing.

if @battler.hidden? || (!@show_dead && @battler.dead?)      self.opacity -= 20    end
I think this means, for example, that if the battler is set to hidden or they're dead and the @show_dead switch is set to false, that their icon is supposed to lose 20 opacity - but the hidden enemies have a 100% opaque icon. Even if I change the 20 to 100 (subtracting it to 0 opacity) or 0 (just to see what happens), nothing changes.

for member in array      next if member.hidden?      result.push(member) unless member.dead?      action.delete(member) if member.dead? and !@show_dead    end    if @show_dead      for member in array        next if member.hidden?        result.push(member) if member.dead?      end    end
So I see here that, I think, there's a check to see if the battler is dead. If it is, they're deleted from the order gauge with the call action.delete(member) - unless the switch to show_dead is on, in which case it just moves their icon along the gauge. So I think if I try to repeat the code, but for hidden enemies, it will delete them from the gauge entirely - such that they won't properly show up when they're no longer hidden, right?

I mean, I do want them deleted from the gauge, but then I'm not sure how I could make them reappear once member.hidden is no longer true. And if they're deleted from the gauge, would they no longer be subject to the result.push command? If that's the case, then the turn order would be wrong once they did appear.
it would depend on when the member array is filled with data - if it's done only at the start of combat, then the deletion would be permanend and it would be the wrong way to go.


If the array is taken every combat turn, then you can delete hidden enemies because their data would be restored next turn.


Another way would be to make the hidden enemy's icon completely transparent in the first code part - but then that would still be seen as an empty place, you would only hide what enemy there is, not it's existence itself...
Can you post a different link to Yami's Order Gauge Script and Resources? The link you provided goes to a site with dead links.
I believe Yami has discontinued support for the CTB script and Order Gauge, in order to focus more on Symphony (I think?). If they are not available at Yami's website, I'm not sure where else you can get them.
I was hoping someone else might have them uploaded to google drive or something like that and was willing to share.

Original thread: https://forums.rpgmakerweb.com/threads/yamis-order-gauge-and-halfway-appear-enemies.26252/