This script contains some convenience functions intended mainly for use in the Discovery and New World starting conditions.
To make these functions available include this file at the beginning of a script via:
- sleep_then_goto(player, sleeptime, field)¶
Wait for the given number of milliseconds, then center the interactive player’s map view on the given Field.
This function returns immediately after calling.
- launch_expeditions(player, items)¶
Creates some expedition ships in random places with the given additional items on them. If called for the interactive player, centers the view on an arbitrary of these ships.
Player) – The player to use
items – An
tableswith ware_or_worker_name = amount pairs. As many ships will be created as there are subtables, and the n-th ship created will load the additional wares and workers defined in
items[n]. The capacity of each ship will be adjusted to accommodate the build cost of the player’s tribe’s port building plus one builder plus the number of additional items for this ship.