Party Member slot changing.

Discussion in 'RPG Maker 2000/2003' started by Capumonproject, Jun 15, 2019.

  1. Capumonproject

    Capumonproject Warper Member

    Messages:
    1
    Likes Received:
    0
    First Language:
    English
    Primarily Uses:
    RM2k3
    I am making a Pokémon Game, everything is going well so far, however when I got to the catching mechanic, I ran into a problem. When I catch a new Pokémon (party full) how do I switch the new Pokémon with another in party member?
    The only option RM2K3 is giving me is the one you choose a character by name to remove and add a new one, however I just want to release a member from the party without having to choose a character in specific, I just want to select the Slot, in order to keep the new one I caught.
    Can someone help me?
     
    Last edited: Jun 15, 2019
    #1
  2. Thanatos

    Thanatos Crixus Veteran

    Messages:
    36
    Likes Received:
    10
    Location:
    YggBrasil
    First Language:
    Portuguese
    Primarily Uses:
    N/A
    There is no way to help you, since you have made a simulated capture system.
    This method only knows why you created it.

    If I did, I would create a map-menu by events, and the protagonist 0002 to 0200 would be pokemons, all blank.
    When capturing a monster you would get characteristics to the next "Hero" using an event counter.
    To give a name it would be enough to use the same event that attributes the characteristics of the monster to "Hero".
     
    #2
  3. BitBrosGames

    BitBrosGames *Keeps ruminating* Veteran

    Messages:
    80
    Likes Received:
    47
    Location:
    Somewhere in the Round Globy World.
    First Language:
    Spanish
    Primarily Uses:
    RM2k3
    You can add and remove a character for your party by using the ID of the hero according to the database.
    You could have, for example, an array of variables where the first four (or six, depending on the length of your team) have the ID of the ones which are currently in the party and the following, would have the IDs of the reserve pokémon in the order they appear on the list.
    When you catch a new pokémon, add 1 to a variable with the number of pokémon you have so far, get that value and modify the hero in that slot giving it the stats, name, graphic and more of the new pokémon (you just need to do this once for each new pokémon).
    That way, if you want to switch a pokémon with another, you just need to check the ID of the pokémon in the slot you want to release, and then add the ID of the pokémon you want on the team, and of course, modify the values of the variables with the order of the pokémon so it can be consistent.

    For example, you have 20 pokémon, and you have D, L, C and A on the team, with IDs 4, 12, 3 and 1 respectively.

    Pkm1: 4
    Pkm2: 12
    Pkm3: 3
    Pkm4: 1
    ---out of the party---
    Pkm5: 5
    Pkm6: 2
    ...
    Pkm20: 20
    Pkm21: 0
    ...
    No.Pkm: 20

    When you catch a new pokémon, U, add 1 to No.Pkm (=21), and modify hero no. 21 with the stats of U.
    Also set Pkm21 to 21 (the slot where U is stored).
    If position variables start at, for example, number 100 on the list of variables of your game, just use 100 + 21 as the variable reference in Control Variables to identify the variable you want to modify and set the new value.


    Pkm1:
    4
    Pkm2: 12
    Pkm3: 3
    Pkm4: 1
    ---out of the party---
    Pkm5: 5
    Pkm6: 2
    ...
    Pkm20: 20
    Pkm21: 21
    Pkm22: 0
    ...
    No.Pkm: 21

    Then in order to switch members, show the list to the player so they can choose.
    If the player decided to switch A (#4) with U (#21), use the ID stored in Pkm4 to remove A and add the ID stored in Pkm21 to put U into the party. Then switch the values of Pkm4 and Pkm21 for consistency:

    Pkm1: 4
    Pkm2: 12
    Pkm3: 3
    Pkm4: 21
    ---out of the party---
    Pkm5: 5
    Pkm6: 2
    ...
    Pkm20: 20
    Pkm21: 1
    Pkm22: 0
    ...
    No.Pkm: 21

    And that's all. :D
     
    #3

Share This Page