How to get multiple NPCs to disappear; leave; vanish!

Status
Not open for further replies.

Pandurah

Warper
Member
Joined
Jul 21, 2013
Messages
4
Reaction score
0
First Language
English
Primarily Uses
Hey there!

Apologies if this is in the wrong section, but I'm new and still finding my feet.

My issue is this:

I have an autorun event where the Player walks into a new map, notices 5 NPCs nearby, and so hides. They pass by, but of course, hit the edge of the map and remain there in a column. I want it so that one by one they "leave" the area. Or they can vanish all together, I'm really past caring now xD

How can I easily get rid of the NPCs? I've searched through a few vids on youtube, but no one seems to answer my question. Whether I'm being a wee bit dense or not, I don't know. It's been driving me mad all evening...I just want to move on!

I've played around with switches, but that just leads to the NPCs being invisible for the whole 'cutscene'.

(A minor issue, which I should be able to find help with, is that the Player, after hiding around the corner, can still be controlled and I want him to remain still...but I think a Google search should help me with that).

Sorry, I guess problems like this are asked about multiple times a day! If I'm missing a nice chunk of tutorial on switches, or whatever, feel free to call me a tool and promptly direct me far, far away (preferably towards the tutorial).

Thanks!

Pan
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
40,098
Reaction score
13,704
First Language
English
Primarily Uses
RMMV
Use a switch. When they get to the edge of the map, turn the switch on, then add an extra page to each of your NPC events, conditioned by that switch, but with everything else left as it is by default (no sprite, no commands, Action Button trigger, Below Characters priority).


Your problem with them being invisible for the whole cutscene is probably that you put the switch as a condition on the event page that contains the sprite. You want it on the next, BLANK event page. Otherwise you are saying to only show the sprite when the switch is on. You want the opposite - to show the sprite while the switch is OFF - which is why you add an extra page with the condition.
 

Daughter of Evil

Nightmare Princess
Veteran
Joined
Jun 21, 2013
Messages
147
Reaction score
19
First Language
English
Primarily Uses
You could make it a move route. Like example: Event guard moves 3 steps forward, then change graphic to none, and through is on. That way the event would be invisible like they left the map and they are also passable(the player can move through them). You could also use the idea of Shaz. :)
 

Pandurah

Warper
Member
Joined
Jul 21, 2013
Messages
4
Reaction score
0
First Language
English
Primarily Uses
Use a switch. When they get to the edge of the map, turn the switch on, then add an extra page to each of your NPC events, conditioned by that switch, but with everything else left as it is by default (no sprite, no commands, Action Button trigger, Below Characters priority).

Your problem with them being invisible for the whole cutscene is probably that you put the switch as a condition on the event page that contains the sprite. You want it on the next, BLANK event page. Otherwise you are saying to only show the sprite when the switch is on. You want the opposite - to show the sprite while the switch is OFF - which is why you add an extra page with the condition.
Thanks for the speedy reply! Ok so I've fixed the issue with them being invisible, thanks! But I'm still unsure how to turn it on when they reach the edge...do I create a new event tile there, or do I add it to the cutscene event after they've all moved? Sorry for the noobish question, I feel like such a spud X__X
 

Pandurah

Warper
Member
Joined
Jul 21, 2013
Messages
4
Reaction score
0
First Language
English
Primarily Uses
You could make it a move route. Like example: Event guard moves 3 steps forward, then change graphic to none, and through is on. That way the event would be invisible like they left the map and they are also passable(the player can move through them). You could also use the idea of Shaz. :)
Ohhhohoh, is that possible if I have everyone's movement on one event tile? (the 'cutscene' tile in the corner) 

<eeek! sorry for the double post everyone :( >
 
Last edited by a moderator:

Daughter of Evil

Nightmare Princess
Veteran
Joined
Jun 21, 2013
Messages
147
Reaction score
19
First Language
English
Primarily Uses
Yeah its possible just change a few things. Example: There are 2 events. One in front the other behind. Event Front moves 3 steps forward, then change graphic to none, then moves right and through is on. Event back moves 4 steps forward, then change graphic to none,  and through is on . If i remember right, the one i mentioned earlier about the Guard thing would work as long as the through is set to on. I think the through also works on events. So no change needs to be done. :)

Example: Event guard moves 3 steps forward, then change graphic to none, and through is on. Event guard 2 (which was behind event guard 1) moves 4 steps forward, then change graphic to none, and through is on. No actual change.
 
