[MV] Olivia Octobattle Randomly crash

Hi again,

Sorry for beeing such a noob in JS...

Recently I have random crashes when I start fights.
It seems to be the 'push' property who is undefined, I take the JS to find the lines were 'push' is defined but I don't find what cause the crashes...

Sometimes it doesn't crash at all and sometimes that happens directly in the first fight, it's so random that i can't find the cause...
Nether the same ennemy, nether the same map. I would really appreciate some support thanks.

Sans titre.png
are the YEP plugins in order? are the notetags correctly (no typo's)?
are the condition placed correctly?

if it's all correct, did you take a look at the sample project that comes with octobattle?
and see how its setup there? does the same thing happen?
Hi thanks for your answer.

I litteraly take the octobattle sample project and create my game in this project. So it cannot be different.
I'll check that more in detail it's a first track
well, I put the octobattle plug in, way in the botton and it's happenned once again.
I think I see the problem. You have the separate plugins together with the all-in-one plugin (bottom). The redundancies are clashing.

Open up the help window on the bottom plugin and you'll see the plugins you need to take out from above.
Hi, I'm back.

There's an issue to my problem.

Shadowdragon was totally right.

I have the all-in-one plugin but the function createNewSprites wasn't called on begin of battle.
So when my hero (who's fast and can have a chance to act twice per turn) attack twice, it create a new sprite in the otb who make this crash.

So to fix it I had to call in begin of battle the function createNewSprites();

Scene_Battle.prototype.createOTBDisplayWindow = function() {
this._otbDisplayWindow = new Window_OTBDisplay(this._helpWindow);
this.addWindow(this._otbDisplayWindow);
// fix
this._otbDisplayWindow.createNewSprites();

};

Now it's works very well.
thanks to you two.

I've moved this thread to Javascript/Plugin Support. Thank you.


@Sektor , please avoid double posting, as it is against the forum rules. You can use the "Edit" function on your posts to add additional information you've forgotten or respond to multiple people. You can review our forum rules here. Thank you.

Hi, I'm back.

There's an issue to my problem.

Shadowdragon was totally right.

I have the all-in-one plugin but the function createNewSprites wasn't called on begin of battle.
So when my hero (who's fast and can have a chance to act twice per turn) attack twice, it create a new sprite in the otb who make this crash.

So to fix it I had to call in begin of battle the function createNewSprites();

Scene_Battle.prototype.createOTBDisplayWindow = function() {
this._otbDisplayWindow = new Window_OTBDisplay(this._helpWindow);
this.addWindow(this._otbDisplayWindow);
// fix
this._otbDisplayWindow.createNewSprites();

};

Now it's works very well.
thanks to you two.


Sorry to ask you, but where do you put those script in?
I have the same problem and I want to solve it..
Hi phiny,

i'm glad if i can help.

you need to find : Scene_Battle.prototype.createOTBDisplayWindow = function()

in the Olivia_OctoBattle.js, and replace ce function by my fix.

But it's not a fully fonctionnal solution, if you fix it like this in the first turn of your battle the littles sprites won't appear on the ATB, in current turn.

Now i know that the crash is caused by the chance of playing twice in a turn. My characters has 5% of playing another time, so when it trigger the ATB can't update the new sprite on the ATB and it crash.

I hope you can fix this bug, with my fix or with a better one. =)
Hi phiny,

i'm glad if i can help.

you need to find : Scene_Battle.prototype.createOTBDisplayWindow = function()

in the Olivia_OctoBattle.js, and replace ce function by my fix.

But it's not a fully fonctionnal solution, if you fix it like this in the first turn of your battle the littles sprites won't appear on the ATB, in current turn.

Now i know that the crash is caused by the chance of playing twice in a turn. My characters has 5% of playing another time, so when it trigger the ATB can't update the new sprite on the ATB and it crash.

I hope you can fix this bug, with my fix or with a better one. =)

uhm.. i guess the Olivia_OctoBattle.js is not Olivia_BattleSysOTB.js, which is what I have..

maybe I should get sampler project later.

anyway thank you so much for answering! 🙂
The OctoBattle is the complete set of plugins, whereas BattleSysOTB would be just one of the eight (I think) plugins that are included in the entirety of the OctoBattle.

I'm not 100% sure, but I think the quick fix that @Sektor is talking about should still be doable in the BattleSysOTB plugin as long as you find the right section @phiny
The OctoBattle is the complete set of plugins, whereas BattleSysOTB would be just one of the eight (I think) plugins that are included in the entirety of the OctoBattle.

I'm not 100% sure, but I think the quick fix that @Sektor is talking about should still be doable in the BattleSysOTB plugin as long as you find the right section @phiny

thanks for your answering!
I think I solved one, but then another came up like this,

Uncaught TypeError: Cannot read property 'setBattler' of null
at Scene_Battle.otbPostPartySwitch (Olivia_OctoBattle.js:8856)
at Scene_Battle.postPartySwitch (Olivia_OctoBattle.js:8850)
at Scene_Battle.processPartySwitching (YEP_X_ActorPartySwitch.js:598)


it occurs when I change my party member during battle 🙁

Original thread: https://forums.rpgmakerweb.com/threads/mv-olivia-octobattle-randomly-crash.121018/