wesnoth/data/multiplayer/scenarios/Random_Scenario.cfg
Chris Beck 43e3d37a21 fix bug #22484 (fix random map generation in mp create)
As described in bug report, mp create had a bizarre implementation
for random map vs scenario generation. Scenario generation was called
map generation, and map generation was impossible. We fix it and make
it work like it works in the rest of the game.

At time of writing the wiki describes map generation wml as follows:

```
To use the default [generator] your [scenario] tag must contain one of
the following keys:

scenario_generation=default
map_generation=default

If ‘scenario_generation’ is used, the engine will expect for your entire
[scenario] sub tags to be inside a [scenario] tag inside [generator].
Tags outside of this will be ignored. There may be value in this, but at
this writing, it’s not clear. ‘map_generation=default’ is simpler and
more commonly used. It is also necessary to use this key so that you can
regenerate a map in MP game creation. In its use only generator data is
in the [generator] tag, all other [scenario] data is placed outside of it.
The exception is if you are making an initial MP scenario available in MP
game creation, for this a [scenario] tag must appear inside of
[generator], containing the [scenario] subtags you want to use.
See “data/multiplayer/scenarios/Random_Scenario.cfg” for an example.
```

This commit essentially removes the "exception" pointed out above.
After this, the mp create dialog treats map and scenario generation
both in the "random maps" classification, and it handles them normally,
scenario generation replacing the entire scenario, and map generation
replacing only the map data of the scenario.
2014-11-05 18:40:45 -05:00

260 lines
6.6 KiB
INI

