Dayz 1.25
Dayz Code Explorer by KGB
Загрузка...
Поиск...
Не найдено
Файл EnConvert.c

См. исходные тексты.

Структуры данных

class  bool
 
class  func
 
class  float
 
class  vector
 
class  typename
 
class  EnumTools
 

Перечисления

enum  EBool { NO = 0 , YES = 1 }
 

Функции

proto string ToString ()
 
proto string AsciiToString ()
 Converts ASCII code to string.
 
string ToStringLen (int len)
 Integer to string with fixed length, padded with zeroes.
 
bool InRange (int min, int max, bool inclusive_min=true, bool inclusive_max=true)
 Check whether integer falls into an inclusive range.
 

Переменные

enum EBool ZERO_PAD_SIZE = 8
 
static string m_ZeroPad [ZERO_PAD_SIZE] = {"", "0", "00", "000", "0000", "00000", "000000", "0000000"}
 
const int MAX = 2147483647
 
const int MIN = -2147483648
 

Перечисления

◆ EBool

Элементы перечислений
NO 
YES 
17{
18 NO = 0,
19 YES = 1
20}
@ NO
Definition EnConvert.c:18
@ YES
Definition EnConvert.c:19

Функции

◆ AsciiToString()

proto string AsciiToString ( )
protected

Converts ASCII code to string.

Аргументы
asciiASCII code for convert to string.
Возвращает
string - Converted int.
int ascii_code = 77;
string str = ascii_code.AsciiToString();
>> str = 'M'
Definition EntityAI.c:95
proto void Print(void var)
Prints content of variable to console/log.

◆ InRange()

bool InRange ( int min,
int max,
bool inclusive_min = true,
bool inclusive_max = true )
protected

Check whether integer falls into an inclusive range.

Аргументы
minint low end of range
maxint high end of range
Возвращает
bool True if this value is withing the set range
int num = 123;
bool test = num.InRange( 100, 150 );
>> s = true
85 {
86 if( ( !inclusive_min && value <= min ) || value < min )
87 return false;
88
89 if( ( !inclusive_max && value >= max ) || value > max )
90 return false;
91
92 return true;
93 }

◆ ToString()

proto string ToString ( )
protected

Используется в HFSMBase< Class FSMStateBase, Class FSMEventBase, Class FSMActionBase, Class FSMGuardBase >::Abort(), RecipeBase::ApplyModificationsResults(), EmoteConstructor::ConstructEmotes(), AnimatedActionBase::Do(), AnimatedActionBase::End(), HFSMBase< Class FSMStateBase, Class FSMEventBase, Class FSMActionBase, Class FSMGuardBase >::FindAbortDestinationState(), ForceSwapEntities(), ScriptedWidgetEventHandler::GenerateQuickBarBackgroundTiles(), UnconsciousnessMdfr::GetDebugText(), CharcoalMdfr::GetDebugTextSimple(), KeysToUIElements::GetKeyToUIElement(), LogTemplates::GetTemplate(), HandleForceSwapEntities(), HandleHandEvent(), HandleSwapEntities(), HandleTakeToDst(), ActionInput::Init(), ActionBaseCB::Interrupt(), MissionBase::InvokeOnConnect(), MissionBase::InvokeOnDisconnect(), Component::LogErrorBadCompType(), BotStateBase::OnAbort(), HandStateBase::OnAbort(), Entity::OnAction(), OnActionEnd(), ScriptConsoleGeneralTab::OnClick(), ManBase::OnConnect(), ManBase::OnDisconnect(), BotStateBase::OnEntry(), HandStateBase::OnEntry(), OnErrorThrown(), BotStateBase::OnExit(), ActionBaseCB::OnFinish(), SymptomBase::OnGetActivatedClient(), SymptomBase::OnGetActivatedServer(), SymptomBase::OnGetDeactivatedClient(), SymptomBase::OnGetDeactivatedServer(), ScriptConsoleGeneralTab::OnItemSelected(), UIPopupScript::OnOpen(), Icon::OnPerformRecipe(), ManBase::OnReconnect(), UIPopupScript::OnUpdate(), HFSMBase< Class FSMStateBase, Class FSMEventBase, Class FSMActionBase, Class FSMGuardBase >::ProcessAbortEvent(), HFSMBase< WeaponStateBase, WeaponEventBase, WeaponActionBase, WeaponGuardBase >::ProcessAbortEvent(), HFSMBase< Class FSMStateBase, Class FSMEventBase, Class FSMActionBase, Class FSMGuardBase >::ProcessEvent(), HFSMBase< WeaponStateBase, WeaponEventBase, WeaponActionBase, WeaponGuardBase >::ProcessEvent(), KeysToUIElements::RegisterKeyToUIElement(), LogTemplates::RegisterLogTamplate(), ScriptedWidgetEventHandler::Remove(), SVNBlamePlugin::Run(), ManBase::Save(), ActionInput::SetInput(), ScriptedWidgetEventHandler::SetInterpTime(), SlotsIcon::SetItemSize(), DebugMonitor::SetPosition(), SetTextSmart(), ScriptedWidgetEventHandler::SetTimeBefore(), ScriptedWidgetEventHandler::Show(), RecipeBase::SpawnItems(), OFSMBase< Class FSMStateBase, Class FSMEventBase, Class FSMActionBase, Class FSMGuardBase >::Start(), FSMBase< Class FSMStateBase, Class FSMEventBase, Class FSMActionBase, Class FSMGuardBase >::Start(), HFSMBase< Class FSMStateBase, Class FSMEventBase, Class FSMActionBase, Class FSMGuardBase >::Start(), StoreInputForRemotes(), SwapEntities(), TakeToDst(), HFSMBase< Class FSMStateBase, Class FSMEventBase, Class FSMActionBase, Class FSMGuardBase >::Terminate(), ComponentEnergyManager::UnplugCordFromSocket(), ScriptConsoleGeneralTab::Update(), ServerBrowserTab::UpdatePageButtons(), ComponentEnergyManager::UpdateSelections(), ComponentEnergyManager::UpdateSocketSelections(), ValidateDestroy(), ValidateSwap() и ValidateSyncMove().

◆ ToStringLen()

string ToStringLen ( int len)
protected

Integer to string with fixed length, padded with zeroes.

Аргументы
numint integer to convert
lenint fixed length
Возвращает
vector Converted s as vector
int num = 123;
string s = num.ToStringLen(5);
>> s = '00123'
60 {
61 string str = value.ToString();
62
63 int l = len - str.Length();
64
65 if (l > 0 && l < ZERO_PAD_SIZE )
66 return m_ZeroPad[l] + str;
67
68 return str;
69 }
enum EBool ZERO_PAD_SIZE
static string m_ZeroPad[ZERO_PAD_SIZE]
Definition EnConvert.c:25

Перекрестные ссылки string::Length(), m_ZeroPad, string::ToString() и ZERO_PAD_SIZE.

Используется в ItemBase::GetSlotPosition(), ItemBase::RemoveSlot(), ItemBase::SetSlotTextureDigged(), ItemBase::SetSlotTextureFertilized(), ItemBase::UpdatePlant() и ItemBase::UpdateSlotTexture().

Переменные

◆ m_ZeroPad

string m_ZeroPad[ZERO_PAD_SIZE] = {"", "0", "00", "000", "0000", "00000", "000000", "0000000"}
staticprotected
25{"", "0", "00", "000", "0000", "00000", "000000", "0000000"};

Используется в ToStringLen().

◆ MAX

◆ MIN

◆ ZERO_PAD_SIZE

enum EBool ZERO_PAD_SIZE = 8

Используется в ToStringLen().