@civ-clone/core-city-growth
TypeScript icon, indicating that this package has built-in type declarations

0.1.2 • Public • Published

core-city-growth

Methods relating to the changing size of Citys.

The main CityGrowth object stores the current state of Food for a City and has convenience methods for controlling when a City's size changes. CityGrowths are retrieved via a CityGrowthRegistry instance. A growth key of AdditionalData is provided for Citys automatically.

Includes the following Rules:

  • Cost for determining how much Food growth requires.
  • FoodExhausted when FoodStorage is depleted.
  • FoodLow triggered when FoodStorage is "low".
  • FoodStorage processed when CityGrowth.check is called.
  • Grow controls what happens when CityGrowth.grow is called.
  • Shrink when CityGrowth.shrink is called.

Package Sidebar

Install

npm i @civ-clone/core-city-growth

Weekly Downloads

1

Version

0.1.2

License

MIT

Unpacked Size

26.3 kB

Total Files

57

Last publish

Collaborators

  • dom111