I don't know why it's happening; these events are practically identical to all the other door events, save graphic and target.
So far, this happens for two buildings, one of which previously worked until I randomly got the glitch for no specific reason.
EDIT: It's not the event; it's actually the map it transfers to. One is a Pokémon center, which is actually just a Pokécenter copy/pasta'd from a previous city. The copy Pokécenter doesn't work. The second is a Trainer dojo, where you can battle trainers and get items. It worked, and then suddenly didn't.
It is possible you're using a global variable that's not alright to use.
One thing I've done in the past is tried using Global Variables 7 and 8. After I did that, I could never properly reenter the map until I made a new save and used different variables. It seems it's caused by the particle engine or something somehow, I'm not really sure how.