Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Simulated battle between events.

Hey,

I'm setting up an alternative battle system for my project that pops up every so often. It uses events on the map to make it appear as if a battle is going on. The events move and attack each other with various animations, so on and so forth. Problem is, I keep running into mistakes with the battle algorithms, as well as using them properly. So, here is my request:

I'd like a script that can simulate an action from one target to another. That is an attack and any skill, and do the algorithm for me (because I'm tired of doing this in events over and over again) as if that target used that action on the 2nd, in a real random battle. That is, figuring out if the action is a hit or critical hit (changing one variable to 0 for a miss, 1 for a crit), as well as the damage/healing, and set it to a 2nd variable (damage = 50, variable is set to 50. Healing of 50, variable becomes -50).

I'd need to be able to in the call script simulate an attack from any actor (based on current level, stats, equipment, states) to any enemy or actor, and any enemy to any actor or enemy. As well as the same for skills, I guess using a call script and putting the skill ID, actor/enemy ID and notifier to show which, and then the target I suppose.

Thanks for reading, if this is too confusing lemme know.
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top