Chapter 4:
Zones; Where, What and How


Zones:
As stated in the beginning zones call scripts based on certain conditions. They tell Verge where it can be activated, how it can be activated, and what happens when it is activated.

Maped3: Placing Zones

Placing a zone and editing its properties is very similar to adding an entity, but it is far simpler!
First click on the "Zones" layer, in the layer box on the right of the map editor. (You'll probably have to scroll down to find it.)
Next click the "Edit Zones" button that will appear fairly close to it.
On the new window that appears, click the "Add New Zone" button, and we'll now be able to edit our new zones properties.
As you can see there isn't as much to worry about when dealing with zones. Let's go through our options.

Zones in action:
So let's create a new script to test our zone. We'll use the MessageBox()function again. For practise, see if you can create a new script without resorting to the one I am about to make, and try to get it to work on your own. If you can't get it, don't fret. It's all apart of the learning process. :)

void TestZone()
{
	MessageBox("I'm a zone!");
}

In the "Script Name" box, put "TestZone". Click "Ok", choose it from the list and place it anywhere on the map you want it to go. It will appear as a blue 16x16, square with a number on it.
I also suggest adding another tile on there as well, and placing the zone over top of it. That way you'll be able to easily find it when you run your game.
If you remember what happened after we assigned and activated our "TalkToCrystal" script, the "TestZone" script will be very similar. The only difference will be the message. Go ahead and experiment with the zones properties and see first hand how you can manipulate its behaviour.

Multiple Zones:
If you have a script that needs to be called via a zone, and appears in multiple places on your map, you do not have to create a new zone for every area that you want to call the same script. You can place as many of the same zone on your map as you would like.

To Summarize, this is what you now know:




Table Of Contents      Chapter 5: Music and Sounds