#textdomain wesnoth-multiplayer
[multiplayer]
# This id is currently hardcoded by the random map generator of the editor
id=multiplayer_Random_Map
name= _ "Random map"
description= _ "Randomly generated map. Note: random maps are often unbalanced, but if you have time, you can regenerate them until you get a good one."
scenario_generation=default
[generator]
[scenario]
name= _ "Random map"
id=multiplayer_Random_Map
{DEFAULT_MUSIC_PLAYLIST}
{DEFAULT_SCHEDULE}
[event]
name=prestart
{SCATTER_EMBELLISHMENTS G* ^Efm 7}
{SCATTER_EMBELLISHMENTS Re,Rb,Gd ^Gvs 5}
{SCATTER_EMBELLISHMENTS G*,D*,R*,Uu*,Ur* ^Es 2}
{SCATTER_EMBELLISHMENTS G*,R*,Uu*,Ur* ^Em 2}
{SCATTER_EMBELLISHMENTS Uu* ^Emf 2}
{SCATTER_EMBELLISHMENTS D* ^Edp 2}
{SCATTER_EMBELLISHMENTS G*,R* ^Wm 0.25}
[/event]
[/scenario]
name=default
map_width=40
map_height=40
iterations=2000
hill_size=6
max_lakes=40
villages=25
players=2
min_lake_height=500
lake_size=150
river_frequency=20
temperature_iterations=2000
temperature_size=4
roads=3
road_windiness=3
#list of common terrain types which come in at
#different heights, from highest to lowest
[height]
height=600
terrain=Mm
[/height]
[height]
height=500
terrain=Hh
[/height]
[height]
height=100
terrain=Gg
[/height]
[height]
height=30
terrain=Ds
[/height]
[height]
height=5
terrain=Ww
[/height]
[height]
height=0
terrain=Wo
[/height]
#water at cold temperatures becomes ice
[convert]
min_height=50
max_temperature=20
from=Ww, Wo
to=Ai
[/convert]
#at low temperatures, snow appears
[convert]
min_height=50
max_temperature=50
from=Gg, Ds
to=Aa
[/convert]
#hills at low temperatures get snow on them
[convert]
max_temperature=50
from=Hh
to=Ha
[/convert]
#swamp appears on low land, at moderate temperatures
[convert]
min_temperature=500
max_temperature=700
max_height=200
from=Gg
to=Ss
[/convert]
#forest appears at moderate temperatures
[convert]
min_temperature=300
max_temperature=500
from=Gg
to=Gs^Fp
[/convert]
#desert appears at high temperatures
[convert]
min_temperature=900
from=Gg
to=Ds
[/convert]
#road costs
[road_cost]
terrain=Gg
cost=10
convert_to=Rr
[/road_cost]
[road_cost]
terrain=Ds
cost=25
convert_to=Rr
[/road_cost]
[road_cost]
terrain=Gs^Fp
cost=20
convert_to=Rr
[/road_cost]
[road_cost]
terrain=Ww
cost=50
convert_to_bridge=Ww^Bw|, Ww^Bw/, Ww^Bw\
convert_to=Ch
[/road_cost]
[road_cost]
terrain=Hh
cost=30
convert_to=Rr
[/road_cost]
[road_cost]
terrain=Mm
cost=50
convert_to=Rr
[/road_cost]
#road going through snow is covered over by
#the snow (presumably the road was built when
#it wasn't snowing)
[road_cost]
terrain=Aa
cost=20
convert_to=Aa
[/road_cost]
#define MIN_COST_ROAD TERRAIN
[road_cost]
terrain={TERRAIN}
cost=2
convert_to={TERRAIN}
[/road_cost]
#enddef
{MIN_COST_ROAD Re}
{MIN_COST_ROAD Ww^Bw|}
{MIN_COST_ROAD Ww^Bw/}
{MIN_COST_ROAD Ww^Bw\}
{MIN_COST_ROAD Ch}
[village]
terrain=Gg
convert_to=Gg^Vh
adjacent_liked=Gg, Ww, Ww, Ww, Ww, Ww, Ww, Ww, Ww^Bw|, Ww^Bw/, Ww^Bw\, Rr, Rr, Re, Re, Gg^Ve, Gg^Vh, Hh, Gs^Fp
rating=8
[/village]
[village]
terrain=Ds
convert_to=Dd^Vda
rating=2
adjacent_liked=Gg, Ww, Ww, Ww, Ww^Bw|, Ww^Bw/, Ww^Bw\, Rr, Rr, Re, Re, Gg^Ve, Gg^Vh, Hh, Gs^Fp
[/village]
#villages in forest are Elvish
[village]
terrain=Gs^Fp
convert_to=Gg^Ve
rating=4
adjacent_liked=Gg, Ww, Ww, Ww, Ww^Bw|, Ww^Bw/, Ww^Bw\, Rr, Rr, Re, Re, Gg^Ve, Gg^Vh, Hh, Gs^Fp, Gs^Fp, Gs^Fp
[/village]
[village]
terrain=Hh
convert_to=Hh^Vhh
rating=4
adjacent_liked=Gg, Ww, Ww, Ww, Ww^Bw|, Ww^Bw/, Ww^Bw\, Rr, Rr, Re, Re, Gg^Ve, Gg^Vh, Hh, Gs^Fp
[/village]
[village]
terrain=Mm
convert_to=Mm^Vhh
rating=3
adjacent_liked=Gg, Ww, Ww, Ww, Ww^Bw|, Ww^Bw/, Ww^Bw\, Rr, Rr, Re, Re, Gg^Ve, Gg^Vh, Hh, Gs^Fp
[/village]
#villages in snow
[village]
terrain=Aa
convert_to=Aa^Vha
rating=3
adjacent_liked=Gg, Ww, Ww, Ww, Ww^Bw|, Ww^Bw/, Ww^Bw\, Rr, Rr, Re, Re, Gg^Ve, Gg^Vh, Hh, Gs^Fp
[/village]
[village]
terrain=Aa^Fpa
convert_to=Aa^Vha
rating=3
adjacent_liked=Gg, Ww, Ww, Ww, Ww^Bw|, Ww^Bw/, Ww^Bw\, Rr, Rr, Re, Re, Gg^Ve, Gg^Vh, Hh, Gs^Fp
[/village]
#swamp villages
[village]
terrain=Ss
convert_to=Ss^Vhs
rating=2
adjacent_liked=Gg, Ww, Ww, Ww, Ww^Bw|, Ww^Bw/, Ww^Bw\, Rr, Rr, Re, Re, Gg^Ve, Gg^Vh, Hh, Gs^Fp
[/village]
#mermen villages - give them low chance of appearing
[village]
terrain=Ww
convert_to=Ww^Vm
rating=1
adjacent_liked=Ww, Ww
[/village]
[castle]
valid_terrain=Gg, Gs^Fp, Hh
min_distance=12
[/castle]
[naming]
{VILLAGE_NAMES}
[/naming]
[village_naming]
{VILLAGE_NAMES}
[/village_naming]
[/generator]
#undef MIN_COST_ROAD
[/multiplayer]