MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / SetGeneratingWorldProgress

Function SetGeneratingWorldProgress

src/genworld_gui.cpp:1525–1530  ·  view source on GitHub ↗

* Set the total of a stage of the world generation. * @param cls the current class we are in. * @param total Set the total expected items for this class. * * Warning: this function isn't clever. Don't go from class 4 to 3. Go upwards, always. * Also, progress works if total is zero, total works if progress is zero. */

Source from the content-addressed store, hash-verified

1523 * Also, progress works if total is zero, total works if progress is zero.
1524 */
1525void SetGeneratingWorldProgress(GenWorldProgress cls, uint total)
1526{
1527 if (total == 0) return;
1528
1529 _SetGeneratingWorldProgress(cls, 0, total);
1530}
1531
1532/**
1533 * Increases the current stage of the world generation with one.

Callers 8

GenerateIndustriesFunction · 0.85
CreateRiversFunction · 0.85
GenerateLandscapeFunction · 0.85
GenerateObjectsFunction · 0.85
GenerateClearTileFunction · 0.85
_GenerateWorldFunction · 0.85
GenerateTreesFunction · 0.85
GenerateTownsFunction · 0.85

Calls 1

Tested by

no test coverage detected