Dayz Explorer 1.28.160049
Loading...
Searching...
No Matches
bioserrormodule.c
Go to the documentation of this file.
1
69
70class BIOSErrorModule : ErrorHandlerModuleScript
71{
72 void BIOSErrorModule()
73 {
74 SetCategory(ErrorCategory.BIOSError);
75 }
76
77 override void InitOptionalVariables()
78 {
79 super.InitOptionalVariables();
80
81 m_Header = "#STR_BIOS_BIOSError";
82 }
83
84 override void FillErrorDataMap()
85 {
86 super.FillErrorDataMap();
87
88 InsertErrorProperties(EBiosError.OK); // Not an error, so no message
89 InsertBIOSError(EBiosError.CANCEL , "#STR_BIOS_OperationCancelled");
90 InsertBIOSError(EBiosError.BAD_PARAMETER , "#STR_BIOS_BadParameter");
91 InsertBIOSError(EBiosError.NOT_FOUND , "#STR_BIOS_NotFound");
92 InsertBIOSError(EBiosError.NOT_IMPLEMENTED , "#STR_BIOS_NotImplemented");
93 InsertBIOSError(EBiosError.PURCHASE_REQUIRED , "#STR_BIOS_PurchaseRequired");
94 InsertBIOSError(EBiosError.NOT_ALLOWED , "#STR_BIOS_ActionRestricted");
95 InsertBIOSError(EBiosError.BANNED , "#STR_auth_publisher_ban");
96 InsertBIOSError(EBiosError.LOGICAL , "#STR_BIOS_APILogicError");
97
98 InsertBIOSError(EBiosError.WRONG_RESPONSE_DATA , "#STR_BIOS_UnexpectedFormat");
99
100 InsertBIOSError(EBiosError.SERVER_HEARTBEAT_SERVER_NOT_FOUND , "#STR_BIOS_ServerNotRegistered");
101 InsertBIOSError(EBiosError.SERVER_REGISTER_ALREADY_EXISTS , "#STR_BIOS_ServerAlreadyRegistered");
102
103 InsertBIOSError(EBiosError.REQUEST_CREATE_FAIL_XHR , "#STR_BIOS_FailedToOpenRequest");
104 InsertBIOSError(EBiosError.REQUEST_SEND_FAIL , "#STR_BIOS_FailedToSendData");
105 InsertBIOSError(EBiosError.REQUEST_WAIT_FAIL , "#STR_BIOS_FailedToWaitOperationEnd");
106
107 InsertBIOSError(EBiosError.NON_JSON_RESPONSE , "#STR_BIOS_UnexpectedFormat");
108
109 InsertBIOSError(EBiosError.UPDATE_REQUIRED , "#STR_BIOS_UpdateRequired");
110 InsertBIOSError(EBiosError.UPDATE_REQUIRED_AND_DOWNLOADED , "#STR_BIOS_UpdateRequiredAndDownloaded");
111
112 InsertBIOSError(EBiosError.COMUNICATION_ERROR , "#STR_BIOS_CommunicationError");
113
114 InsertBIOSError(EBiosError.UNKNOWN , "#server_browser_error_unknown");
115 InsertBIOSError(EBiosError.BAD_SCRIPT , "#STR_BIOS_LinkageError");
116
117 InsertBIOSError(EBiosError.COMMUNICATION_TIMED_OUT , "#STR_BIOS_CommTimeOutError");
118 InsertBIOSError(EBiosError.COMMUNICATION_RESET , "#STR_BIOS_CommResetError");
119 InsertBIOSError(EBiosError.COMMUNICATION_ABORTED , "#STR_BIOS_CommAbortError");
120 }
121
122 void InsertBIOSError(int code, string message)
123 {
124 #ifdef PLATFORM_CONSOLE
125 InsertDialogueErrorProperties(code, message);
126 #else
127 InsertErrorProperties(code, message);
128 #endif
129 }
130}
EBiosError
Possible Error codes for bios API. This is the list of errors that can be returned from bios API....
@ COMUNICATION_ERROR
23 - Resource is unreachable or unavailable, can be 404 or no internet connection (etc....
@ NOT_IMPLEMENTED
4 - The call is not supported for the current platform. Can be returned from any call.
@ NOT_ALLOWED
6 - The action is not allowed. (restricted, not enough permission)
@ COMMUNICATION_TIMED_OUT
26 - Connection has timed out.
@ LOGICAL
8 - API usage error. For example, usage of objects whos native lifetime ended. Can be returned from a...
@ PURCHASE_REQUIRED
5 - [XB] The action cannot be performed because the user does not own the content.
@ BAD_SCRIPT
25 - Extended error. Script not properly linked with engine. May be removed in future.
@ REQUEST_SEND_FAIL
13 - Failed to send the data
@ UPDATE_REQUIRED
21 - [PS] Mandatory update exist and is required.
@ OK
0 - No error. Can be returned from any call.
@ SERVER_HEARTBEAT_SERVER_NOT_FOUND
10 - Server is no longer registered
@ REQUEST_CREATE_FAIL_XHR
12 - Failed to open the request
@ WRONG_RESPONSE_DATA
9 - Response was of unexpected format
@ COMMUNICATION_RESET
27 - Connection was reset.
@ BAD_PARAMETER
1 - The operation was cancelled. See individual calls for details.
@ COMMUNICATION_ABORTED
28 - Connection was aborted.
@ UNKNOWN
24 - Any other error. Can be returned from any call.
@ SERVER_REGISTER_ALREADY_EXISTS
11 - Server was already registered
@ NON_JSON_RESPONSE
15 - Response was expected to be in JSON format, but it was not
@ NOT_FOUND
3 - The call could not find some data. See individual calls for details.
@ REQUEST_WAIT_FAIL
14 - Failed to wait for the operation to end - only in a synchronous call
@ UPDATE_REQUIRED_AND_DOWNLOADED
22 - [PS] Mandatory update exist and is ready to install.
@ BANNED
7 - [XB] The user is banned from some action.
class ErrorHandlerModule m_Header
This is where to input logic and extend functionality of ErrorHandlerModule.
void InsertDialogueErrorProperties(int code, string message, int dialogButtonType=DBT_OK, int defaultButton=DBB_OK, int dialogMeaningType=DMT_EXCLAMATION, bool displayAdditionalInfo=true)
Insert an error with Dialogue as handling, using the Optional Variables.
void InsertErrorProperties(int code, string message="")
Insert an error with no handling.
ErrorCategory
ErrorCategory - To decide what ErrorHandlerModule needs to be called and easily identify where it cam...