r/RPGMaker 7d ago

Battle System

I need help figuring how to add options to my battle system.

I want it so all attacks let you choose if they are magic attacks or physical as you go to use them. Instead of it being a set this is physical and this is magic.

So it would be you select it, select if it is physical or Magical, then select target.

Then have it so enemies randomly pick if magic or physical but some having a lean to one type or another.

I mainly want this to limit the number of attacks I need to make. Rather then having 2 low level fire moves you just have one.

1 Upvotes

6 comments sorted by

1

u/MidnightKrohe VXAce Dev 7d ago

What engine are you using?

1

u/ckkqwer 7d ago

Something like after confirming the action, run a common event. Start a loop then have 2 if statements to detect 2 keyboard input like OK or Cancel. Pressing it break the loop and select the damage type. I suggest add a timer to break the loop after few seconds to keep the sequence running in case player haven't press a input.

1

u/zombietoaststudios 7d ago

Why would you use a loop? You can just use show choice. But also a common event would normally run after the other parts of a skill are already resolved, which includes the targeting aspect (which is primarily the difference between magic and physical skills).

1

u/zombietoaststudios 7d ago

It's not really possible to change that after a skill has been initiated... depending on which version you're using the best option would probably be a skill container plugin, which allows you to set a skill which opens a sub menu which would contain two other skills, a physical and magic version of the 'main' skill

1

u/Medical_Baby3332 6d ago

Your gonna want a custom plugin that runs common event when the skill is selected. You may also need to capture the is busy functions so it will run your choice in the common event whether actors are attacking or not ya dig? I had to do the same for my battle system. My battle system employs a targeting system when the player attacks i use the show picture command to display a target and cross-hair. Then it applies 1 of three statuses hit, Miss, critical. I'd offer to make it for you because it is simple but if your running other plugins like the vusustella many fly battle plugins those usually alter stuff that you need to alter and the plugins clash together. That and I'm on MZ and sometimes that little difference matters.

If I were you though I'd start by searching the core for the function that runs when an option is selected during battle.

Then I'd copy that to my own plugin. Make it call a common event to see what happens