The neatest way to do it without a plugin is to allocate a region id to each "area" and draw an outline around that area with that region. Actually, you just need to draw it where the player can cross from one region to another.
So if you have a map that divides down the middle, and the left side is region 1 and the right side is region 2, use region 1 to draw along the edge of region 1, and use region 2 to draw along the edge of region 2. So where the two meet, you'll have the two regions drawn side by side.
Now create a parallel process event and tuck it away in the corner of your map. Add these commands (use whatever variables you have available, but make sure you name them):
Code:
Wait 5 frames
Control Variables: Player Region = Script: $gamePlayer.regionId()
If Variable [Player Region] # 0
If Variable [Player Region] # Variable [Saved Region]
If Variable [Player Region] = 1
Script: $dataMap.displayName = "Region 1"
Jump to Label: UpdateRegion
End
If Variable [Player Region] = 2
Script: $dataMap.displayName = "Region 2"
Jump to Label: UpdateRegion
End
End
End
Jump to Label: SkipRegionUpdate
Label: UpdateRegion
Script: SceneManager._scene._mapNameWindow.open();
Control Variables: Saved Region = Player Region
Label: SkipRegionUpdate
You will have one of these blocks:
Code:
If Variable [Player Region] = 1
Script: $dataMap.displayName = "Region 1"
Jump to Label: UpdateRegion
End
for each region.
Finally if you start on this map, create a new parallel process event that sets the [Saved Region] variable to whatever region number the player will start in. If you transfer to this map from other maps, have the transfer event set the [Saved Region] to whatever region it's transferring you to.
Here's how this works ...
every 5 frames, the event will check if the player is on a region. If they are, it checks if it's the same region they were on previously (this is so you only get the message once, when you enter the region). If it's not the same, it will do a series of tests to see what region the player is in, and set the "map" name accordingly. Once it's found a valid region and set the map name, it skips the rest of the tests, shows the message, then saves the region so it can keep track of where you currently are.
You can still use regions for other things, and if the player goes onto one of those tiles, this event will drop through all the tests without finding a valid region, then will skip the steps to show the name and save the region.
The only issue with the above is when you transfer to the map from another map, it will show the map name, not the region name. I'm not sure how to change that without actually creating a plugin.