Romestead Assembly Reference

CandideServer.ServerManagers.TownsServerManager

Type JSON

public class in CandideServer.ServerManagers

Methods20
Properties0
Fields2
Events0
Type metadata
  • AssemblyCandideServer
  • NamespaceCandideServer.ServerManagers
  • Base typeSystem.Object
  • Hash0E0CFAA840554AA662B7AD9081631C847144545993102855FCF369E7A85FD47E

Relationships

Base type

System.Object

Fields

NameVisibilitySignature
CitizensOverviewReuseprivateprivate System.Collections.Generic.Dictionary<System.Guid, CandideServer.MessageModels.Towns.CitizenTownOverviewData> CitizensOverviewReuse
ReUseBuildingIdsListprivateprivate System.Collections.Generic.List<System.Guid> ReUseBuildingIdsList

Methods

AddBuildingToNearestTown

public System.Void AddBuildingToNearestTown(CandideServer.SimulationModels.BuildingSimulationModel building)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Void
  • StaticTrue
  • VirtualFalse
  • Hash32D8DC86D69FFFC1322EE7C73E18BA85DE4CAFB85AADA00EC215148D877A2C9D
  • Body hashF89E3F02854D3760AC41F807EFEF5B8872129EAA59E17091D445D6B57DE4908D
  • IL size354
Referenced calls
  • System.Nullable<System.Guid>::get_HasValue()
  • Microsoft.Xna.Framework.Rectangle::get_Location()
  • Microsoft.Xna.Framework.Point::ToVector2()
  • Microsoft.Xna.Framework.Rectangle::get_Size()
  • Microsoft.Xna.Framework.Vector2::op_Multiply(Microsoft.Xna.Framework.Vector2, System.Single)
  • Microsoft.Xna.Framework.Vector2::op_Addition(Microsoft.Xna.Framework.Vector2, Microsoft.Xna.Framework.Vector2)
  • System.Collections.Generic.Dictionary<System.Guid, CandideServer.Models.Town.ServerTownModel>::get_Values()
  • Dictionary.ValueCollection<System.Guid, CandideServer.Models.Town.ServerTownModel>::GetEnumerator()
  • Dictionary.ValueCollection.Enumerator<System.Guid, CandideServer.Models.Town.ServerTownModel>::get_Current()
  • System.Collections.Generic.HashSet<System.Guid>::GetEnumerator()
  • HashSet.Enumerator<System.Guid>::get_Current()
  • System.Collections.Generic.Dictionary<System.Guid, CandideServer.SimulationModels.BuildingSimulationModel>::TryGetValue(!0, !1&)
  • Microsoft.Xna.Framework.Vector2::Distance(Microsoft.Xna.Framework.Vector2, Microsoft.Xna.Framework.Vector2)
  • CandideServer.ServerControllers.TownsServerController::AddBuildingToTown(CandideServer.SimulationModels.BuildingSimulationModel, CandideServer.Models.Town.ServerTownModel)
  • HashSet.Enumerator<System.Guid>::MoveNext()
  • System.IDisposable::Dispose()
  • Dictionary.ValueCollection.Enumerator<System.Guid, CandideServer.Models.Town.ServerTownModel>::MoveNext()
  • CandideServer.MessageModels.Towns.TownUpdatedMessage::.ctor()
  • CandideServer.ServerServices.TownsServerService::Send_TownBuildingsUpdated(CandideServer.MessageModels.Towns.TownUpdatedMessage)

AddNewBuildingToTown

public System.Void AddNewBuildingToTown(CandideServer.SimulationModels.BuildingSimulationModel building, System.Guid townId)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Void
  • StaticTrue
  • VirtualFalse
  • Hash96D23067C68B8F52313BB3B09703C082C0AA25460C49238B8D7C832278A0FEA2
  • Body hashC9441B489572F568500538B70C1E8AA9EA7D47969AF51A2FEBF4E09E60150681
  • IL size100
Referenced calls
String literals
  • Could not find town with id '
  • ' when adding new building.

AssignCitizenToSlot

public System.Void AssignCitizenToSlot(CandideServer.MessageModels.Towns.AssignCitizenToSlotMessage msg)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Void
  • StaticTrue
  • VirtualFalse
  • Hash43BF509F3880794C5C0BAF7CC89A2EA623F1D96A194F48FA433EBA7A2B3276E5
  • Body hash3098AE01ABB2035E1FB8E1EBDB07024D21828A9CD7A282117B63873ECD719E32
  • IL size276
Referenced calls
Called by
String literals
  • AssignCitizenToSlot: Citizen already has a slot ID set.
  • TownsServerManager
  • : Building with ID
  • is missing a town ID

