Skip to main content

FB2CityEditManager

Overview

  • Manages city editing.

Metadata

FieldValue
Kindsystem
EnvironmentB2 - Simulation
Categorysystems
ExtendsFB2ManagerBase
Requirerequire('Systems.B2CityEditManager')

Properties (12)

NameTypeDescription
CurrentSelectionIdListtable<string, FB1MeshReplaceSelectionList>
DailyLogFB1DailyLog
DailyLogBuffCountertable<FB1EntityId, table<string, boolean>>Used to count per-day occurrences when handling DailyLog buffs. Not saved; not gameplay-critical, and it only matters that it accumulates once even after continuing a game.
DecorationObjectSpawnListtable<string, FB1DecorationObjectList>
DecorationSpawnCounttable<string, FB1DecorationSpawnCountList>worldName
DecorationSpawnRemainTimenumber
DecorationSpawnTickCountinteger
MaxSpawnCountTotalCachetable<TPair<FName, FName>,int32>(mapName, categoryName) -> total max spawn slots cache. Comes from a data asset/table lookup so it is runtime-immutable (no explicit invalidate needed); since the key includes mapName, different entries are used automatically on level change.
ModifierMaptable<EB1ModifierType, table<string, FB1ModifierData>>
PendingDecorationSpawnListtable<string, FB1DecorationSpawnInfoList>
WorldDecorationSpawnCountValuetable<string, FB1WorldDecorationSpawnCountDataList>
bCityEditModeboolean

Functions (33)

FunctionParametersReturnsDescription
AddWorldModifierValueInModifierId: string, InOverrideValue: number-Adds World Modifier Value.
AsyncSpawnDecorationDeltaTime: number-
CalculateModifierValueInModifierType: EB1ModifierType, InKey: string, InValue: numbernumber
GetDecorationCountValueInCategoryName: stringnumberReturns Decoration Count Value.
GetDecorationSpawnedCountInCategory: stringintegerSums the current spawned count / target count per category.
GetDecorationTargetCountInCategory: stringintegerReturns Decoration Target Count.
GetMaxSpawnCountInMapName: string, InCategoryName: string, OutMaxSpawnCountMap: table<string, integer>-Returns Max Spawn Count.
GetMaxSpawnCountTotalInMapName: string, InCategoryName: stringintegerAccumulates the sum of per-decoId quotas directly (e.g. for a debug HUD), without TMap allocation/iteration.
GetMeshReplaceSelectionInCategory: string, OutSelectionList: FB1MeshReplaceSelectionData[]booleanReturns Mesh Replace Selection.
GetModifierValueInModifierId: stringnumberReturns Modifier Value.
GetType-EB2ManagerTypeReturns Type.
GetWholeMeshReplaceSelectionOutSelectionList: FB1MeshReplaceSelectionData[]booleanReturns Whole Mesh Replace Selection.
HandleBirthLog (static)--
HandleBuffLog (static)InBuffEntityId: FB1EntityId, InId: string-
HandleCarAccidentLog (static)--
HandleDeathLog (static)InLifeTriggerId: string-
HandleDreamLog (static)InId: string-
HandleInteractionFinishLog (static)InId: string-
HandleRelationshipChangedLog (static)InId: string-
HandleStateLog (static)InId: string-
IsCityEditMode-booleanReturns whether City Edit Mode.
IsSpawnCountIsolateInCategoryName: string, InDecoId: stringbooleanReturns whether Spawn Count Isolate.
IsTickable-booleanReturns whether Tickable.
OnDayOfWeekChangedInCityId: string, Before: FDateTime, After: FDateTime-Callback invoked on Day Of Week Changed.
RemoveWorldModifierValueInModifierId: string-Removes World Modifier Value.
Reset--
SetCityEditModebInCityEditMode: boolean-Sets City Edit Mode.
SetSelectionInSelection: table<string, FB1MeshReplaceSelectionList>-Sets Selection.
SetStabilitySelectionInId: string, InValue: number-Sets Stability Selection.
UpdateSpawnCountRatioDecorationInCategory: string, InValue: number-Updates Spawn Count Ratio Decoration.
UpdateSpawnDecorationInCategory: string-Updates Spawn Decoration.
UpdateSpawnDecorationWhole--Updates Spawn Decoration Whole.
UpdateZoITotalCount--Updates Zo ITotal Count.

Override points (18)

Implement these in Lua as FB2CityEditManager.Override_Name = function(...) end.

FunctionParametersReturnsDescription
Override_AddWorldModifierValueInModifierId: string, InOverrideValue: number-Adds World Modifier Value.
Override_AsyncSpawnDecorationDeltaTime: number-
Override_CalculateModifierValueInModifierType: EB1ModifierType, InKey: string, InValue: numbernumber
Override_HandleBirthLog (static)--
Override_HandleBuffLog (static)InEntityId: FB1EntityId, InId: string-
Override_HandleCarAccidentLog (static)--
Override_HandleDeathLog (static)InLifeTriggerId: string-
Override_HandleDreamLog (static)InId: string-
Override_HandleInteractionFinishLog (static)InId: string-
Override_HandleRelationshipChangedLog (static)InId: string-
Override_HandleStateLog (static)InId: string-
Override_OnDayOfWeekChangedInCityId: string, Before: FDateTime, After: FDateTime-Callback invoked on Day Of Week Changed.
Override_RemoveWorldModifierValueInModifierId: string-Removes World Modifier Value.
Override_Reset--
Override_UpdateSpawnCountRatioDecorationInCategory: string, InValue: number-Updates Spawn Count Ratio Decoration.
Override_UpdateSpawnDecorationInCategory: string-Updates Spawn Decoration.
Override_UpdateSpawnDecorationWhole--Updates Spawn Decoration Whole.
Override_UpdateZoITotalCount--Updates Zo ITotal Count.