Attack enemy cursor is hovering over?

The title's probably a little bit confusing so allow me to explain what I'm trying to accomplish:
The combat system for my game, ideally, is real-time combat where the player clicks on the enemy they want to attack. Combining YEA's CATB and Vlue's basic mouse system has gotten me pretty close to what I envisioned, but clicking on an enemy does not actually target them, it simply brings up the combat menu as if the player were hitting enter as normal. Is there a way to detect when the player's cursor is over an enemy's graphic and skip straight to attacking that enemy, over the normal selection system?
I have moved this thread from RPG Maker VXAce Support to RGSSx Script Support.
theoretically yes, but only if the battlesystem supports that function.

VXA has no default mouse control, which means every function you want a mouse to have has to be added by scripts. and since the script you're using is called "basic" it probably means that it doesn't support advanced functions like mouse targeting.

If you provide links to the websites of those scripts we can check, but most likely you'll need to find a different mouse script.
but clicking on an enemy does not actually target them, it simply brings up the combat menu as if the player were hitting enter as normal.
This part makes me confused. Hitting enter when the enemy is selected will set the action.
So I am unsure what your doing?
Can you make a demo for me to look at. And describe the steps that you want to happen vs what is happening.
theoretically yes, but only if the battlesystem supports that function.

VXA has no default mouse control, which means every function you want a mouse to have has to be added by scripts. and since the script you're using is called "basic" it probably means that it doesn't support advanced functions like mouse targeting.

If you provide links to the websites of those scripts we can check, but most likely you'll need to find a different mouse script.
You make a very good point! Here are the two scripts I have installed atm (along with YEA Ace Battle Engine to make the CATB script work)

YSA Battle System: Classical ATB

Basic Mouse System + Addons

I also tried Amaranth's Super Simple Mouse System but that doesn't seem particularly more suited to the task than Vlue's version. The main benefit I see with sticking with Vlue's is that it seems to store mouse position as a variable which seems at least half way to what I need. (Amaranth's might as well and I'm just not seeing it, I'm not the most code-literate person)

These were the only two VXA mouse scripts I could find. If there is a better suited one I'll be happy to switch to it but I'm operating under the assumption that I'll more or less have to build my own script off the back of one of these two.

This part makes me confused. Hitting enter when the enemy is selected will set the action.
So I am unsure what your doing?
Can you make a demo for me to look at. And describe the steps that you want to happen vs what is happening.

My basic point is just that using the mouse in combat is effectively the same as using the keyboard which isn't what I wanted. Clicking anywhere on the screen simply advances combat the same way that hitting enter does in normal VXA. Hopefully this gets across how I want combat to work a little better.

Flowchart.png


I did export the game project but I don't know if just lobbing the EXE up here is allowed. I don't think you'll gleam much extra from it anyway, all I've done so far is install the above scripts and make a tiny test map.


EDIT: Reading up on Ruby and other VXA scripts, I'm thinking that the most robust way to do this would be to add an event to each troop that essentially defines hitboxes via rects (or however buttons like the ones in the command menu are defined), with the event activating the attack command upon it detecting a left click within that rect. Trying to pull everything together now, but coding makes my brain hurt.
EDIT 2: There is a way within basic mouse system to check that the cursor is within a rect and if the left click is being clicked, which im hoping I can then route to force action to make the player attack. I just don't know how to actually define the rect lmao
EDIT 3: I'm a bit lost on how scripts within events work. I would like the script that checks that the mouse is within the rect and that the left click is pressed to activate that force action command but I don't know how to actually call it.
My basic point is just that using the mouse in combat is effectively the same as using the keyboard which isn't what I wanted. Clicking anywhere on the screen simply advances combat the same way that hitting enter does in normal VXA. Hopefully this gets across how I want combat to work a little better.
That looks like essentially bypassing the skill command. How would you select skills instead of attack if you want the enemy window to be active?
Normally you would click the command then the enemy.
You seem to want an interactive battle system. When hovering over attack it will be selected, if hovering over special it will bring up the skill menu.
This will take a lot of work to figure out, unless someone knows a system that can do this.

The mouse systems I know of are
Amaranth mouse
Vlue mouse
Woratana Mouse
DerWulfman mouse input
Jet10985 mouse
That looks like essentially bypassing the skill command. How would you select skills instead of attack if you want the enemy window to be active?
Normally you would click the command then the enemy.
You seem to want an interactive battle system. When hovering over attack it will be selected, if hovering over special it will bring up the skill menu.
This will take a lot of work to figure out, unless someone knows a system that can do this.

The mouse systems I know of are
Amaranth mouse
Vlue mouse
Woratana Mouse
DerWulfman mouse input
Jet10985 mouse
There most likely won't be skills in this system. I'll have a look at the other mouse systems you mentioned, I had only found the first 2 in my googling.

Original thread: https://forums.rpgmakerweb.com/threads/attack-enemy-cursor-is-hovering-over.162484/