Loading...
Searching...
No Matches
CityBuilderTown Namespace Reference

Classes

class  ItemConstructionComponent
 building component that waits for items to be delivered to it
when all items have been delivered it terminates itself and places a different building in its stead
an example can be found in CityBuilderCore.Tests/City/ResourceSystems/Construct/ConstructionDebugging More...
 
class  ManualTownWalkerSpawner
 concrete implementation for serialization, not needed starting unity 2020.1 More...
 
class  TownBuildingDialog
 visualizes the state of a town building in the UI More...
 
class  TownBuildTask
 task that makes walkers go to it and progress it while playing the work animation
used by the TownConstructionComponent More...
 
class  TownClearTask
 makes walkers walk to its point and play a quick work animation
after that a specified structure has the point removed and the task finishes
used by TownConstructionComponent to clear the ground of grass before the actual building starts More...
 
class  TownConstructionComponent
 building component used when constructing buildings
when first placed it checks if there are any trees or rocks in the way and creates harvest tasks so they are replaced
when all obstructions are cleared it creates TownClearTasks for every point of the building which removes grass details from the terrain
if there are any items specified in ItemStorage.ItemCapacities it creates a TownDeliverTask for those next
finally if there is a BuildTaskPrefab specified it creates that and waits for the building to be done
after all the work is done it terminates itself and adds the building specified in FinishedBuilding More...
 
class  TownDeliverTask
 task that makes walkers deliver whatever items are needed by the IItemReceiver of the building under the task
used to supply food and wood to TownMarketComponent, to get building materials to TownConstructionComponent and for raw materials needed in TownProductionComponent More...
 
class  TownDemolishTask
 task makes walker walk to it, work for a little and the removes the structure it sits on
when it is placed on a building it makes the walker go to the building instead of the task point More...
 
class  TownDemolishTool
 tool that removes tasks and places demlish tasks for structures More...
 
class  TownDifficulty
 inherited version of Difficulty with additional fields specific to the Town demo More...
 
class  TownDistributionTask
 makes a walker go to the market the task stands on and pick up items
the walker then roams the roads connected to the market filling up their stores
afterwards the walker walks back to the market and returns the remaining items
the items carried by the walker are reserved in the market to avoid the market getting filled while the walker is out More...
 
class  TownFarmingComponent
 building component that creates and manages a TownFieldTask for every point of its building
actual farming mechanics are performed in those tasks More...
 
class  TownFieldTask
 in spring the field can be tilled which makes a walker go to its point and work for a set time
if the tilling was completed in spring the field will grow during summer when autumn comes and the field has grown fully it can be harvested by a walker which places an item and resets the field More...
 
class  TownForestingComponent
 periodically spawns a TownPlantTask and a TownHarvestTask within a specified radius
only spawns up to 2 of each of them so they dont spawn infinitely of there is no walker taking care of them More...
 
class  TownGatheringComponent
 periodically spawns a TownGatherTask within its radius
only spawns up to 2 taks so they dont spawn infinitely of there is no walker taking care of them
used to collect berries from bushes which is better than harvesting because it does not remove the bush and berries will regrow More...
 
class  TownGatherTask
 after a walker goes to the task point and spend some time working the task is finished and the walker receives some items
the point is also removed from a source structure and may be added to a destination structure
for example when gathering berries the point is removed from the berries structure and added to berries empty More...
 
class  TownHarvestTask
 makes walker go to point> work> wait> work and then places an item on the ground
when gathering a tree the first work fells the tree and removes it from the primary structure
the wait time is spent waiting for the tree to fall
working the second duration represents the walker making the falling ready for pickup More...
 
class  TownHarvestTool
 tool that places TownHarvestTask at points that have structures that match a harvest tasks PrimaryStructureKey
harvest tasks have to be known to TownManager More...
 
class  TownHomeComponent
 houses TownWalkers and stores food and wood
items are filled by the inhabitants or peddlers that work in a market that is connected via road
food is taken by by walkers to restore their food value
wood is periodically consumed by the component, as long as there is any walkers can restore their warmth value when they visit the house
the home also periodically spawns walkers up to its capacity More...
 
struct  TownIdentity
 holds the "personality" of a TownWalker, randomly generated when a walker spawns More...
 
class  TownItemTask
 items lying on the map ready to be collected and stored
a walker has to go to the task and spend a little bit of time picking it up
after that the items are added to the walkers storage and the task is finished
storing the item is the walkers business and not part of the task More...
 
class  TownJobInput
 ui behaviour that lets players set number of walkers for the specified job More...
 
class  TownLimitInput
 lets players set limits for certain items
for example wood has to be limited because there might be no logs left for construction otherwise More...
 
class  TownManager
 central manager for the town demo
manages tasks, jobs, walkers, seasons
More...
 
class  TownMarketComponent
 component that has food and wood delivered to it and distributes them to any recipients connected by road More...
 
class  TownMenu
 visualy fades between the different menu panels and provides logic for exiting and quitting the game More...
 
class  TownMenuContinue
 used to continue the last saved game, disabled itself if there is no game to continue More...
 
