When i take damage in a battle the game crashes :/

So, i was testing my game Blonesis, and i entered in a battle, but when is took damage, the game crashed, and this message appeared


Script "Game_ActionResult" line 119: ArgumentError occurred


too few arguments


help me pls


(Also i dont talk english very well, so sorry if i have grammar error)
Does this happen only after you load a saved gamefile, or also after you start a new game?


Such errors are usually caused by adding a script and then either having that script not correctly configured, incompatible to another script or (most often) because you forgot to start a new game after installing the script as 80% of all scripts make old savefiles incompatible.


I've moved this thread to Script Support. Please be sure to post your threads in the correct forum next time. Thank you.


Tech-Support is for getting the editors to run.


I also suggest you follow the link "how to use a script" in my signature, it also includes bughunting advice on script problems. And if you can't find the cause yourself, we'll need a screenshot of the backtracer message (which contains more data than the default error messages)
in both occasions happen, also, i dont have any script for battling, only for menus :/
It doesn't matter what kind of script it is, it usually causes a lot of different but similiar errors.


If you can't find the error on your own, we need the backtracer console output as described in that tutorial I mentioned. We can't help you without that info.
i removed all the scripts, and i still get the error, im just going to start the game new again, thanks anyway
@blackak123 That will not help you in the long term, because you might get the same or similiar errors again.


Please follow the instructions in my tutorial "how to use a script" to install the backtracer script and give us a screenshot of its console output - that is absolutely vital for any bughunting in scripts, and you'll either need to learn how to do that or forget about using scripts at all.
Okey, i will, thanks 🙂
Don't think it's needed.  Here's line 119 of that script, and I've included the line above it too:

Code:
      fmt = @battler.actor? ? Vocab::ActorDamage : Vocab::EnemyDamage
      sprintf(fmt, @battler.name, @hp_damage)



And here is ActorDamage and EnemyDamage from the Vocab script:

Code:
  ActorDamage     = "%s took %s damage!"
  EnemyDamage     = "%s took %s damage!"

The error "too few arguments" means that you have changed one or both of those Vocab strings (if the error is when a party member takes damage, then it's the ActorDamage string, and if the error is when an enemy takes damage, it's the EnemyDamage string), and you've got an extra % in there, or maybe more.


Please look at your Vocab script, line 52, and see if ActorDamage is defined exactly as above.  If it is, then do a global search in your scripts using Control+Shift+F for ActorDamage and provide a screenshot of the result.  My scripts only contain two instances - one where it's defined, and one where it's used.  I'd expect yours to contain three or more, and two of them will be definitions.

Original thread: https://forums.rpgmakerweb.com/threads/when-i-take-damage-in-a-battle-the-game-crashes.72744/