Share Age of Empires 2 Random Map Script snippets online
<PLAYER_SETUP>
if REGICIDE
#define KINGGAME
else
if LOW_RESOURCES
#define KINGGAME
#define GUARDSTATE
endif
endif
/* regicide stuff */
if GUARDSTATE
guard_state KING AMOUNT_GOLD 0 1
effect_amount MOD_RESOURCE AMOUNT_STARTING_WOOD ATTR_ADD 300
effect_amount MOD_RESOURCE AMOUNT_STARTING_FOOD ATTR_ADD 300
effect_amount MOD_RESOURCE AMOUNT_STARTING_GOLD ATTR_ADD -100
effect_amount MOD_RESOURCE AMOUNT_STARTING_STONE ATTR_ADD -50
endif
/* spies + treason with regicide */
if KINGGAME
effect_amount GAIA_SET_PLAYER_DATA DATA_MODE_FLAGS ATTR_SET 3
endif
<OBJECT_GENERATION>
if KINGGAME
create_object VILLAGER
{
number_of_objects 7
set_place_for_every_player
min_distance_to_players 6
max_distance_to_players 7
}
create_object KING
{
set_place_for_every_player
min_distance_to_players 6
max_distance_to_players 7
}
/* optional castle */
create_object CASTLE
{
set_place_for_every_player
min_distance_to_players 10
max_distance_to_players 11
}
endif