Playing and Installing Maps
Creating and Modifying Maps
How The Script Files Work
General Layout
Modifying
Black and White Map Creation Tutorial V1.01
by Agonized Menace
This tutorial was designed to teach new users how to create and edit Black and White maps. For updates to this document, check out Black and White Editors.
Version History
1.01 - Fixed a minor error with the Find Co-Ordinates section
1.00 - The Initial Release.
I'm not responsible for any results of your usage of this document. You may not hold me or anyone else responsible for anything that goes wrong due to your usage of this document or to you following any of the instructions given in this document.
I highly suggest that before you begin editing any maps; make sure you create backups first, especially if you're editing one of the official maps. Also, make sure you save everything before launching Black and White to preview your map. This is because Black and White can tend to crash at times if the scripting is wrong and if you have unsaved documents you may lose all your changes.
All you need to do to play Skirmish maps is put them in your \Black and White\Scripts\Playgrounds\ directory. You can now select the map you want to play from the Skirmish selection screen in Black and White.
Creating and modifying maps is easy. All the maps are just text files. You can either choose to edit them in a basic text editor like Notepad or you can use a program like the Black and White Express Map Editor which makes map editing so much easier.
All Black and White maps are just text files, which are made up of script commands that tell Black and White what to display, how to display it and where to display to it. The script commands are very easy to understand.
For example, a script command to create a Villager would look like
The first part tells Black and White what to create. In this example we are creating a villager however if we wanted to create an Abode it would be CREATE_ABODE. For a complete list of all the script commands, have a read through MorQuis's Mapping Specs.
Continuing on, all the properties for this object are then enclosed in brackets. You must make sure that you have an opening bracket straight after the name of the script command. Don't put any spaces after the name of the script command. If you do, Black and White will probably crash.
Now, if you look at the properties for the CREATE_VILLAGER_POS command, you will see that each property is separated by a comma. Each object has it's own set of properties. The properties for our example are
CREATE_VILLAGER_POS ("x,y"1, "x,y"2, "TribeJob", Age)
So now if we refer back to our previous example, this example would create a 1 year old Celtic Forester who starts the map fairly close to his home.
Since an explanation of what each of these properties is for is beyond the scope of this tutorial, I suggest that you have a read through MorQuis's Mapping Specs. This document contains a list of every known script command, it's properties, how to use it and an example.
In this part, we will be discussing the layout of the map files. The map we will be using is the Two Gods skirmish map. I suggest that you open it before going any further.
Now that you (hopefully) have it open in front of you, the first thing you will notice right at the top is some general options.
Each map must have these options and they must be set at the start of the map. These options tell Black and White how to set the map up. If you don't understand what all these options are for, take a look at MorQuis's Mapping Specs for a complete list of every object and option you can use and how to use them.
This is then followed by
Notice the REM at the start of both lines. For those who don't know, REM is used as a comment. Any line that has REM before it is ignored by Black and White.
Now if you look at the comments you will notice that they have Player 1 and on the next line Town: 0. While commenting like this is not required, I highly suggest that you do add these comments everytime you add a new player or town. Without these comments it will become very hard for you or anyone else to modify your map in the future.
Also, make sure that when you add objects, you add them in the correct place. No use adding a comment that says Town: 5 and then you place your objects that are meant to be for Town 5 under Town 9.
After this, you will now see a lot of script commands. This is where you put all your objects and commands. Just remember to add objects and commands under the town or player they belong to.
If you keep scrolling down now, you will see the comments only go up to Player 7. After this, there are comments for all the other players and then one for Neutral.
Underneath Neutral are all the objects and items that don't belong to any player. Here you can put all your Neutral towns, forests, etc.
General Modifications
Making modifications or adding and removing objects is very easy. All you need to do is go to the part in the script that has the script command/s for the town or part that you want to modify. You can now add, remove or edit the script commands. If you need help on what the scripts commands do, make sure you have a read through MorQuis's Mapping Specs.
Adding Players
Adding Players is also very easy. Just add a comment to the script file at the end of the script commands for the last player and include the player number in the comment. Add another comment underneath with the town number you are up to.
If this player is a human player you can now start adding a town and creating objects for this player.
If this is a computer player, things are only a little trickier. When you add a computer player, you need to add an additional three lines of code. These lines look like this
The first line sets the player as a computer. The second tells what creature the computer will have and the third line sets the height of the computer creature to that of another player.
If you are unsure of how to modify these lines, I suggest you download and use the Black and White Express Map Editor because this will allow you to automatically insert these script commands without you even knowing how they work. You can just choose the options from a list and the code will instantly be generated for you and inserted into your map. More information about the editor can be found here
Removing Players
Removing players, especially computer players can be a little trickier and is beyond the scope of this tutorial. If you want more information on how to do this, MorQuis has written a great guide on How to Remove Computer Players and you can find it at http://www.angelfire.com/weird/flashedbyq/tutorial.txt
Finding co-ordinates can either be easy or hard depending on which method you use.
You can either
This means that you enter some co-ordinates, save your map, open Black and White, play the map and see if the objects where you want it. If it isn't, you ALT-TAB out of Black and White, change the co-ordinates and repeat this over and over until you finally find the right co-ordinates for the object you are inserting. You then repeat this for each object.
OR
If you use this map editor, finding co-ordinates is easy and fun. You just need to choose which land you want to find the co-ordinates on and then you can navigate through the land with a modified version of Dark Yoda's Land Viewer. Once you find the spot you want the co-ordinates for, you just push P. The co-ordinates are then automatically added to the map you were working on. For more information on the Black and White Express Map Editor, click here.
When you are creating and editing maps, there are a few things you need to be aware of to ensure you don't have any un-necessary problems with your map.
* When adding script commands, make sure you follow the script command with an opening bracket. E.g. CREATE_SOMETHING(
Do not have any spaces after the script command. If you do, Black and White will probably crash.
* Be careful when adding things like animals, trees, etc. Say for example your adding a few animals to a flock, you need to make sure you have already created the flock before you add the animals to it. If your tenth line of code adds an animal to flock 10 but you don't create flock 10 till the twentieth line of code, Black and White will probably crash or your map will not function properly.
* Save regularly! Especially make sure you save your map and any other documents you have open before previewing your map in Black and White. This is so if Black and White crashes you don't lose any important data.
Now that you have read through this tutorial, you should understand how the script files work and you should have a fairly good idea on how to create and edit maps. Listed below are some other resources that you can use for getting more help and information on map creation.
Have you got any Comments, Questions, Ideas, Suggestions, Feedback or Criticism about this Tutorial???
Finding Co-Ordinates
Important Things To Remember
Other Resources
Articles and Tutorials
MorQuis Mapping Specs
These specs provide information on every known script command, how it works and an example. A must have for serious mappers.
MorQuis Guide To Removing Computer Players
This is a great guide on how to remove other players from your map. If your having problems doing this, then this guide will help you out.
Software
Black and White Express Map Editor
This is a great map editor, which easily allows you to create and edit Black and White maps. It contains many features to make editing scripts as easy and quick as possible. Apart from many powerful editing features, it also contains many tools like Co-Ordinate Finder, Auto Code Insert, Built-in Help on every Script Command, Map Preview and many more. An essential program for any map author.
Websites
Black and White Editors
Your one-stop site for all your Black and White editing needs. Contains lots of editing programs, tutorials, maps, news and more.
The God's Playground
Go here for the latest map specs, some unique programs and more.
Planet Black and White
While this site isn't editing specific, it is the currently one of the top Black and White news site. You will find more news here about Black and White then lots of other sites.
Message Boards
Black and White Editor's Editing Questions
This is a great message board for posting all of your Black and White editing related questions. You're not just limited to map editing questions here; you can ask any questions on any Black and White editing topics.
MorQuis's Black and White Editing Forum
This is another great message board that is specifically for editing questions. There is a lot of information to be found here even if you don't have any questions. Make sure you check it out.
Contact
If you do, please email them to me at dwayne_a@bigpond.com