AssignCitizenToSlot

public System.Void AssignCitizenToSlot(CandideServer.Models.Town.ServerTownModel town, CandideServer.Models.Citizen.CitizenModel citizen, CandideServer.SimulationModels.BuildingSimulationModel building, CandideServer.SimulationModels.CitizenSlotSimulationModel slot)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Void
  • StaticTrue
  • VirtualFalse
  • HashD50B89B33613B6B123782B952F506059D3D296CC89E14BEA7DD6D11B273A55B3
  • Body hashFDE100B2103B79424AABF7ED691CAB8B0EF39289867C54ED973CCA5DA554D823
  • IL size107
Referenced calls
Called by

ChangeTownName

public System.Void ChangeTownName(System.Guid townId, System.String name, System.Nullable<System.Guid> characterId, CandideServer.SyncStrategies.SyncStrategy syncStrategy)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Void
  • StaticTrue
  • VirtualFalse
  • HashAB487394857B6A880790548138ADE66CC9C967A097BBB9AB9BE087C9D04ACF5D
  • Body hash35A6A643CD64AFF3784F29D21839167ECC42449F62FA3583EBBD36DA5B31A59B
  • IL size43
Referenced calls
Called by

CitizenSwitchTown

public System.Void CitizenSwitchTown(CandideServer.MessageModels.Towns.CitizenSwitchTownMessage msg)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Void
  • StaticTrue
  • VirtualFalse
  • Hash9BF6446DB6260800C88796EB0E84BBAE8AF38A0A7EE0E266851E23ECFB46A68F
  • Body hash5C3226F95A54D3C76780EDCFCA1CE264DCFB50E64D799391EA8F50978D2599C3
  • IL size506
Referenced calls
Called by
String literals
  • CitizenSwitchTown
  • : Tried to switch town for citizen
  • but the citizen does not belong to the given source town
  • but the target town
  • does not have any available slots

CreateOverviewListeningData

public CandideServer.MessageModels.Towns.TownOverviewListeningData CreateOverviewListeningData(CandideServer.Models.Town.ServerTownModel town)

Method metadata
Referenced calls
  • System.Collections.Generic.Dictionary<System.Guid, CandideServer.MessageModels.Towns.CitizenTownOverviewData>::Clear()
  • System.Collections.Generic.HashSet<System.Guid>::GetEnumerator()
  • HashSet.Enumerator<System.Guid>::get_Current()
  • CandideServer.ServerGameState::TryGetCitizen(System.Guid, CandideServer.Models.Citizen.CitizenModel&)
  • CandideServer.MessageModels.Towns.CitizenTownOverviewData::.ctor()
  • System.Collections.Generic.Dictionary<System.Guid, CandideServer.MessageModels.Towns.CitizenTownOverviewData>::Add(!0, !1)
  • HashSet.Enumerator<System.Guid>::MoveNext()
  • System.IDisposable::Dispose()
  • CandideServer.ServerGameState::TryGetBuilding(System.Guid, CandideServer.SimulationModels.BuildingSimulationModel&)
  • System.Collections.Generic.List<System.Guid>::get_Count()
  • System.Collections.Generic.List<System.Guid>::GetEnumerator()
  • List.Enumerator<System.Guid>::get_Current()
  • CandideServer.ServerGameState::TryGetCitizenSlot(System.Guid, CandideServer.SimulationModels.CitizenSlotSimulationModel&)
  • System.Nullable<System.Guid>::get_HasValue()
  • System.Nullable<System.Guid>::get_Value()
  • System.Collections.Generic.Dictionary<System.Guid, CandideServer.MessageModels.Towns.CitizenTownOverviewData>::get_Item(!0)
  • System.Runtime.CompilerServices.DefaultInterpolatedStringHandler::.ctor(System.Int32, System.Int32)
  • System.Runtime.CompilerServices.DefaultInterpolatedStringHandler::AppendLiteral(System.String)
  • System.Runtime.CompilerServices.DefaultInterpolatedStringHandler::AppendFormatted(!!0)
  • System.Runtime.CompilerServices.DefaultInterpolatedStringHandler::ToStringAndClear()
  • CandideServer.ServerManagers.ServerCitizenException::.ctor(System.String)
  • List.Enumerator<System.Guid>::MoveNext()
  • CandideServer.MessageModels.Towns.TownOverviewListeningData::.ctor()
Called by
String literals
  • Citizen with ID
  • should have its citizien slot ID set
  • should have its home building ID set

CreateTown

