MZ Using Fossil with Battle Core, an error occurs when enemy attacks in first person view, but not in side view.

I use Fossil 1.9 (the modified version), BattleCore and Damage Core. My code is this:

<damage formula>
var armourClass = target.atk;
var diceRoll = Math.randomInt(20) + 1 + user.def;
if diceRoll >= armourClass {value = (Math.randomInt(8) + 1 + user.mat);
} else {
value = 0;
}
</damage formula>

The error im getting is: this._damagePopup.push, which seems to be the engine trying to make a popup happen on the actor, but as it is in first person mode, it doesn't display and it crashes. It is resolved in Side battle
I use Fossil 1.9 (the modified version), BattleCore and Damage Core. My code is this:
to be certain, Yanfly's Battle Engine Core and Damage Core, or Visustella Battle core and Yanfly Damage core?

please press f12 when the crash happens and show the error trace from the console tab of the devtools window. You didnt say what specific error you got from that (assuming a "not a function" error?) or which plugin its from, (assuming its the battle engine core, but may not be the only plugin you have that interacts with plugins) but both would be shown in a trace.

I use Fossil 1.9 (the modified version), BattleCore and Damage Core. My code is this:
is the damage core relevant to this crash? lines containing this._damagePopup.push can be found in yanfly's battle engine core, but not the damage core.

does the crash only happen with this skill, or all skills? your notetag does have an error in it and is missing parenthesis around the IF condition assuming the forum formatting didnt alter it. use
Code:
 [CODE] tags or the code tool in the toolbar above the textbox to avoid that in the future if thats the case.
to be certain, Yanfly's Battle Engine Core and Damage Core, or Visustella Battle core and Yanfly Damage core?

please press f12 when the crash happens and show the error trace from the console tab of the devtools window. You didnt say what specific error you got from that (assuming a "not a function" error?) or which plugin its from, (assuming its the battle engine core, but may not be the only plugin you have that interacts with plugins) but both would be shown in a trace.


is the damage core relevant to this crash? lines containing this._damagePopup.push can be found in yanfly's battle engine core, but not the damage core.

does the crash only happen with this skill, or all skills? your notetag does have an error in it and is missing parenthesis around the IF condition assuming the forum formatting didnt alter it. use
Code:
 [CODE] tags or the code tool in the toolbar above the textbox to avoid that in the future if thats the case.
I am using Yanflys, the console showed me this:

rmmz_managers.js:2080 TypeError: this._damagePopup.push is not a function at Game_Actor.Game_Battler.startDamagePopup (YEP_BattleEngineCore.js:3789) at Game_Action.apply (YEP_BattleEngineCore.js:3515) at Function.BattleManager.invokeNormalAction (rmmz_managers.js:2832) at Function.BattleManager.invokeAction (YEP_BattleEngineCore.js:2098) at Function.<anonymous> (YEP_BattleEngineCore.js:2712) at Array.forEach (<anonymous>) at Function.BattleManager.actionActionEffect (YEP_BattleEngineCore.js:2709) at Function.BattleManager.processActionSequence (YEP_BattleEngineCore.js:2303) at Function.BattleManager.processActionSequence (YEP_DamageCore.js:1007) at Function.BattleManager.processActionSequenceCheck (YEP_BattleEngineCore.js:2285)SceneManager.catchNormalError @ rmmz_managers.js:2080

it works fine in side battle mode for me, but i did fix the If statement and it didnt change
the console showed me this:
in the future, share it as a screenshot so that the organization can be kept

it works fine in side battle mode for me, but i did fix the If statement and it didnt change
normally id say stick a if (!this._damagePopup) this.clearDamagePopup(); at the start of startDamagePopup inside the battle engine core, but since popups arent supposed to happen to actors in front view anyways, you could try emptying out the function for them.
Code:
Game_Actor.prototype.startDamagePopup = function() {};
in the future, share it as a screenshot so that the organization can be kept


normally id say stick a if (!this._damagePopup) this.clearDamagePopup(); at the start of startDamagePopup inside the battle engine core, but since popups arent supposed to happen to actors in front view anyways, you could try emptying out the function for them.
Code:
Game_Actor.prototype.startDamagePopup = function() {};

Ive been searching inside battle engine and I cannot find .startDamagePopup at all. The script calls for it but its not in the file

Here is the image
Ive been searching inside battle engine and I cannot find .startDamagePopup at all. The script calls for it but its not in the file
it starts on line 3778, but i should have been clearer. what i gave you is meant to overwrite what the actor's version of it is since their version is just what they inherit from the battler version. take what i gave and save it in a .js file to make it its own plugin and keep track of that change being made
it starts on line 3778, but i should have been clearer. what i gave you is meant to overwrite what the actor's version of it is since their version is just what they inherit from the battler version. take what i gave and save it in a .js file to make it its own plugin and keep track of that change being made
you beautiful person this has worked <3

Original thread: https://forums.rpgmakerweb.com/threads/using-fossil-with-battle-core-an-error-occurs-when-enemy-attacks-in-first-person-view-but-not-in-side-view.180455/