NPC problem

Lifeh

Warper
Member
Joined
Sep 30, 2020
Messages
3
Reaction score
1
First Language
Italiano
Primarily Uses
RMVXA
Hi all, we are making an open world game, but we are having an issue with an NPC, the NPC should become a playable character after talking to him and follows the main character, but if we leave that part of the map and then come back the npc is there and makes the conversation start again, rather than disappearing.
Does anyone know how to fix this issue?
 

Aerosys

Veteran
Veteran
Joined
Apr 23, 2019
Messages
366
Reaction score
338
First Language
german
Primarily Uses
RMMZ
I think you are new to RPG Maker, right?

Let's look at your NPC / Event. You will see that every event can have multiple pages, and each page has its own conditions. The first page with passed conditions is chosen, starting from highest number.

So you can add a 2nd page, keep it blank, and set as condition that the NPC is in your party. So, when he is part of your party, the blank page is used, otherwise the first page.
 

Jennavieve

Veteran
Veteran
Joined
Oct 21, 2020
Messages
54
Reaction score
47
First Language
English
Primarily Uses
RMMZ
Probably the easiest way to do this is to have a switch turned on when the NPC joins your party, something like "NPC acquired." Then make a second page in the NPCs event pages that's blank (no image or processes whatsoever) and set it with the "NPC acquired" switch as a condition.
 

Lifeh

Warper
Member
Joined
Sep 30, 2020
Messages
3
Reaction score
1
First Language
Italiano
Primarily Uses
RMVXA
I think you are new to RPG Maker, right?

Let's look at your NPC / Event. You will see that every event can have multiple pages, and each page has its own conditions. The first page with passed conditions is chosen, starting from highest number.

So you can add a 2nd page, keep it blank, and set as condition that the NPC is in your party. So, when he is part of your party, the blank page is used, otherwise the first page.
Do I have to keep the 2nd page blank and put a switch on the first page or?
 

Jennavieve

Veteran
Veteran
Joined
Oct 21, 2020
Messages
54
Reaction score
47
First Language
English
Primarily Uses
RMMZ
Do I have to keep the 2nd page blank and put a switch on the first page or?
You want the first page (the way the NPC is supposed to be before he joins the party) to have no conditions set. It's just on the second empty page that you want to set the switch condition so it triggers once that switch is turned on and the NPC essentially disappears.
 

kiyasu

Veteran
Veteran
Joined
Aug 19, 2020
Messages
42
Reaction score
27
First Language
maybe English?
Primarily Uses
RMVXA
First page:
1. On the left: Set this to "Action button" for the trigger, with the NPC's character sprite, and same level as characters.
2. In the event box on right: put "Show Text" event and have the NPC say something.
3. Then, another "Show Text" event saying "NPC has joined your party!" (EDIT: Forgot to mention that you also add an "Add Party Member" event here.)
4. Then, add "Turn on Self-Switch" and pick one, any... (A, B, C, or D) but usually it's Self-Switch A = ON.

Second page:
1. On the left, make sure there are no character graphics set or anything.
2. Still on the left: make it a required condition that "Self-Switch A = ON" for this page.
3. Make this a blank event and don't put anything on the right, unless there are indeed events that happen here after the NPC disappears.
 

Jennavieve

Veteran
Veteran
Joined
Oct 21, 2020
Messages
54
Reaction score
47
First Language
English
Primarily Uses
RMMZ
First page:
1. On the left: Set this to "Action button" for the trigger, with the NPC's character sprite, and same level as characters.
2. In the event box on right: put "Show Text" event and have the NPC say something.
3. Then, another "Show Text" event saying "NPC has joined your party!" (EDIT: Forgot to mention that you also add an "Add Party Member" event here.)
4. Then, add "Turn on Self-Switch" and pick one, any... (A, B, C, or D) but usually it's Self-Switch A = ON.

Second page:
1. On the left, make sure there are no character graphics set or anything.
2. Still on the left: make it a required condition that "Self-Switch A = ON" for this page.
3. Make this a blank event and don't put anything on the right, unless there are indeed events that happen here after the NPC disappears.
This is actually the best way to do it. I suggested a regular switch rather than a self-switch in case the NPC was picked up through a separate event but I just realized you mentioned that you pick him up after the conversation so a self-switch is the way to go since it's all contained in one event.
 

Lifeh

Warper
Member
Joined
Sep 30, 2020
Messages
3
Reaction score
1
First Language
Italiano
Primarily Uses
RMVXA
You want the first page (the way the NPC is supposed to be before he joins the party) to have no conditions set. It's just on the second empty page that you want to set the switch condition so it triggers once that switch is turned on and the NPC essentially disappears.
Ok, It worked Thank you! :rhappy:
 

kiyasu

Veteran
Veteran
Joined
Aug 19, 2020
Messages
42
Reaction score
27
First Language
maybe English?
Primarily Uses
RMVXA
Hello, Jennavieve, thanks for the reply and compliment! Yes, if the NPC always returns to that same spot after he leaves the party, then I would recommend Switches instead of Self-Switches. However, it sounded like it is a simple one-time event.

In the case that if you want your new NPC character able to leave your party many times (for example) and always returns to that same spot where you have to talk to him/her to join your party again, then this is how you can do it:

First page:
1. On the left: Set this to "Action button" for the trigger, with the NPC's character sprite, and same level as characters.
2. Still on the left: make it a required condition that "Switch = OFF." To do this, you click on one of the Switch conditions (the "..." thing), and it should take you to a window called "Switches."
3. Then, on the "Switches" window, you name a Switch on the right. For example, maybe the name of Switch 001 is "[IN PARTY] NPC."
4. Then, on the right, add the events I mentioned earlier. However, instead of "Self Switch A = ON," you add "Switch 001 [IN PARTY] NPC = ON."
5. Later on in the game, for every event or time where the NPC leaves your party, you add a "Switch 001 [IN PARTY] NPC = OFF" to such events.
6. That's it, and no need for a second page!
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Profile Posts

Yet another gaming question, i'm currently playing Last of Us 2 and want to get another game to play next but can't decide between Ghost of Tsushima, Miles Morales & Jedi Fallen Order. After the latest mandalorian i AM on a star wars kick, but i also LOVED the last spiderman game that prequels Miles Morales. Ghost of Tsushima is the bottom of my list but i heard it was AWESOME. Just want a good story & fun gameplay.
I checked out Genshin Impact gameplay out of curiosity. I can't believe it's available as a mobile game too. Smooth animation, great music, and stellar sound effects (the ambient sounds are pretty detailed).

I'm flabbergasted to see games have becoming more and more advanced. Maybe also because I'm oblivious to current trend for a long time, it almost feel like I'm being sent into distant future. xD
xDRAGOONx wrote on WaywardMartian's profile.
Your artwork is amazing!!!
:ewat:
Stream will be live shortly with a session of the Interactive Text Adventure! Feel free to drop by!
I should finish the cat video I'm editing and finish the indesign stuff. So far only 1 is done and 4 to go

Forum statistics

Threads
105,664
Messages
1,015,380
Members
137,341
Latest member
jasapembuatanwebsite
Top