// Call refresh on a newly joined $gameParty member
const Game_Party_AddActor = Game_Party.prototype.addActor;
Game_Party.prototype.addActor = function(actorId) {
Game_Party_AddActor.call(this, actorId);
this.refreshMembers();
};
// Reinhard Tristan Eugen Heydrich's Fix.
const Game_Party_removeActor = Game_Party.prototype.removeActor;
Game_Party.prototype.removeActor = function(actorId) {
Game_Party_removeActor.call(this, actorId);
this.refreshMembers();
this.ensureVariables();
};