public CandideServer.Models.Town.ServerTownModel CreateTown(System.Guid id, System.Guid firstBuildingId)

Method metadata
  • Visibilitypublic
  • Return typeCandideServer.Models.Town.ServerTownModel
  • StaticTrue
  • VirtualFalse
  • Hash983208B8FC50A5101DCFC06339225162E376BE441F6398622DE2A5D9DD003396
  • Body hash344B5753792172023CC05AE65978798587895A1D9D6B4DF90922ACF195748968
  • IL size72
Referenced calls
String literals
  • town
  • Town_Chat_Founded

GetAllMaterialStoragesForTown

public System.Collections.Generic.HashSet<System.Guid> GetAllMaterialStoragesForTown(CandideServer.Models.Town.TownModel town)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Collections.Generic.HashSet<System.Guid>
  • StaticTrue
  • VirtualFalse
  • Hash72B329641C68F949158F9B3DBBE21B4CB82D5AAC8E4E64E34EFEF96D6200F567
  • Body hash922DDFEE34F3A5E806C5B45799DE7F029F290BC874100D7264A8C81958E70AD8
  • IL size96
Referenced calls
Called by
String literals
  • material_storage

GetAvailableBuildingAndSlotForOneCitizen

public System.Nullable<System.ValueTuple<CandideServer.SimulationModels.BuildingSimulationModel, CandideServer.SimulationModels.CitizenSlotSimulationModel>> GetAvailableBuildingAndSlotForOneCitizen(CandideServer.Models.Town.ServerTownModel town)

Method metadata
Referenced calls
  • System.Collections.Generic.HashSet<System.Guid>::get_Count()
  • System.Collections.Generic.HashSet<System.Guid>::GetEnumerator()
  • HashSet.Enumerator<System.Guid>::get_Current()
  • CandideServer.ServerGameState::TryGetBuilding(System.Guid, CandideServer.SimulationModels.BuildingSimulationModel&)
  • System.Collections.Generic.List<System.Guid>::GetEnumerator()
  • List.Enumerator<System.Guid>::get_Current()
  • CandideServer.ServerGameState::TryGetCitizenSlot(System.Guid, CandideServer.SimulationModels.CitizenSlotSimulationModel&)
  • CandideServer.Models.Citizen.CitizenSlotModel::get_IsOccupied()
  • System.Nullable<System.ValueTuple<CandideServer.SimulationModels.BuildingSimulationModel, CandideServer.SimulationModels.CitizenSlotSimulationModel>>::get_HasValue()
  • System.Nullable<System.ValueTuple<CandideServer.SimulationModels.BuildingSimulationModel, CandideServer.SimulationModels.CitizenSlotSimulationModel>>::get_Value()
  • System.String::op_Inequality(System.String, System.String)
  • System.String::op_Equality(System.String, System.String)
  • System.ValueTuple<CandideServer.SimulationModels.BuildingSimulationModel, CandideServer.SimulationModels.CitizenSlotSimulationModel>::.ctor(!0, !1)
  • System.Nullable<System.ValueTuple<CandideServer.SimulationModels.BuildingSimulationModel, CandideServer.SimulationModels.CitizenSlotSimulationModel>>::.ctor(!0)
  • List.Enumerator<System.Guid>::MoveNext()
  • System.IDisposable::Dispose()
  • HashSet.Enumerator<System.Guid>::MoveNext()
  • CandideServer.ServerManagers.ServerCitizenException::.ctor(System.String)
Called by
String literals
  • insula
  • We have more citizens than slots for some reason. Unexpected

GetClosestTown

public CandideServer.Models.Town.ServerTownModel GetClosestTown(Microsoft.Xna.Framework.Vector2 worldPosition)

Method metadata
  • Visibilitypublic
  • Return typeCandideServer.Models.Town.ServerTownModel
  • StaticTrue
  • VirtualFalse
  • Hash2BD546F0D201898E91C93BB05533FC8DCFF0296E47465BC1972C91F65DA13D43
  • Body hash50069E4891009B3139A75BBB36B8D541DBBC32B51FF37A7AC8517CFAB9426EEE
  • IL size90
Referenced calls
  • Microsoft.Xna.Framework.Vector2::op_Division(Microsoft.Xna.Framework.Vector2, System.Single)
  • System.Collections.Generic.Dictionary<System.Guid, CandideServer.Models.Town.ServerTownModel>::get_Values()
  • Dictionary.ValueCollection<System.Guid, CandideServer.Models.Town.ServerTownModel>::GetEnumerator()
  • Dictionary.ValueCollection.Enumerator<System.Guid, CandideServer.Models.Town.ServerTownModel>::get_Current()
  • Microsoft.Xna.Framework.Rectangle::Contains(Microsoft.Xna.Framework.Vector2)
  • Dictionary.ValueCollection.Enumerator<System.Guid, CandideServer.Models.Town.ServerTownModel>::MoveNext()
  • System.IDisposable::Dispose()
