DayZ 1.24
Loading...
Searching...
No Matches
ErrorProperties.c File Reference

Go to the source code of this file.

Classes

class  ErrorProperties
 Class which holds the properties and handling of an error. More...
 

Functions

void DialogueErrorProperties (string message, string serverMessage, string header, UIScriptedMenu handler=null, int dialogButtonType=DBT_OK, int defaultButton=DBB_OK, int dialogMeaningType=DMT_EXCLAMATION, bool displayAdditionalInfo=true)
 
override void HandleError (int errorCode, string additionalInfo="")
 
string GetHeader ()
 
int GetDialogButtonType ()
 
int GetDefaultButton ()
 
int GetDialogMeaningType ()
 
UIScriptedMenu GetHandler ()
 

Variables

class ErrorProperties m_Header
 Error which shows a generic Dialogue UI.
 
int m_DialogButtonType
 
int m_DefaultButton
 
int m_DialogMeaningType
 
UIScriptedMenu m_Handler
 
bool m_DisplayAdditionalInfo
 

Function Documentation

◆ DialogueErrorProperties()

void DialogueErrorProperties ( string message,
string serverMessage,
string header,
UIScriptedMenu handler = null,
int dialogButtonType = DBT_OK,
int defaultButton = DBB_OK,
int dialogMeaningType = DMT_EXCLAMATION,
bool displayAdditionalInfo = true )
protected

◆ GetDefaultButton()

int GetDefaultButton ( )
protected

Definition at line 78 of file ErrorProperties.c.

78{ return m_DefaultButton; }

References m_DefaultButton.

◆ GetDialogButtonType()

int GetDialogButtonType ( )
protected

Definition at line 77 of file ErrorProperties.c.

77{ return m_DialogButtonType; }

References m_DialogButtonType.

◆ GetDialogMeaningType()

int GetDialogMeaningType ( )
protected

Definition at line 79 of file ErrorProperties.c.

79{ return m_DialogMeaningType; }

References m_DialogMeaningType.

◆ GetHandler()

UIScriptedMenu GetHandler ( )
protected

Definition at line 80 of file ErrorProperties.c.

80{ return m_Handler; }

References m_Handler.

◆ GetHeader()

string GetHeader ( )
protected

Definition at line 76 of file ErrorProperties.c.

76{ return m_Message; }

References ErrorProperties::m_Message.

Referenced by AttachmentCategoriesRow::Init().

◆ HandleError()

override void HandleError ( int errorCode,
string additionalInfo = "" )
protected

Definition at line 55 of file ErrorProperties.c.

56 {
57#ifdef NO_GUI
58 return; //do not display error if GUI is disabled
59#endif
60
61#ifdef SERVER
62 return;
63#else
64 string message;
66 message = string.Format(EP_MESSAGE_FORMAT_STRING, m_Message, additionalInfo);
67 else
68 message = m_Message;
69
70 GetGame().GetUIManager().ShowDialog(
71 string.Format(EP_HEADER_FORMAT_STRING, m_Header, ErrorModuleHandler.GetErrorHex(errorCode)),
73#endif
74 }
The error handler itself, for managing and distributing errors to modules Manages the ErrorHandlerMod...
static proto owned string GetErrorHex(int errorCode)
Returns a formatted string of the error code.
proto native CGame GetGame()

References ErrorModuleHandler::GetErrorHex(), GetGame(), m_DefaultButton, m_DialogButtonType, m_DialogMeaningType, m_DisplayAdditionalInfo, m_Handler, m_Header, and ErrorProperties::m_Message.

Variable Documentation

◆ m_DefaultButton

int m_DefaultButton
protected

Definition at line 40 of file ErrorProperties.c.

Referenced by DialogueErrorProperties(), GetDefaultButton(), and HandleError().

◆ m_DialogButtonType

int m_DialogButtonType
protected

Definition at line 39 of file ErrorProperties.c.

Referenced by DialogueErrorProperties(), GetDialogButtonType(), and HandleError().

◆ m_DialogMeaningType

int m_DialogMeaningType
protected

Definition at line 41 of file ErrorProperties.c.

Referenced by DialogueErrorProperties(), GetDialogMeaningType(), and HandleError().

◆ m_DisplayAdditionalInfo

bool m_DisplayAdditionalInfo
protected

Definition at line 43 of file ErrorProperties.c.

Referenced by DialogueErrorProperties(), and HandleError().

◆ m_Handler

UIScriptedMenu m_Handler
protected

Definition at line 42 of file ErrorProperties.c.

Referenced by DialogueErrorProperties(), GetHandler(), and HandleError().

◆ m_Header

Error which shows a generic Dialogue UI.