Important: Age of Empires II: The Conquerors Expansion allows you to create your own random map scripts. You may share these custom random map scripts for the purposes of gameplay, ut you may not sell or ma!e other commercial uses of the custom random map scripts. "icrosoft Corporation reser#es all other rights to the editors and files. COPRIG!T "OTICE This information contained in this pu#$ication%document &the 'Information() ma* #e redistri#uted on$* as permitted #* the text #e$o+ and pro,ided that such Information and this cop*right notice remain intact- "o part of the Information ma* in an* form or #* an* e$ectronic. mechanica$. photocopied. recorded or an* other means #e reproduced. stored in a retrie,a$ s*stem. #roadcast or transmitted +ithout the prior +ritten permission of the pu#$isher of the Information. Ensem#$e Studios Corporation- "either the Information nor an* portion thereof ma* #e stored in a computer or other e$ectronic storage de,ice except for persona$ and non/commercia$ use- 0sers of the Information must see1 permission from Ensem#$e Studios Corporation for a$$ uses that are not a$$o+ed #* fair use and other pro,isions of the 0- S- Cop*right Act. as amended from time to time &the 'Act()- This Information ma* not. under an* circumstances. #e reso$d or redistri#uted for compensation of an* 1ind +ithout the prior +ritten permission of Ensem#$e Studios Corporation. 23443 "- Centra$ Express+a*. Suite 2533. 6a$$as. T7 89:;2- The Information ma* on$* #e used as a source of data and ma* on$* #e used for non/commercia$ purposes- An* cop* of this Information or portion thereof must inc$ude this cop*right notice- An* pu#$ished data contained in the Information. inc$uding 0R< and other Internet =e# Site references. is su#>ect to change from time to time +ithout notice- The Information does not carr* a +arrant* of an* 1ind. +hether express or imp$ied- A$though e,er* effort is made to pro,ide the most accurate and up/to/date information possi#$e. Ensem#$e Studios Corporation ac1no+$edges that this Information cou$d inc$ude certain errors. inc$uding t*pographica$ errors and technica$ inaccuracies- Additions and changes +i$$ #e made to the Information on an on/going #asis? thus the Information contained herein is su#>ect to change +ithout prior notice- Comp$*ing +ith the Act and a$$ other app$ica#$e federa$ or state cop*right $a+s is the so$e responsi#i$it* of the user- The user here#* is deemed to assume a$$ such cop*right $a+ comp$iance responsi#i$it* #* his or her use of the Information- Ensem#$e Studios Corporation ma* ha,e 0-S- federa$ and%or state patents. patent app$ications. trademar1s. ser,ice mar1s. trade names. cop*rights or other inte$$ectua$ propert* rights co,ering su#>ect matter in the Information- Except as express$* pro,ided in an* +ritten $icense agreement from Ensem#$e Studios Corporation. the furnishing of the Information does not gi,e the user an* $icense to such patents. patent app$ications. trademar1s. ser,ice mar1s. trade names. $"%&.doc ' cop*rights or other inte$$ectua$ propert* rights. +hich are express$* retained #* Ensem#$e Studios Corporation- $"%&.doc ( Ta#$e of Contents Introduction..................................................................................................................................... ) %yntax............................................................................................................................................. ) "ap si*es.................................................................................................................................... + &loal instructions.......................................................................................................................... + ,ocal instructions............................................................................................................................ - &eneration Instructions............................................................................................................... - %cript writing tips.......................................................................................................................... '- $esources................................................................................................................................. '- %etting *ones............................................................................................................................ '- Testing player start areas.......................................................................................................... '- %cattering o.ects...................................................................................................................... '- "a!ing it all fit........................................................................................................................... '- %tandard resources................................................................................................................... '/ 0.ect names............................................................................................................................... '/ Annotated $andom "ap %cript................................................................................................. () Introduction $andom "ap scripts are text files that can e composed in any text editor. They must end with 1.$"% and must e placed in the $A230" directory. $andom "ap scripts are automatically transferred in multiplayer games to players who do not ha#e them. $andom "ap scripts place the same starting terrain and resources for e#ery player. It is not possile to start different players with different resources. Thus, all scripts in theory will e fair to all players. 4owe#er, !nowledge of a map script can still help a player when playing on that map. 5erhaps the player !nows that there is a lot of gold generated in the center of the map 6as in &old $ush7. 8hen you play on someone else9s $andom "ap script, you are placing some trust in that person that the map is going to e interesting and fair. Computer 5layers should e ale to play on any $andom "ap script, ut unless you compose a new .AI file for that map, the Computer 5layer may not play with optimal efficiency. :or example, the Computer 5layer may not uild oats e#en if the map has ample water. "a!ing $andom "aps that can consistently gi#e each player the resources they need can e difficult and may in#ol#e a lot of trial and error. 3on9t get frustrated. Internet fan sites are a great resource for hints, tric!s and other support for ma!ing maps that wor!. A $andom "ap starts with ,and first, then Ele#ation, then Terrain, and finally Cliffs and Connections. The order is important. S*ntax $andom map scripts are case sensiti#e. ;races <= enclose commands under specific instruction. 0pening and closing races must e on their own line. >1 %lashes and asteris!s enclose comments that the scripting system ignores, such as remar!s, su?headings, etc. @se >1 to open a comment and 1> to close it. ;e sure to lea#e a space etween the 1 and other characters. $"%&.doc ) ;rac!ets AB enclose #ariales. These are not used in the random map scripts themsel#es, only in the context of this document. If an instruction says CAnumerBD, .ust type C)-D not CA)-BD. Instructions that egin with CsetD do not require a #ariale. Map si@es Map $a#e$ Ti$es on a side Tota$ ti$es Sca$ing factor tinyEmap F(xF( -,'G+ H.- smallEmap I/xI/ I,('/ H.I mediumEmap '(Hx'(H '+,+HH '.+ largeEmap '++x'++ (H,F)/ (.' hugeEmap (HHx(HH +H,HHH +.H giganticEmap (--x(-- /(,H(- /.( %caling factor can e used to place more o.ects on a larger map relati#e to a smaller map. A &igantic "ap is '(.+ times larger than a Tiny "ap, e#en though one side of each map is only ).+ times larger. "ap laels can e used in if?then statements. Examp$e: If medium_map create_object STONE { number_of_objects 7 number_of_groups 2 group_placement_radius 3 } endif G$o#a$ instructions &loal instructions are used to control script flow, ma!e the script change from run to run, and ma!e script control easier. Adefine B$a#e$C 3efines a #ariale that you can use later on. Examp$e: Start_random percent_cance 33 !define "ESE#T_$%& end_random This instruction gi#es a ))J chance of the map eing a C3E%E$TE"A5D. You could then say if 3E%E$TE"A5 later on to put down sand instead of grass or palm trees instead of oa!s. BconstDnameC Anum#er $"%&.doc + Constants are used to tie a name, such as an o.ect or terrain, with its identifier in the dataase. Ensemle %tudios has already pre?defined all necessary constants in the randomEmap.def file so they do not need to e changed. if B$a#e$C e$seif B$a#e$C e$se endif Conditional statements are used when there is more than one option. :or example: If the map is gigantic, then add extra resources. If the map is a desert map, then use sand instead of grass. CIfD initiates the conditional statement and CendifD completes it. @se CelseD to specify all other conditions, or CelseifD to specify a single other condition. Examp$e: if %'&INE_$%& base_terrain (%TE# elseif "ESE#T_$%& base_terrain "ESE#T else base_terrain )#%SS2 endif startDrandom percentDchance BpercentC endDrandom $andom statements are used to specify an instruction running only part of the time. The random chance is specified as a percent 6'?'HH7. If the percents do not add up to 'HH, then the remaining percentage will apply towards a default setting. E#erything etween startErandom and endErandom is considered part of the same random instruction. $andom statements can e nested inside each other. Examp$e: start_random percent_cance 2* !define "ESE#T_$%& percent_cance 2* !define %'&INE_$%& end_random The map will e a desert (HJ of the time, an alpine map (HJ of the time, and a normal 6proaly grass7 map the remaining /HJ of the time. Alternati#ely, the instruction could ha#e had the line to define grass map at /HJ, ut this is not necessary. <oca$ instructions The following instructions are used to create a random map. %ome instructions require a #ariale, which is generally a numer K, a numer of tiles Ktiles, or a terrain constant Aterrain constantB. Instructions that egin with CsetD do not require a #ariale. Generation Instructions $"%&.doc - ;efore any specific instructions can e gi#en, you must indicate what part of the random map the instructions refer to. :or example, ATE$$AI2E&E2E$ATI02B tells the random map generator that the instructions that follow refer to terrain. A $andom "ap starts with ,and first, then Ele#ation, then Terrain and finally Cliffs and Connections. The order is important. The se#en generation instructions are explained elow along with their specific instructions. A5,AYE$E%ET@5B 5laces players A,A23E&E2E$ATI02B Creates types of land, such as islands and player lands ATE$$AI2E&E2E$ATI02B Creates terrain, such as forests and desert A0;LECT%E&E2E$ATI02B Creates o.ects, such as trees, gold mines and #illagers AC022ECTI02E&E2E$ATI02B Connects different land *ones such as shallows etween islands AE,EMATI02E&E2E$ATI02B Creates ele#ation to place hills AC,I::E&E2E$ATI02B Creates cliffs BP<AERDSET0PC randomDp$acement 5laces players randomly. This is the only #alid entry under A5,AYE$E%ET@5B. All maps must ha#e this line in them. B<A"6DGE"ERATIO"C ,and is used to create something aside from the default terrain type, most typically islands of grass in water. There are two types of land, normal lands 6.ust called ,ands7 and 5layer ,ands. In most random maps, 5layer ,ands include a Town Center, %cout Ca#alry, #illagers, and the starting resources placed near the Town Center. 5layer ,ands is also useful for telling terrain, such as forests, to a#oid the player start areas. ,and is all generated at the same time, so the order used in placing land is not important. 6Terrain and o.ects, howe#er, are placed in order.7 #aseDterrain Bterrain constantC %pecifies what default terrain to start with. An island map proaly uses water, while a grassland map uses grass. Examp$e: base_terrain (%TE# createDp$a*erD$ands EinstructionsF %tarts creating 5layer ,ands. The percentage of land allotted to player lands is di#ided among all the players. Therefore, if player lands were specified to ta!e up (HJ of the map, then ( players would each get 'HJ, ut + players would each get -J. It is important that player lands e large enough to contain a player9s town. If player lands on an island map are too small, then the Town Center might e susceptile to fire from oats. 0n a hill country map, hills might e placed too close to the Town Center. 5layer lands are always set at a constant ele#ation of (. Examp$e: create_pla+er_lands { terrain_t+pe grass base_si,e -* land_percent 2* } $"%&.doc / Creates an area for each player that is 'H tiles of grass in si*e. createD$and EinstructionsF Creates an area of land that is not for players. 8hat type of lands are there to ma!eN In an island map, you might want to lay down onus islands that contain gold. You might want to create a mountain range in the middle of a map. terrainDt*pe BterrainDconstantC %pecifies what type of terrain to ma!e the land. :or 5layer ,ands, this must e grass or desert to a#oid goofy results. $andDpercent BpercentC 3efines what percent of the map is ta!en up y the land area. :or 5layer ,ands, this area will e di#ided y the numer of players, so if the numer is set to /HJ and there are / players, each will start with aout 'HJ of the map. ;est results seem to occur when using /H?GHJ. num#erDofDti$es BA ti$esC An alternate way of specifying land area si*e, in this case y numer of tiles. @nli!e ,andEpercent, these areas will not scale with map si*e. It is necessary to use only ,andEpercent or 2umerEofEtiles. #aseDsi@e BA ti$esC %pecifies a minimum radius that the land grows from. This instruction is useful for insuring that each player has an area large enough to uild a town and !eep at least some uildings free from na#al omardment. If ;aseEsi*e is not specified, 5layer ,ands may e thin and sna!y. $eftD#order BpercentC rightD#order BpercentC topD#order BpercentC #ottomD#order BpercentC 5ercent from edge to stop land growth. This instruction recogni*es the distance to the map order, so it is useful for placing terrain near the middle of the map. :or example, defining a order of (- will place land near the center of the map, while a order of - will place land almost to the edge of the map. In "editerranean and ;altic maps, this instruction places the inland sea near the center of the map. In Continental maps, this instruction insures there is a order of water. CTopD is random on the maps, so .ust specifying Top and ;ottom ut not ,eft or $ight can create a narrow strip of terrain. 2ote that the map land had a hard?coded feature to round off edges to ma!e land loo! more natural. As maps get smaller 6order B (HJ7 they may loo! less li!e rectangles and more li!e circles or octagons. #orderDfu@@iness BpercentC The percent chance per tile of stopping at a order. If this instruction is not used, orders will e straight lines. %pecifying a low numer, -?(H, will ma!e edges ragged and more li!e real geography. @one BA @oneC $"%&.doc F This is a descripti#e command, used to assign a lael to a certain land area. Oones with the same *one id can o#erlap, while land areas with different id9s are distinct. If no *one is specified, each player will e on their own island 6though it will only loo! li!e an island if the ase terrain is water7. $andDid BA idC Assigns a lael to a certain land area that can e used to assign o.ects only to that land. setD@oneD#*Dteam 8ill !eep all players on a certain team in the same *one. :or example, on an island map this will allow a team to share an island. To !eep e#eryone on their own island, do not include this command. setD@oneDrandom$* 8ill randomly determine *ones, so that some players may e on the same island, while others may not e. otherD@oneDa,oidanceDdistance BA ti$esC This instruction is the one that specifies how large a land should e, so if it is not included, the land will not appear. Oone a#oidance is used to specify the width of ri#ers etween player lands. assignDtoDp$a*er BA p$a*erC Assigns a land area to a certain player. 2ote, this does not wor! with player lands. c$umpingDfactor BA factorC Clumping affects how much land tends to form squares instead of rectangles. The default #alue is G, and the range is ' to '-. ,ower numers tend to produce sna!y islands while higher numers tend to produce squares. 2ote that clumpingEfactor for land and for terrain ha#e different ranges and defaults. BTERRAI"DGE"ERATIO"C Terrain is different from ,and. ,and is used to create something aside from the default terrain type, most typically islands of grass in water. Terrain includes features on that land, such as desert and forests. An important distinction is that land is placed down efore ele#ation, ut terrain is placed down after ele#ation. The order terrain is placed is also important. If you place palm desert on desert terrain efore you place any desert terrain on the map, then you aren9t going to see any palm trees. $ememer, land is placed all at once. Terrain and o.ects are placed in order. createDterrain Bterrain constant C EinstructionsF Creates a clump of terrain Examp$e: create_terrain &%'$_"ESE#T { base_terrain "ESE#T spacing_to_oter_terrain_t+pes 3 land_percent - $"%&.doc G number_of_clumps 3 set_a.oid_pla+er_start_areas } Creates ) clumps of 5alm 3esert on 3esert terrain. These clumps will ta!e up a total of 'J of all tiles and will e placed away from 5layer %tart Areas.
#aseDterrain Bterrain constant C %pecifies what terrain type the new terrain will e placed on. :or example, palm desert could e placed on desert, or grass) could e placed on grass'. $andDpercent BApercent of map to co,erC The percent of total land that this terrain will co#er. It is est to use small percentages 6'?'H7 for terrain if many different types of terrain are going to e laid down. num#erDofDti$es BAsi@e of terrain c$ump in ti$esC The si*e of terrain can e placed in terms of tiles instead of as a percent. 5ercent is generally more useful as it will automatically scale with map si*e. num#erDofDc$umps BAnum#er of c$umps to p$aceC The percent or numer of tiles of terrain are e#enly distriuted into clumps. If numer of clumpsP) and numer of tileP'G, the terrain will e appear as ) clumps of / tiles each. spacingDtoDotherDterrainDt*pes BAdistance from other terrain t*pesC %pecifies how far terrain should e from other terrain 6including terrain of the same type7. This command is useful for pre#enting trees from ecoming connected walls, or !eeping forests away from water. It is a good idea to specify some distance for terrain that loc!s mo#ement, ut is not necessary for terrain such as desert and grass. setDsca$eD#*Dgroups %cales numer of terrain clumps with map si*e 6ase 'HHx'HH map7. %o, if ( clumps are specified, then a large map would ha#e ( 6( x '.+7 clumps, ut a &igantic map would ha#e ') 6( x /.-7 clumps. setDsca$eD#*Dsi@e %cales si*e of terrain patch with map si*e. %o, if 'H tiles are specified, then a large map would ha#e '+H 6'H x '.+7 tiles, ut a &igantic map would ha#e /-H 6'H x /.-7 tiles. setDa,oidDp$a*erDstartDareas "ost terrain, li!e forests and water, will a#oid player start areas y default, ut this instruction can e used, for example, if you want desert to a#oid Town Centers. c$umpingDfactor BAfactorC Clumping affects how much land tends to form squares instead of rectangles. The default #alue is (H. ,ower numers tend to produce sna!y patches while higher numers tend to produce squares. 2ote that clumpingEfactor for land and for terrain ha#e different ranges and defaults. heightD$imits BAminimum ti$e heightC BAmaximum ti$e heightC $"%&.doc I %pecifies on what ele#ation terrain can e placed 6from H?G7. This instruction can e used to place grass on hill tops or place water only in depressions. setDf$atDterrainDon$* Instructs terrain to a#oid hills. @seful for ma!ing sure ponds don9t cross more than one ele#ation. BOGHECTSDGE"ERATIO"C 0nce land, ele#ation and terrain are placed, you are ready to place o.ects. 2ote that some o.ects may already e placed y terrain. :orests, for example, will e filled with tree o.ects. 4owe#er, you will need to specify starting units, resources and other o.ects needed to ma!e a map ha#e more character and detail. $ememer, land is placed all at once. Terrain and o.ects are placed in order. createDo#>ect Bo#>ect constant C EinstructionsF 5laces an o.ect. Examp$e: create_object )O'" { number_of_groups 2 number_of_objects 3 group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } &i#es e#ery player ( piles of gold with ) gold o.ects in each pile. The pile is confined to a radius of ( tiles and is placed from I to +H tiles from the center of a player9s lands. minDdistanceDtoDp$a*ers BAnum#er of ti$esC maxDdistanceDtoDp$a*ers BAnum#er of ti$esC %pecifies the limits where the o.ect can e placed relati#e to the center of a piece of land. The o.ect will appear at random anywhere etween the minimum and maximum. :or example, a Town Center placed at minimum H and maximum H will appear in the center of each player9s lands. A gold mine placed at 'H to '( will appear aout one screen away from the Town Center, ut not too far away. The defaults for these instructions are H and infinity, respecti#ely, so if no distance is specified, the o.ect will appear somewhere on that land. ;e careful not to specify a minimum that is greater than the land radius, or the o.ect may not appear or may appear in the wrong location. $ememer that when used with placeEonEspecificElandEid instead of setEplaceEforEe#eryEplayer that the distances refer to the center of that piece of land and not to the players. setDsca$ingDtoDmapDsi@e %cales the numer of groups to larger or smaller maps. 8hen this instruction is used, numerEofEgroups will apply only to ,arge "aps. :or example, if / groups are specified on a ,arge "ap, then a "edium "ap will ha#e + groups, and a %mall "ap will ha#e (. 2ote: If numerEofEgroups is not used 6essentially ma!ing all the o.ects separate7, then scaling will apply to the o.ects themsel#es. This is a good way to scatter things li!e fish and trees on a map. $"%&.doc 'H %pecify a large numer of o.ects ut no groups and then use setEscalingEofEgroupsEtoEmapEsi*e. Alternati#ely, you can create a large numer of groups with one o.ect each. The effect will e the same. 2ote that scaling can e set to player numer or map si*e, not oth. 4owe#er, it is possile to ha#e different o.ects of the same type set to different scales. 0ne gold mine could scale to player numer, while another scales to map si*e. Examp$e: create_object 1IS2 { number_of_objects 3* set_scaling_to_map_si,e terrain_to_place_on (%TE# set_gaia_object_onl+ min_distance_group_placement / } Creates -H fish 6on a ,arge "ap, fewer on a smaller map, more on a larger map7 scattered across the water, ut ne#er more than + tiles from another fish. setDsca$ingDtoDp$a*erDnum#er 2ote that scaling can e set to player numer or map si*e, not oth. 4owe#er, it is possile to ha#e different o.ects of the same type set to different scales. 0ne gold mine could scale to player numer, while another scales to map si*e. minDdistanceDgroupDp$acement BAti$esC 3istance to separate center of a groupQpre#ents a massi#e wad of gold, stone and erries all together. Lust as in setEscalingEofEgroupsEtoEmapEsi*e, if no groups are assigned, then this instruction will apply to all o.ects. 2ote: groupEplacementEradius, setElooseEgrouping, and setEtightEgrouping will all o#erride scattering of o.ects and !eep a group together.
Examp$e: create_object 1IS2 { number_of_objects 3* set_scaling_of_groups_to_map_si,e terrain_to_place_on (%TE# set_gaia_object_onl+ min_distance_group_placement / } Creates -H fish 6on a ,arge "ap, fewer on a smaller map, more on a larger map7 scattered across the water, ut ne#er more than + tiles from another fish. maxDdistanceDtoDotherD@ones BAti$esC %pecifies how close the o.ects can e to other *ones. This is useful it !eeping o.ects away from the shore 6and enemy ships.7 num#erDofDo#>ects BA o#>ectsC $"%&.doc '' %pecifies how many o.ects are placed, e.g. gold mines in a patch of mines. If no groups are specified, then there will e one group for each o.ect. In other words, the o.ects will all e scattered. num#erDofDgroups BA groupsC %pecifies the numer of groups placed. Each group will ha#e the numer of o.ects specified in numerEofEo.ects. If no groups are specified, then there will e one group for each o.ect. In other words, the o.ects will all e scattered. groupD,ariance BA num#er added or su#tracted from num#erDofDgroupsC %ometimes you want some randomness in the numer of o.ects placed. &roupE#ariance will add or sutract from the numer of o.ects in a group. :or example, a group of ) deer with a #ariance of ( will actually place from ' to - deer at random. groupDp$acementDradius BAti$esC %pecifies how much area is occupied y a group. &roups of large o.ects can ecome #ery long if the o.ects are placed in a row. %pecifying a small groupEplacementEradius will confine a group to a smaller area. setD$ooseDgrouping setDtightDgrouping ,oose groups can ha#e a tile or two of space among the o.ects, li!e sheep or deer. Tight groups ha#e no space among the o.ects, li!e gold or stone. terrainDtoDp$aceDon Bterrain constant C Confines the group to a certain terrain. :or example, you can place gold mines only on desert terrain. If no terrain is specified, the o.ect will e placed anywhere on the map within reason. ;e sensile??some o.ects can only e placed on water 6li!e fish7 and others can only e placed on land 6li!e #illagers and trees7. setDgaiaDo#>ectDon$* @sed if you want an o.ect to e &aia 6elonging to no player7, such as sheep or onus units hidden on the map. 8ill not affect o.ects with no inherent ownership, li!e gold or trees. setDp$aceDforDe,er*Dp$a*er 5laces a group for e#ery player who .oins the game. If you want there to e one $elic for e#ery player, or one Town Center for e#ery player, use this command. If you want e#ery player to start with a pile of gold, use this command. If you want an extra pile of gold lying out in the wilderness, do not use this command. p$aceDonDspecificD$andDid B$and idC If you designated a piece of land as a particular id, you can now use that id to place o.ects only on this land. 0n the Crater ,a!e map, this command is used to place the onus gold on the spire at the center of the inland la!e.
BE<EIATIO"DGE"ERATIO"C $"%&.doc '( After land is placed, ut efore terrain is placed, you can specify how hilly a section of land is. Ele#ation is laid down asically li!e terrain. ;aseEterrain, numerEofEclumps, numerEofEtiles, setEscaleEyEgroups and setEscaleEyEsi*e all wor! for ele#ation the way they do for terrain. Ele#ations always a#oid player start areas. createDe$e,ation BA maximum heightC EinstructionsF 5laces hills. The range of ele#ation is from ' to F. 2ote that ele#ations are not placed at the specified ele#ation ut up to the specified ele#ation. Thus if you state ele#ation /, you will get some ele#ations at '?/. %tating ele#ation F will create '?F. Examp$e: create_ele.ation 7 { if "ESE#T_$%& base_terrain "I#T elseif %SI%N_$%& base_terrain )#%SS2 else base_terrain )#%SS endif number_of_clumps -/ number_of_tiles -*** set_scale_b+_groups set_scale_b+_si,e } 5laces 'HHH tiles of up to le#el F ele#ation on dirt, grass( or grass. BC<IJJDGE"ERATIO"C Cliffs can add extra di#ersity to maps with a lot of open space, though they may crowd smaller islands. Examp$e: min_number_of_cliffs 3 ma4_number_of_cliffs 5 min_lengt_of_cliff / ma4_lengt_of_cliff -* cliff_curliness -* min_distance_cliffs 3 5laces -?G cliffs of +?'H length on the map, ut !eeps them ) tiles away from each other. minDnum#erDofDc$iffs BAnum#er of c$iffsC maxDnum#erDofDc$iffs BAnum#er of c$iffsC %pecifies a range for how many cliffs are placed on a map. %pecifying a minimum of ' and a maximum of '( will place ' to '( cliffs on a map. minD$engthDofDc$iff BAnum#er of ti$esC maxD$engthDofDc$iff BAnum#er of ti$esC %pecifies the length of each cliff. $"%&.doc ') c$iffDcur$iness BApercentC %pecifies the percent chance a cliff will turn instead of continuing straight. 4igh numers will produce *ig*ag cliffs, while low numers will produce straight lines. As with e#erything, experiment. minDdistanceDc$iffs BAti$esC In order to !eep cliffs from forming too close to other cliffs, specify a minimum distance. BCO""ECTIO"DGE"ERATIO"C Connections are lines drawn among player lands. Connections can e used to place roads etween Town Centers, to place shallows across ri#ers, or to cut clearings through forests. createDconnectDteamsD$ands EInstructionsF createDconnectDa$$D$ands EInstructionsF createDconnectDa$$Dp$a*ersD$and EInstructionsF ,and can e connected .ust among team memers, among all players, or among all lands placed on a map. "ore than one connection can e placed. :or ;lac! :orest, one set of connections opens up paths among players while another set places roads .ust among team memers. Examp$e: 67ONNE7TION_)ENE#%TION8 create_connect_all_pla+ers_land { replace_terrain (%TE# S2%''O( replace_terrain $E"_(%TE# S2%''O( replace_terrain "EE&_(%TE# S2%''O( terrain_cost (%TE# 7 terrain_cost $E"_(%TE# 0 terrain_cost "EE&_(%TE# -3 terrain_si,e (%TE# 3 - terrain_si,e $E"_(%TE# 3 - terrain_si,e "EE&_(%TE# 3 - } Connects e#ery player y placing shallows across water, with a preference for shallow water o#er deep water. rep$aceDterrain BterrainDconstantC BterrainDconstantC @sually when you ma!e connections, you want to replace one terrain with another, such as replacing water with shallows or replacing forest with road. You need to use a replace terrain command for each type of terrain placed on a map. %o, if you mix grass', grass( and grass), you need a replace terrain command for each. terrainDcost BterrainDconstantC BAcost to pass through a ti$eC Assigning costs to terrain can force a connection to ta!e a different route. If you want your shallows to a#oid deep water and try and follow shallow water, then assign a high cost to deep water 6li!e '-7 and a lower cost to shallow water 6li!e F7. terrainDsi@e BterrainDconstantC BAti$e radiusC BA,arianceC $"%&.doc '+ You need to specify how wide a connection is going to e. A three?tile wide stretch of shallows will e easier to defend than a fifteen?tile wide shallows. :or each terrain through which a connection may pass, specify a tile radius and a #ariance on that radius. :or example, terrainEsi*e "E3E8ATE$ ) ', create shallows that are '?+ tiles 6) R>? '7 in width. Script +riting tips Resources 0n Ensemle %tudios map types, e#ery player starts with a set numer of resources 6two gold mines, for example7. Additionally, extra resources are added for each player using setEscalingEtoEmapEsi*e or y adding if statements using map si*e as the condition. :inally, the larger map si*es ha#e additional resources. Setting @ones "any Ensemle %tudios random maps use the random statement to specify one of four *one types: set *one y team, set *one to a specific id, set *one randomly, or don9t set *one at all. This ensures that some of the time the players on a team will share a *one 6set *one y team7, some of the time they all players will share a *one 6set *one to a specific id7, some of the time some players will o#erlap 6set *one randomly7, and some of the time players will all e separate 6don9t set *one at all7. Oones ha#e the greatest impact on play when the ase terrain type is water, which will ma!e *ones equi#alent to islands. 2ote that in the following script, the default 6no *one at all7 will occur +HJ of the time. start_random percent_cance 2* set_,one_b+_team percent_cance 2* ,one - percent_cance 2* set_,one_randoml+ end_random Testing p$a*er start areas 3ifferent lands and player lands can e temporarily set to terrain types to distinguish different land areas. %etting the ase terrain to grass and the player lands to desert will re#eal where player lands occur. If you are trying to ha#e a large open area of any terrain type, a "editerranean?style map is a good place to start, as it creates a large Cla!eD near the middle of the map. Scattering o#>ects There are two ways to lay down o.ects, indi#idually or in groups. If numerEofEgroups is not specified, then each o.ect is treated as its own group and will respond to the setEscalingEofEgroupsEtoEmapEsi*e and minEdistanceEgroupEplacement instructions, unless instructions to !eep the group together o#erride it. Instructions to !eep a group together are groupEplacementEradius, setElooseEgrouping, and setEtightEgrouping. %tandard Ensemle %tudios maps scatter fish, ut !eep gold and stone mines in tight groups. Ma1ing it a$$ fit $"%&.doc '- ,and is placed all at once ut terrain is placed in the order you specify, and then o.ects are placed on top of terrain. If you place down too much forest, for example, there might not e enough open space for all of the gold and stone. The map generator does not try se#eral iterations until it creates a map that wor!sQif there is not enough space for oar for player (, then player ( will not ha#e any oar. If your maps seem li!e they are missing resources, you can try relaxing the constraints on where the resources are placed. Try decreasing the minimum and increasing the maximum distance the resources can e placed from a Town Center. You may ha#e to ultimately cut ac! on the amount of water or forests on a map. Standard resources "any 6ut not all7 Ensemle maps use the same amount of starting resources so that players !now what to expect. There are exceptions, howe#er, including %candina#ia9s lac! of erries and Yucatan9s extra food. You can find the standard resources placed according to map si*e and player numer in the map description elow. It might e a good idea to start with these resources so that your map will not seem too difficult for other people to play on it. The standard starting resources include: / ;erries ' group of F gold mines ( groups of + gold mines ' group of - stone mines ' group of + stone mines ' group of + sheep ( groups of ( sheep ' group of + deer ( oar ( wol#es ' group of ) straggler trees ' group of ( straggler trees O#>ect names These are the names of o.ects and terrain that the $andom "ap generator !nows. You must refer to these names when placing terrain or o.ects. "A5 2A"E% %#%9I% %#72I&E'%)O %#EN% 9%'TI7 9'%7:_1O#EST 7O%ST%' 7ONTINENT%' 7#%TE#_'%:E 1O#T#ESS )2OST_'%:E )O'"_#;S2 2I)2'%N" IS'%N"S $E"ITE##%NE%N $I)#%TION $ON)O'I% $"%&.doc '/ NO$%" O%SIS #I<E#S S%'T_$%#S2 S7%N"%N%<I% TE%$_IS'%N"S =;7%T%N &A"E 2A"E% :IN)_O1_T2E_2I'' #E)I7I"E TE$$AI2 2A"E% 9%$9OO 9E%72 "ESE#T "I#T "I#T2 "I#T3 1O#EST )#%SS )#%SS2 )#%SS3 I7E SNO( )#%SS_SNO( "I#T_SNO( >;N)'E 'E%<ES &%'$_"ESE#T &INE_1O#EST SNO(_1O#EST S2%''O( (%TE# $E"_(%TE# "EE&_(%TE# #O%" #O%"2 0;LECT 2A"E%, &AIA 9%$9OO_1O#EST_T#EE 9%$9OO_T#EE 9O%# 9#O:EN_7%#T 7%7T;S 7%#%<%N 7#%7:S 7#%TE# "EE# "I#E_(O'1 "O#%"O 1'O(E#_9E" 1'O(E#S_- $"%&.doc 'F 1'O(E#S_2 1'O(E#S_3 1'O(E#S_/ 1O#%)E 1O#%)E_9;S2 1O#EST_T#EE )O'" )#%<E 2%(: 2%=_ST%7: 2E%" I#ON_9O%# >%);%# >%<E'IN% >;N)'E_T#EE $%7%( $%#'IN- $%#'IN2 $O;NT%IN_- $O;NT%IN_2 $O;NT%IN_3 $O;NT%IN_/ O%:_1O#EST_T#EE O%:T#EE O'"_STONE_2E%" &%'$_1O#EST_T#EE &%'$T#EE &%T2_- &%T2_2 &%T2_3 &%T2_/ &IE7E_O1_T2E_T#;E_7#OSS &INE_1O#EST_T#EE &INET#EE &'%NT #%9I"_(O'1 #E'I7 #O7: #O$%N_#;INS #;)S #;INS S%'$ON SE%_#O7:S_- SE%_#O7:S_2 S2EE& S2O#E_1IS2 SI)N S:E'ETON SN%&&E# SNO(_&INE_T#EE ST%T;E STONE ST;$& T#EE_% T#EE_9 T#EE_7 $"%&.doc 'G T#EE_" T#EE_E T#EE_1 T#EE_) T#EE_2 T#EE_I T#EE_> T#EE_: T#EE_' T#EE_T" T#EE- T#EE2 T#EE3 T#EE/ T#EE3 T;N% T;#:E= (I'"_9O%# (I'"_2O#SE (O'1 0;LECT 2A"E%, %CE2A$I0 7%T2E"#%' ES_1'%) 1'%)_% 1'%)_9 1'%)_7 1'%)_" 1'%)_E )#E%T_&=#%$I" 2O#SE :IN) $%&_#E<E%'E# $ON;$ENT $OS?;E NINE_9%N"S &%<I'ION &%<I'ION2 &%<I'ION3 &=#%$I" #;99'E_-_@_- #;99'E_2_@_2 #;99'E_3_@_3 S2EE& S2I&(#E7: S2I&(#E7:2 TO#72 TO#72_7ON<E#TIN) T#%"E_(O#:S2O& =;#T =;#T2 =;#T3 =;#T/ =;#T3 =;#TA $"%&.doc 'I =;#T7 =;#T5 0;LECT 2A"E%, A$C4E$Y $A2&E @2IT% %#72E# 7%<%'#=_%#72E# 2%N"_7%NNONEE# S:I#$IS2E# %#9%'EST 7#OSS9O($%N E'ITE_S:I#$IS2E# 2E%<=_7%<%'#=_%#72E# 0;LECT 2A"E%, ;A$$ACS% @2IT% E%)'E_(%##IO# $I'ITI% S&E%#$%N 72%$&ION E'ITE_E%)'E_(%##IO# 2%'9E#"IE# 'ON)_S(O#"S$%N $%N_%T_%#$S &I:E$%N T(O_2%N"E"_S(O#"S$%N 0;LECT 2A"E%, CA%T,E @2IT% 9E#SE#: 7%T%&2#%7T 72;_:O_N; 7ON?;IST%"O# 2;S:%#' >%);%#_(%##IO# >%NISS%#= 'ON)9O($%N $%$E';:E $%N);"%I &ET%#" &';$E"_%#72E# S%$;#%I T%#:%N TE;TONI7_:NI)2T T2#O(IN)_%@E$%N T#E9;72ET T#E9;72ET_&%7:E" (%#_E'E&2%NT (%#_(%)ON (O%"_#%I"E# E'ITE_9E#SE#: E'ITE_7%T%&2#%7T E'ITE_72;_:O_N; E'ITE_7ON?;IST%"O# E'ITE_2;S:%#' E'ITE_>%);%#_(%##IO# $"%&.doc (H E'ITE_>%NISS%#= E'ITE_'ON)9O($%N E'ITE_$%$E';:E E'ITE_$%N);"%I E'ITE_&';$E"_%#72E# E'ITE_S%$;#%I E'ITE_T%#:%N E'ITE_TE;TONI7_:NI)2T E'ITE_T2#O(IN)_%@E$%N E'ITE_(%#_E'E&2%NT E'ITE_(%#_(%)ON E'ITE_(O%"_#%I"E# 0;LECT 2A"E%, C4@$C4 @2IT% $ISSION%#= $ON: 0;LECT 2A"E%, 30CS @2IT% 7%NNON_)%''EON "E$O'ITION_S2I& 1I#E_S2I& 1IS2IN)_S2I& )%''E= 'ON)9O%T T#%"E_7O) T#%NS&O#T_S2I& T;#T'E_S2I& E'ITE_7%NNON_)%''EON E'ITE_'ON)9O%T E'ITE_T;#T'E_S2I& 1%ST_1I#E_S2I& )%''EON 2E%<=_"E$O'ITION_S2I& (%#_)%''E= 0;LECT 2A"E%, 4E$0 @2IT% %"$I#%'_=I_S;N_S2IN %ET2E'1I#T2 %#729IS2O& %#72E#S_O1_T2E_E=ES %TTI'%_T2E_2;N 9%"_NEI)29O# 9%"_NEI)29O#_&%7:E" 9E'IS%#I;S 9'E"%_T2E_2;N 72%#'E$%)NE 72%#'ES_$%#TE' 7ONST%9'E_#I72E$ONT "O$E_O1_T2E_#O7: ";:E_"_%'EN7ON E'_7I" E'_7I"_7%$&E%"O# E$&E#O#_IN_%_9%##E' $"%&.doc (' E#I:_T2E_#E" 1#%N:IS2_&%'%"IN 1#I%#_T;7: )%(%IN )EN)2IS_:2%N )O"S_O(N_S'IN) )O"S_O(N_S'IN)_&%7:E" );=_>OSSE'=NE 2%#%'"_2%#"#%%"E 2EN#=_< 2#O'1_T2E_)%N)E# 2;NTIN)_(O'1 I$%$ >E%N_9;#E%; >E%N_"E_'O##%IN >O%N_O1_%#7 >O%N_T2E_$%I" :IN)_%'1ONSO :IN)_%#T2;# :IN)_S%N72O :IT%9%T%:E :;S2';: '%_2I#E '%N7E'OT 'O#"_"E_)#%<I''E $%STE#_O1_T2E_TE$&'%# $IN%$OTO $O#"#E" NO9;N%)% O#N';_T2E_(O'1 &O&E_'EO_I #E=N%'"_"E_72%TI''ON #I72%#"_T2E_'ION2E%#TE" #O9IN_2OO" #O'%N" S%9OTE;# S7=T2I%N_S7O;T S7=T2I%N_(I'"_(O$%N S2%2 S2E#I11_O1_NOTTIN)2%$ SIE)1#IE" SIE;#_9E#T#%N" SIE;#_"E_$ETB SI#_>O2N_1%STO'1 S;9OT%I T%$E#'%NE T2E_%77;#SE"_TO(E# T2E_9'%7:_&#IN7E T2E_TO(E#_O1_1'IES T2EO"O#I7_T2E_)OT2 (I''I%$_(%''%7E (I''I%$_T2E_7ON?;E#O# (I''I%$_T2E_7ON?;E#O#2 0;LECT 2A"E%, "A$SET @2IT $"%&.doc (( T#%"E_7%#T 0;LECT 2A"E%, %IE&E 80$S%405 @2IT% 9%TTE#IN)_#%$ 9O$9%#"_7%NNON $%N)ONE' S7O#&ION 7%&&E"_#%$ 2E%<=_S7O#&ION ON%)E# SIE)E_ON%)E# SIE)E_#%$ 0;LECT 2A"E%, %TA;,E @2IT% 7%$E' :NI)2T S7O;T S7O;T_7%<%'#= 7%<%'IE# 2E%<=_7%$E' 2;SS%# 'I)2T_7%<%'#= &%'%"IN 0;LECT 2A"E%, T082 CE2TE$ @2IT <I''%)E# 0;LECT 2A"E%, ;@I,3I2& %#72E#=_#%N)E 9%##%7:S 9'%7:S$IT2 9O$9%#"_TO(E# 7%ST'E "O7: 1%#$ 1IS2_T#%& 1O#TI1IE"_(%'' );%#"_TO(E# 2O;SE :EE& ';$9E#_7%$& $%#:ET $I'' $ININ)_7%$& $ON%STE#= O;T&OST &%'IS%"E_(%'' SIE)E_(O#:S2O& ST%9'E STONE_(%'' TO(N_7ENTE# ;NI<E#SIT= $"%&.doc () (%'' (%T72_TO(E# (ON"E# Annotated Random Map Script The following script was created y Ensemle %tudios for the Coastal $andom "ap type. You can use it to figure out how to start maps of your own and see what standard resources go into most maps. $ememer that e#erything etween >1 slash mar!s 1> is a comment and is not read y the "ap &enerator. CD DDDDDDDDDDDD 7O%ST%' DDDDDDDDDDDD DC CD 20 $%# ** DC CD DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD DC 6&'%=E#_SET;&8 random_placement CD DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD DC 6'%N"_)ENE#%TION8 base_terrain (%TE# /* Coastal is basically a large island placed on water, so water is the base terrain. Using water1 (the shallow water) makes it easier to add deeper water later */ start_random percent_cance -3 !define "ESE#T_$%& percent_cance -3 !define %'&INE_$%& percent_cance -3 !define %SI%N_$%& percent_cance -3 !define 1#OBEN_$%& percent_cance -3 !define T#O&I7%'_$%& end_random /* Coastal maps can have different terrain, sch as desert or rain forest. !here is a 1"# chance of the map sing one of these different terrain sets. !hese names are $st sed as variables. %o can define yor own. */ create_pla+er_lands { if "ESE#T_$%& terrain_t+pe "I#T elseif %'&INE_$%& terrain_t+pe )#%SS2 elseif %SI%N_$%& terrain_t+pe )#%SS2 elseif 1#OBEN_$%& terrain_t+pe SNO( else terrain_t+pe )#%SS endif /* &epending on what terrain type is chosen, we se a different base terrain */ $"%&.doc (+ start_random percent_cance 33 land_percent 32 percent_cance 33 land_percent A* percent_cance 33 land_percent A3 end_random /* !he amont of land sed is random. Using "'# means there is often a lake in the middle of the map. Using ("# means that there tends to be a large, s)are landmass */ base_si,e 5 start_random percent_cance 23 left_border A top_border 5 bottom_border A percent_cance 23 left_border A top_border A rigt_border 5 percent_cance 23 rigt_border A left_border A bottom_border 5 percent_cance 23 rigt_border 5 top_border A bottom_border A end_random /* !here is a random chance for varios border si*es. Coastal always has one edge that toches the border of the map, bt it is random which border this is */ border_fu,,iness -3 ,one - oter_,one_a.oidance_distance 7 clumping_factor -3 } CD DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD DC 6TE##%IN_)ENE#%TION8 CD $I@IN) (%TE# DC create_terrain $E"_(%TE# { base_terrain (%TE# number_of_clumps -* spacing_to_oter_terrain_t+pes 2 land_percent /* } create_terrain $E"_(%TE# { base_terrain (%TE# number_of_clumps 3* spacing_to_oter_terrain_t+pes - $"%&.doc (- land_percent - } create_terrain "EE&_(%TE# { base_terrain $E"_(%TE# number_of_clumps 5 spacing_to_oter_terrain_t+pes 3 land_percent 2* } create_terrain "EE&_(%TE# { base_terrain $E"_(%TE# number_of_clumps 3* spacing_to_oter_terrain_t+pes - land_percent - } create_terrain $E"_(%TE# { base_terrain "EE&_(%TE# number_of_clumps 3* spacing_to_oter_terrain_t+pes - land_percent - } create_terrain (%TE# { base_terrain $E"_(%TE# number_of_clumps 3* spacing_to_oter_terrain_t+pes - land_percent - } /* !his adds deeper water to the shallow water. +e se small percentages and spacing of 1,- tiles to make sre the shallow water is closest to land and other waters are placed farther from land. ./periment with different percentages of water so that there are not large e/panses of one color. */ CD &#I$%#= 1O#EST DC if "ESE#T_$%& create_terrain &%'$_"ESE#T { base_terrain "I#T spacing_to_oter_terrain_t+pes 3 land_percent 0 number_of_clumps -* set_a.oid_pla+er_start_areas set_scale_b+_groups } elseif %'&INE_$%& create_terrain &INE_1O#EST { base_terrain )#%SS2 spacing_to_oter_terrain_t+pes 3 $"%&.doc (/ land_percent 0 number_of_clumps -* set_a.oid_pla+er_start_areas set_scale_b+_groups } elseif 1#OBEN_$%& create_terrain SNO(_1O#EST { base_terrain SNO( spacing_to_oter_terrain_t+pes 3 land_percent 0 number_of_clumps -* set_a.oid_pla+er_start_areas set_scale_b+_groups } elseif %SI%N_$%& create_terrain &INE_1O#EST { base_terrain )#%SS2 spacing_to_oter_terrain_t+pes 3 land_percent 0 number_of_clumps -* set_a.oid_pla+er_start_areas set_scale_b+_groups } elseif T#O&I7%'_$%& create_terrain >;N)'E { base_terrain )#%SS spacing_to_oter_terrain_t+pes 3 land_percent 0 number_of_clumps -* set_a.oid_pla+er_start_areas set_scale_b+_groups } else create_terrain 1O#EST { base_terrain )#%SS spacing_to_oter_terrain_t+pes 3 land_percent 0 number_of_clumps -* set_a.oid_pla+er_start_areas set_scale_b+_groups } endif /* !he 0rimary 1orest on Coastal covers 2# of the map and can be oak forest, pine forest or even rain forest, depending on the kind of map we want */ CD &#I$%#= &%T72 DC if "ESE#T_$%& create_terrain "ESE#T { base_terrain "I#T $"%&.doc (F number_of_clumps -2 spacing_to_oter_terrain_t+pes * land_percent 5 set_scale_b+_si,e } elseif %'&INE_$%& create_terrain )#%SS3 { base_terrain )#%SS2 number_of_clumps 5 spacing_to_oter_terrain_t+pes * land_percent A set_scale_b+_si,e } elseif 1#OBEN_$%& create_terrain )#%SS_SNO( { base_terrain SNO( number_of_clumps 5 spacing_to_oter_terrain_t+pes * land_percent A set_scale_b+_si,e } elseif %SI%N_$%& create_terrain )#%SS3 { base_terrain )#%SS2 number_of_clumps 5 spacing_to_oter_terrain_t+pes * land_percent A set_scale_b+_si,e } else create_terrain "I#T { base_terrain )#%SS number_of_clumps 5 spacing_to_oter_terrain_t+pes * land_percent 0 set_scale_b+_si,e } endif /* !hese patches and additional forests are sed for variation. 3dding grass or dirt on top of the base terrain is really only for cosmetic prposes. 1orests affect how defensive the map can be and how hard it is to path from one town to another */ CD SE7ON"%#= 1O#EST DC if "ESE#T_$%& create_terrain 1O#EST { base_terrain )#%SS spacing_to_oter_terrain_t+pes 3 land_percent - number_of_clumps 3 $"%&.doc (G set_a.oid_pla+er_start_areas set_scale_b+_groups } elseif %'&INE_$%& create_terrain 1O#EST { base_terrain )#%SS2 spacing_to_oter_terrain_t+pes 3 land_percent - number_of_clumps 3 set_a.oid_pla+er_start_areas set_scale_b+_groups } elseif 1#OBEN_$%& create_terrain SNO(_1O#EST { base_terrain )#%SS_SNO( spacing_to_oter_terrain_t+pes 3 land_percent - number_of_clumps 3 set_a.oid_pla+er_start_areas set_scale_b+_groups } elseif %SI%N_$%& create_terrain 9%$9OO { base_terrain )#%SS2 spacing_to_oter_terrain_t+pes 3 land_percent - number_of_clumps 3 set_a.oid_pla+er_start_areas set_scale_b+_groups } else create_terrain &%'$_"ESE#T { base_terrain "I#T spacing_to_oter_terrain_t+pes 3 land_percent - number_of_clumps 3 set_a.oid_pla+er_start_areas set_scale_b+_groups } endif CD SE7ON"%#= &%T72 DC if "ESE#T_$%& create_terrain "I#T3 { base_terrain "I#T number_of_clumps 2/ spacing_to_oter_terrain_t+pes * land_percent 2 set_scale_b+_si,e } $"%&.doc (I elseif %'&INE_$%& create_terrain "I#T3 { base_terrain )#%SS2 number_of_clumps 2/ spacing_to_oter_terrain_t+pes * land_percent 2 set_scale_b+_si,e } elseif 1#OBEN_$%& create_terrain "I#T_SNO( { base_terrain SNO( number_of_clumps 2/ spacing_to_oter_terrain_t+pes * land_percent 2 set_scale_b+_si,e } elseif %SI%N_$%& create_terrain "I#T3 { base_terrain )#%SS2 number_of_clumps 2/ spacing_to_oter_terrain_t+pes * land_percent 2 set_scale_b+_si,e } else create_terrain )#%SS3 { base_terrain )#%SS number_of_clumps 2/ spacing_to_oter_terrain_t+pes * land_percent 2 set_scale_b+_si,e } endif CD TE#TI%#= &%T72 DC if "ESE#T_$%& create_terrain )#%SS3 { base_terrain "I#T number_of_clumps 3* spacing_to_oter_terrain_t+pes * land_percent 2 set_scale_b+_si,e } elseif %'&INE_$%& create_terrain )#%SS { base_terrain )#%SS2 number_of_clumps 3* spacing_to_oter_terrain_t+pes * land_percent 2 $"%&.doc )H set_scale_b+_si,e } elseif 1#OBEN_$%& create_terrain )#%SS2 { base_terrain )#%SS_SNO( number_of_clumps 3* spacing_to_oter_terrain_t+pes * land_percent 2 set_scale_b+_si,e } elseif %SI%N_$%& create_terrain )#%SS { base_terrain )#%SS2 number_of_clumps 3* spacing_to_oter_terrain_t+pes * land_percent 2 set_scale_b+_si,e } else create_terrain "I#T3 { base_terrain )#%SS number_of_clumps 3* spacing_to_oter_terrain_t+pes * land_percent 2 set_scale_b+_si,e } endif CD DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD DC 6O9>E7TS_)ENE#%TION8 CD &'%=E# ST%#T O9>E7TS DC create_object TO(N_7ENTE# { set_place_for_e.er+_pla+er group_placement_radius -5 min_distance_to_pla+ers * ma4_distance_to_pla+ers * } create_object <I''%)E# { set_place_for_e.er+_pla+er min_distance_to_pla+ers A ma4_distance_to_pla+ers A } create_object S7O;T { number_of_objects - set_place_for_e.er+_pla+er min_distance_to_pla+ers 7 $"%&.doc )' ma4_distance_to_pla+ers 0 } create_object #E'I7 { number_of_objects 3 min_distance_to_pla+ers 23 temp_min_distance_group_placement 2* } /* .ach player starts with a !own Center, villagers and a scot. !he 4ap 5enerator knows that Chinese need ( villagers and that 3*tecs have an .agle +arrior. !here are also " 6elics placed on most map types. */ CD S&E7I%' ST;11 1O# #E)I7I"E DC if #E)I7I"E create_object <I''%)E# { number_of_objects 7 set_place_for_e.er+_pla+er min_distance_to_pla+ers A ma4_distance_to_pla+ers A } create_object :IN) { set_place_for_e.er+_pla+er min_distance_to_pla+ers A ma4_distance_to_pla+ers A } create_object 7%ST'E { set_place_for_e.er+_pla+er min_distance_to_pla+ers -* ma4_distance_to_pla+ers -* } endif /* 6egicide games re)ire a Castle, 7ing and more villagers. 8ther game types, sch as &efend the +onder, are handled atomatically. */ CD NE%# 1O#%)E DC create_object 1O#%)E { number_of_objects A group_placement_radius 3 set_tigt_grouping set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers -* ma4_distance_to_pla+ers -2 min_distance_group_placement A $"%&.doc )( } /* 8n most maps, everyone gets berry bshes near their town */ CD NE%# )O'" DC create_object )O'" { number_of_objects 7 group_placement_radius 3 set_tigt_grouping set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers -2 ma4_distance_to_pla+ers -A min_distance_group_placement 7 ma4_distance_to_oter_,ones 7 } CD $E"I;$ )O'" DC create_object )O'" { number_of_objects / group_placement_radius 3 set_tigt_grouping set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers -5 ma4_distance_to_pla+ers 2A min_distance_group_placement 7 ma4_distance_to_oter_,ones 7 } CD 1%# )O'" DC create_object )O'" { number_of_objects / group_placement_radius 3 set_tigt_grouping set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers 23 ma4_distance_to_pla+ers 33 min_distance_group_placement 7 ma4_distance_to_oter_,ones 7 } /* .veryone gets - sets of gold mines. 9ometimes the far gold mine is really far (-" tiles) from the player:s !own Center. */ CD NE%# STONE DC create_object STONE { $"%&.doc )) number_of_objects 3 group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers -/ ma4_distance_to_pla+ers -5 min_distance_group_placement 7 ma4_distance_to_oter_,ones 7 } CD 1%# STONE DC create_object STONE { number_of_objects / group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers 2* ma4_distance_to_pla+ers 2A min_distance_group_placement 7 ma4_distance_to_oter_,ones 7 } /* +e place stone last since it is more important to start with berries and gold. ;f the map rns ot of room it might not place stone. !his is not ideal, bt it is better than losing gold. */ CD 9%% 9%% DC if T#O&I7%'_$%& create_object T;#:E= { number_of_objects / set_loose_grouping set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers -* ma4_distance_to_pla+ers -2 } create_object T;#:E= { number_of_objects 2 number_of_groups 2 set_loose_grouping set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers -/ ma4_distance_to_pla+ers 3* } else create_object S2EE& { number_of_objects / set_loose_grouping $"%&.doc )+ set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers -* ma4_distance_to_pla+ers -2 } create_object S2EE& { number_of_objects 2 number_of_groups 2 set_loose_grouping set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers -/ ma4_distance_to_pla+ers 3* } endif /* 9heep and !rkeys are small, so they are easy to place. ;f yo really want to confse players, mi/ sheep and trkeys on a map. */ create_object "EE# { number_of_objects / group_.ariance - group_placement_radius 3 set_loose_grouping set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers -/ ma4_distance_to_pla+ers 3* } if T#O&I7%'_$%& create_object >%<E'IN% else create_object 9O%# endif { number_of_objects - set_loose_grouping set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers -A ma4_distance_to_pla+ers 22 } if T#O&I7%'_$%& create_object >%<E'IN% else create_object 9O%# endif { number_of_objects - set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers -A $"%&.doc )- ma4_distance_to_pla+ers 22 } /* 9tff to hnt. */ if T#O&I7%'_$%& create_object >%);%# { number_of_objects 2 set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_group_placement -2 min_distance_to_pla+ers 3* ma4_distance_to_pla+ers /* } else create_object (O'1 { number_of_objects 2 set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_group_placement -2 min_distance_to_pla+ers 3* ma4_distance_to_pla+ers /* } endif /* <ad gys. =eave them off if yo want a rshing map. */ CD #ESO;#7ES 9= $%& DC if '%#)E_$%& create_object 1O#%)E { number_of_groups - number_of_objects 3 group_placement_radius 3 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* ma4_distance_to_pla+ers -2* min_distance_group_placement 7 } endif /* <ecase large maps have more open space, they need more resorces. !hese resorces do not >belong? to anyone. !hey are scattered for the taking. */ if 2;)E_$%& create_object 1O#%)E { number_of_groups 2 number_of_objects 3 group_placement_radius 3 set_tigt_grouping set_gaia_object_onl+ $"%&.doc )/ min_distance_to_pla+ers /* ma4_distance_to_pla+ers -2* min_distance_group_placement 7 } endif if )I)%NTI7_$%& create_object 1O#%)E { number_of_groups 3 number_of_objects 3 group_placement_radius 3 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* ma4_distance_to_pla+ers -2* min_distance_group_placement 7 } endif CD E@T#% )O'" DC if TIN=_$%& create_object )O'" { number_of_groups 2 number_of_objects 3 group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } endif if S$%''_$%& create_object )O'" { number_of_groups 2 number_of_objects 3 group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } endif if $E"I;$_$%& create_object )O'" { number_of_groups 3 number_of_objects 3 group_.ariance - group_placement_radius 2 set_tigt_grouping $"%&.doc )F set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } endif if '%#)E_$%& create_object )O'" { number_of_groups 3 number_of_objects 3 group_.ariance - group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } endif if 2;)E_$%& create_object )O'" { number_of_groups / number_of_objects / group_.ariance - group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } endif if )I)%NTI7_$%& create_object )O'" { number_of_groups 3 number_of_objects / group_.ariance - group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } endif CD E@T#% STONE DC if TIN=_$%& create_object STONE { number_of_groups - number_of_objects / group_.ariance - $"%&.doc )G group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } endif if S$%''_$%& create_object STONE { number_of_groups - number_of_objects / group_.ariance - group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } endif if $E"I;$_$%& create_object STONE { number_of_groups 2 number_of_objects / group_.ariance - group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } endif if '%#)E_$%& create_object STONE { number_of_groups 3 number_of_objects / group_.ariance - group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } endif if 2;)E_$%& create_object STONE { number_of_groups / number_of_objects / group_.ariance - $"%&.doc )I group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } endif if )I)%NTI7_$%& create_object STONE { number_of_groups 3 number_of_objects / group_.ariance - group_placement_radius 2 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers /* min_distance_group_placement 0 } endif if "ESE#T_$%& create_object &%'$T#EE { number_of_objects 2 set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers / ma4_distance_to_pla+ers 3 min_distance_group_placement 2 } create_object &%'$T#EE { number_of_objects 3 set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers A ma4_distance_to_pla+ers 5 min_distance_group_placement 2 } elseif %'&INE_$%& create_object &INET#EE { number_of_objects 2 set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers / ma4_distance_to_pla+ers 3 min_distance_group_placement 2 } create_object &INET#EE { number_of_objects 3 set_gaia_object_onl+ set_place_for_e.er+_pla+er $"%&.doc +H min_distance_to_pla+ers A ma4_distance_to_pla+ers 5 min_distance_group_placement 2 } elseif %SI%N_$%& create_object 9%$9OO_T#EE { number_of_objects 2 set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers / ma4_distance_to_pla+ers 3 min_distance_group_placement 2 } create_object &INET#EE { number_of_objects 3 set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers A ma4_distance_to_pla+ers 5 min_distance_group_placement 2 } elseif T#O&I7%'_$%& create_object &%'$T#EE { number_of_objects 2 set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers / ma4_distance_to_pla+ers 3 min_distance_group_placement 2 } create_object O%:T#EE { number_of_objects 3 set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers A ma4_distance_to_pla+ers 5 min_distance_group_placement 2 } elseif 1#OBEN_$%& create_object SNO(&INET#EE { number_of_objects 2 set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers / ma4_distance_to_pla+ers 3 min_distance_group_placement 2 } create_object SNO(&INET#EE { number_of_objects 3 set_gaia_object_onl+ $"%&.doc +' set_place_for_e.er+_pla+er min_distance_to_pla+ers A ma4_distance_to_pla+ers 5 min_distance_group_placement 2 } else create_object O%:T#EE { number_of_objects 2 set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers / ma4_distance_to_pla+ers 3 min_distance_group_placement 2 } create_object O%:T#EE { number_of_objects 3 set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers A ma4_distance_to_pla+ers 5 min_distance_group_placement 2 } endif /* !hese are the >straggler? trees near every !own Center. */ if T#O&I7%'_$%& create_object $%7%( { number_of_objects A set_scaling_to_map_si,e } else create_object 2%(: { number_of_objects A set_scaling_to_map_si,e } endif if T#O&I7%'_$%& create_object >%);%# { number_of_groups 3 set_loose_grouping start_random percent_cance 73 number_of_objects - percent_cance 23 number_of_objects 2 end_random set_scaling_to_map_si,e set_gaia_object_onl+ min_distance_group_placement -2 $"%&.doc +( min_distance_to_pla+ers /* ma4_distance_to_pla+ers -2* } else create_object (O'1 { number_of_groups 3 set_loose_grouping start_random percent_cance 73 number_of_objects - percent_cance 23 number_of_objects 2 end_random set_scaling_to_map_si,e set_gaia_object_onl+ min_distance_group_placement -2 min_distance_to_pla+ers /* ma4_distance_to_pla+ers -2* } endif /* 4ore wildlife. <irds have no affect on gameplay, bt make the map more interesting. */ create_object 1O#%)E { number_of_groups - number_of_objects 3 group_placement_radius 3 set_tigt_grouping set_gaia_object_onl+ min_distance_to_pla+ers -0 ma4_distance_to_pla+ers -2* min_distance_group_placement 0 } create_object "EE# { number_of_objects / group_.ariance - set_loose_grouping set_gaia_object_onl+ set_place_for_e.er+_pla+er min_distance_to_pla+ers -0 } if "ESE#T_$%& create_object &%'$T#EE { number_of_objects 3* set_gaia_object_onl+ set_scaling_to_map_si,e min_distance_to_pla+ers 5 } elseif %'&INE_$%& create_object &INET#EE $"%&.doc +) { number_of_objects 3* set_gaia_object_onl+ set_scaling_to_map_si,e min_distance_to_pla+ers 5 } elseif 1#OBEN_$%& create_object SNO(&INET#EE { number_of_objects 3* set_gaia_object_onl+ set_scaling_to_map_si,e min_distance_to_pla+ers 5 } elseif %SI%N_$%& create_object 9%$9OO_T#EE { number_of_objects 3* set_gaia_object_onl+ set_scaling_to_map_si,e min_distance_to_pla+ers 5 } elseif T#O&I7%'_$%& create_object &%'$T#EE { number_of_objects 3* set_gaia_object_onl+ set_scaling_to_map_si,e min_distance_to_pla+ers 5 } else create_object O%:T#EE { number_of_objects 3* set_gaia_object_onl+ set_scaling_to_map_si,e min_distance_to_pla+ers 5 } endif /* !hese are the lone trees scattered across the map. ;t makes the map look more believable than if there were $st forests and no straggler trees. */ if "ESE#T_$%& create_object "O#%"O { number_of_objects -3 set_scaling_to_map_si,e set_gaia_object_onl+ ma4_distance_to_oter_,ones / } create_object SN%&&E# { number_of_objects -* set_scaling_to_map_si,e set_gaia_object_onl+ $"%&.doc ++ ma4_distance_to_oter_,ones / } elseif %'&INE_$%& create_object S%'$ON { number_of_objects -3 set_scaling_to_map_si,e set_gaia_object_onl+ ma4_distance_to_oter_,ones / } create_object SN%&&E# { number_of_objects -* set_scaling_to_map_si,e set_gaia_object_onl+ ma4_distance_to_oter_,ones / } elseif 1#OBEN_$%& create_object S%'$ON { number_of_objects -3 set_scaling_to_map_si,e set_gaia_object_onl+ ma4_distance_to_oter_,ones / } create_object SN%&&E# { number_of_objects -* set_scaling_to_map_si,e set_gaia_object_onl+ ma4_distance_to_oter_,ones / } elseif %SI%N_$%& create_object T;N% { number_of_objects -3 set_scaling_to_map_si,e set_gaia_object_onl+ ma4_distance_to_oter_,ones / } create_object SN%&&E# { number_of_objects -* set_scaling_to_map_si,e set_gaia_object_onl+ ma4_distance_to_oter_,ones / } else create_object "O#%"O { number_of_objects 3 set_scaling_to_map_si,e set_gaia_object_onl+ ma4_distance_to_oter_,ones / } create_object T;N% $"%&.doc +- { number_of_objects -* set_scaling_to_map_si,e set_gaia_object_onl+ ma4_distance_to_oter_,ones / } create_object SN%&&E# { number_of_objects -* set_scaling_to_map_si,e set_gaia_object_onl+ ma4_distance_to_oter_,ones / } endif create_object S2O#E_1IS2 { number_of_objects 23 set_scaling_to_map_si,e min_distance_group_placement 3 set_gaia_object_onl+ } create_object $%#'IN- { number_of_groups 3 number_of_objects - set_scaling_to_map_si,e set_gaia_object_onl+ min_distance_group_placement -* ma4_distance_to_oter_,ones 7 } create_object $%#'IN2 { number_of_groups 3 number_of_objects - set_scaling_to_map_si,e set_gaia_object_onl+ min_distance_group_placement -* ma4_distance_to_oter_,ones 7 } /* 8ne of or designers is picky abot which fish live in which part of the contry. 8nly the 4arlin and the 9hore fish have different amonts of food in them. !he other fish are $st for variety. */ CD DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD DC 6E'E<%TION_)ENE#%TION8 create_ele.ation 7 { if "ESE#T_$%& base_terrain "I#T elseif %'&INE_$%& base_terrain )#%SS2 $"%&.doc +/ elseif 1#OBEN_$%& base_terrain SNO( elseif %SI%N_$%& base_terrain )#%SS2 else base_terrain )#%SS endif number_of_clumps -/ number_of_tiles 2*** set_scale_b+_groups set_scale_b+_si,e } /* @otice that the elevation mst be placed on a certain terrain, whichever is the base terrain for the map. ;f yo se lots of different terrain, yo may need to have mltiple elevation statements. */ 67'I11_)ENE#%TION8 min_number_of_cliffs 3 ma4_number_of_cliffs 5 min_lengt_of_cliff / ma4_lengt_of_cliff -* cliff_curliness -* min_distance_cliffs 3 /* Cliffs work okay on land maps bt are best left off island maps. */ CD DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD DC 67ONNE7TION_)ENE#%TION8 create_connect_all_pla+ers_land { if 1#OBEN_$%& replace_terrain (%TE# I7E replace_terrain $E"_(%TE# I7E replace_terrain "EE&_(%TE# I7E else replace_terrain (%TE# S2%''O( replace_terrain $E"_(%TE# S2%''O( replace_terrain "EE&_(%TE# S2%''O( endif /* .very player on a team mst be connected in Coastal. !his part pts shallows or ice across water to make sre no one is on an island. 8n an 3rchipelago map, it is okay if some players are on their own islands. */ terrain_cost (%TE# 7 terrain_cost $E"_(%TE# 0 terrain_cost "EE&_(%TE# -3 terrain_cost 1O#EST 7 terrain_cost &INE_1O#EST 7 terrain_cost &%'$_"ESE#T 7 terrain_cost SNO(_1O#EST 7 terrain_cost >;N)'E 7 terrain_cost S2%''O( 3 terrain_cost "ESE#T 2 terrain_cost "I#T 2 $"%&.doc +F terrain_cost "I#T2 2 terrain_cost "I#T3 2 terrain_cost "I#T_SNO( 2 terrain_cost )#%SS 2 terrain_cost )#%SS2 2 terrain_cost )#%SS3 2 terrain_cost )#%SS_SNO( 2 terrain_cost SNO( 2 terrain_cost 9E%72 7 terrain_si,e (%TE# 2 - terrain_si,e $E"_(%TE# 2 - terrain_si,e "EE&_(%TE# 2 - terrain_si,e )#%SS * * terrain_si,e )#%SS2 * * terrain_si,e )#%SS3 * * terrain_si,e )#%SS_SNO( * * terrain_si,e SNO( * * terrain_si,e "I#T * * terrain_si,e "I#T2 * * terrain_si,e "I#T3 * * terrain_si,e "I#T_SNO( * * terrain_si,e SNO(_1O#EST * * terrain_si,e 1O#EST * * terrain_si,e &INE_1O#EST * * terrain_si,e &%'$_"ESE#T * * terrain_si,e >;N)'E * * terrain_si,e "ESE#T * * } >1 Terrain cost is used to ma!e the connections try and go o#er land and not through forests which loo!s fa!e, unless you pa#e the connections with road, as in ;lac! :orest. 1> $"%&.doc +G