Need help with Party Changing System by Leon_Westbrooke

I've been running into an issue with the script. There's a script call I can, in theory, use to put a party member into reserve.
I say in theory as I can't seem to get it to work.
Whenever I try to use it, I get the error message: ArgumentError occurred while running script. wrong number of arguments (0 for 1)
The call is $game_party.remove_actor_to_party(actor_id)

The part of the script I think is in question is this:

Code:
#==================================================
#  Game_Party
#==================================================
class Game_Party

  attr_accessor :party_members
  attr_accessor :move
  attr_accessor :locked
  attr_accessor :min_size
  attr_accessor :max_size
 
  alias leon_partyswitch_gameactor_initialize initialize

  def initialize
    leon_partyswitch_gameactor_initialize
    @party_members = []
    #  Edit :This is to change if an actor is locked or not. To lock them, add
    #        their id to the array below.
    @locked = []
    @min_size = 1
    @max_size = 4
  end
 
 
  def add_actor(actor_id)
    actor = $game_actors[actor_id]
    if @actors.size < @max_size
      unless @actors.include?(actor)
        unless @party_members.include?(actor.id)
          @actors.push(actor)
          $game_player.refresh
        end
      end
    else
      unless @party_members.include?(actor.id)
        unless @actors.include?(actor)
          @party_members.push(actor.id)
          $game_player.refresh
        end
      end
    end
  end
 
  def remove_actor(actor_id)
    @actors.delete($game_actors[actor_id])
    @party_members.delete(actor_id)
    $game_player.refresh
  end
 
  def remove_actor_from_party(actor_id)
    if @actors.include?($game_actors[actor_id])
      unless @party_members.include?(actor_id)
        @party_members.push(actor_id)
        @party_members.sort!
      end
    end
      @actors.delete($game_actors[actor_id])
    $game_player.refresh
  end

  def add_actor_to_party(actor_id)
    if @party_members.include?(actor_id)
      if @actors[@max_size - 1] != nil
        @party_members.push(@actors[@max_size - 1].id)
        @actors.delete_at(@max_size - 1)
      end
      @actors.push($game_actors[actor_id])
      @party_members.delete(actor_id)
    end
  end
end
#==================================================
#  END Game_Party
#==================================================

...I don't know what's wrong. All I am doing is replacing actor_id in the script call with a number (in the case of my testing, it was actor 26)
I don't know what I'm doing wrong (or if there's an error in the script as this is like trying to read... a language using an alphabet that isn't of that language) so... um...
Help, please?
Edit: Also, this is not the entire script. I'm just posting what seems to be connected with my issue.
Could you please edit your post to include a link to the web page where you got the script. That way, if anyone needs to check something before offering a suggestion, they don't have to go hunting.
Thanks.
The call is $game_party.remove_actor_to_party(actor_id)
You mean $game_party.remove_actor_from_party(actor_id)
This does not put a member into reserve, from what I can see, it should remove them, like they were never in your party.
Edit: Also, this is not the entire script. I'm just posting what seems to be connected with my issue.
You were asked to post a link to the script, not to what you think is the problem.
Help, please?
We are trying, but it is difficult. We really need that script to see what it is suppose to do.
Is this a script that was commissioned for you? if not then tell us what the script is and where to get it.
Thanks
😳 Kinda curious where you found that myself. It doesn't exist in Creation Asylum where Leon posted many of his other works.
Apologies. Here is the link: https://www.gdunlimited.net/forums/index.php/topic/8413-party-changing-system/
Fixed. At least for me.
The problem I found is that the command window for script input (event command) is too short.
When entering in the phrase $game_party.remove_actor_from_party(2) ( not remove_actor_to_party <- typo)
it would give the error you are receiving as the line for this text is too long and the number would fall down to the next line.
Like this
$game_party.remove_actor_from_party
(2)

I fixed it by changing the script def name.
Line 96 def remov_actor_from_party(actor_id)
I remove the e in remove. This shorten it enough to allow the value to exist on the same line as the rest of the code.
I imagine that if you were to use 10 or more characters you would have to shorten it another character.

Second is
Line 472 $game_party.remov_actor_from_party($game_party.actors[@slot_window.index].id)
Again removed the e in remove.

then the script worked correctly.

I suppose you could use
$game_party.move_actor_from_party(actor_id)

Then that would give you two characters to be safe.
Just so you know, line breaks are permitted after punctuation within scripts and script calls. It's quite valid to enter the original command as so:

$game_party.
remove_actor_from_party(2)

Now as to SPELLING and bugs like that... OOPS?
Thanks for the help. Putting a break after the period fixed it.(as did the shortening it in the script, but I found putting a line break after the period easier).

Original thread: https://forums.rpgmakerweb.com/threads/need-help-with-party-changing-system-by-leon_westbrooke.103990/