void PrepareGenerateWorldProgress()
Initializes the progress counters to the starting point.
void GWDoneProc()
Procedure called when the genworld process finishes.
GenWorldProgress
Current stage of world generation process.
Generate objects (radio tower, light houses)
void StartNewGameWithoutGUI(uint seed)
Start a normal game without the GUI.
Generate a map for a new game.
void GenerateWorldSetAbortCallback(GWAbortProc *proc)
Set here the function, if any, that you want to be called when landscape generation is aborted...
uint size_y
Y-size of the map.
GenWorldMode
Modes for GenerateWorld.
static const uint CUSTOM_SEA_LEVEL_NUMBER_DIFFICULTY
Value for custom sea level in difficulty settings.
Initialize/allocate the map, start economy.
bool IsGeneratingWorldAborted()
Is the generation being aborted?
Smoothness preset 'smooth'.
void ShowGenerateWorldProgress()
Show the window where a user can follow the process of the map generation.
Generate a newgame from a heightmap.
static const uint GENERATE_NEW_SEED
Create a new random seed.
GenWorldMode mode
What mode are we making a world in.
bool quit_thread
Do we want to quit the active thread.
uint size_x
X-size of the map.
Smoothness preset 'rough'.
Smoothness preset 'very rough'.
bool abort
Whether to abort the thread ASAP.
GWDoneProc * proc
Proc that is called when done (can be NULL)
TgenSmoothness
Smoothness presets.
bool _generating_world
Whether we are generating the map or not.
bool IsGenerateWorldThreaded()
Tells if the world generation is done in a thread or not.
TerraGenesis Perlin landscape generator.
bool threaded
Whether we run _GenerateWorld threaded.
Properties of current genworld process.
Generate an empty map (sea-level)
void StartScenarioEditor()
Start with a scenario editor.
void GenerateWorld(GenWorldMode mode, uint size_x, uint size_y, bool reset_settings=true)
Generate a world.
Runs the tile loop 1280 times to make snow etc.
void GWAbortProc()
Called when genworld is aborted.
GWAbortProc * abortp
Proc that is called when aborting (can be NULL)
LandscapeGenerator
Constants related to world generation.
void HandleGeneratingWorldAbortion()
Really handle the abortion, i.e.
void ShowCreateScenario()
Show the window to create a scenario.
Runs the game script at most 2500 times, or when ever the script sleeps.
static const uint CUSTOM_SEA_LEVEL_MIN_PERCENTAGE
Minimum percentage a user can specify for custom sea level.
CompanyID lc
The local_company before generating.
class ThreadObject * thread
The thread we are in (can be NULL)
void AbortGeneratingWorld()
Initializes the abortion process.
Make rough and rocky areas.
Types related to companies.
The original landscape generator.
static const uint CUSTOM_SEA_LEVEL_MAX_PERCENTAGE
Maximum percentage a user can specify for custom sea level.
void WaitTillGeneratedWorld()
This will wait for the thread to finish up his work.
Owner
Enum for all companies/owners.
void SetGeneratingWorldProgress(GenWorldProgress cls, uint total)
Set the total of a stage of the world generation.
void GenerateWorldSetCallback(GWDoneProc *proc)
Set here the function, if any, that you want to be called when landscape generation is done...
void SetNewLandscapeType(byte landscape)
Changes landscape type and sets genworld window dirty.
void IncreaseGeneratingWorldProgress(GenWorldProgress cls)
Increases the current stage of the world generation with one.
A Thread Object which works on all our supported OSes.
Generate a random map for SE.
Really prepare to start the game.
Smoothness preset 'very smooth'.