RPG Maker Forums

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.

Latest Threads

Latest Profile Posts

Our latest feature is an interview with... me?!

People4_2 (Capelet off and on) added!

Just beat the last of us 2 last night and starting jedi: fallen order right now, both use unreal engine & when I say i knew 80% of jedi's buttons right away because they were the same buttons as TLOU2 its ridiculous, even the same narrow hallway crawl and barely-made-it jump they do. Unreal Engine is just big budget RPG Maker the way they make games nearly identical at its core lol.
Can someone recommend some fun story-heavy RPGs to me? Coming up with good gameplay is a nightmare! I was thinking of making some gameplay platforming-based, but that doesn't work well in RPG form*. I also was thinking of removing battles, but that would be too much like OneShot. I don't even know how to make good puzzles!
one bad plugin combo later and one of my followers is moonwalking off the screen on his own... I didn't even more yet on the new map lol.

Forum statistics

Threads
106,034
Messages
1,018,447
Members
137,820
Latest member
georg09byron
Top