Called by

GetClosestTownWithAvailableSlot

public CandideServer.Models.Town.ServerTownModel GetClosestTownWithAvailableSlot(Microsoft.Xna.Framework.Vector2 worldPosition, System.Guid worldId)

Method metadata
  • Visibilitypublic
  • Return typeCandideServer.Models.Town.ServerTownModel
  • StaticTrue
  • VirtualFalse
  • HashDCAE2775834540F560CE27C2F1683CC95994F06987CE730269FD2E8A9D230CF8
  • Body hash39DDE7565EB1EF569231A94581C7A2CEF432682023D24A87CD15606F20E70963
  • IL size301
Referenced calls
Called by
String literals
  • GetClosestTownWithAvailableSlot: We have more citizens than slots for some reason. Unexpected

RegisterTownDefenceValue

public System.Void RegisterTownDefenceValue(System.Guid townId, Shared.Models.Construction.ConstructionModel construction, System.Guid spawnId)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Void
  • StaticTrue
  • VirtualFalse
  • HashD01BF9A6733139CED5DB398E60788B3C7F1D4E06884763E7A88DFA484F68889E
  • Body hashBBD1B085B6477A30B1B12ACA44C82FA428BF02680D97B32800CAAFC807C6D0F6
  • IL size157
Referenced calls
Called by
String literals
  • Town already has a Defense Provider with ID

RemoveTown

public System.Void RemoveTown(CandideServer.Models.Town.TownModel town)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Void
  • StaticTrue
  • VirtualFalse
  • Hash9CA95051500071CA7DF8DA3703E095A99E8A1A4EEA83F63F5CC90FF47B7DCC38
  • Body hashCE23348D13A49427690E7686AE650A473457B7864C33DA377F41EBBFFE9F5D21
  • IL size100
Referenced calls
Called by

SwitchCitizenSlots

public System.Void SwitchCitizenSlots(CandideServer.MessageModels.Towns.SwitchCitizenSlotsMessage msg)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Void
  • StaticTrue
  • VirtualFalse
  • Hash8BA5B1AE5A44890B07BB18C22DF3C050679974C42894E52DC1AA7B6720F152B5
  • Body hashAE98C778D3ECE696FE78251776B09C974D5B1D951FAB8141A23EBB55821ECFB2
  • IL size901
Referenced calls
Called by
String literals
  • TownsServerManager
  • : Building with ID
  • is missing a town ID
  • SwitchCitizenSlots: Citizen slot had not the same citizen ID which was requested
  • SwitchCitizenSlots: Citizen slot had not the same building ID which was requested. Very grave error
  • SwitchCitizenSlots
  • SwitchCitizenSlots: Tried switching citizen slot but the source slot building's town and the target slot building's town

TryGetBuildingInTown

public System.Boolean TryGetBuildingInTown(System.String buildingTypeId, CandideServer.Models.Town.ServerTownModel town, out CandideServer.SimulationModels.BuildingSimulationModel& outBuilding)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Boolean
  • StaticTrue
  • VirtualFalse
  • Hash3B0790955DC783F2D206F3AD3343AA6EC2C5681F24869666BA45B317A7FB806A
  • Body hash653FDA22ED2BCC39CAC00B60932058AAAC464FC0C8CD76A1EED91DF7B5C59DFD
  • IL size93
Referenced calls
Called by

TryGetRandomBuildingInTown

public System.Boolean TryGetRandomBuildingInTown(CandideServer.Citizens.Base.AbstractCitizenController controller, CandideServer.Models.Town.ServerTownModel town, out CandideServer.SimulationModels.BuildingSimulationModel& outBuilding, System.Collections.Generic.List<System.Guid> excludedBuildingIds, System.Boolean excludeCurrentBuilding, System.Boolean excludeInteriors, System.Boolean excludeExteriors)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Boolean
  • StaticTrue
  • VirtualFalse
  • HashCDDBDB4C8A51171C60B3B95CC1983E0F10A343B69362ADBEBAC8DC41618AC48E
  • Body hash14E5FEE73B81B8A2268F842AC8EAC2F0EF063F0CBE56885B0C6D1E7C1E634AE2
  • IL size448
