DayZ 1.24
Loading...
Searching...
No Matches
Managed Class Reference

TODO doc. More...

Inheritance diagram for Managed:
[legend]
Collaboration diagram for Managed:
[legend]

Protected Member Functions

void IntroSceneCharacter ()
 
void ~IntroSceneCharacter ()
 
bool IsDefaultCharacter ()
 
void SetToDefaultCharacter ()
 
void SetCharacterID (int char_id)
 
int GetCharacterID ()
 
PlayerBase GetCharacterObj ()
 
TStringArray GetCharGenderList ()
 
TStringArray GetCharList (ECharGender gender)
 
TStringArray GetCharShirtsList ()
 
TStringArray GetCharPantsList ()
 
TStringArray GetCharShoesList ()
 
void SetCharacterGender (ECharGender gender)
 
bool IsCharacterFemale ()
 
ECharGender GetCharacterGender ()
 
vector GetPosition ()
 
int GetNextCharacterID ()
 
int GetPrevCharacterID ()
 
void CreateNewCharacterRandom ()
 
void CreateNewCharacterById (int character_id)
 
void CreateNewCharacterByName (string character_name, bool randomize_equip=true)
 
void CreateDefaultCharacter ()
 
void GetLastPlayedServer (int characterID, out string address, out string name, out int port)
 
void CreateNewCharacter ()
 
void LoadCharacterData (vector char_pos, vector char_rot, bool default_char=false)
 Generates random equip for the new IntroSceneCharacter, whatever is defined in 'cfgCharacterCreation'.
 
void CharacterUnload ()
 
void CharacterLoad (int character_id, vector char_pos, vector char_rot)
 
void SetupPlayerName (bool new_name)
 
void SetAttachment (string type, int slot)
 
string GetCharacterNameById (int char_id)
 
string GetCharacterName ()
 
void SaveCharName (string name)
 
void SaveDefaultCharacter ()
 
void TransferValues (PlayerBase player)
 
void Init ()
 
void OnScheduledTick (float deltatime)
 
void CheckValues ()
 
float GetBlood ()
 
float GetHealth ()
 
void CheckHealth ()
 
void CheckBlood ()
 
void SendInitValues ()
 Sends values on object creation.
 
void SendValue (int value_type, float value)
 
void ReceiveValue (int value_type, float value)
 
void OnRPC (ParamsReadContext ctx)
 
void ShowDebugValues (bool show)
 
void BleedingIndicator (int source_ID, int severity, GameplayEffectsDataBleeding parent)
 
void InitIndicator (vector position)
 
void StopIndicator (bool instant=false)
 
void StartRunningDrops ()
 
bool IsRunningDrops ()
 Are any drops currently being animated?
 
void TrySpawnNextDrop ()
 
void ResetSequence ()
 
void ResetIndicator ()
 
void Update (float timeSlice)
 
bool GetEndNow ()
 
int GetSeverity ()
 
void GameplayEffectsData (array< ref Widget > input, int type, int user_override=-1)
 
void Init (array< ref Widget > input, int type, Widget layout_root, int user_override=-1)
 
array< ref WidgetGetWidgetSet ()
 
int GetWidgetSetType ()
 
int GetWidgetSetID ()
 
bool HasDefinedHandle ()
 Returns 'true' if this class contains update info.
 
bool DataInitialized ()
 
void UpdateVisibility (bool state)
 
void RegisterData (Param p)
 
void Update (float timeSlice=0, Param p=null, int handle=-1)
 
void ForceStop ()
 

Protected Attributes

int m_CharacterId
 
string m_CharacterType
 
MenuData m_CharacterDta
 
PlayerBase m_CharacterObj
 
vector m_CharacterPos
 
vector m_CharacterRot
 
ref TStringArray m_CharGenderList = new TStringArray
 
ref TStringArray m_CharShirtList = new TStringArray
 
ref TStringArray m_CharPantsList = new TStringArray
 
ref TStringArray m_CharShoesList = new TStringArray
 
ref map< ECharGender, ref array< string > > m_Characters = new map<ECharGender, ref array<string>>
 
ECharGender m_CharGender
 
bool m_InitialSyncSent
 
bool m_Initialized
 
bool m_Terminating = false
 
bool m_EndNow = false
 
bool m_IsRunning = false
 
int m_DropSpawnsQueued
 
int m_ActiveDropsCount
 
int m_Severity
 
int m_SourceID
 
GameplayEffectsDataBleeding m_ParentMetaData
 
array< floatm_DropProbabilityArray
 
float m_AverageFrequency
 
float m_SequenceTick
 
float m_SequenceDuration
 
float m_TimeElapsedTotal
 
float m_TimeElapsedSequence
 
float m_LastDropSpawnTime
 
float m_DropSpawnMinDelay
 
float m_DropSpawnMaxDelay
 
int m_CurrentDropProbabilityStep
 
int m_DropProbabilityRollsCount
 
vector m_BasePosition
 
ref set< ref BleedingIndicatorDropDatam_ActiveDrops
 
ref set< intm_CleanupQueue
 
ref array< ref Widgetm_WidgetArray
 
int m_Type
 
int m_WidgetSetIdentifier
 
Widget m_LayoutRoot
 

Private Member Functions

void IncreaseMaskUpdateCount ()
 
void ResetMaskUpdateCount ()
 
bool IsAnyEffectRunning ()
 
bool AreEffectsSuspended ()
 
void AddActiveEffects (array< int > effects)
 
void RemoveActiveEffects (array< int > effects)
 
void StopAllEffects ()
 
void AddSuspendRequest (int request_id)
 
void RemoveSuspendRequest (int request_id)
 
void ClearSuspendRequests ()
 
int GetSuspendRequestCount ()
 
void UpdateWidgets (int type=-1, float timeSlice=0, Param p=null, int handle=-1)
 
void Update (float timeSlice)
 
void OnVoiceEvent (float breathing_resistance01)
 
void SetBreathIntensityStamina (float stamina_cap, float stamina_current)
 
void RegisterGameplayEffectData (int id, Param p)
 

Static Private Member Functions

static void Init ()
 
static void Cleanup ()
 
static PPERequesterBase GetRequester (typename type)
 Returns an instance (singleton) of a requester based on typename.
 
static PPERequesterBase GetRequester (int index)
 Returns an instance (singleton) of a requester based on index.
 
static int GetRequesterID (typename type)
 Returns an ID of a requester type.
 
static GetRequesterTypename (int index)
 Returns a typename from a requester ID.
 
static int RegisterRequester (typename type)
 Registers new requester type.
 
static bool VerifyRequester (PPERequesterBase req)
 Verifies the instance.
 

Private Attributes

int m_MaskWidgetUpdateCount
 
const int TYPE_HEALTH = 1
 
const int TYPE_BLOOD = 2
 
const float VALUE_CHECK_INTERVAL = 5
 
const float SENSITIVTY_PERCENTAGE = 1
 
const int BLOOD_THRESHOLD_LOW = 3000
 
PlayerBase m_Player
 
float m_TimeSinceLastTick = VALUE_CHECK_INTERVAL + 1
 
float m_LastHealthUpdate
 
float m_LastBloodUpdate
 
float m_HealthMaxValue
 
float m_BloodMaxValue
 
float m_BloodClient
 
float m_HealthClient
 
int m_AnimType
 
float m_HitDir
 
float m_HealthDamage
 
bool m_Fullbody
 
bool m_HasSource
 

Static Private Attributes

static ref map< int, ref PPERequesterBasem_Instances
 
static bool m_Initialized = false
 
static int m_lastID = -1
 
static const int INVALID = -1
 
static const int REQ_INVENTORYBLUR = RegisterRequester(PPERequester_InventoryBlur)
 
static const int REQ_CONTROLLERDISCONNECT = RegisterRequester(PPERequester_ControllerDisconnectBlur)
 
static const int REQ_GLASSESSPORTBLACK = RegisterRequester(PPERequester_GlassesSportBlack)
 
static const int REQ_GLASSESSPORTBLUE = RegisterRequester(PPERequester_GlassesSportBlue)
 
static const int REQ_GLASSESSPORTGREEN = RegisterRequester(PPERequester_GlassesSportGreen)
 
static const int REQ_GLASSESSPORTORANGE = RegisterRequester(PPERequester_GlassesSportOrange)
 
static const int REQ_GLASSESAVIATOR = RegisterRequester(PPERequester_GlassesAviator)
 
static const int REQ_GLASSESDESIGNER = RegisterRequester(PPERequester_GlassesDesignerBlack)
 
static const int REQ_GLASSESTACTICAL = RegisterRequester(PPERequester_TacticalGoggles)
 
static const int REQ_MOTOHELMETBLACK = RegisterRequester(PPERequester_MotoHelmetBlack)
 
static const int REQ_GLASSESWELDING = RegisterRequester(PPERequester_WeldingMask)
 