class  TownMenuLoad
 displays the created save games per mission and difficulty
save games can be selected and then loaded or deleted More...
 
class  TownMenuNew
 manages the options for new games and also starts a new game and passes the options into the mission parameters More...
 
class  TownMenuSave
 displays the created save games for the current mission and difficulty
save games can be deleted or overriden with a new save, creating a new save is done with a seperate input and button More...
 
class  TownPathTask
 task that makes a walker go to its point and spand a little time working
after that a road is added at that point More...
 
class  TownPathTool
 tool that places TownPathTask at available points More...
 
class  TownPlantTask
 task that makes a walker go to its point and spand a little time working
after that a point is added to a structure at the tasks location
for example the forrester creates a plant task for the Trees Growing structure
which eventually turns into a full tree that can be harvested for logs More...
 
class  TownProductionComponent
 produces items using specified raw materials and places them in specified points
used in combination with TownWorkComponent for the woodcutter
the production component sets IsWorking when all the raw materials have arrived
when IsWorking is true the work component activates its work tasks which drive efficiency
production is dependent on efficiency so progress is only made when walkers are working More...
 
class  TownProgressAction
 walker action that progresses a task by calling (like harvesting or building)
calls TownTask.ProgressTask(TownWalker, string) and ends when that returns false
this is done so the progress value can be stored on the task which makes it possible
for multiple walkers to work on the same task and for walkers to stop progressing midway More...
 
class  TownProvisionAction
 action that provisions a TownHomeComponent with a type of item like food or wood
which item that is, as well as the giver and the path to take, has to be provided
the action reserves the items quantity in the giver and the needed capacity in the home More...
 
class  TownRecoveryAction
 walker action that is triggered when a walker runs out of energy from working
the action leaves the walker standing still and calls TownWalker.Recover until the walker returns false when it has full energy again More...
 
class  TownSaveGame
 behaviour used when displaying save games
shows things like name, image and duration and gives access to the button that is used to select saves More...
 
class  TownSelectionSwitcher
 variant of the SelectionSwitcher that also cycles walkers by the job they have in the town demo More...
 
class  TownSetup
 generates a random terrain at the start of the game
can be tested in the editor using the buttons in the inspector
theres a save test scene in CityBuilderTown.Tests/Setup/TownSetupTest.unity More...
 
class  TownSignalAction
 walker action that just sends a signal in the form of a text key to the walkers current task
may be used to signal to the task that a certain stage of the process has been reached More...
 
class  TownStartupTool
 tool used when the game first starts to place the initial buildings and walkers
after it is used once it gets hidden by TownManager and the rest of the tools appear More...
 
class  TownTask
 tasks are behaviours that contain a series of action for a walker to complete
this can be as simple as an item pickup or more complex like a farming field that changes throughout the years
they are either managed(creation, persistence, termination) globally by the TownManager or locally by, for example, a building component
when they are not otherwise occupied TownWalkers query the TownManager for the most appropriate task which depends on their position and job More...
 
class  TownTaskData
 class used when persisting tasks
tasks that have state of their own can override TownTask.saveExtras and TownTask.loadExtras(string) More...
 
class  TownTaskSet
 some collection of tasks
a set of all taks in the game is needed by TownManager so tasks can be found when a game gets loaded More...
 
class  TownViewWalkerEnergyBar
 view that visualizes a walkers current energy in percent More...
 
class  TownViewWalkerFoodBar
 view that visualizes a walkers current food in percent More...
 
class  TownViewWalkerWarmthBar
 view that visualizes a walkers current warmth in percent More...
 
class  TownWalker
 town walkers are the only kind of walker in the town demo and are managed by the TownManager
they have some inherent actions like eat or chill that they take on their own
when none of those is currently needed they check if theres a TownTask available for them and perform that More...
 
class  TownWalkerActionBar
 visualizes what the walker is currently doing using an icon
tasks are visualized using TownTask.Icon, other processes use icons found in TownManager More...
 
class  TownWalkerDialog
 visualizes the state of a town walker in the UI More...
 
class  TownWalkerInfoBar
 visualizes a walkers job and name More...
 
class  TownWorkAction
 just puts the walker in an animation that shows it is working
in combination with TownWorkTask and TownWorkComponent this can drive a buildings efficiency
(for example in the Woodcutter which has a TownProductionComponent that uses that efficiency) More...
 
class  TownWorkComponent
 building component that uses TownWorkTasks to drive the buildings efficiency
the work tasks are only active when the buildings IsWorking is true
this is used in TownProductionComponent to only activate work when raw materials are present More...
 
class  TownWorkTask
 task that makes a walker work at its point on the map
the TownWorkComponent uses this task to get walkers to work at it and check how many are doing so More...
 
class  ViewBuildingBarGeneric
 view used for bars that take care of retrieving values on their own instead of using an IBuildingValue More...
 
class  ViewWalkerBarGeneric
 view used for bars that take care of retrieving values on their own instead of using an IWalkerValue More...
 

Enumerations

enum  TownSeason { Spring = 0 , Summer = 1 , Autumn = 2 , Winter = 3 }