cEgo.Walk(372,164);
You haven't used the blocking option, meaning the script doesn't wait for the walking to finish before executing the next script command. Change it to:
cEgo.Walk(372,164, eBlock);
Next up:
RunDialog(13);
player.ChangeRoom(19, 158, 175);
RunDialog and Character.ChangeRoom are both delayed-response functions, meaning they execute when the current script finishes. You can't use these two like that, since both try to execute when the script finishes. They somehow conflict with each other and so the character probably just jumps to the ChangeRoom coordinates, but doesn't actually change the room.
As I've tried to tell you in my first post, put everything you want to happen after the dialog, i.e.
player.ChangeRoom(19, 158, 175);
in a second "Run script" action for the same event. This way the dialog runs, and after it has finished, the second "Run script" with the ChangeRoom command is executed.
You haven't used the blocking option, meaning the script doesn't wait for the walking to finish before executing the next script command. Change it to:
cEgo.Walk(372,164, eBlock);
Next up:
RunDialog(13);
player.ChangeRoom(19, 158, 175);
RunDialog and Character.ChangeRoom are both delayed-response functions, meaning they execute when the current script finishes. You can't use these two like that, since both try to execute when the script finishes. They somehow conflict with each other and so the character probably just jumps to the ChangeRoom coordinates, but doesn't actually change the room.
As I've tried to tell you in my first post, put everything you want to happen after the dialog, i.e.
player.ChangeRoom(19, 158, 175);
in a second "Run script" action for the same event. This way the dialog runs, and after it has finished, the second "Run script" with the ChangeRoom command is executed.