Event blocking an exit

Rayspect

Warper
Member
Joined
Sep 18, 2020
Messages
4
Reaction score
0
First Language
French
Primarily Uses
RMMV
Hi guys
I try to create an event where the player can not leave the room before the end of another event. I try to made an event in 2 step. The firts one do not need any condition and the player will back off with an NPC telling him not to leave. The second one need the condition self switch B on and it’s the transfert command. The player needs the do another event that will activates the self switch B. But even if the self switch B is (suppose to be) on, the transfert do not work. And if I press the action button, it’s the first part that occure even if the it’s is set on player touch.
Can someone help me please?
 

ShadowDragon

Veteran
Veteran
Joined
Oct 8, 2018
Messages
2,587
Reaction score
880
First Language
Dutch
Primarily Uses
RMMV
if selfswitch B is on while page 1 = empty, it cannot trigger it, unless you told it
so in the other event.

best way is below character, with touch event (like you transfer the player).

if: switch x = ON
transfer player
else
NPC: or event or whatever,
you cannot leave yet, compleet the mission or talk to <name> for information.
end

in this example, I use a normal switch (selfswitch will work) but you need
a scriptcall to turn it on, this switch x can also be used on the other event,
that go from page 1 to page 2, or to 3, so it is ready to leave.

there are other methodes as well, but it also depends on how you event
you events and mechanisme that suits your need.

another simple way is page 1: same as character and player touch,
page: 1
you cannot leave yet

page 2: below character, and transfer with condition switch ON
transfer wherever he need to go.
 

Rayspect

Warper
Member
Joined
Sep 18, 2020
Messages
4
Reaction score
0
First Language
French
Primarily Uses
RMMV
Thanks a lot
I just learn that self switch only affect the event. Normal switch affect the area. Witch means that I have to use normal switch.
 

ShadowDragon

Veteran
Veteran
Joined
Oct 8, 2018
Messages
2,587
Reaction score
880
First Language
Dutch
Primarily Uses
RMMV
you can use selfswitches anywhere in any map, than you use a scriptcall
in the other event between those lines:

$gameSelfSwitches.setValue([this._mapId, EVENT_ID, 'SELFSWITCH'], true/false);

so for example:
$gameSelfSwitches.setValue([this._mapId, 14, 'A'], true);

this will activate selfswitch A on this MAP, of Event 14 to true.
 

Triangle45

Veteran
Veteran
Joined
Aug 26, 2020
Messages
81
Reaction score
22
First Language
Spanish
Primarily Uses
RMMV
just make 2 events
event 1: creatively blocking event2: page 1 If "questswitch=off" then "do this or you cant leave", move hero away, else SetSelfSwitch A to ON,
page2 Switch A ON: blank page, event below character.
event 2: on the door or whatever, do a simple transfer command
 

Rayspect

Warper
Member
Joined
Sep 18, 2020
Messages
4
Reaction score
0
First Language
French
Primarily Uses
RMMV
Ooooohhhh
I found my mistake. It’s not about switches. In the animation of the first event an NPC is leaving the room by the exact same door. For the animation, I made the NPC invisible so we think he left the room. But the only thing I did, is blocking the exit with this invisible NPC. I have to find out how to make him leave the room without blocking the door.
Thanks
 

Triangle45

Veteran
Veteran
Joined
Aug 26, 2020
Messages
81
Reaction score
22
First Language
Spanish
Primarily Uses
RMMV
Ooooohhhh
I found my mistake. It’s not about switches. In the animation of the first event an NPC is leaving the room by the exact same door. For the animation, I made the NPC invisible so we think he left the room. But the only thing I did, is blocking the exit with this invisible NPC. I have to find out how to make him leave the room without blocking the door.
Thanks
Something similar happened to me, just use little tricks, I imagine the game is a theater play so you can imagine your actors moving around behind scenes without anyone noticing.

Leave your NPC invisible and activate Through ON, and now the NPC can just chill at the (I assume) doorway and the player will just go through its ghost. Or for extra measure, make the NPC invisible, Through ON, and while those 2 are active, make the NPC run inside the room to a corner that is not used by the player (possibly blocked by some furniture). Think if you want to activate the "wait for completition box". If you do so, the player will remain stuck until the invisible NPC does its job and the player will wonder "Why cant I move"?. If it is unchecked, then the player might collide with the NPC and reactivate the NPC or stop its movement (if through is off). For this, I changed my NPC's speed to 5 so it sprints to a dark corner that was blocked by a bookcase and let the NPC remain invisible and through and set a new page to self switch empty. To avoid collisions, I gave the player 2 boxes of text for "flavor" (Oh that was weird, well I better get going blah blah) but also to allow 2 seconds for the ghost NPC to finish its route.
 

Rayspect

Warper
Member
Joined
Sep 18, 2020
Messages
4
Reaction score
0
First Language
French
Primarily Uses
RMMV
Seriously
I do not know why, but it’s like the self switch B do not turn on. I made an event with the command of turning the self switch B on and another event like: if self switch B = on, blabla
Else, another blabla
But even if I do the event thats suppose to turn the self switch B on, the other always do the Else part.
 

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

Latest Threads

Latest Posts

Latest Profile Posts

Yesterday I made my first step towards eating more healthily.
I saw candy on discount and did not buy it.
"They yearn for what they fear for."
I always told my DA fans how much I hate slot machines. They're fine in games as a risk-and-reward system. But when you're spending REAL MONEY in a Vegas casino to try and hit the jackpot (which very, very few people will), it can really hurt your budget. Gambling is a bad habit, and I don't like wasting my money on a slim chance. Go to Vegas for the experience, not the jackpot.
Took the kids to a corn maze. They gave us a map and had lights at certain points in the maze. Not overwhelming... or underwhelming... just... whelming.
Okay, vacuuming fruit flies out of the air is surprisingly effective.

Forum statistics

Threads
104,393
Messages
1,006,075
Members
135,927
Latest member
ecelebrithytrend
Top