Refresh State Icons in Battle

Is there a way to refresh the state/buff icons in the battle status window?

I overwrote the Window_BattleStatus "draw_item" method and am redrawing icons using "draw_actor_icons(...)"

but it's drawing duplicate icons on top of others. I'm looking for a "clear" method that doesn't clear the entire battle status window (due to performance issues) but only clears the icons.
should be able to with the following

clear_rect(x, y, width, height)

it's in the bitmap class in the help file 🙂
I've moved this thread to RGSSx Script Support. Please be sure to post your threads in the correct forum next time. Thank you.
why not just refresh the status window itself?
You pretty much can't.


Once a bitmap is blt'd onto another bitmap, those pixels are pretty much stuck.


Which means you might want to consider separating the icons into their own sprites or something.
You can clear a rect of a bitmap and then draw something else over it.
why not just refresh the status window itself?
My problem was that redrawing the whole battle status window caused a huge lag spike. Turns out I had the refresh call inside a loop which was being done for every battler.

So yeah just a dumb bug on my part. There's no huge lag now on each turn end.

Thanks guys!
This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.

Original thread: https://forums.rpgmakerweb.com/threads/refresh-state-icons-in-battle.25514/