static const int REQ_CAMERANV = RegisterRequester(PPERequester_CameraNV)
 
static const int REQ_CAMERAADS = RegisterRequester(PPERequester_CameraADS)
 
static const int REQ_BLOODLOSS = RegisterRequester(PPERequester_BloodLoss)
 
static const int REQ_DEATHEFFECTS = RegisterRequester(PPERequester_DeathDarkening)
 
static const int REQ_UNCONEFFECTS = RegisterRequester(PPERequester_UnconEffects)
 
static const int REQ_TUNELVISSION = RegisterRequester(PPERequester_TunnelVisionEffects)
 
static const int REQ_BURLAPSACK = RegisterRequester(PPERequester_BurlapSackEffects)
 
static const int REQ_INTROCHROMABB = RegisterRequester(PPERequester_IntroChromAbb)
 
static const int REQ_FEVEREFFECTS = RegisterRequester(PPERequester_FeverEffects)
 
static const int REQ_FLASHBANGEFFECTS = RegisterRequester(PPERequester_FlashbangEffects)
 
static const int REQ_SHOCKHITEFFECTS = RegisterRequester(PPERequester_ShockHitReaction)
 
static const int REQ_HEALTHHITEFFECTS = RegisterRequester(PPERequester_HealthHitReaction)
 
static const int REQ_MENUEFFECTS = RegisterRequester(PPERequester_MenuEffects)
 
static const int REQ_CONTROLLERBLUR = RegisterRequester(PPERequester_ControlsBlur)
 
static const int REQ_SERVERBROWSEREFFECTS = RegisterRequester(PPERequester_ServerBrowserBlur)
 
static const int REQ_TUTORIALEFFECTS = RegisterRequester(PPERequester_TutorialMenu)
 
static const int REQ_CONTAMINATEDAREA = RegisterRequester(PPERequester_ContaminatedAreaTint)
 
static const int REQ_SPOOKYAREA = RegisterRequester(PPERequester_SpookyAreaTint)
 
static const int REQ_PAINBLUR = RegisterRequester(PPERequester_PainBlur)
 
static const int REQ_UNDERGROUND = RegisterRequester(PPERUndergroundAcco)
 
static const int REQ_DROWNING = RegisterRequester(PPERequester_Drowning)
 
static ref PPERequesterRegistrations m_Registrations
 

Detailed Description

TODO doc.

generic metadata class

indicator wrapper for a specific bleeding source.

extendable type to allow for smarter hit data syncing

Requester bank contains all registered type instances as singletons. Creating new instances outside of bank might be a bad idea (and a way to memory leakage)

Definition at line 117 of file EnScript.c.

Constructor & Destructor Documentation

◆ ~IntroSceneCharacter()

void Managed::~IntroSceneCharacter ( )
inlineprotected

Definition at line 24 of file IntroSceneCharacter.c.

25 {
27 }
void CharacterUnload()

References CharacterUnload().

Member Function Documentation

◆ AddActiveEffects()

void Managed::AddActiveEffects ( array< int > effects)
inlineprivate

Definition at line 10 of file GameplayEffectWidgets_base.c.

10{}

◆ AddSuspendRequest()

void Managed::AddSuspendRequest ( int request_id)
inlineprivate

Definition at line 13 of file GameplayEffectWidgets_base.c.

13{}

◆ AreEffectsSuspended()

bool Managed::AreEffectsSuspended ( )
inlineprivate

Definition at line 9 of file GameplayEffectWidgets_base.c.

9{}

◆ BleedingIndicator()

void Managed::BleedingIndicator ( int source_ID,
int severity,
GameplayEffectsDataBleeding parent )
inlineprotected

Definition at line 31 of file BleedingIndicator.c.