Referenced calls
  • System.Collections.Generic.List<System.Guid>::Clear()
  • System.Collections.Generic.List<System.Guid>::get_Count()
  • System.Collections.Generic.HashSet<System.Guid>::GetEnumerator()
  • HashSet.Enumerator<System.Guid>::get_Current()
  • System.Collections.Generic.List<System.Guid>::Contains(!0)
  • CandideServer.ServerGameState::TryGetBuilding(System.Guid, CandideServer.SimulationModels.BuildingSimulationModel&)
  • System.Nullable<System.Guid>::get_HasValue()
  • System.Nullable<System.Guid>::GetValueOrDefault()
  • System.Guid::op_Equality(System.Guid, System.Guid)
  • System.Collections.Generic.List<System.Guid>::Add(!0)
  • HashSet.Enumerator<System.Guid>::MoveNext()
  • System.IDisposable::Dispose()
  • System.Random::get_Shared()
  • System.Random::Next(System.Int32)
  • System.Collections.Generic.List<System.Guid>::get_Item(System.Int32)
  • System.Collections.Generic.Dictionary<System.Guid, CandideServer.SimulationModels.BuildingSimulationModel>::get_Item(!0)
Called by

TryGetTownWithinRange

public System.Boolean TryGetTownWithinRange(Microsoft.Xna.Framework.Vector2 center, System.Single range, out CandideServer.Models.Town.ServerTownModel& outTown, out Microsoft.Xna.Framework.Vector2& outTownAltarPos)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Boolean
  • StaticTrue
  • VirtualFalse
  • Hash6E1C9E5F7DD26BBEB08D28A11DE16514ABC6BA1B39C1D33F5FAEBC7A1A65A544
  • Body hash904ADB24A539D36103323AFB3FE616AD7D10FBD3B3205EE013873B3450B74D06
  • IL size165
Referenced calls
  • Microsoft.Xna.Framework.Vector2::get_Zero()
  • System.Collections.Generic.Dictionary<System.Guid, CandideServer.Models.Town.ServerTownModel>::get_Values()
  • Dictionary.ValueCollection<System.Guid, CandideServer.Models.Town.ServerTownModel>::GetEnumerator()
  • Dictionary.ValueCollection.Enumerator<System.Guid, CandideServer.Models.Town.ServerTownModel>::get_Current()
  • CandideServer.ServerManagers.TownsServerManager::TryGetBuildingInTown(System.String, CandideServer.Models.Town.ServerTownModel, CandideServer.SimulationModels.BuildingSimulationModel&)
  • Microsoft.Xna.Framework.Rectangle::get_Center()
  • Microsoft.Xna.Framework.Point::ToVector2()
  • Microsoft.Xna.Framework.Vector2::op_Multiply(Microsoft.Xna.Framework.Vector2, System.Single)
  • Microsoft.Xna.Framework.Vector2::op_Subtraction(Microsoft.Xna.Framework.Vector2, Microsoft.Xna.Framework.Vector2)
  • Microsoft.Xna.Framework.Vector2::LengthSquared()
  • Dictionary.ValueCollection.Enumerator<System.Guid, CandideServer.Models.Town.ServerTownModel>::MoveNext()
  • System.IDisposable::Dispose()
String literals
  • altar

UnassignCitizenFromSlot

public System.Void UnassignCitizenFromSlot(CandideServer.MessageModels.Towns.UnassignCitizenFromSlotMessage msg)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Void
  • StaticTrue
  • VirtualFalse
  • HashA88A30B49C3AE44271FA0E0625388922720D0AC3DF2A940FD4E0D005A769BA6D
  • Body hash92B54836B04A10D6465C76FC7500C782CBB6D0DE552B1B9C9B609C1548C3A987
  • IL size427
Referenced calls
Called by
String literals
  • TownsServerManager
  • : Building with ID
  • is missing a town ID
  • UnassignCitizenFromSlot: Citizen slot had not the same citizen ID which was requested
  • UnassignCitizenFromSlot: Citizen slot had not the same building ID which was requested. Very grave error

UnregisterTownDefenseValue

public System.Void UnregisterTownDefenseValue(CandideServer.Models.Town.ServerTownModel town, System.Guid spawnId)

Method metadata
  • Visibilitypublic
  • Return typeSystem.Void
  • StaticTrue
  • VirtualFalse
  • Hash50D27DB7B285FBF4D8892C2CF0AE7AA15C0725DFFF9C77250261672AE5AB2EBC
  • Body hash50C651B97E6DFB95AEFDB03E55E242A47FF7B635B6BC442D2E95AD0E37C52EDF
  • IL size28
Referenced calls
Called by