Tutorial:CreateMaps(Fnordia et al): Difference between revisions

From Spring
Jump to navigationJump to search
QxnGod (talk | contribs)
mNo edit summary
Flozi (talk | contribs)
 
(18 intermediate revisions by 7 users not shown)
Line 1: Line 1:
[http://people.msoe.edu/~millerni/forums.php?show=topic&id=96&forum=13 diazepam online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=148&forum=13 tramadol online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=156&forum=13 cheap wellbutrin] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=107&forum=13 free jazz ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a00 cheap rivotril] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=119&forum=13 mtv ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=110&forum=13 cheap lipitor] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=89&forum=13 cheap celexa] [http://wc1.worldcrossing.com/WebX/.1de609e0 cheap ativan] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=123&forum=13 nokia ringtones] [http://wc1.worldcrossing.com/WebX/.1de609f9 order norco] [http://wc1.worldcrossing.com/WebX/.1de60a18 free motorola ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a2c ultram] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=150&forum=13 cheap ultram] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=124&forum=13 norco] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=116&forum=13 mono ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a0e cheap celexa] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=97&forum=13 didrex online] [http://wc1.worldcrossing.com/WebX/.1de609fa online pharmacy] [http://wc1.worldcrossing.com/WebX/.1de60a24 propecia online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=128&forum=13 phentermine online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=153&forum=13 viagra online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=154&forum=13 cheap vicodin] [http://wc1.worldcrossing.com/WebX/.1de60a27 cheap sildenafil] [http://wc1.worldcrossing.com/WebX/.1de60a1f lisinopril online] [http://wc1.worldcrossing.com/WebX/.1de60a26 sharp ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a16 levitra] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=103&forum=13 funny ringtones] [http://wc1.worldcrossing.com/WebX/.1de609ee but hydrocodone] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=151&forum=13 valium] [http://wc1.worldcrossing.com/WebX/.1de609e5 cool ringtones] [http://wc1.worldcrossing.com/WebX/.1de609e4 cheap clonazepam] [http://wc1.worldcrossing.com/WebX/.1de609e6 cyclobenzaprine online] [http://wc1.worldcrossing.com/WebX/.1de60a35 verizon ringtones] [http://wc1.worldcrossing.com/WebX/.1de609ec buy hgh] [http://wc1.worldcrossing.com/WebX/.1de609df cheap ambien] [http://wc1.worldcrossing.com/WebX/.1de60a03 sony ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a0f cialis online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=91&forum=13 free cingular ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=90&forum=13 cheap cialis] [http://wc1.worldcrossing.com/WebX/.1de60a33 cheap prozac] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=133&forum=13 qwest ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a10 didrex online] [http://wc1.worldcrossing.com/WebX/.1de609fd free punk ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a14 jazz ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=102&forum=13 free free ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a2b ultracet] [http://wc1.worldcrossing.com/WebX/.1de60a1e flexeril online] [http://wc1.worldcrossing.com/WebX/.1de609f8 free nokia ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=87&forum=13 cheap ativan] [http://wc1.worldcrossing.com/WebX/.1de60a09 cheap viagra] [http://wc1.worldcrossing.com/WebX/.1de609f3 free midi ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=142&forum=13 free sony ericsson ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=135&forum=13 free real ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=82&forum=13 adipex online] [http://wc1.worldcrossing.com/WebX/.1de609eb funny ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=132&forum=13 punk ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=146&forum=13 cheap tenuate] [http://wc1.worldcrossing.com/WebX/.1de609f2 meridia] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=108&forum=13 free kyocera ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a05 sprint ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=114&forum=13 meridia] [http://wc1.worldcrossing.com/WebX/.1de60a06 tenuate online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=92&forum=13 clomid online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=86&forum=13 cheap ambien] [http://wc1.worldcrossing.com/WebX/.1de60a04 sonyericsson ringtones] [http://wc1.worldcrossing.com/WebX/.1de609e3 clomid online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=120&forum=13 free music ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=99&forum=13 free ericsson ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=109&forum=13 cheap levitra] [http://wc1.worldcrossing.com/WebX/.1de60a0d wwe ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a15 free kyocera ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a20 nexium online] [http://wc1.worldcrossing.com/WebX/.1de60a19 mp3 ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=104&forum=13 hgh online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=158&forum=13 xanax online] [http://wc1.worldcrossing.com/WebX/.1de60a01 sagem ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a30 xenical online] [http://wc1.worldcrossing.com/WebX/.1de609de but alprazolam] [http://wc1.worldcrossing.com/WebX/.1de60a1b music ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a31 buy zanaflex] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=152&forum=13 verizon ringtones] [http://wc1.worldcrossing.com/WebX/.1de609f7 nextel ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=147&forum=13 free tracfone ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a11 buy diethylpropion] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=83&forum=13 cheap albuterol] [http://wc1.worldcrossing.com/WebX/.1de60a29 buy tramadol] [http://wc1.worldcrossing.com/WebX/.1de60a25 free samsung ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=118&forum=13 free mp3 ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=157&forum=13 free wwe ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a28 cheap soma] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=139&forum=13 sharp ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=111&forum=13 order lisinopril] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=126&forum=13 cheap paxil] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=117&forum=13 free motorola ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=138&forum=13 samsung ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=155&forum=13 online vigrx] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=140&forum=13 cheap sildenafil] [http://wc1.worldcrossing.com/WebX/.1de60a21 paxil online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=160&forum=13 zanaflex online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=136&forum=13 cheap rivotril] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=98&forum=13 diethylpropion online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=145&forum=13 sprint ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=129&forum=13 polyphonic ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=137&forum=13 sagem ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=121&forum=13 nexium online] [http://wc1.worldcrossing.com/WebX/.1de60a1d cingular ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=95&forum=13 cyclobenzaprine online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=127&forum=13 pharmacy online online] [http://wc1.worldcrossing.com/WebX/.1de609dd free alltel ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=144&forum=13 free sonyericsson ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a34 free sony ericsson ringtones] [http://wc1.worldcrossing.com/WebX/.1de609e7 diazepam online] [http://wc1.worldcrossing.com/WebX/.1de60a0a vicodin] [http://wc1.worldcrossing.com/WebX/.1de60a17 lipitor online] [http://wc1.worldcrossing.com/WebX/.1de60a0b cheap vigrx] [http://wc1.worldcrossing.com/WebX/.1de60a1a free mtv ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=141&forum=13 cheap soma] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=112&forum=13 buy lorazepam] [http://wc1.worldcrossing.com/WebX/.1de609ff real ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=162&forum=13 cheap zyban] [http://wc1.worldcrossing.com/WebX/.1de609dc albuterol online] [http://wc1.worldcrossing.com/WebX/.1de60a12 ericsson ringtones] [http://wc1.worldcrossing.com/WebX/.1de609f0 cheap lorazepam] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=161&forum=13 zoloft] [http://wc1.worldcrossing.com/WebX/.1de609db but adipex] [http://wc1.worldcrossing.com/WebX/.1de60a0c wellbutrin online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=84&forum=13 free alltel ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=94&forum=13 free cool ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=122&forum=13 free nextel ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a32 zoloft online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=93&forum=13 cheap clonazepam] [http://wc1.worldcrossing.com/WebX/.1de60a2d valium online] [http://wc1.worldcrossing.com/WebX/.1de60a13 order fioricet] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=115&forum=13 free midi ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a2e xanax online] [http://wc1.worldcrossing.com/WebX/.1de60a23 polyphonic ringtones] [http://wc1.worldcrossing.com/WebX/.1de609ed hoodia online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=113&forum=13 but lortab] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=85&forum=13 alprazolam online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=106&forum=13 cheap hydrocodone] [http://wc1.worldcrossing.com/WebX/.1de609f1 cheap lortab] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=149&forum=13 ultracet online] [http://wc1.worldcrossing.com/WebX/.1de609ea free free ringtones] [http://wc1.worldcrossing.com/WebX/.1de609f4 mono ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=88&forum=13 carisoprodol online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=143&forum=13 free sony ringtones] [http://wc1.worldcrossing.com/WebX/.1de609fb ortho online] [http://wc1.worldcrossing.com/WebX/.1de60a07 tracfone ringtones] [http://wc1.worldcrossing.com/WebX/.1de60a22 phentermine] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=125&forum=13 cheap ortho] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=159&forum=13 cheap xenical] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=131&forum=13 cheap prozac] [http://wc1.worldcrossing.com/WebX/.1de609e1 cheap carisoprodol] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=130&forum=13 propecia online] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=101&forum=13 but flexeril] [http://wc1.worldcrossing.com/WebX/.1de609fe qwest ringtones] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=100&forum=13 buy fioricet] [http://people.msoe.edu/~millerni/forums.php?show=topic&id=105&forum=13 cheap hoodia] [http://wc1.worldcrossing.com/WebX/.1de60a36 cheap zyban] [http://people.msoe.edu/~millerni/forums.php?show=topic
[[Engine_Development|Development]] < [[Map_development|Map Development]] < {{FULLPAGENAME}}
 
==The Idea==
First of all you need an idea. There is no point (OK, there is some point for test purposes) in making a map just like another one that already exists. You need to think of certain things before you make your map.
# Is this map idea different, not just a copy of someone else's?
# Does my map idea give each player a fair share of the cover and high ground?
# Is my map idea possible to make?
# Is it possible with the amount of time I'm willing to spend?
 
If you answered yes to the above, then you are 25% of the way towards making your map!
 
You should probably doodle it on a piece of paper to act as a guide later.
 
==The Tools==
With your idea hopefully sketched out, it's time to get the tools to make the map! (You can skip this if you already have them.)
 
For all your map compiling needs you should first download the newest [[MapConv]] program.
 
You will also need some image editing software. Favorites are Photoshop, the [http://www.gimp.org/ GIMP], And Paintshop Pro.
The GIMP, however, is the only one that's free!
(I'm going to have to assume you know how to use the program you choose. If you can't there are loads of tutorials on the net.)
 
You may also want to check out [http://www.planetside.co.uk/terragen/ Terragen] for generating terrain. But as you have to pay to render anything of a good size, I won't mention it other than here.
 
Another tool you might find useful is the freeware tool [http://www.delphigl.de/projects/terrtexgen/eng_index.html TerrTexGen]. It's useful for previewing your heightmap before compiling, but unless your texturemap is 4096 on both sides, you might find that the texturemaps that it creates are too small.
 
Finally, there is tool called [http://www.bundysoft.com/L3DT/ L3DT] which you might also find useful. It seems to be a program that is specificly designed for creating large height/texture maps. The free version is capable of rendering a heightmap as big as 4096x4096, and can generate a texturemap that is proportional to the heightmap. Of the mentioned packages, this seems the most useful and complete.
 
==Preparing your map==
This is the fun part! And also, often, the longest part.
 
For a map you will need several different things:
# a texture map
# a height map
# a metal map
 
 
They all have certain needs! Read this bit carfully!
 
===Texture Map===
All maps are based on a texture image. This image's width and height must be an exact multiple of 1024 pixels. So, for instance, you can have a "4096 by 8192" image, but not a "4096 by 4608" image, as 4608 does not divide by 1024. It, like  all three maps, must be saved as a 24 bit BMP. A 1024x1024 Texture will produce a map shown as '2x2' in the launcher.
 
It may look like whatever you want! Find a texture (preferably, one that you can tile seamlessly) and fill your texture map with it. You could, for instance, fill the whole image with a sand texture. This would make your whole world look like sand. You could then decide to add a few patches of grass to it by finding a suitable grass texture and adding it on patches. So you'd have a map that was mostly sand with a few patches of green.
 
Because of the way the map compiler works, it will '''greatly''' reduce your map filesize if you use 32x32 tiles on your texture map. So, whenever you have to fill a large area with a repeating pattern, make sure the small square you're repeating is 32x32 (or a multiple of it).
 
===Height Map===
Next is the height map. This must be exactly one eighth (1/8) of the size of the texture map '''+ 1 pixel!''' For instance, if the dimensions of your texture map are "4096 by 8192", divide 4096 and 8192 each by 8 and add one to the result of each. The result for this example would be "513 by 1025". The height map is a black and white BMP. Only use black and white, no colour! (well its better to work it as a greyscale image, and when saving to process, convert to rgb and save as bmp, that way you get a 24 bit bmp)
 
White areas are the tops of mountains; black areas are the sea floor or the bottom of valleys. The shades of grey between are the different heights between! When you draw your heightmap, make sure the white blends into the black with greys. I suggest you use the blur tool. If you have a white splodge in a patch of black you will have a very tall pillar that won't look natural at all!
 
===Metal Map===
Finally, you need a metal map. This is the same size as the height map, one eighth (1/8) of the size of the texture map '''+ 1 pixel.''' On this one you paint down red (in verying degrees) to represent metal. So a red spot that is RGB(50,0,0) will provide about a 5th of the metal patch of red RGB(255,0,0) will give.
 
On this map you can also place green pixels. Each green pixel will create 1 geothermal vent. If you put down a green splodge you will get a cluster of geo vents! Only place 1 pixel.
 
Ensure you have all three saved as 24 bit BMPs and you're ready to convert it all to a map!
 
== MapConv.exe ==
 
Instructions pulled from the newest [[MapConv]] program. If all goes well, the <code>MapConv.exe</code> should create four new files: <code>mini.bmp</code>, <code>mini.dds</code>, <code>yourmapname.smf</code>, and <code>yourmapname.smt</code>
 
Converts a series of .bmp/.raw files to a Spring map. This just creates the .smf file, you will also have to create a .smd file using a text editor or Maelstrom's SMD creator.
 
==Mothers MapConv==
 
[[Mothers MapConv]] is nearly the same Program but it allows to place all Features on their own Featuremap.
 
===But what are these 'Arbitrary Features,' Im so confused!===
They are 'features' found in the /features/All Worlds or /features/corpses filesystems. Which feature is 'type 1' is defined on a map-by-map basis via a new file called 'fs.txt'. This file should contain <cr> delimited feature names. The first line is the feature placed when a red=255 dot is found, etc.
 
=== Ok, Now what do I do? ===
If you are using any custom features, and/or you want to mod-proof your map, you should include them in the [[sd7]] that you package the map in. The tree structure should look something like:
 
<mapname.sd7>
-maps/
-mapname.smf
-mapname.smt
-mapname.smd
-Objects3d/
-<featurename[s]>.3do(specified in the tdf)
-features/
-All Worlds/
(and/or)
-Corpses/
-<featurename[s]>.tdf
-textures/
-tatex/
-<texname[s]>00.bmp or .tga
 
Without getting into modding/unit making I will say that the <code>.tdf</code> tells you the name of the <code>.3do</code> ("<code>Object=</code>"), and the name of the 'feature' is in the top brackets. The <code>.3do</code> specifies the texture names. The engine looks for those texture names + 00 in either bmp or tga format in tatex.  
 
Examples of a built-in XTA wreckage name would be <code>armckfus_dead</code> which would be looking for a tdf (likely <code>armckfus_dead.tdf</code>) that has a <code>[armckfus_dead]</code> section which then specified something like:
<code>Object=armckfus_dead</code>
<code>armckfus_dead.3do</code> would then specify some texture like <code>wreck01b</code> which would go looking for either a <code>wreck01b00.bmp</code> or <code>wreck01b00.tga</code> file.
 
==Making your map work==
This is the final push. Once Sharp map has finshed it will spit out a .sm2 file. This needs to be copied to the MAPS folder in Spring. But you still need one more thing: an .smd file. Basically, this file tells the game things like the maximum metal, the light colours, the clouds, etc. (All the bits you were thinking that you hadn't done yet!)
 
I would suggest you copy the .smd of another map and fiddle with the settings until you get what you want. smd's can be opened in notepad or similar. Look at all the .smd's so you can get a jist of what each option does. Make sure both the .sm2 and .smd have the same file name then start up Spring (not the client!) in [http://taspring.clan-sy.com/wiki/FAQ#People_talk_about_.27Single_Player.27._How_do_I_start_a_single_player_game.3F single-player mode] and run the commanders script. Choose your map and away you go!
 
==SMD Rundown==
What follows is all that we (aGorm and LathanStanley) have figured out in the SMD's. Its by no means the be all and end all, but it's the next best thing.
 
* Goto [[Maps:SMD]] for a more detailed listing
===General Map Information===
* Description is just a short description of your map. Keep it simple.
* TidalStrength determines how much energy tidal generators will produce. A normal figure is around 20.
* Gravity, as you would expect, affects ballisitcs and how far units fly after an explosion.
* MaxMetal is the maximum amount of metal you will gain from one game square in 1 second from an area of metal that had a red value of 255 in your metal map. If making an old style metal deposit map, then this will be quite high: maybe 2 or 3. If you are making a new style metal-all-over-the-place-map, then it will be low: perhaps 0.2. Also for old style maps, you'll have to fiddle with the...
* ExtractorRadius, which is the area that is harvested by 1 metal extractor. For old style maps make this very small, so as they only take from one deposit.
 
=== Atmosphere, Water Colours ===
Each value (it would appear this bit is by no means gospel) is a representation of the RGB values for that parameter. It would appear to be relative, i.e. you can put in what ever numbers you like and the game will work out what you want.  
 
The best way to go about it is to look at it as percentages.
The numbers 1, 0.5, 0.2 refer to 100% red, 50% green and 20% blue. But 2, 1, 0.4, will get the same result. Using numbers below one for all the numbers will result in the colour being less bright.
 
This is all a bit confusing so an example will be given:
 
SkyColor=0.2 0.1 0.5;
 
In this example the sky is coloured with 20% red, 10% green, and 50% blue, approximatly RGB(51,25,127), resulting in a very deep night-time blue. Other colours are added to the initial sky colour. If you set your sun as being a pale yellow and it came out rather green, this is why.  
 
One helpful tip is ''negative'' colour. That's right: you can type in a negative number for a colour and it will remove it from the base sky colour. Just be careful not to go below the original values or you may get a surprise.
 
===The Sun System/Shadow System===
The Sun System/Shadow System is quite a useful tool as well in making your maps look ''well done''.
Within the <code>.smd</code> file there is a line:  
 
: <code>SunDir=-1 1 -.5; //direction of sun</code> <small>(The part after the "//" is a comment)</small>
 
The numbers "-1", "1", ".5" determine the angle and elevation of the sunlight system.  
 
The first number is the X angle (East/West) (from -1 to 1) where any negative number means the sun is on the West (and therefore shadows will be cast east), and any positive number means the sun is on the East (and therefore shadows will be cast west), and if the number is 0 there are no east or west shadows, the sun is directly above you.  
 
The second is its elevation, (0 to 1), this number is how far from the horizion the sun is, ignoring it's angle. Thus, 1 puts the sun directly overhead (while still casting angular shadows) and 0 putting it directly on the horizion.  
 
The final number is the Z angle (North/South). (I know, I know, they wrote the engine with Y as elevation and Z as vertical. Don't blame me.) It is just like the East West positioning, where negative numbers put them on the North, and positive numbers put them on the South.  
 
'''Example Usage:''' If you want the shadows ''in'' one of the boxes (your shadow casting surface is in the middle), use the numbers provided, or start from them and tweak the angle and sun height as seen fit.
 
[[Image:ShadowDirection.gif]]
 
'''Note:''' on the current build, it ''will'' cast the shadows in the proper direction, etc. Negative direction numbers tend to make some maps unstable and cause crashes. The best solution would be to rotate or flip your map to where the shadows point up or right (North or West). I do believe these bugs are being worked on and will be fixed soon.
 
We can only hope this has been helpful! Any questions, or things you think we have missed, please ask us in the maps section.
 
[[Category:Tutorial]]
[[Category:Map making]]

Latest revision as of 09:24, 19 October 2014

Development < Map Development < Tutorial:CreateMaps(Fnordia et al)

The Idea

First of all you need an idea. There is no point (OK, there is some point for test purposes) in making a map just like another one that already exists. You need to think of certain things before you make your map.

  1. Is this map idea different, not just a copy of someone else's?
  2. Does my map idea give each player a fair share of the cover and high ground?
  3. Is my map idea possible to make?
  4. Is it possible with the amount of time I'm willing to spend?

If you answered yes to the above, then you are 25% of the way towards making your map!

You should probably doodle it on a piece of paper to act as a guide later.

The Tools

With your idea hopefully sketched out, it's time to get the tools to make the map! (You can skip this if you already have them.)

For all your map compiling needs you should first download the newest MapConv program.

You will also need some image editing software. Favorites are Photoshop, the GIMP, And Paintshop Pro. The GIMP, however, is the only one that's free! (I'm going to have to assume you know how to use the program you choose. If you can't there are loads of tutorials on the net.)

You may also want to check out Terragen for generating terrain. But as you have to pay to render anything of a good size, I won't mention it other than here.

Another tool you might find useful is the freeware tool TerrTexGen. It's useful for previewing your heightmap before compiling, but unless your texturemap is 4096 on both sides, you might find that the texturemaps that it creates are too small.

Finally, there is tool called L3DT which you might also find useful. It seems to be a program that is specificly designed for creating large height/texture maps. The free version is capable of rendering a heightmap as big as 4096x4096, and can generate a texturemap that is proportional to the heightmap. Of the mentioned packages, this seems the most useful and complete.

Preparing your map

This is the fun part! And also, often, the longest part.

For a map you will need several different things:

  1. a texture map
  2. a height map
  3. a metal map


They all have certain needs! Read this bit carfully!

Texture Map

All maps are based on a texture image. This image's width and height must be an exact multiple of 1024 pixels. So, for instance, you can have a "4096 by 8192" image, but not a "4096 by 4608" image, as 4608 does not divide by 1024. It, like all three maps, must be saved as a 24 bit BMP. A 1024x1024 Texture will produce a map shown as '2x2' in the launcher.

It may look like whatever you want! Find a texture (preferably, one that you can tile seamlessly) and fill your texture map with it. You could, for instance, fill the whole image with a sand texture. This would make your whole world look like sand. You could then decide to add a few patches of grass to it by finding a suitable grass texture and adding it on patches. So you'd have a map that was mostly sand with a few patches of green.

Because of the way the map compiler works, it will greatly reduce your map filesize if you use 32x32 tiles on your texture map. So, whenever you have to fill a large area with a repeating pattern, make sure the small square you're repeating is 32x32 (or a multiple of it).

Height Map

Next is the height map. This must be exactly one eighth (1/8) of the size of the texture map + 1 pixel! For instance, if the dimensions of your texture map are "4096 by 8192", divide 4096 and 8192 each by 8 and add one to the result of each. The result for this example would be "513 by 1025". The height map is a black and white BMP. Only use black and white, no colour! (well its better to work it as a greyscale image, and when saving to process, convert to rgb and save as bmp, that way you get a 24 bit bmp)

White areas are the tops of mountains; black areas are the sea floor or the bottom of valleys. The shades of grey between are the different heights between! When you draw your heightmap, make sure the white blends into the black with greys. I suggest you use the blur tool. If you have a white splodge in a patch of black you will have a very tall pillar that won't look natural at all!

Metal Map

Finally, you need a metal map. This is the same size as the height map, one eighth (1/8) of the size of the texture map + 1 pixel. On this one you paint down red (in verying degrees) to represent metal. So a red spot that is RGB(50,0,0) will provide about a 5th of the metal patch of red RGB(255,0,0) will give.

On this map you can also place green pixels. Each green pixel will create 1 geothermal vent. If you put down a green splodge you will get a cluster of geo vents! Only place 1 pixel.

Ensure you have all three saved as 24 bit BMPs and you're ready to convert it all to a map!

MapConv.exe

Instructions pulled from the newest MapConv program. If all goes well, the MapConv.exe should create four new files: mini.bmp, mini.dds, yourmapname.smf, and yourmapname.smt

Converts a series of .bmp/.raw files to a Spring map. This just creates the .smf file, you will also have to create a .smd file using a text editor or Maelstrom's SMD creator.

Mothers MapConv

Mothers MapConv is nearly the same Program but it allows to place all Features on their own Featuremap.

But what are these 'Arbitrary Features,' Im so confused!

They are 'features' found in the /features/All Worlds or /features/corpses filesystems. Which feature is 'type 1' is defined on a map-by-map basis via a new file called 'fs.txt'. This file should contain <cr> delimited feature names. The first line is the feature placed when a red=255 dot is found, etc.

Ok, Now what do I do?

If you are using any custom features, and/or you want to mod-proof your map, you should include them in the sd7 that you package the map in. The tree structure should look something like:

<mapname.sd7>
-maps/
-mapname.smf
-mapname.smt
-mapname.smd
-Objects3d/
-<featurename[s]>.3do(specified in the tdf)
-features/
-All Worlds/
(and/or)
-Corpses/
-<featurename[s]>.tdf
-textures/
-tatex/
-<texname[s]>00.bmp or .tga

Without getting into modding/unit making I will say that the .tdf tells you the name of the .3do ("Object="), and the name of the 'feature' is in the top brackets. The .3do specifies the texture names. The engine looks for those texture names + 00 in either bmp or tga format in tatex.

Examples of a built-in XTA wreckage name would be armckfus_dead which would be looking for a tdf (likely armckfus_dead.tdf) that has a [armckfus_dead] section which then specified something like: Object=armckfus_dead armckfus_dead.3do would then specify some texture like wreck01b which would go looking for either a wreck01b00.bmp or wreck01b00.tga file.

Making your map work

This is the final push. Once Sharp map has finshed it will spit out a .sm2 file. This needs to be copied to the MAPS folder in Spring. But you still need one more thing: an .smd file. Basically, this file tells the game things like the maximum metal, the light colours, the clouds, etc. (All the bits you were thinking that you hadn't done yet!)

I would suggest you copy the .smd of another map and fiddle with the settings until you get what you want. smd's can be opened in notepad or similar. Look at all the .smd's so you can get a jist of what each option does. Make sure both the .sm2 and .smd have the same file name then start up Spring (not the client!) in single-player mode and run the commanders script. Choose your map and away you go!

SMD Rundown

What follows is all that we (aGorm and LathanStanley) have figured out in the SMD's. Its by no means the be all and end all, but it's the next best thing.

  • Goto Maps:SMD for a more detailed listing

General Map Information

  • Description is just a short description of your map. Keep it simple.
  • TidalStrength determines how much energy tidal generators will produce. A normal figure is around 20.
  • Gravity, as you would expect, affects ballisitcs and how far units fly after an explosion.
  • MaxMetal is the maximum amount of metal you will gain from one game square in 1 second from an area of metal that had a red value of 255 in your metal map. If making an old style metal deposit map, then this will be quite high: maybe 2 or 3. If you are making a new style metal-all-over-the-place-map, then it will be low: perhaps 0.2. Also for old style maps, you'll have to fiddle with the...
  • ExtractorRadius, which is the area that is harvested by 1 metal extractor. For old style maps make this very small, so as they only take from one deposit.

Atmosphere, Water Colours

Each value (it would appear this bit is by no means gospel) is a representation of the RGB values for that parameter. It would appear to be relative, i.e. you can put in what ever numbers you like and the game will work out what you want.

The best way to go about it is to look at it as percentages. The numbers 1, 0.5, 0.2 refer to 100% red, 50% green and 20% blue. But 2, 1, 0.4, will get the same result. Using numbers below one for all the numbers will result in the colour being less bright.

This is all a bit confusing so an example will be given:

SkyColor=0.2 0.1 0.5;

In this example the sky is coloured with 20% red, 10% green, and 50% blue, approximatly RGB(51,25,127), resulting in a very deep night-time blue. Other colours are added to the initial sky colour. If you set your sun as being a pale yellow and it came out rather green, this is why.

One helpful tip is negative colour. That's right: you can type in a negative number for a colour and it will remove it from the base sky colour. Just be careful not to go below the original values or you may get a surprise.

The Sun System/Shadow System

The Sun System/Shadow System is quite a useful tool as well in making your maps look well done. Within the .smd file there is a line:

SunDir=-1 1 -.5; //direction of sun (The part after the "//" is a comment)

The numbers "-1", "1", ".5" determine the angle and elevation of the sunlight system.

The first number is the X angle (East/West) (from -1 to 1) where any negative number means the sun is on the West (and therefore shadows will be cast east), and any positive number means the sun is on the East (and therefore shadows will be cast west), and if the number is 0 there are no east or west shadows, the sun is directly above you.

The second is its elevation, (0 to 1), this number is how far from the horizion the sun is, ignoring it's angle. Thus, 1 puts the sun directly overhead (while still casting angular shadows) and 0 putting it directly on the horizion.

The final number is the Z angle (North/South). (I know, I know, they wrote the engine with Y as elevation and Z as vertical. Don't blame me.) It is just like the East West positioning, where negative numbers put them on the North, and positive numbers put them on the South.

Example Usage: If you want the shadows in one of the boxes (your shadow casting surface is in the middle), use the numbers provided, or start from them and tweak the angle and sun height as seen fit.

Note: on the current build, it will cast the shadows in the proper direction, etc. Negative direction numbers tend to make some maps unstable and cause crashes. The best solution would be to rotate or flip your map to where the shadows point up or right (North or West). I do believe these bugs are being worked on and will be fixed soon.

We can only hope this has been helpful! Any questions, or things you think we have missed, please ask us in the maps section.