Failed to execute "createLinearGradient" on "CanvasRenderingContext2D: the provided double value is non finite error whenever enemy uses skill.

This thing is giving me a headache since trying to make this skill work is taking way longer than it should be.
So a while ago i asked how i could make the Level 5 Death skill from Final Fantasy. (short explination for skill: if target's level is a multiple of 5, they die.)



I have the skill set up like this Screenshot (143).png
But in battle, when the enemy uses the skill on the party, i get this error screen.Screenshot (144).png
Is there any reason as to why this is happening?
Try putting 0 in the damage formula box.

By default RMMV returns 0 for non-numerical formula results, but some plugins (e.g. YEP Damage Core) remove that safety check. If the end result is not a number, that will make the target's HP/MP not a number, which causes this error when the game tries to redraw the corresponding gauge.
Try putting 0 in the damage formula box.

By default RMMV returns 0 for non-numerical formula results, but some plugins (e.g. YEP Damage Core) remove that safety check. If the end result is not a number, that will make the target's HP/MP not a number, which causes this error when the game tries to redraw the corresponding gauge.
Tried it and the skill doesn't cause an error but doesn't kill the actor whose level 15.
I just tested with only YEP Skill Core active (v1.13) and that notetag works for me: an actor target dies instantly at levels 5 and 15, but only receives normal damage at level 1.

Yanfly's plugins should be loaded in the order listed on their site:
You can click+drag to rearrange the order. Remember to save your project to apply Plugin Manager changes before testing.

Maybe share screenshot(s) of your Plugin Manager so people can see all the plugins you are using.
YEP plugins are known for strange behaviour in the wrong order and
has 1 strict order to follow, either by his website or by the plugin in
my spoiler for the YEP order checker (same as website), so you
can re-arrange them correctly.
I just tested with only YEP Skill Core active (v1.13) and that notetag works for me: an actor target dies instantly at levels 5 and 15, but only receives normal damage at level 1.

Yanfly's plugins should be loaded in the order listed on their site:
You can click+drag to rearrange the order. Remember to save your project to apply Plugin Manager changes before testing.

Maybe share screenshot(s) of your Plugin Manager so people can see all the plugins you are using.
Screenshot (97).png
Here it is
Just for fun...it's possible that Incapacitate State changes something with the behavior of the default death state.

Try turning that off and testing.
Just for fun...it's possible that Incapacitate State changes something with the behavior of the default death state.

Try turning that off and testing.
Tried it and nothing happened.

Honestly i might just give up on this skill...
Did you remember to save to apply Plugin Manager changes before testing?

A couple more ideas:
  1. Give the skill an Add State: Death effect, see if that works.

  2. Turn off all plugins except Skill Core, save your project, then test. If a level 5 actor still refuses to die instantly when hit by the skill, then check for a "State Resist: Death" trait. It might be on the actor, or their class, or their equipment, or a state.
Honestly i might just give up on this skill...
I understand feeling frustrated when something doesn't work.

The problem with giving up is that if something isn't working correctly, for all you know it's affecting another skill or it will affect in the future something else you want to do.

It makes more sense to figure out the actual reason, even if that means you leave it on your list but work on other parts of your game for a few days until you feel better.

Are you testing in an actual play test where you're selecting New Game? Using the Battle Test from the editor won't work reliably when you start introducing plugins and notetags.
I understand feeling frustrated when something doesn't work.

The problem with giving up is that if something isn't working correctly, for all you know it's affecting another skill or it will affect in the future something else you want to do.

It makes more sense to figure out the actual reason, even if that means you leave it on your list but work on other parts of your game for a few days until you feel better.

Are you testing in an actual play test where you're selecting New Game? Using the Battle Test from the editor won't work reliably when you start introducing plugins and notetags.
Tried it both in game and in battle test, still won't work.

Original thread: https://forums.rpgmakerweb.com/threads/failed-to-execute-createlineargradient-on-canvasrenderingcontext2d-the-provided-double-value-is-non-finite-error-whenever-enemy-uses-skill.153145/