MZ Trying to do an summoning system, failing at it. I need help.

SO, I am trying to make my summoner to summon (duh), and it is really hard to make.
I was using scripts to do so, also with a plugin (Visustella Party System).
The script goes like this: BattleManager.setEventCallback(function(result) {if (result === 0, 1) $gameParty.removeActor(0010);});

This is the script I use to make my summoning go away if the battle ends.
There is no way it works the way I want. So... could someone please help me?

This is the common event I use to summon.

1726072612267.png


Thanks a lot.
Welcome!

For future reference, it's more helpful if you post your screenshots in English. In Steam, you can right-click MZ in your library, select Properties, and change the language drop-down to English. That will let us more easily read the event commands.

I think adding an event callback via code like that is not a great way to do this.

VisuStella has built right into the Battle Core plugin parameters a common event you can call at the end of every battle, so I would just put the regular Change Party Member event command in there. (or use whatever plugin commands you need)

As far as your code, it has incorrect syntax - you never put leading zeros in an ID. It would just be
Code:
$gameParty.removeActor(10)
Thanks a lot! I appreciate this.
I have 0 skills at coding, so I did not knew about all the zeros were wrong.
So, I will try what you say and I will say something about it.
Really appreciated your help. Thank you 🙂

Welcome!

For future reference, it's more helpful if you post your screenshots in English. In Steam, you can right-click MZ in your library, select Properties, and change the language drop-down to English. That will let us more easily read the event commands.

I think adding an event callback via code like that is not a great way to do this.

VisuStella has built right into the Battle Core plugin parameters a common event you can call at the end of every battle, so I would just put the regular Change Party Member event command in there. (or use whatever plugin commands you need)

As far as your code, it has incorrect syntax - you never put leading zeros in an ID. It would just be
Code:
$gameParty.removeActor(10)
So, I did what you told me, and it worked 100%.
Thanks a lot, you saved my life 🙂

Original thread: https://forums.rpgmakerweb.com/threads/trying-to-do-an-summoning-system-failing-at-it-i-need-help.171835/