Barrier Switch Not Working
#1
So in my current project, I have a barrier in front of an archway that I do not want to vanish until you are done talking to the introductory NPC. Then I want it to vanish and the character is free to walk through the arch way.
My issue is, with the code I have currently, the moment the character enters the room, the barrier vanishes, never to return. There is no barrier, the talking to the NPC does nothing.
Here is my code, currently...

NPC's Code

Barrier's Code Pg.1
Barrier's Code Pg.2
Said an envious, erudite ermine,
"There's one thing I cannot determine:
When a girl wears my coat,
She's a person of note.
When I wear it, I'm called only vermin."
Reply }
#2
It is a little known fact that map events in RPGMaker XP do not always automatically refresh upon command if the action asking the event to refresh is being performed by ANOTHER event.

In other words, if you asked ONE event to refresh, it will. If you ask ONE Event to do something, the other event may not immediately refresh. This isn't always the case, but a sometimes factor (including here). Smaller codes... no issues.

There IS a way to solve this (actually a few, but I'm not gonna talk rewriting the switches section now):

Add the following 'script call' right after you turn your switch on:
$game_map.need_refresh = true
This will force the game map to refresh, and re-check every visible event.
Up is down, left is right and sideways is straight ahead. - Cord "Circle of Iron", 1978 (written by Bruce Lee and James Coburn... really...)

[Image: QrnbKlx.jpg]
[Image: sGz1ErF.png]    [Image: liM4ikn.png]    [Image: fdzKgZA.png]    [Image: sj0H81z.png]
[Image: QL7oRau.png]    [Image: uSqjY09.png]    [Image: GAA3qE9.png]    [Image: 2Hmnx1G.png]    [Image: BwtNdKw.png%5B]
  Above are clickable links
Reply }
#3
(08-14-2015, 04:21 AM)DerVVulfman Wrote: It is a little known fact that map events in RPGMaker XP do not always automatically refresh upon command if the action asking the event to refresh is being performed by ANOTHER event.

In other words, if you asked ONE event to refresh, it will.  If you ask ONE Event to do something, the other event may not immediately refresh.  This isn't always the case, but a sometimes factor (including here).  Smaller codes... no issues.

There IS a way to solve this  (actually a few, but I'm not gonna talk rewriting the switches section now):

Add the following 'script call' right after you turn your switch on:
 $game_map.need_refresh = true
This will force the game map to refresh, and re-check every visible event.

It's still vanishing. Do I put that script after every switch, or just the door lock switch? Sweat
Said an envious, erudite ermine,
"There's one thing I cannot determine:
When a girl wears my coat,
She's a person of note.
When I wear it, I'm called only vermin."
Reply }
#4
Oh, I am sorry. I thought you had an issue where your barrier did NOT vanish. So what's happening is that your switch is being triggered when you enter the map, or was already triggered prior to entering.

Inquiries:
You're showing a self-switch activated page for your dialog. The first page... is it an auto-run or parallel process event. And if so, did you check to see if the code for the barrier switch (0009: Door Lock) may be there?

Maybe you are accidentally using Switch 0009 elsewhere in the game or in some custom script (it happens), and it is being turned on automatically. Have you tried using a different switch for your door lock?
Up is down, left is right and sideways is straight ahead. - Cord "Circle of Iron", 1978 (written by Bruce Lee and James Coburn... really...)

[Image: QrnbKlx.jpg]
[Image: sGz1ErF.png]    [Image: liM4ikn.png]    [Image: fdzKgZA.png]    [Image: sj0H81z.png]
[Image: QL7oRau.png]    [Image: uSqjY09.png]    [Image: GAA3qE9.png]    [Image: 2Hmnx1G.png]    [Image: BwtNdKw.png%5B]
  Above are clickable links
Reply }


Possibly Related Threads…
Thread Author Replies Views Last Post
  Variable = Actor Level not working (VX) nuberus 3 7,476 09-08-2011, 11:11 AM
Last Post: Kain Nobel



Users browsing this thread: 1 Guest(s)