Fire Puzzle Code Help

The goal of my trap is to have the player "push" fires into stands. Two key points:

1. the flame moves until it either hits a wall or a stand.

2. the flame can move over lava.

The second page of the event *should* change the animation to a larger flame as visual feedback to the player. 

Spoiler
[IMG]https://i.imgur.com/6NagNFw.png[/IMG][IMG]https://i.imgur.com/F6FzR8U.png[/IMG]

[IMG]https://i.imgur.com/Z4BO1O0.png[/IMG]
EDIT: Sorry I never posted the issue! Whenever in play testing I activate the event the game freezes. I'm unsure of the cause. 

Thanks for the help!
Alpha
Well, actually you are checking Region ID of a fixed spot. It gives you always the same value...and if that vaule is neither 1 or 2 you have an infinite loop and your flame moves forever.

I assume you want to check the Region ID of the flame current location and not of the (22, 16) spot. If the (22, 16) square Region ID is neither 1 or 2 that's why the game freezes.
You also have 'Turn away from player', not 'Move away from player'. You could get all your other commands right, but until you change that one, nothing will happen.

Original thread: https://forums.rpgmakerweb.com/threads/fire-puzzle-code-help.50379/