FB2HopeComponent
Overview
- Component that manages hopes.
Metadata
| Field | Value |
|---|---|
| Kind | component |
| Environment | B2 - Simulation |
| Category | components |
| Extends | FB2Component |
| Require | require('Components.B2HopeComponent') |
Properties (17)
| Name | Type | Description |
|---|---|---|
AvailableHopes | table<FB2HopeAvailableData, boolean> | |
CachedActiveSiteTags | string[] | Cache of the same 5-stage chain call used by autonomy (B2AutonomyComponent); recomputed via GetTPOSiteTags + CollectTPOTagsFromSiteTags and cached per CurrentTicks. |
CachedActiveSiteTagsTick | integer | |
CachedPerferenceCRC | integer | Cache of frequently used data. |
CachedPreferenceConsMap | table<integer, boolean> | |
CachedTPOTags | FB2TPOCollectedTags | |
CurrentPoolIndex | integer | Iterator used during split condition updates. |
CurrentTicks | integer | |
DeSelectedHopes | table<string, integer> | |
HopeDistributeContainer | FB2HopeDistributeContainer | Struct for split processing. |
NextDistributeCheckIndex | integer | |
NextFilterTicks | integer | |
NextSelectTicks | integer | |
ScriptContext | FB2ScriptContext | |
SelectedHopes | FB1HopeSlotInfo[] | |
TempAvailableHopes | table<FB2HopeAvailableData, boolean> | Buffer used during lazy update. |
bInLazyUpdateHopes | boolean |
Functions (30)
| Function | Parameters | Returns | Description |
|---|---|---|---|
DeSelectAllHopes | - | - | Cheat/test-only. |
Deinitialize (static) | - | - | |
FixHope | InHopeId: string, bIsFix: boolean | boolean | |
ForceUpdateHopes | - | boolean | |
ForceUpdateHopesForCheat | - | boolean | |
GetCityMovePolicyMap | InCityMoveDataPolicyType: EB1CityMoveDataPolicyType | table<string, EB1CityMoveDataPolicy> | Returns City Move Policy Map. |
GetDeSelectedHopes | - | table<string, integer> | Returns De Selected Hopes. |
GetDefaultCityMoveDataPolicy | - | EB1CityMoveDataPolicy | Returns Default City Move Data Policy. |
GetSelectedHopes | - | FB1HopeSlotInfo[] | Returns Selected Hopes. |
HandleCustomPolicyCityMoveData | InCityMovedData: nil, InCityMoveDataPolicyType: EB1CityMoveDataPolicyType | - | |
Initialize (static) | - | - | |
IsAlreadySelected | InHopeId: string | boolean | Returns whether Already Selected. |
IsSelectedOrPossessedPlayer (static) | EntityId: FB1EntityId | boolean | Whether the entity is being watched - selected or possessed. |
LazyUpdateAvailableHopes | UpdateCnt: integer | boolean | |
MakeSyncPreferenceCRC | IsChangedCRC: boolean | boolean | Makes Sync Preference CRC. |
OnAmbitionChanged | - | - | Event |
OnChangeCharacterGroupType | InPrevGroupType: EB1CharacterGroupType, InCurrGroupType: EB1CharacterGroupType | - | Callback invoked on Change Character Group Type. |
OnFinishMission | InHopeId: string, InMissionId: FB1MissionId | boolean | Mission. |
OnHopeLifeChanged | - | - | Callback invoked on Hope Life Changed. |
OnOwnerStateChanged | - | - | Callback invoked on Owner State Changed. |
OnPerspectiveValueChanged | - | - | Callback invoked on Perspective Value Changed. |
OnPreferenceUpdated | - | - | Callback invoked on Preference Updated. |
OnTargetEntityDeath | InDeadEntityId: FB1EntityId | - | Callback invoked on Target Entity Death. |
ProcessCachedCondition | Condition: FB1Condition | boolean | Cahced [7/12/2024 ahnseok.kim] |
RequestAddSpecificAvailableHopeSingle | InHopeId: string | boolean | Requests Add Specific Available Hope Single. |
ResetLazyUpdateFlag | - | - | Resets Lazy Update Flag. |
SetCachedCondition | Condition: FB1Condition, Result: boolean | - | Sets Cached Condition. |
ShouldUseScheduler | - | boolean | Returns whether it should Use Scheduler. |
UpdateAvailableHopes | bCheckConditions: boolean, bCheckTicks: boolean | boolean | Updates Available Hopes. |
UpdateSelectedPlayer (static) | InSelectedPlayerId: FB1EntityId | - | Updates Selected Player. |
Override points (21)
Implement these in Lua as FB2HopeComponent.Override_Name = function(...) end.
| Function | Parameters | Returns | Description |
|---|---|---|---|
Override_DeSelectAllHopes | - | - | Cheat/test-only. |
Override_Deinitialize (static) | - | - | |
Override_FixHope | InHopeId: string, bIsFix: boolean | boolean | |
Override_ForceUpdateHopes | - | boolean | |
Override_ForceUpdateHopesForCheat | - | boolean | |
Override_HandleCustomPolicyCityMoveData | InCityMovedData: nil, InCityMoveDataPolicyType: EB1CityMoveDataPolicyType | - | |
Override_Initialize (static) | - | - | |
Override_LazyUpdateAvailableHopes | - | boolean | |
Override_OnAmbitionChanged | - | - | Event |
Override_OnChangeCharacterGroupType | InPrevGroupType: EB1CharacterGroupType, InCurrGroupType: EB1CharacterGroupType | - | Callback invoked on Change Character Group Type. |
Override_OnFinishMission | InHopeId: string, InMissionId: FB1MissionId | boolean | Mission. |
Override_OnHopeLifeChanged | - | - | Callback invoked on Hope Life Changed. |
Override_OnOwnerStateChanged | - | - | Callback invoked on Owner State Changed. |
Override_OnPerspectiveValueChanged | - | - | Callback invoked on Perspective Value Changed. |
Override_OnPreferenceUpdated | - | - | Callback invoked on Preference Updated. |
Override_OnTargetEntityDeath | InDeadEntityId: FB1EntityId | - | Callback invoked on Target Entity Death. |
Override_ProcessCachedCondition | Condition: FB1Condition | boolean | Cahced [7/12/2024 ahnseok.kim] |
Override_RequestAddSpecificAvailableHopeSingle | InHopeId: string | boolean | Requests Add Specific Available Hope Single. |
Override_ResetLazyUpdateFlag | - | - | Resets Lazy Update Flag. |
Override_UpdateAvailableHopes | - | boolean | Updates Available Hopes. |
Override_UpdateSelectedPlayer (static) | InSelectedPlayerId: FB1EntityId | - | Updates Selected Player. |