Dayz Build 1.29.163047, Scripts Rev. 123548
Dayz Code Explorer by Zeroy
Loading...
Searching...
No Matches
quickbarbase.c File Reference

Go to the source code of this file.

Data Structures

class  QuickBarItem

Functions

void ~QuickBarBase ()
void _RemoveEntity (int index)
void _SetEntity (EntityAI entity, int index, bool force=false)
void _SetEntityShortcut (EntityAI entity, int index, bool force=false)
bool CanAddAsShortcut (EntityAI entity)
void CancelContinuousUse (int index)
int FindEntityIndex (EntityAI entity)
EntityAI GetEntity (int index)
int GetNonEmptyCount ()
int GetSize ()
bool OnInputUserDataProcess (int userDataType, ParamsReadContext ctx)
void OnSetEntityNoSync (EntityAI entity, int index, bool force=false)
void OnSetEntityRequest (ParamsReadContext ctx)
 Reaction on SetEntityShortcut from client.
void OnSetEntityRPC (ParamsReadContext ctx)
 Reaction on Rpc from server for set inicial state for quickbar.
void QuickBarBase (PlayerBase player)
void SetEntityShortcut (EntityAI entity, int index, bool force=false)
void SetShotcutEnable (int index, bool value)
void SetSize (int newSize)
void UpdateShotcutVisibility (int index)
void updateSlotsCount ()

Variables

PlayerBase _player
class QuickBarItem m_aQuickbarEnts [MAX_QUICKBAR_SLOTS_COUNT]
int m_slotsCount
const int MAX_QUICKBAR_SLOTS_COUNT = 10

Function Documentation

◆ ~QuickBarBase()

void ~QuickBarBase ( )
protected

Definition at line 276 of file quickbarbase.c.

◆ _RemoveEntity()

void _RemoveEntity ( int index)
protected

Definition at line 242 of file quickbarbase.c.

References _player, CancelContinuousUse(), m_aQuickbarEnts, and MAX_QUICKBAR_SLOTS_COUNT.

Referenced by _SetEntityShortcut().

◆ _SetEntity()

void _SetEntity ( EntityAI entity,
int index,
bool force = false )
protected

◆ _SetEntityShortcut()

void _SetEntityShortcut ( EntityAI entity,
int index,
bool force = false )
protected

◆ CanAddAsShortcut()

bool CanAddAsShortcut ( EntityAI entity)
protected

Definition at line 137 of file quickbarbase.c.

References _player, and InventoryLocation::GetParent().

Referenced by _SetEntity(), SetShotcutEnable(), and UpdateShotcutVisibility().

◆ CancelContinuousUse()

void CancelContinuousUse ( int index)
protected

◆ FindEntityIndex()

int FindEntityIndex ( EntityAI entity)
protected

Definition at line 95 of file quickbarbase.c.

References m_aQuickbarEnts, and MAX_QUICKBAR_SLOTS_COUNT.

Referenced by _SetEntityShortcut().

◆ GetEntity()

EntityAI GetEntity ( int index)
protected

Definition at line 78 of file quickbarbase.c.

References m_aQuickbarEnts, and m_slotsCount.

◆ GetNonEmptyCount()

int GetNonEmptyCount ( )
protected

Definition at line 66 of file quickbarbase.c.

References m_aQuickbarEnts, and m_slotsCount.

◆ GetSize()

int GetSize ( )
protected

Definition at line 90 of file quickbarbase.c.

References m_slotsCount.

◆ OnInputUserDataProcess()

bool OnInputUserDataProcess ( int userDataType,
ParamsReadContext ctx )
protected

Definition at line 106 of file quickbarbase.c.

References INPUT_UDT_QUICKABARSHORTCUT, and OnSetEntityRequest().

◆ OnSetEntityNoSync()

void OnSetEntityNoSync ( EntityAI entity,
int index,
bool force = false )
protected

Definition at line 175 of file quickbarbase.c.

References _SetEntityShortcut().

◆ OnSetEntityRequest()

void OnSetEntityRequest ( ParamsReadContext ctx)
protected

Reaction on SetEntityShortcut from client.

Definition at line 192 of file quickbarbase.c.

References _SetEntityShortcut(), and Serializer::Read().

Referenced by OnInputUserDataProcess().

◆ OnSetEntityRPC()

void OnSetEntityRPC ( ParamsReadContext ctx)
protected

Reaction on Rpc from server for set inicial state for quickbar.

Definition at line 181 of file quickbarbase.c.

References _SetEntityShortcut(), and Serializer::Read().

◆ QuickBarBase()

void QuickBarBase ( PlayerBase player)
protected

Definition at line 21 of file quickbarbase.c.

References _player, m_aQuickbarEnts, m_slotsCount, and MAX_QUICKBAR_SLOTS_COUNT.

Referenced by ManBase::Init().

◆ SetEntityShortcut()

◆ SetShotcutEnable()

void SetShotcutEnable ( int index,
bool value )
protected

Definition at line 127 of file quickbarbase.c.

References _player, CanAddAsShortcut(), CancelContinuousUse(), and m_aQuickbarEnts.

◆ SetSize()

void SetSize ( int newSize)
protected

Definition at line 34 of file quickbarbase.c.

References _player, m_aQuickbarEnts, m_slotsCount, and MAX_QUICKBAR_SLOTS_COUNT.

◆ UpdateShotcutVisibility()

void UpdateShotcutVisibility ( int index)
protected

Definition at line 117 of file quickbarbase.c.

References _player, CanAddAsShortcut(), CancelContinuousUse(), and m_aQuickbarEnts.

◆ updateSlotsCount()

void updateSlotsCount ( )
protected

Definition at line 228 of file quickbarbase.c.

References _player, Math::Min(), and SetSize().

Variable Documentation

◆ _player

◆ m_aQuickbarEnts

◆ m_slotsCount

int m_slotsCount
protected

Definition at line 19 of file quickbarbase.c.

Referenced by GetEntity(), GetNonEmptyCount(), GetSize(), QuickBarBase(), and SetSize().

◆ MAX_QUICKBAR_SLOTS_COUNT

const int MAX_QUICKBAR_SLOTS_COUNT = 10

Definition at line 1 of file quickbarbase.c.

Referenced by _RemoveEntity(), _SetEntity(), FindEntityIndex(), QuickBarBase(), and SetSize().