Last edited by a moderator:

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
40,098
Reaction score
13,704
First Language
English
Primarily Uses
RMMV
How are you moving them? Do you have a single event controlling all of them, or are you using Autonomous Movement or a Move Route with a parallel processing event on each one?


If you have a single event controlling them, use the Set Move Route to do a Change Graphic to None on each one (that way, they'll each walk to the edge then disappear, rather than ALL disappearing when one gets to the edge). After the last move route, which should have a Wait for Completion, just do a Control Switches. That'll MAKE them stay gone, even when you come back to the map again.


A couple of things ...


- if you just do a Change Graphic (none), when you leave the map and come back, they'll be there again. You NEED to have that extra event page on each one with no graphic, controlled by the switch.


- when each one gets to the edge, add a Through ON to the move route. Otherwise the ones coming behind will line up but not be able to walk onto the next tile, because even though you can't see it, the preceding event is still actually there. Setting Through to ON as each one reaches the edge will allow any followers to walk onto the same tile.


If you are using Autonomous Movement or parallel process events with the move route on each one, it's better to use a self switch rather than a switch, so just turn self switch A on after the move route (make sure you wait for completion), then have the second, blank event page conditioned by the self switch instead of the switch. That way, you're not using up a switch for it, and you don't have to worry about any others disappearing before they get to the edge. If you're using Autonomous Movement, just add a Script call right at the end that says $game_self_switches[[map_id, @id, 'A']] = true, since there's no move route command to set a self switch.
 

Pandurah

Warper
Member
Joined
Jul 21, 2013
Messages
4
Reaction score
0
First Language
English
Primarily Uses
Yeah its possible just change a few things. Example: There are 2 events. One in front the other behind. Event Front moves 3 steps forward, then change graphic to none, then moves right and through is on. Event back moves 4 steps forward, then change graphic to none,  and through is on . If i remember right, the one i mentioned earlier about the Guard thing would work as long as the through is set to on. I think the through also works on events. So no change needs to be done. :)

Example: Event guard moves 3 steps forward, then change graphic to none, and through is on. Event guard 2 (which was behind event guard 1) moves 4 steps forward, then change graphic to none, and through is on. No actual change.
How are you moving them? Do you have a single event controlling all of them, or are you using Autonomous Movement or a Move Route with a parallel processing event on each one?

If you have a single event controlling them, use the Set Move Route to do a Change Graphic to None on each one (that way, they'll each walk to the edge then disappear, rather than ALL disappearing when one gets to the edge). After the last move route, which should have a Wait for Completion, just do a Control Switches. That'll MAKE them stay gone, even when you come back to the map again.

A couple of things ...

- if you just do a Change Graphic (none), when you leave the map and come back, they'll be there again. You NEED to have that extra event page on each one with no graphic, controlled by the switch.

- when each one gets to the edge, add a Through ON to the move route. Otherwise the ones coming behind will line up but not be able to walk onto the next tile, because even though you can't see it, the preceding event is still actually there. Setting Through to ON as each one reaches the edge will allow any followers to walk onto the same tile.

If you are using Autonomous Movement or parallel process events with the move route on each one, it's better to use a self switch rather than a switch, so just turn self switch A on after the move route (make sure you wait for completion), then have the second, blank event page conditioned by the self switch instead of the switch. That way, you're not using up a switch for it, and you don't have to worry about any others disappearing before they get to the edge. If you're using Autonomous Movement, just add a Script call right at the end that says $game_self_switches[[map_id, @id, 'A']] = true, since there's no move route command to set a self switch.
Ahaa! I didn't even notice the Change Graphic option in the move route, and thanks for pointing it out guys! My problem is now solved, they disappear at the edge, one by one, perfect!  

Still unsure on how to use switches properly (I'm sure there're plenty of tutorials I can find though).

Thank you two for the help and advice, you guys have cured my headache :D
 
Last edited by a moderator:

Celianna

Tileset artist
Veteran
Joined
Mar 1, 2012
Messages
10,557
Reaction score
5,592
First Language
Dutch
Primarily Uses
RMMV
Yup, plenty of tutorials available, go look at our tutorial forum.


This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.
 
Status
Not open for further replies.

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

Latest Threads

Latest Posts

Latest Profile Posts

Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD
How many parameters is 'too many'??

Forum statistics

Threads
105,867
Messages
1,017,061
Members
137,575
Latest member
akekaphol101
Top