JavaScript Custom Plugin Error Need Help Fixing

I have an issue when I changed battlers during "Battle Test" using a combination of plugins. I used to not have this issue when I didn't use DragonBones battlers. I do use custom interface and plugins, but I could use some help figuring the issue out. If you're willing to help me, please let me know.

The issue I get is "Damage of Undefined". However, when I move the battler from slot 4 to slot 1, there is no issue, and again, in my old version, I did not have this issue. I did not update the game or anything. Here is the error. If it is a major issue, and not something silly, I can pay.

When I turn off "Custom Battle Results", the problem solve it's self, so I assume that is the issue and I have not tested it in game yet but will do that today.

1586271277868.png
It looks like slot 1 might be defined somewhere in the Custom Battle Results code at line 640 and when the battler is in another slot, slot 1 returns undefined and thus the typeerror. Could post or screenshot what's at line 640?

EDIT: why in the world did I assume so explicitly this was the issue

EDIT: COULD POST OR SCREENSHOT
1586273871127.png
Alright weird. I might have to find and look at the full plugin to understand better. When you say you move the battlers to different slots what do you mean specifically? How do you do that?
So, for some reason, when I move actor 3 to actor 1, it doesn't work. I get this error. When I move actor 4 to slot 1 it works. It's just strange. If you're able to work with me, I can pay if it's a complicated issue. Do you use discord? Usually the guy who works with me is really good about helping me out but I think he's sick right now.
@Solis are your plugins in the correct order of Yanfly? if not, it will gives error,
Check his website and re-order the plugin EXACLY given on his website.

if you have other plugins, make sure they are in the corect section as well.
This has nothing to do with your current error, but to prevent other problems you need to rename your folder.

Do you see all those %20 in your error messages? They are there because no browser can handle spaces in folder- or filenames. And that will cause other errors on deployment and a number of special situations.
So please rename your folder to follow networking rules (no spaces, latin letters only etc.)
Thank you so much - I checked my folders, but don't see any spaces haha. Also, is it just folders, or file names (like music) that I should check.
I checked my folders, but don't see any spaces
according to your screenshot above, your game folder is named:
"e:\Last Envoy - Path of Transference"
That name contains five spaces:
LastSPACEEnvoySPACE-SPACEPathSPACEofSPACETransference
rename it to
Last_Envoy-Path_of_Transference
or something like it. Underlines are allowed, spaces are not.

Anything replaced by %-number in any browser error message indicates a symbol that the browser can't handle natively. That counts for both folders and filenames, everything that needs to be loaded by a browser.
I still don't understand what you mean by moving the actors. I assume you mean in the formation menu in-game?

Let me postulate:
  1. the actorDamage() function's this-keyword likely refers to $gameParty
  2. $gameParty._actors[] is using zero-based numbering meaning formation index 1 is ._actors[0]
  3. would the author not know this it could result in an OBOE (off by one error)
  4. index 4 should be ._actor[3], but an OBOE could mean the function looks for ._actor[4] which is index 5 and that returns undefined
It's a wild guess, but because we're troubleshooting why not cut down the treetops a bit. If you change line 630 to
JavaScript:
let actor = this._actors[index - 1];
does that fix it or make it worse? :distrust:

If that doesn't do it you're welcome to pm me a link to the plugin and I can take a brief look at it to see what I can see. I like to help solve these problems on my free time for the benefit of the community and I'll do that for free... to an extent. The level it becomes a job it usually means I'm getting underpaid so you're of course welcome to pm me an offer but I won't do a gig for scraps 😎
Oh, dang. I didn't know that. @ ozubon, I'm def going to check. Thanks!

Original thread: https://forums.rpgmakerweb.com/threads/javascript-custom-plugin-error-need-help-fixing.119920/