I'm putting together a battle UI and for visual clarity, it'd be good to be able to indicate on the UI which target is being hovered while selecting the targets of an ability. I know that Yanfly already has a battle select cursor plugin, but ideally I'd like to be able to apply a cursor to a UI element rather than the battler itself as is the case in Yanfly's plugin.
I've been looking through the MV library but I just cannot find anything that corresponds to this function. Does anyone know what it might be, or if there's a better way to do this?
Thanks kindly for your time!
yes and no - it completely depends on how that UI is designed.
The target selector needed is basically the index of the enemy in the troop.
Unfortunately for you the position of any enemy is variable, you can drag the picture around in the editor on the troop screen. And by default the enemy pictures can overlap in any form you want.
To go back from a position on the screen toward identifying the index of an enemy in the troop would at first require you to not have enemy pictures overlap - otherwise you will never be able to differ between two enemies at the same position.
So if you reprogram the entire battlescreen to ignore the placement info from the editor and distribute the enemy pictures in a way you know it, then you can use position checks on your own UI to identify the index needed for the targeting.
But that will require both the UI and the pictures of the enemies to be designed in a way to handle that - for example it is almost impossible to prevent overlap if the enemy picture is too big.
Specifically I'd like to have small pictures at a fixed position on the screen representing each enemy with their health bar attached and with a floating cursor pointing to them that appears when they're selected. Would I still run into these issues with this set-up, given that the representative pictures of the enemies wouldn't move around?