Tiles that alter movement direction

I have four tiles that each have a unique symbol on them (a frying pan, a whisk, a spatula and a grater). Each tile is a specific region. When you are standing on the frying pan, and you press the up key, I want you to go left, if you press the right key, you go up, down key moves you right and left key moves you down. Each symbol has a different remapped movement override. This is similar to Dragon Warrior 3's Castle of Zoma level B2.

I setup a variable called WhatTileAmIOn and then set it to read the region ID of the current tile; this runs parallel.
Control Variables:#0025 WhatTileAmIOn = $gameMap.regionId($gamePlayer.x, $gamePlayer.y)

Then I setup if statements like this
if on frying pan
up button is pressed, player movement move left
right button is pressed, player movement move up
...
if on whisk
etc.

I've also tried using this instead of button pressed
If:Script:Input.isTriggered('up')



What I'm finding is that this is triggering when I move onto the tile, so if I'm below the frying pan and move up to it, it sends me left. I want the movement overrides to happen when I leave the tile.

I've also tried using Visustella and running a common event for each region, but all I could find was on touch or on ok, neither of those are what I'm looking for. Can anyone help me get started on this?

Link to current prototype of my game - https://bcollins74.itch.io/kitchen-warrior-i
I think you could modify Game_Player.prototype.moveByInput or Game_Player.prototype.getInputDirection or Game_Player.prototype.executeMove, like set a conditional that if a switch is ON and if the player is standing on a certain region, switch the value it gives 'direction'. But are you still using VisuStella, since they seem to modify all those functions? Don't know if you can run into some problems if you alias them and set it up so that you use your own stuff on a certain map (when a switch is ON) where you don't use any strange plugin effects or whatever.

EDIT:
But yeah, I think the position gets set before your character sprite has moved to the location. You can help it a bit with your current system if you add a conditional check !$gamePlayer.isMoving() But unless you set move to slow, it's still easy to make the move in the disoriented direction. Don't think changing the functions would help with that. Though with your current system I think it also gets messed if you hold a direction key. Then it'd alternate between up/left moves.
I was able to get that to work by using two parallel events. One to grab the Terrain ID (Though you could use Region instead) and setting a switch to change movement, dependent on which terrain the player is on.

Then the other waits a couple of frames so that the player movement can complete and goes into a loop if the switch is active. Loop starts by locking player movement with a player movement route that has wait 1. Then looks if a directional button is being pressed. Adjust player movement as you like, break the loop and finally turn off the switch.

I only did it for 1 tile, but easy enough to add more switch checks to the second event.

There are a number of ways to make this a bit more efficient as well.
So I got it to work using !$gamePlayer.isMoving() but if you hold down a direction key, it ignores the overrides. Would the loop method @Crim_T described help with this issue?

Original thread: https://forums.rpgmakerweb.com/threads/tiles-that-alter-movement-direction.180471/