Party Leader Changing

Hey guys! This has been brought up before here - http://www.rpgmakervxace.net/topic/7292-locking-a-leader-character-in-place-in-the-party/

However, this is more than a year old and no answer was brought. The problem is that whenever a new character is added, they then take the roll of party leader, no matter what. Things that have been tried:

  • Adding Actor 2, Removing Actor 1, Adding Actor 1
  • Removing Actor 1, Adding Actor 2, Adding Actor 1
  • Using Yanfly Party Engine to lock Actor 1 as party leader (Actor 1 gets unlocked, bumped down the queue then re-locked)
  • Using scripts in events to say things like $game_party.members[0] == $game_actors[1]
This is really frustrating and the first time I've ever encountered this problem. Does anyone know of any solution?

Also, before this is suggested, I have made the 392 and 402 line change in Yanfly's Party Engine script.
Hey guys! This has been brought up before here - http://www.rpgmakervxace.net/topic/7292-locking-a-leader-character-in-place-in-the-party/

However, this is more than a year old and no answer was brought. The problem is that whenever a new character is added, they then take the roll of party leader, no matter what. Things that have been tried:

  • Adding Actor 2, Removing Actor 1, Adding Actor 1
  • Removing Actor 1, Adding Actor 2, Adding Actor 1
  • Using Yanfly Party Engine to lock Actor 1 as party leader (Actor 1 gets unlocked, bumped down the queue then re-locked)
  • Using scripts in events to say things like $game_party.members[0] == $game_actors[1]
This is really frustrating and the first time I've ever encountered this problem. Does anyone know of any solution?

Also, before this is suggested, I have made the 392 and 402 line change in Yanfly's Party Engine script.
Just press Esc Then change their formation

Then put the actor you want to be the party leader in the first spot
First (and that is the same as in the linked topic in the other forum) you need to find the reason why the last added member becomes the leader.


Because in default, the last added member becomes the last member of the party, NOT the leader.


So you have a script added that changes that behaviour - remove all scripts until the last added member stays the last member, then check if that remains if the last deactivated script is the only one deactivated or if it's an incompatibility between several scripts.


After you've found the script that replaces the leader with the last added member, then we can help looking how to correct that script back into proper behaviour.
First (and that is the same as in the linked topic in the other forum) you need to find the reason why the last added member becomes the leader.

Because in default, the last added member becomes the last member of the party, NOT the leader.

So you have a script added that changes that behaviour - remove all scripts until the last added member stays the last member, then check if that remains if the last deactivated script is the only one deactivated or if it's an incompatibility between several scripts.

After you've found the script that replaces the leader with the last added member, then we can help looking how to correct that script back into proper behaviour.
Or he can just use my method Instead of removing Scripts
Or he can just use my method Instead of removing Scripts
But that means the eventual player will have to do that each time, which seems a bit unprofessional to me.  The player shouldn't have to do something because a script is malfunctioning, so I think it's better to find the reason for the error and deal with it.
Or he can just use my method Instead of removing Scripts
No, because that is something only the player can do - if the developer requires an actor to be in the first slot for story reasons, then your methods doesn't work because then the player needs to be forbidden to be able to change formation.
First (and that is the same as in the linked topic in the other forum) you need to find the reason why the last added member becomes the leader.

Because in default, the last added member becomes the last member of the party, NOT the leader.

So you have a script added that changes that behaviour - remove all scripts until the last added member stays the last member, then check if that remains if the last deactivated script is the only one deactivated or if it's an incompatibility between several scripts.

After you've found the script that replaces the leader with the last added member, then we can help looking how to correct that script back into proper behaviour.
Good call! I never thought of that. I got rid of Yanfly's Party System and it works fine now. It's strange though because in another game I was making, if I added a member he went to the back of the party, not the leader. I copied and pasted that script directly from that previous game into this one.
Good call! I never thought of that. I got rid of Yanfly's Party System and it works fine now. It's strange though because in another game I was making, if I added a member he went to the back of the party, not the leader. I copied and pasted that script directly from that previous game into this one.
Then it's probably not because of a single script, but because of a combination of scripts.
Yanfly's scripts are relatively bug-free (one of the reasons why a lot of people use them), and I don't think that this effect was made by the party system alone (haven't tested it). Most probably it happens because another script effect was mixed up in the party system - that's why I suggested continuing seeking that other skript and only then decide which one to correct or ditch.
Then it's probably not because of a single script, but because of a combination of scripts.

Yanfly's scripts are relatively bug-free (one of the reasons why a lot of people use them), and I don't think that this effect was made by the party system alone (haven't tested it). Most probably it happens because another script effect was mixed up in the party system - that's why I suggested continuing seeking that other skript and only then decide which one to correct or ditch.
I've been through all of my scripts and removed them, none of the others seem to be causing the issue. The other thing is that at the moment, I only have Yanfly scripts installed. I'm planning on adding more later, but right now, there's only a few and they're all his.
I use Yanfly's Party System script without this problem, and it's in conjunction with a lot of other scripts, so if you have not modified the script in any way, that, imo, cannot be the root cause of what's happening.
I use Yanfly's Party System script without this problem, and it's in conjunction with a lot of other scripts, so if you have not modified the script in any way, that, imo, cannot be the root cause of what's happening.
Nope, not modded at all. Like I said, I've used this exact version of the script in another game and it's worked perfectly fine. I have no idea what's wrong now
Hey I just had this same problem and I realize this is 4 years late and you may have very well solved this and had the same "oh my god i am so dumb" revelation that I did, but the problem was that I added a char and removed the first actor assuming that actor 2 would take lead position but they were actually still occupying slot 2, so when another actor is added - they would take lead. Solution was to swap removing and adding.
Necro-post notice: Member

Not only do you know that this is 4 years old, and therefore the OP is unlikely to be still searching for an answer, but the OP hasn't been on the site for over 3 years so will not see your post anyway.

Original thread: https://forums.rpgmakerweb.com/threads/party-leader-changing.21981/