32 {
33 m_Initialized = false;
36 m_ParentMetaData = parent;
42
43 switch (m_Severity)
44 {
46 {
51 break;
52 }
54 {
59 break;
60 }
62 {
67 break;
68 }
69
70 default:
71 {
75 Debug.Log("Unknown severity value!");
76 }
77#ifdef DIAG_DEVELOPER
79 {
83 }
84#endif
85 }
86
89 }
Definition Debug.c:14
static void Log(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Prints debug message with normal prio.
Definition Debug.c:133
float m_SequenceDuration
ref set< ref BleedingIndicatorDropData > m_ActiveDrops
ref set< int > m_CleanupQueue
GameplayEffectsDataBleeding m_ParentMetaData
int m_CurrentDropProbabilityStep
array< float > m_DropProbabilityArray
float m_TimeElapsedTotal
static bool m_Initialized
float m_TimeElapsedSequence
int m_DropProbabilityRollsCount
float m_AverageFrequency
float m_DropSpawnMinDelay
float m_DropSpawnMaxDelay

References BleedingIndicationConstants::INDICATOR_SEVERITY_HIGH, BleedingIndicationConstants::INDICATOR_SEVERITY_LOW, BleedingIndicationConstants::INDICATOR_SEVERITY_MEDIUM, Debug::Log(), DbgBleedingIndicationStaticInfo::m_DbgDropMaxDelay, DbgBleedingIndicationStaticInfo::m_DbgDropMinDelay, DbgBleedingIndicationStaticInfo::m_DbgSequenceDuration, DbgBleedingIndicationStaticInfo::m_DbgUseOverrideValues, m_Initialized, BleedingIndicationConstants::SEQUENCE_DROP_AVERAGE_HIGH, BleedingIndicationConstants::SEQUENCE_DROP_AVERAGE_LOW, BleedingIndicationConstants::SEQUENCE_DROP_AVERAGE_MEDIUM, BleedingIndicationConstants::SEQUENCE_DROP_DELAY_MAX_HIGH, BleedingIndicationConstants::SEQUENCE_DROP_DELAY_MAX_LOW, BleedingIndicationConstants::SEQUENCE_DROP_DELAY_MAX_MEDIUM, BleedingIndicationConstants::SEQUENCE_DROP_DELAY_MIN_HIGH, BleedingIndicationConstants::SEQUENCE_DROP_DELAY_MIN_LOW, BleedingIndicationConstants::SEQUENCE_DROP_DELAY_MIN_MEDIUM, BleedingIndicationConstants::SEQUENCE_DURATION_HIGH, BleedingIndicationConstants::SEQUENCE_DURATION_LOW, and BleedingIndicationConstants::SEQUENCE_DURATION_MEDIUM.

◆ CharacterLoad()

void Managed::CharacterLoad ( int character_id,
vector char_pos,
vector char_rot )
inlineprotected

Definition at line 336 of file IntroSceneCharacter.c.

337 {
338 if (character_id == -1)
339 {
340 Error("IntroSceneCharacter->CharacterLoad: character_id = " + character_id + " Cant Load Character!!!");
341 return;
342 }
343
345
347
349
350 if (m_CharacterObj)
351 {
352
353 m_CharacterObj.PlaceOnSurface();
354 m_CharacterObj.SetPosition(char_pos);
355 m_CharacterObj.SetOrientation(char_rot);
356 }
357 }
void SetCharacterID(int char_id)
PlayerBase m_CharacterObj
MenuData m_CharacterDta
proto native Man CreateCharacterPerson(int index)
Return Character person or null if character initialization failed (inventory load,...
void Error(string err)
Messagebox with error message.
Definition EnDebug.c:90

References CharacterUnload(), MenuData::CreateCharacterPerson(), Error(), and SetCharacterID().

Referenced by CreateNewCharacterById().

◆ CharacterUnload()

void Managed::CharacterUnload ( )
inlineprotected

Definition at line 324 of file IntroSceneCharacter.c.

325 {
326 if (m_CharacterObj)
327 {
328 g_Game.ObjectDelete(m_CharacterObj);
330 }
331 }
DayZGame g_Game
Definition DayZGame.c:3528

References g_Game.

Referenced by CharacterLoad(), CreateDefaultCharacter(), CreateNewCharacter(), and ~IntroSceneCharacter().

◆ CheckBlood()

void Managed::CheckBlood ( )
inlineprotected

Definition at line 132 of file TransferValues.c.

133 {
134 float blood_current = m_Player.GetHealth("", "Blood");
135 //float blood_normalized = blood_current / m_BloodMaxValue;
140
141 if (diff_abs > (SENSITIVTY_PERCENTAGE / 100))
142 {
145 }
146 }
const int BLOOD_THRESHOLD_LOW
float m_BloodMaxValue
float m_LastBloodUpdate
const float SENSITIVTY_PERCENTAGE
void SendValue(int value_type, float value)
PlayerBase m_Player
const int TYPE_BLOOD
Definition EnMath.c:7
static proto float Clamp(float value, float min, float max)
Clamps 'value' to 'min' if it is lower than 'min', or to 'max' if it is higher than 'max'.
static proto float InverseLerp(float a, float b, float value)
Calculates the linear value that produces the interpolant value within the range [a,...
static proto float AbsFloat(float f)
Returns absolute value.

References Math::AbsFloat(), Math::Clamp(), Math::InverseLerp(), m_LastBloodUpdate, m_Player, SendValue(), and SENSITIVTY_PERCENTAGE.

Referenced by CheckValues().

◆ CheckHealth()

void Managed::CheckHealth ( )
inlineprotected

◆ CheckValues()

void Managed::CheckValues ( )
inlineprotected

Definition at line 77 of file TransferValues.c.

78 {
80 CheckBlood();
81 }
void CheckHealth()
void CheckBlood()

References CheckBlood(), and CheckHealth().

Referenced by OnScheduledTick().

◆ Cleanup()

static void Managed::Cleanup ( )
inlinestaticprivate

Definition at line 57 of file PPERequesterBank.c.

58 {
59 if (m_Initialized)
60 {
61 delete m_Registrations;
62 m_Instances.Clear();
63 }
64 }
static ref PPERequesterRegistrations m_Registrations
static ref map< int, ref PPERequesterBase > m_Instances

References m_Initialized, m_Instances, and m_Registrations.

◆ ClearSuspendRequests()

void Managed::ClearSuspendRequests ( )
inlineprivate

Definition at line 15 of file GameplayEffectWidgets_base.c.

15{}

◆ CreateDefaultCharacter()

void Managed::CreateDefaultCharacter ( )
inlineprotected

Definition at line 205 of file IntroSceneCharacter.c.

206 {
208 //m_CharacterDta.RequestGetDefaultCharacterData();
209 m_CharacterType = GetGame().GetMenuDefaultCharacterData().GetCharacterType();
210 if (m_CharacterType != "")
212
213 if (m_CharacterObj)
214 {
215 m_CharacterObj.PlaceOnSurface();
216 m_CharacterObj.SetPosition(m_CharacterPos);
217 m_CharacterObj.SetOrientation(m_CharacterRot);
218 }
219 else
220 {
223 //m_CharacterDta.SetCharacterName(GameConstants.DEFAULT_CHARACTER_MENU_ID, default_name);
224 GetGame().GetMenuDefaultCharacterData().SetCharacterName(GameConstants.DEFAULT_CHARACTER_NAME);
225 }
226 }
string m_CharacterType
void CreateNewCharacter()
void CreateNewCharacterRandom()
vector m_CharacterPos
vector m_CharacterRot
proto native CGame GetGame()
const string DEFAULT_CHARACTER_NAME
Definition constants.c:838

References CharacterUnload(), CreateNewCharacter(), CreateNewCharacterRandom(), GameConstants::DEFAULT_CHARACTER_NAME, and GetGame().

Referenced by CreateNewCharacterById().

◆ CreateNewCharacter()

void Managed::CreateNewCharacter ( )
inlineprotected

Definition at line 237 of file IntroSceneCharacter.c.

238 {
239 // Unload old character (if exist)
241
242 // Create Character
244
245 if (m_CharacterObj)
246 {
247 m_CharacterObj.PlaceOnSurface();
248 m_CharacterObj.SetOrientation(m_CharacterRot);
249 GetGame().GetMenuDefaultCharacterData().EquipDefaultCharacter(m_CharacterObj);
250 }
251
252 //Create New Random Character
253 SetupPlayerName(true);
254 }
const int ECE_PLACE_ON_SURFACE
void SetupPlayerName(bool new_name)

References CharacterUnload(), ECE_PLACE_ON_SURFACE, g_Game, GetGame(), and SetupPlayerName().

Referenced by CreateDefaultCharacter(), and CreateNewCharacterByName().

◆ CreateNewCharacterById()

void Managed::CreateNewCharacterById ( int character_id)
inlineprotected

Definition at line 184 of file IntroSceneCharacter.c.

185 {
188 else
190 }
void CreateDefaultCharacter()
void CharacterLoad(int character_id, vector char_pos, vector char_rot)
const int DEFAULT_CHARACTER_MENU_ID
Definition constants.c:840

References CharacterLoad(), CreateDefaultCharacter(), and GameConstants::DEFAULT_CHARACTER_MENU_ID.

Referenced by LoadCharacterData().

◆ CreateNewCharacterByName()

void Managed::CreateNewCharacterByName ( string character_name,
bool randomize_equip = true )
inlineprotected

Definition at line 195 of file IntroSceneCharacter.c.

196 {
198 GetGame().GetMenuDefaultCharacterData().SetCharacterType(m_CharacterType);
199 if (randomize_equip)
200 GetGame().GetMenuDefaultCharacterData().GenerateRandomEquip();
201
203 }

References CreateNewCharacter(), and GetGame().

Referenced by CreateNewCharacterRandom().

◆ CreateNewCharacterRandom()

void Managed::CreateNewCharacterRandom ( )
inlineprotected

Definition at line 169 of file IntroSceneCharacter.c.

170 {
171 // Select random gender
173
174 // Select random character skin (class name)
175 string char_name_random = m_Characters[GetCharacterGender()].GetRandomElement();
176
177 // Create new character
179 }
void SetCharacterGender(ECharGender gender)
ref map< ECharGender, ref array< string > > m_Characters
void CreateNewCharacterByName(string character_name, bool randomize_equip=true)
ECharGender GetCharacterGender()
static proto int RandomInt(int min, int max)
Returns a random int number between and min [inclusive] and max [exclusive].

References CreateNewCharacterByName(), GetCharacterGender(), Math::RandomInt(), and SetCharacterGender().

Referenced by CreateDefaultCharacter().

◆ DataInitialized()

bool Managed::DataInitialized ( )
inlineprotected

Definition at line 55 of file GEWidgetsMetaData.c.

56 {
57 return true;
58 }

◆ ForceStop()

void Managed::ForceStop ( )
protected

◆ GameplayEffectsData()

void Managed::GameplayEffectsData ( array< ref Widget > input,
int type,
int user_override = -1 )
inlineprotected

Definition at line 13 of file GEWidgetsMetaData.c.

14 {
16 m_Type = type;
18
19 if (user_override != -1)
21 }
int m_WidgetSetIdentifier
ref array< ref Widget > m_WidgetArray

References m_Type.

◆ GetBlood()

float Managed::GetBlood ( )
inlineprotected

Definition at line 83 of file TransferValues.c.

84 {
85 return m_BloodClient;
86
87 }
float m_BloodClient

References m_BloodClient.

◆ GetCharacterGender()

ECharGender Managed::GetCharacterGender ( )
inlineprotected

Definition at line 121 of file IntroSceneCharacter.c.

122 {
123 return m_CharGender;
124 }
ECharGender m_CharGender

References m_CharGender.

Referenced by CreateNewCharacterRandom().

◆ GetCharacterID()

int Managed::GetCharacterID ( )
inlineprotected

Definition at line 49 of file IntroSceneCharacter.c.

50 {
51 return m_CharacterId;
52 }

References m_CharacterId.

◆ GetCharacterName()

string Managed::GetCharacterName ( )
inlineprotected

Definition at line 408 of file IntroSceneCharacter.c.

409 {
410 string character_name;
411 if (IsDefaultCharacter())
412 character_name = GetGame().GetMenuDefaultCharacterData().GetCharacterName();
413 else
415 return character_name;
416 }
bool IsDefaultCharacter()
proto void GetCharacterName(int index, out string name)

References MenuData::GetCharacterName(), GetGame(), and IsDefaultCharacter().

◆ GetCharacterNameById()

string Managed::GetCharacterNameById ( int char_id)
inlineprotected

Definition at line 398 of file IntroSceneCharacter.c.

399 {
400 string character_name;
402 character_name = GetGame().GetMenuDefaultCharacterData().GetCharacterName();
403 else
405 return character_name;
406 }

References GameConstants::DEFAULT_CHARACTER_MENU_ID, MenuData::GetCharacterName(), and GetGame().

◆ GetCharacterObj()

PlayerBase Managed::GetCharacterObj ( )
inlineprotected

Definition at line 57 of file IntroSceneCharacter.c.

58 {
59 return m_CharacterObj;
60 }

References m_CharacterObj.

Referenced by LoadCharacterData(), and DayZIntroScene::ResetIntroCamera().

◆ GetCharGenderList()

TStringArray Managed::GetCharGenderList ( )
inlineprotected

Definition at line 65 of file IntroSceneCharacter.c.

66 {
67 return m_CharGenderList;
68 }
ref TStringArray m_CharGenderList

References m_CharGenderList.

◆ GetCharList()

TStringArray Managed::GetCharList ( ECharGender gender)
inlineprotected

Definition at line 73 of file IntroSceneCharacter.c.

74 {
75 return m_Characters[gender];
76 }

◆ GetCharPantsList()

TStringArray Managed::GetCharPantsList ( )
inlineprotected

Definition at line 89 of file IntroSceneCharacter.c.

90 {
91 return m_CharPantsList;
92 }
ref TStringArray m_CharPantsList

References m_CharPantsList.

◆ GetCharShirtsList()

TStringArray Managed::GetCharShirtsList ( )
inlineprotected

Definition at line 81 of file IntroSceneCharacter.c.

82 {
83 return m_CharShirtList;
84 }
ref TStringArray m_CharShirtList

References m_CharShirtList.

◆ GetCharShoesList()

TStringArray Managed::GetCharShoesList ( )
inlineprotected

Definition at line 97 of file IntroSceneCharacter.c.

98 {
99 return m_CharShoesList;
100 }
ref TStringArray m_CharShoesList

References m_CharShoesList.

◆ GetEndNow()

bool Managed::GetEndNow ( )
inlineprotected

Definition at line 236 of file BleedingIndicator.c.

237 {
238 return m_EndNow;
239 }

References m_EndNow.

◆ GetHealth()

float Managed::GetHealth ( )
inlineprotected

Definition at line 89 of file TransferValues.c.

90 {
91 return m_HealthClient;
92 }
float m_HealthClient

References m_HealthClient.

◆ GetLastPlayedServer()

void Managed::GetLastPlayedServer ( int characterID,
out string address,
out string name,
out int port )
inlineprotected

Definition at line 228 of file IntroSceneCharacter.c.

229 {
233 }
PlayerSpawnPresetDiscreteItemSetSlotData name
one set for cargo
proto native int GetLastServerPort(int index)
proto void GetLastServerAddress(int index, out string address)
proto void GetLastServerName(int index, out string address)

References MenuData::GetLastServerAddress(), MenuData::GetLastServerName(), MenuData::GetLastServerPort(), and name.

◆ GetNextCharacterID()

int Managed::GetNextCharacterID ( )
inlineprotected

Definition at line 137 of file IntroSceneCharacter.c.

138 {
140
141 if (count == 0)
142 return -1;
143
144 if (m_CharacterId + 1 < count)
145 return m_CharacterId + 1;
146 else
147 return -1;
148 }
proto native int GetCharactersCount()

References MenuData::GetCharactersCount().

◆ GetPosition()

vector Managed::GetPosition ( )
inlineprotected

Definition at line 129 of file IntroSceneCharacter.c.

130 {
131 return m_CharacterObj.GetPosition();
132 }

Referenced by DayZIntroScene::ResetIntroCamera().

◆ GetPrevCharacterID()

int Managed::GetPrevCharacterID ( )
inlineprotected

Definition at line 153 of file IntroSceneCharacter.c.

154 {
156
157 if (count == 0)
158 return -1;
159
160 if (m_CharacterId > -1)
161 return m_CharacterId - 1;
162
163 return count - 1;
164 }

References MenuData::GetCharactersCount().

◆ GetRequester() [1/2]

static PPERequesterBase Managed::GetRequester ( int index)
inlinestaticprivate

Returns an instance (singleton) of a requester based on index.

Parameters
indexint Index of the registered requester.
Returns
PPERequesterBase Requester singleton.
Note
Returns only already registered instances, does not register anything.

Definition at line 103 of file PPERequesterBank.c.

104 {
106
107 if (!ret)
108 Debug.Log("Requester idx '" + index + "' not found in bank! Register first in 'RegisterRequester' method.");
109 return ret;
110 }

References Debug::Log(), and m_Instances.

◆ GetRequester() [2/2]

static PPERequesterBase Managed::GetRequester ( typename type )
inlinestaticprivate

Returns an instance (singleton) of a requester based on typename.

Parameters
typetypename Typename of the requester.
Returns
PPERequesterBase Requester singleton.
Note
Returns only already registered instances, does not register anything.

Definition at line 72 of file PPERequesterBank.c.

73 {
74 if (!type)
75 {
76 Error("Requested type is NULL!");
77 return null;
78 }
79
82 for (int i = 0; i < m_Instances.Count(); i++)
83 {
84 temp = m_Instances.GetElement(i);
85 if (temp.Type() == type)
86 {
88 break;
89 }
90 }
91
92 if (!ret)
93 Debug.Log("'" + type.ToString() + "' not found in bank! Register first in 'RegisterRequester' method.");
94 return ret;
95 }
Super root of all classes in Enforce script.
Definition EnScript.c:11
static proto bool CastTo(out Class to, Class from)
Try to safely down-cast base class to child class.

References Class::CastTo(), Error(), Debug::Log(), and m_Instances.

◆ GetRequesterID()

static int Managed::GetRequesterID ( typename type )
inlinestaticprivate

Returns an ID of a requester type.

Parameters
typetypename Typename of the requester.
Returns
int Requester ID.
Note
Returns '-1' if not found.

Definition at line 118 of file PPERequesterBank.c.

119 {
120 int ret = -1;
122
123 for (int i = 0; i < m_Instances.Count(); i++)
124 {
125 temp = m_Instances.GetElement(i);
126 if (temp.Type() == type)
127 ret = m_Instances.GetKey(i);
128 }
129
130 if (ret == -1)
131 Debug.Log("Requester instance of the '" + type.ToString() + "' type not found in bank! Register first in 'RegisterRequester' method.");
132 return ret;
133 }

References Debug::Log(), and m_Instances.

◆ GetRequesterTypename()

static Managed::GetRequesterTypename ( int index)
inlinestaticprivate

Returns a typename from a requester ID.

Parameters
indexint ID of the requester.
Returns
typename Requester typename.

Definition at line 140 of file PPERequesterBank.c.

141 {
142 typename ret;
144 if (!temp)
145 Debug.Log("No requester exists under idx '" + index + "' in bank! Register first in 'RegisterRequester' method.");
146 else
147 ret = temp.Type();
148
149 return ret;
150 }

References Debug::Log(), and m_Instances.

◆ GetSeverity()

int Managed::GetSeverity ( )
inlineprotected

Definition at line 241 of file BleedingIndicator.c.

242 {
243 return m_Severity;
244 }

References m_Severity.

◆ GetSuspendRequestCount()

int Managed::GetSuspendRequestCount ( )
inlineprivate

Definition at line 16 of file GameplayEffectWidgets_base.c.

16{}

◆ GetWidgetSet()

array< ref Widget > Managed::GetWidgetSet ( )
inlineprotected

Definition at line 34 of file GEWidgetsMetaData.c.

35 {
36 return m_WidgetArray;
37 }

◆ GetWidgetSetID()

int Managed::GetWidgetSetID ( )
inlineprotected

Definition at line 44 of file GEWidgetsMetaData.c.

45 {
47 }

◆ GetWidgetSetType()

int Managed::GetWidgetSetType ( )
inlineprotected

Definition at line 39 of file GEWidgetsMetaData.c.

40 {
41 return m_Type;
42 }

References m_Type.

◆ HasDefinedHandle()

bool Managed::HasDefinedHandle ( )
inlineprotected

Returns 'true' if this class contains update info.

Definition at line 50 of file GEWidgetsMetaData.c.

51 {
52 return false;
53 }

◆ IncreaseMaskUpdateCount()

void Managed::IncreaseMaskUpdateCount ( )
inlineprivate

Definition at line 5 of file GameplayEffectWidgets_base.c.

◆ Init() [1/3]

static void Managed::Init ( )
inlinestaticprivate

Definition at line 47 of file PPERequesterBank.c.

48 {
50
51 if (!m_Instances)
53
54 m_Initialized = true;
55 }
class PPERequesterBank extends Managed PPERequesterRegistrations()
Mod this, if you wish to register custom requesters.

References m_Initialized, m_Instances, m_Registrations, and PPERequesterRegistrations().

Referenced by TransferValues().

◆ Init() [2/3]

void Managed::Init ( )
inlineprotected

Definition at line 34 of file TransferValues.c.

35 {
38 m_HealthMaxValue = m_Player.GetMaxHealth("", "Health");
39 m_BloodMaxValue = m_Player.GetMaxHealth("", "Blood");
40 m_BloodClient = 0;
42 }

References m_HealthMaxValue, m_LastHealthUpdate, and m_Player.

◆ Init() [3/3]

void Managed::Init ( array< ref Widget > input,
int type,
Widget layout_root,
int user_override = -1 )
inlineprotected

Definition at line 23 of file GEWidgetsMetaData.c.

24 {
26 m_Type = type;
29
30 if (user_override != -1)
32 }
Widget m_LayoutRoot

References m_Type.

◆ InitIndicator()

void Managed::InitIndicator ( vector position)
inlineprotected

Definition at line 91 of file BleedingIndicator.c.

92 {
95 m_Initialized = true;
96 }
void ResetIndicator()
vector m_BasePosition

References m_Initialized, and ResetIndicator().

◆ IntroSceneCharacter()

void Managed::IntroSceneCharacter ( )
inlineprotected

◆ IsAnyEffectRunning()

bool Managed::IsAnyEffectRunning ( )
inlineprivate

Definition at line 8 of file GameplayEffectWidgets_base.c.

8{}

◆ IsCharacterFemale()

bool Managed::IsCharacterFemale ( )
inlineprotected

Definition at line 113 of file IntroSceneCharacter.c.

114 {
115 return (m_CharGender == ECharGender.Female);
116 }
ECharGender
Definition ECharGender.c:2

◆ IsDefaultCharacter()

bool Managed::IsDefaultCharacter ( )
inlineprotected

◆ IsRunningDrops()

bool Managed::IsRunningDrops ( )
inlineprotected

Are any drops currently being animated?

Definition at line 121 of file BleedingIndicator.c.

122 {
123 return m_ActiveDropsCount > 0;
124 }
int m_ActiveDropsCount

Referenced by Update().

◆ LoadCharacterData()

void Managed::LoadCharacterData ( vector char_pos,
vector char_rot,
bool default_char = false )
inlineprotected

Generates random equip for the new IntroSceneCharacter, whatever is defined in 'cfgCharacterCreation'.

Definition at line 276 of file IntroSceneCharacter.c.

277 {
278 m_CharacterDta = g_Game.GetMenuData();
281
283 {
286 }
287
288 // Load all avalible options for character creation; mostly legacy stuff
289 g_Game.ConfigGetTextArray("cfgCharacterCreation" + " gender", m_CharGenderList);
290 g_Game.ConfigGetTextArray("cfgCharacterCreation" + " top", m_CharShirtList);
291 g_Game.ConfigGetTextArray("cfgCharacterCreation" + " bottom", m_CharPantsList);
292 g_Game.ConfigGetTextArray("cfgCharacterCreation" + " shoe", m_CharShoesList);
293
294 // Init character table
295 m_Characters.Clear();
296 m_Characters.Insert(ECharGender.Male, new array<string>);
297 m_Characters.Insert(ECharGender.Female, new array<string>);
298
299 // Sort character by Gender
300 TStringArray characters = GetGame().ListAvailableCharacters();
301 for (int i = 0; i < characters.Count(); i++)
302 {
303 string char_cfg_name = characters.Get(i);
304 if (GetGame().IsKindOf(char_cfg_name, "SurvivorMale_Base"))
306 else
307 m_Characters[ECharGender.Female].Insert(char_cfg_name);
308 }
309
310 CreateNewCharacterById(m_CharacterId/*, m_CharacterPos, m_CharacterRot*/);
311
312 if (GetCharacterObj())
313 {
314 if (GetCharacterObj().IsMale())
316 else
318 }
319 }
PlayerBase GetCharacterObj()
void CreateNewCharacterById(int character_id)
proto native int GetLastPlayedCharacter()

References CreateNewCharacterById(), g_Game, MenuData::GetCharacterName(), GetCharacterObj(), GetGame(), MenuData::GetLastPlayedCharacter(), and SetCharacterGender().

◆ OnRPC()

void Managed::OnRPC ( ParamsReadContext ctx)
inlineprotected

Definition at line 184 of file TransferValues.c.

185 {
187
190
192 }
static ref Param2< int, float > PARAM2_INT_FLOAT
void ReceiveValue(int value_type, float value)

References CachedObjectsParams::PARAM2_INT_FLOAT, and ReceiveValue().

◆ OnScheduledTick()

void Managed::OnScheduledTick ( float deltatime)
inlineprotected

Definition at line 44 of file TransferValues.c.

45 {
46#ifdef DIAG_DEVELOPER
47#ifndef SERVER
48 ShowDebugValues(DiagMenu.GetBool(DiagMenuIDs.TRANSFER_VALUES_SHOW));
49#endif
50#endif
51
52 if (GetGame().IsClient()) return;
53
55
59 {
60 /*
61 Print(m_TimeSinceLastTick.ToString());
62 Print(VALUE_CHECK_INTERVAL.ToString());
63 Print("--------------");
64 */
67
68 // send sync junctures if necessary
69 // TODO: !!!! event is sent too often, please fix it
70 /*
71 float damage = 1 - m_Player.GetHealth("", "") / 100;
72 DayZPlayerSyncJunctures.SendInjury(m_Player, true, damage);
73 */
74 }
75 }
DiagMenuIDs
Definition EDiagMenuIDs.c:2
void ShowDebugValues(bool show)
void CheckValues()
const float VALUE_CHECK_INTERVAL
float m_TimeSinceLastTick
void SendInitValues()
Sends values on object creation.
bool m_InitialSyncSent
static proto bool GetBool(int id, bool reverse=false)
Get value as bool from the given script id.

References CheckValues(), DiagMenu::GetBool(), GetGame(), m_TimeSinceLastTick, SendInitValues(), ShowDebugValues(), and VALUE_CHECK_INTERVAL.

◆ OnVoiceEvent()

void Managed::OnVoiceEvent ( float breathing_resistance01)
inlineprivate

Definition at line 19 of file GameplayEffectWidgets_base.c.

19{}

◆ ReceiveValue()

void Managed::ReceiveValue ( int value_type,
float value )
inlineprotected

Definition at line 176 of file TransferValues.c.

177 {
178 if (value_type == TYPE_HEALTH)
180 else if (value_type == TYPE_BLOOD)
182 }

Referenced by OnRPC().

◆ RegisterData()

void Managed::RegisterData ( Param p)
inlineprotected

Definition at line 61 of file GEWidgetsMetaData.c.

61{}

◆ RegisterGameplayEffectData()

void Managed::RegisterGameplayEffectData ( int id,
Param p )
inlineprivate

Definition at line 22 of file GameplayEffectWidgets_base.c.

22{}

◆ RegisterRequester()

static int Managed::RegisterRequester ( typename type )
inlinestaticprivate

Registers new requester type.

Note
Performed only on game start. New requesters can be registered in 'PPERequesterRegistrations'

Definition at line 156 of file PPERequesterBank.c.

157 {
158 if (!m_Instances)
160
161 if (GetRequester(type) != null)
162 {
163 //Error("Trying to register an already existing requester type: " + type);
164 Debug.Log("Trying to register an already existing requester type: " + type);
165 return -1;
166 }
167
168 m_lastID++;
169
171 req = PPERequesterBase.Cast(type.Spawn());
172 req.SetRequesterIDX(m_lastID);
174
175 return m_lastID;
176 }
PPERUndergroundAcco GetRequester()
static int m_lastID

References GetRequester(), Debug::Log(), m_Instances, and m_lastID.

◆ RemoveActiveEffects()

void Managed::RemoveActiveEffects ( array< int > effects)
inlineprivate

Definition at line 11 of file GameplayEffectWidgets_base.c.

11{}

◆ RemoveSuspendRequest()

void Managed::RemoveSuspendRequest ( int request_id)
inlineprivate

Definition at line 14 of file GameplayEffectWidgets_base.c.

14{}

◆ ResetIndicator()

void Managed::ResetIndicator ( )
inlineprotected

Definition at line 150 of file BleedingIndicator.c.

151 {
152 m_Terminating = false;
153 m_EndNow = false;
159 }
bool m_Terminating
int m_DropSpawnsQueued
float m_LastDropSpawnTime

Referenced by InitIndicator().

◆ ResetMaskUpdateCount()

void Managed::ResetMaskUpdateCount ( )
inlineprivate

Definition at line 6 of file GameplayEffectWidgets_base.c.

◆ ResetSequence()

void Managed::ResetSequence ( )
inlineprotected

Definition at line 143 of file BleedingIndicator.c.

Referenced by Update().

◆ SaveCharName()

void Managed::SaveCharName ( string name)
inlineprotected

Definition at line 421 of file IntroSceneCharacter.c.

422 {
423 if (IsDefaultCharacter())
424 GetGame().GetMenuDefaultCharacterData().SetCharacterName(name);
425 else
428 }
proto native void SaveCharactersLocal()
Saves characters menu data to file.
proto native void SetCharacterName(int index, string newName)

References GetGame(), IsDefaultCharacter(), name, MenuData::SaveCharactersLocal(), and MenuData::SetCharacterName().

◆ SaveDefaultCharacter()

void Managed::SaveDefaultCharacter ( )
inlineprotected

Definition at line 433 of file IntroSceneCharacter.c.

434 {
435 //if (m_CharacterObj)
436 {
438 }
439 }
proto void RequestSetDefaultCharacterData()

References MenuData::RequestSetDefaultCharacterData().

◆ SendInitValues()

void Managed::SendInitValues ( )
inlineprotected

Sends values on object creation.

Definition at line 149 of file TransferValues.c.

150 {
151 m_InitialSyncSent = true;
152
153 //HP
154 float health_current = m_Player.GetHealth("", "Health");
158
159 //Blood
160 float blood_current = m_Player.GetHealth("", "Blood");
163 //Print("DbgBlood | SendInitValues | blood_normalized: " + blood_normalized);
166 }

References Math::Clamp(), Math::InverseLerp(), m_HealthMaxValue, m_LastHealthUpdate, m_Player, and SendValue().

Referenced by OnScheduledTick().

◆ SendValue()

void Managed::SendValue ( int value_type,
float value )
inlineprotected

Definition at line 168 of file TransferValues.c.

169 {
172
173 GetGame().RPCSingleParam(m_Player, ERPCs.RPC_DAMAGE_VALUE_SYNC, CachedObjectsParams.PARAM2_INT_FLOAT, true, m_Player.GetIdentity());
174 }
ERPCs
Definition ERPCs.c:2

References GetGame(), m_Player, and CachedObjectsParams::PARAM2_INT_FLOAT.

Referenced by CheckBlood(), CheckHealth(), and SendInitValues().

◆ SetAttachment()

void Managed::SetAttachment ( string type,
int slot )
inlineprotected

Definition at line 385 of file IntroSceneCharacter.c.

386 {
387 if (!m_CharacterObj)
388 return;
389
390 g_Game.ObjectDelete(m_CharacterObj.GetInventory().FindAttachment(slot));
391
392 EntityAI entity = EntityAI.Cast(g_Game.CreateObjectEx(type, m_CharacterObj.GetPosition(), ECE_PLACE_ON_SURFACE));
393
394 if (entity)
395 m_CharacterObj.LocalTakeEntityAsAttachmentEx(entity, slot);
396 }

References ECE_PLACE_ON_SURFACE, and g_Game.

◆ SetBreathIntensityStamina()

void Managed::SetBreathIntensityStamina ( float stamina_cap,
float stamina_current )
inlineprivate

Definition at line 20 of file GameplayEffectWidgets_base.c.

20{}

◆ SetCharacterGender()

void Managed::SetCharacterGender ( ECharGender gender)
inlineprotected

Definition at line 105 of file IntroSceneCharacter.c.

106 {
108 }

Referenced by CreateNewCharacterRandom(), and LoadCharacterData().

◆ SetCharacterID()

void Managed::SetCharacterID ( int char_id)
inlineprotected

Definition at line 41 of file IntroSceneCharacter.c.

42 {
44 }

Referenced by CharacterLoad().

◆ SetToDefaultCharacter()

void Managed::SetToDefaultCharacter ( )
inlineprotected

◆ SetupPlayerName()

void Managed::SetupPlayerName ( bool new_name)
inlineprotected

Definition at line 362 of file IntroSceneCharacter.c.

363 {
365
366#ifdef PLATFORM_CONSOLE
367 BiosUserManager user_manager = GetGame().GetUserManager();
368 if (user_manager)
369 {
370 BiosUser user = user_manager.GetSelectedUser();
371 if (user)
372 name = user.GetName();
373 }
374#else
375 if (!new_name)
377#endif
378
379 g_Game.SetPlayerGameName(name);
380 }

References GameConstants::DEFAULT_CHARACTER_NAME, g_Game, MenuData::GetCharacterName(), GetGame(), and name.

Referenced by CreateNewCharacter().

◆ ShowDebugValues()

void Managed::ShowDebugValues ( bool show)
inlineprotected

Definition at line 194 of file TransferValues.c.

195 {
196#ifdef DIAG_DEVELOPER
197 if (show)
198 {
200 DbgUI.Begin("Values", 50, 50);
201
202 DbgUI.Text("Blood: " + m_BloodClient.ToString());
203 DbgUI.Text("Health: " + m_HealthClient.ToString());
204
205 DbgUI.End();
207 }
208 else
209 {
211 DbgUI.Begin("Values", 50, 50);
212 DbgUI.End();
214 }
215#endif
216 }
Definition DbgUI.c:60
proto string ToString()
static proto native void End()
static proto native void Begin(string windowTitle, float x=0, float y=0)
static proto native void Text(string label)
static proto void BeginCleanupScope()
static proto native void EndCleanupScope()

References DbgUI::Begin(), DbgUI::BeginCleanupScope(), DbgUI::End(), DbgUI::EndCleanupScope(), DbgUI::Text(), and float::ToString().

Referenced by OnScheduledTick().

◆ StartRunningDrops()

void Managed::StartRunningDrops ( )
inlineprotected

Definition at line 110 of file BleedingIndicator.c.

References m_IsRunning, and TrySpawnNextDrop().

Referenced by Update().

◆ StopAllEffects()

void Managed::StopAllEffects ( )
inlineprivate

Definition at line 12 of file GameplayEffectWidgets_base.c.

12{}

◆ StopIndicator()

void Managed::StopIndicator ( bool instant = false)
inlineprotected

Definition at line 98 of file BleedingIndicator.c.

99 {
100 if (!m_Terminating)
101 {
102 m_IsRunning = false;
103
104 if (instant)
105 m_EndNow = true;
106 m_Terminating = true;
107 }
108 }

References m_IsRunning.

◆ TransferValues()

void Managed::TransferValues ( PlayerBase player)
inlineprotected

Definition at line 27 of file TransferValues.c.

28 {
30 m_InitialSyncSent = false;
31 Init();
32 }
static void Init()

References Init(), and m_Player.

◆ TrySpawnNextDrop()

void Managed::TrySpawnNextDrop ( )
inlineprotected

Definition at line 126 of file BleedingIndicator.c.

127 {
129 if (Class.CastTo(dropImage, m_ParentMetaData.GetNextDropImage()) && !dropImage.IsVisible()) //IsVisible false means the drop is free to be used
130 {
132 data.SetBasePosition(m_BasePosition);
133 data.StartDrop();
134
135 m_ActiveDrops.Insert(data);
137 }
138
141 }

References Class::CastTo(), and m_TimeElapsedTotal.

Referenced by StartRunningDrops(), and Update().

◆ Update() [1/3]

void Managed::Update ( float timeSlice)
inlineprivate

Definition at line 18 of file GameplayEffectWidgets_base.c.

18{}

◆ Update() [2/3]

void Managed::Update ( float timeSlice)
inlineprotected

Definition at line 161 of file BleedingIndicator.c.

162 {
163 if (!m_Initialized)
164 return;
165
166#ifdef DIAG_DEVELOPER
169#endif
171
172 //run drops, if possible
173 if (!m_Terminating)
174 {
175 if (m_IsRunning)
176 {
178 {
180 {
181 float rnd = Math.RandomFloat01();
184
186 }
187 }
188
192 else if (m_DropSpawnsQueued > 0) //spawn queued drop
193 {
196 }
198 {
199 TrySpawnNextDrop(); //guaranteed drop
200 m_CurrentDropProbabilityStep++; //substitutes a regular roll..
201 }
202 }
203 else //1st drop ignores delay
205 }
206
207 for (int i = 0; i < m_ActiveDropsCount; i++)
208 {
209 if (!m_EndNow)
210 {
211 //Simulate drops
212 m_ActiveDrops[i].Update(timeSlice);
213 }
214 else
215 m_ActiveDrops[i].StopDrop();
216
217 if (!m_ActiveDrops[i].IsRunning())
218 m_CleanupQueue.Insert(i);
219 }
220
221 //Cleanup drops
222 for (i = m_CleanupQueue.Count() - 1; i >= 0; i--)
223 {
226 }
227 m_CleanupQueue.Clear();
228
230 m_EndNow = true;
231
234 }
void ResetSequence()
bool IsRunningDrops()
Are any drops currently being animated?
float m_SequenceTick
void StartRunningDrops()
static float RandomFloat01()
Returns a random float number between and min [inclusive] and max [inclusive].
Definition EnMath.c:126
bool IsRunning()
Definition tools.c:252

References IsRunning(), IsRunningDrops(), m_ActiveDropsCount, DbgBleedingIndicationStaticInfo::m_DbgSequenceDuration, DbgBleedingIndicationStaticInfo::m_DbgUseOverrideValues, m_DropProbabilityRollsCount, m_Initialized, m_IsRunning, m_LastDropSpawnTime, Math::RandomFloat01(), ResetSequence(), StartRunningDrops(), and TrySpawnNextDrop().

◆ Update() [3/3]

void Managed::Update ( float timeSlice = 0,
Param p = null,
int handle = -1 )
inlineprotected

Definition at line 62 of file GEWidgetsMetaData.c.

62{}

◆ UpdateVisibility()

void Managed::UpdateVisibility ( bool state)
inlineprotected

Definition at line 60 of file GEWidgetsMetaData.c.

60{}

◆ UpdateWidgets()

void Managed::UpdateWidgets ( int type = -1,
float timeSlice = 0,
Param p = null,
int handle = -1 )
inlineprivate

Definition at line 17 of file GameplayEffectWidgets_base.c.

17{}

◆ VerifyRequester()

static bool Managed::VerifyRequester ( PPERequesterBase req)
inlinestaticprivate

Verifies the instance.

Definition at line 179 of file PPERequesterBank.c.

180 {
181 if (!m_Initialized) //initial registrations are fair game
182 return true;
183
185 for (int i = 0; i < m_Instances.Count(); i++)
186 {
187 temp = m_Instances.GetElement(i);
188 if (temp == req)
189 return true;
190 }
191
192 //Error("Requester instance " + req + " not valid! Please use registered instances from PPERequesterBank.");
193 Debug.Log("Requester instance '" + req + "' not valid! Please use registered instances from PPERequesterBank.");
194 return false;
195 }

References Debug::Log(), m_Initialized, and m_Instances.

Member Data Documentation

◆ BLOOD_THRESHOLD_LOW

const int Managed::BLOOD_THRESHOLD_LOW = 3000
private

Definition at line 9 of file TransferValues.c.

◆ INVALID

const int Managed::INVALID = -1
staticprivate

Definition at line 11 of file PPERequesterBank.c.

◆ m_ActiveDrops

ref set<ref BleedingIndicatorDropData> Managed::m_ActiveDrops
protected

Definition at line 28 of file BleedingIndicator.c.

◆ m_ActiveDropsCount

int Managed::m_ActiveDropsCount
protected

Definition at line 10 of file BleedingIndicator.c.

Referenced by Update().

◆ m_AnimType

int Managed::m_AnimType
private

Definition at line 4 of file SyncHitInfo.c.

◆ m_AverageFrequency

float Managed::m_AverageFrequency
protected

Definition at line 16 of file BleedingIndicator.c.

◆ m_BasePosition

vector Managed::m_BasePosition
protected

Definition at line 26 of file BleedingIndicator.c.

◆ m_BloodClient

float Managed::m_BloodClient
private

Definition at line 22 of file TransferValues.c.

Referenced by GetBlood().

◆ m_BloodMaxValue

float Managed::m_BloodMaxValue
private

Definition at line 20 of file TransferValues.c.

◆ m_CharacterDta

MenuData Managed::m_CharacterDta
protected

Definition at line 5 of file IntroSceneCharacter.c.

◆ m_CharacterId

int Managed::m_CharacterId
protected

Definition at line 3 of file IntroSceneCharacter.c.

Referenced by GetCharacterID().

◆ m_CharacterObj

PlayerBase Managed::m_CharacterObj
protected

Definition at line 6 of file IntroSceneCharacter.c.

Referenced by GetCharacterObj().

◆ m_CharacterPos

vector Managed::m_CharacterPos
protected

Definition at line 7 of file IntroSceneCharacter.c.

◆ m_CharacterRot

vector Managed::m_CharacterRot
protected

Definition at line 8 of file IntroSceneCharacter.c.

◆ m_Characters

ref map<ECharGender, ref array<string> > Managed::m_Characters = new map<ECharGender, ref array<string>>
protected

Definition at line 15 of file IntroSceneCharacter.c.

◆ m_CharacterType

string Managed::m_CharacterType
protected

Definition at line 4 of file IntroSceneCharacter.c.

◆ m_CharGender

ECharGender Managed::m_CharGender
protected

Definition at line 17 of file IntroSceneCharacter.c.

Referenced by GetCharacterGender().

◆ m_CharGenderList

ref TStringArray Managed::m_CharGenderList = new TStringArray
protected

Definition at line 10 of file IntroSceneCharacter.c.

Referenced by GetCharGenderList().

◆ m_CharPantsList

ref TStringArray Managed::m_CharPantsList = new TStringArray
protected

Definition at line 12 of file IntroSceneCharacter.c.

Referenced by GetCharPantsList().

◆ m_CharShirtList

ref TStringArray Managed::m_CharShirtList = new TStringArray
protected

Definition at line 11 of file IntroSceneCharacter.c.

Referenced by GetCharShirtsList().

◆ m_CharShoesList

ref TStringArray Managed::m_CharShoesList = new TStringArray
protected

Definition at line 13 of file IntroSceneCharacter.c.

Referenced by GetCharShoesList().

◆ m_CleanupQueue

ref set<int> Managed::m_CleanupQueue
protected

Definition at line 29 of file BleedingIndicator.c.

◆ m_CurrentDropProbabilityStep

int Managed::m_CurrentDropProbabilityStep
protected

Definition at line 24 of file BleedingIndicator.c.

◆ m_DropProbabilityArray

array<float> Managed::m_DropProbabilityArray
protected

Definition at line 14 of file BleedingIndicator.c.

◆ m_DropProbabilityRollsCount

int Managed::m_DropProbabilityRollsCount
protected

Definition at line 25 of file BleedingIndicator.c.

Referenced by Update().

◆ m_DropSpawnMaxDelay

float Managed::m_DropSpawnMaxDelay
protected

Definition at line 23 of file BleedingIndicator.c.

◆ m_DropSpawnMinDelay

float Managed::m_DropSpawnMinDelay
protected

Definition at line 22 of file BleedingIndicator.c.

◆ m_DropSpawnsQueued

int Managed::m_DropSpawnsQueued
protected

Definition at line 9 of file BleedingIndicator.c.

◆ m_EndNow

bool Managed::m_EndNow = false
protected

Definition at line 7 of file BleedingIndicator.c.

Referenced by GetEndNow().

◆ m_Fullbody

bool Managed::m_Fullbody
private

Definition at line 7 of file SyncHitInfo.c.

◆ m_HasSource

bool Managed::m_HasSource
private

Definition at line 9 of file SyncHitInfo.c.

◆ m_HealthClient

float Managed::m_HealthClient
private

Definition at line 23 of file TransferValues.c.

Referenced by GetHealth().

◆ m_HealthDamage

float Managed::m_HealthDamage
private

Definition at line 6 of file SyncHitInfo.c.

◆ m_HealthMaxValue

float Managed::m_HealthMaxValue
private

Definition at line 19 of file TransferValues.c.

Referenced by CheckHealth(), and SendInitValues().

◆ m_HitDir

float Managed::m_HitDir
private

Definition at line 5 of file SyncHitInfo.c.

◆ m_Initialized [1/2]

bool Managed::m_Initialized = false
staticprivate

Definition at line 7 of file PPERequesterBank.c.

◆ m_Initialized [2/2]

bool Managed::m_Initialized
protected

Definition at line 5 of file BleedingIndicator.c.

◆ m_InitialSyncSent

bool Managed::m_InitialSyncSent
protected

Definition at line 25 of file TransferValues.c.

◆ m_Instances

ref map<int, ref PPERequesterBase> Managed::m_Instances
staticprivate

Definition at line 6 of file PPERequesterBank.c.

◆ m_IsRunning

bool Managed::m_IsRunning = false
protected

Definition at line 8 of file BleedingIndicator.c.

◆ m_LastBloodUpdate

float Managed::m_LastBloodUpdate
private

Definition at line 14 of file TransferValues.c.

Referenced by CheckBlood().

◆ m_LastDropSpawnTime

float Managed::m_LastDropSpawnTime
protected

Definition at line 21 of file BleedingIndicator.c.

Referenced by Update().

◆ m_LastHealthUpdate

float Managed::m_LastHealthUpdate
private

Definition at line 13 of file TransferValues.c.

Referenced by CheckHealth().

◆ m_lastID

int Managed::m_lastID = -1
staticprivate

Definition at line 9 of file PPERequesterBank.c.

◆ m_LayoutRoot

Widget Managed::m_LayoutRoot
protected

Definition at line 11 of file GEWidgetsMetaData.c.

◆ m_MaskWidgetUpdateCount

int Managed::m_MaskWidgetUpdateCount
private

Definition at line 3 of file GameplayEffectWidgets_base.c.

◆ m_ParentMetaData

GameplayEffectsDataBleeding Managed::m_ParentMetaData
protected

Definition at line 13 of file BleedingIndicator.c.

◆ m_Player

PlayerBase Managed::m_Player
private

Definition at line 10 of file TransferValues.c.

◆ m_Registrations

ref PPERequesterRegistrations Managed::m_Registrations
staticprivate

Definition at line 45 of file PPERequesterBank.c.

◆ m_SequenceDuration

float Managed::m_SequenceDuration
protected

Definition at line 18 of file BleedingIndicator.c.

◆ m_SequenceTick

float Managed::m_SequenceTick
protected

Definition at line 17 of file BleedingIndicator.c.

◆ m_Severity

int Managed::m_Severity
protected

Definition at line 11 of file BleedingIndicator.c.

Referenced by GetSeverity().

◆ m_SourceID

int Managed::m_SourceID
protected

Definition at line 12 of file BleedingIndicator.c.

◆ m_Terminating

bool Managed::m_Terminating = false
protected

Definition at line 6 of file BleedingIndicator.c.

◆ m_TimeElapsedSequence

float Managed::m_TimeElapsedSequence
protected

Definition at line 20 of file BleedingIndicator.c.

◆ m_TimeElapsedTotal

float Managed::m_TimeElapsedTotal
protected

Definition at line 19 of file BleedingIndicator.c.

Referenced by TrySpawnNextDrop().

◆ m_TimeSinceLastTick

float Managed::m_TimeSinceLastTick = VALUE_CHECK_INTERVAL + 1
private

Definition at line 11 of file TransferValues.c.

◆ m_Type

int Managed::m_Type
protected

Definition at line 9 of file GEWidgetsMetaData.c.

◆ m_WidgetArray

ref array<ref Widget> Managed::m_WidgetArray
protected

Definition at line 8 of file GEWidgetsMetaData.c.

◆ m_WidgetSetIdentifier

int Managed::m_WidgetSetIdentifier
protected

Definition at line 10 of file GEWidgetsMetaData.c.

◆ REQ_BLOODLOSS

const int Managed::REQ_BLOODLOSS = RegisterRequester(PPERequester_BloodLoss)
staticprivate

Definition at line 25 of file PPERequesterBank.c.

◆ REQ_BURLAPSACK

const int Managed::REQ_BURLAPSACK = RegisterRequester(PPERequester_BurlapSackEffects)
staticprivate

Definition at line 29 of file PPERequesterBank.c.

◆ REQ_CAMERAADS

const int Managed::REQ_CAMERAADS = RegisterRequester(PPERequester_CameraADS)
staticprivate

Definition at line 24 of file PPERequesterBank.c.

◆ REQ_CAMERANV

const int Managed::REQ_CAMERANV = RegisterRequester(PPERequester_CameraNV)
staticprivate

Definition at line 23 of file PPERequesterBank.c.

◆ REQ_CONTAMINATEDAREA

const int Managed::REQ_CONTAMINATEDAREA = RegisterRequester(PPERequester_ContaminatedAreaTint)
staticprivate

Definition at line 39 of file PPERequesterBank.c.

◆ REQ_CONTROLLERBLUR

const int Managed::REQ_CONTROLLERBLUR = RegisterRequester(PPERequester_ControlsBlur)
staticprivate

Definition at line 36 of file PPERequesterBank.c.

◆ REQ_CONTROLLERDISCONNECT

const int Managed::REQ_CONTROLLERDISCONNECT = RegisterRequester(PPERequester_ControllerDisconnectBlur)
staticprivate

Definition at line 13 of file PPERequesterBank.c.

◆ REQ_DEATHEFFECTS

const int Managed::REQ_DEATHEFFECTS = RegisterRequester(PPERequester_DeathDarkening)
staticprivate

Definition at line 26 of file PPERequesterBank.c.

◆ REQ_DROWNING

const int Managed::REQ_DROWNING = RegisterRequester(PPERequester_Drowning)
staticprivate

Definition at line 43 of file PPERequesterBank.c.

◆ REQ_FEVEREFFECTS

const int Managed::REQ_FEVEREFFECTS = RegisterRequester(PPERequester_FeverEffects)
staticprivate

Definition at line 31 of file PPERequesterBank.c.

◆ REQ_FLASHBANGEFFECTS

const int Managed::REQ_FLASHBANGEFFECTS = RegisterRequester(PPERequester_FlashbangEffects)
staticprivate

Definition at line 32 of file PPERequesterBank.c.

◆ REQ_GLASSESAVIATOR

const int Managed::REQ_GLASSESAVIATOR = RegisterRequester(PPERequester_GlassesAviator)
staticprivate

Definition at line 18 of file PPERequesterBank.c.

◆ REQ_GLASSESDESIGNER

const int Managed::REQ_GLASSESDESIGNER = RegisterRequester(PPERequester_GlassesDesignerBlack)
staticprivate

Definition at line 19 of file PPERequesterBank.c.

◆ REQ_GLASSESSPORTBLACK

const int Managed::REQ_GLASSESSPORTBLACK = RegisterRequester(PPERequester_GlassesSportBlack)
staticprivate

Definition at line 14 of file PPERequesterBank.c.

◆ REQ_GLASSESSPORTBLUE

const int Managed::REQ_GLASSESSPORTBLUE = RegisterRequester(PPERequester_GlassesSportBlue)
staticprivate

Definition at line 15 of file PPERequesterBank.c.

◆ REQ_GLASSESSPORTGREEN

const int Managed::REQ_GLASSESSPORTGREEN = RegisterRequester(PPERequester_GlassesSportGreen)
staticprivate

Definition at line 16 of file PPERequesterBank.c.

◆ REQ_GLASSESSPORTORANGE

const int Managed::REQ_GLASSESSPORTORANGE = RegisterRequester(PPERequester_GlassesSportOrange)
staticprivate

Definition at line 17 of file PPERequesterBank.c.

◆ REQ_GLASSESTACTICAL

const int Managed::REQ_GLASSESTACTICAL = RegisterRequester(PPERequester_TacticalGoggles)
staticprivate

Definition at line 20 of file PPERequesterBank.c.

◆ REQ_GLASSESWELDING

const int Managed::REQ_GLASSESWELDING = RegisterRequester(PPERequester_WeldingMask)
staticprivate

Definition at line 22 of file PPERequesterBank.c.

◆ REQ_HEALTHHITEFFECTS

const int Managed::REQ_HEALTHHITEFFECTS = RegisterRequester(PPERequester_HealthHitReaction)
staticprivate

Definition at line 34 of file PPERequesterBank.c.

◆ REQ_INTROCHROMABB

const int Managed::REQ_INTROCHROMABB = RegisterRequester(PPERequester_IntroChromAbb)
staticprivate

Definition at line 30 of file PPERequesterBank.c.

◆ REQ_INVENTORYBLUR

const int Managed::REQ_INVENTORYBLUR = RegisterRequester(PPERequester_InventoryBlur)
staticprivate

Definition at line 12 of file PPERequesterBank.c.

◆ REQ_MENUEFFECTS

const int Managed::REQ_MENUEFFECTS = RegisterRequester(PPERequester_MenuEffects)
staticprivate

Definition at line 35 of file PPERequesterBank.c.

◆ REQ_MOTOHELMETBLACK

const int Managed::REQ_MOTOHELMETBLACK = RegisterRequester(PPERequester_MotoHelmetBlack)
staticprivate

Definition at line 21 of file PPERequesterBank.c.

◆ REQ_PAINBLUR

const int Managed::REQ_PAINBLUR = RegisterRequester(PPERequester_PainBlur)
staticprivate

Definition at line 41 of file PPERequesterBank.c.

◆ REQ_SERVERBROWSEREFFECTS

const int Managed::REQ_SERVERBROWSEREFFECTS = RegisterRequester(PPERequester_ServerBrowserBlur)
staticprivate

Definition at line 37 of file PPERequesterBank.c.

◆ REQ_SHOCKHITEFFECTS

const int Managed::REQ_SHOCKHITEFFECTS = RegisterRequester(PPERequester_ShockHitReaction)
staticprivate

Definition at line 33 of file PPERequesterBank.c.

◆ REQ_SPOOKYAREA

const int Managed::REQ_SPOOKYAREA = RegisterRequester(PPERequester_SpookyAreaTint)
staticprivate

Definition at line 40 of file PPERequesterBank.c.

◆ REQ_TUNELVISSION

const int Managed::REQ_TUNELVISSION = RegisterRequester(PPERequester_TunnelVisionEffects)
staticprivate

Definition at line 28 of file PPERequesterBank.c.

◆ REQ_TUTORIALEFFECTS

const int Managed::REQ_TUTORIALEFFECTS = RegisterRequester(PPERequester_TutorialMenu)
staticprivate

Definition at line 38 of file PPERequesterBank.c.

◆ REQ_UNCONEFFECTS

const int Managed::REQ_UNCONEFFECTS = RegisterRequester(PPERequester_UnconEffects)
staticprivate

Definition at line 27 of file PPERequesterBank.c.

◆ REQ_UNDERGROUND

const int Managed::REQ_UNDERGROUND = RegisterRequester(PPERUndergroundAcco)
staticprivate

Definition at line 42 of file PPERequesterBank.c.

◆ SENSITIVTY_PERCENTAGE

const float Managed::SENSITIVTY_PERCENTAGE = 1
private

Definition at line 7 of file TransferValues.c.

◆ TYPE_BLOOD

const int Managed::TYPE_BLOOD = 2
private

Definition at line 4 of file TransferValues.c.

◆ TYPE_HEALTH

const int Managed::TYPE_HEALTH = 1
private

Definition at line 3 of file TransferValues.c.

◆ VALUE_CHECK_INTERVAL

const float Managed::VALUE_CHECK_INTERVAL = 5
private

Definition at line 6 of file TransferValues.c.


The documentation for this class was generated from the following files: