DayZ 1.27
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ OnJoin()

void BiosUserManager::OnJoin ( EBiosJoinType type,
BiosUser joiner,
string handle,
string joinee,
EBiosError error )
inlineprivate

Callback function.

Called when a join is parsed or when a runtime join is accepted from the system UI.

Аргументы
typethe type of join. Undefined on error.
joinerthe user that is joining. NULL on error.
handlejoin handle for a session. Empty on error.
joineeuid of the user that is being joined. Empty on error.
errorindicating if parsing failed. OK if not a result of ParseJoinAsync.

См. определение в файле BiosUserManager.c строка 211

212 {
213 if ( !OnlineServices.ErrorCaught( error ) )
214 {
215 OnlineServices.SetBiosUser( joiner );
216
217 SelectUserEx( joiner );
218 OnlineServices.SetSessionHandle( handle );
219
220 if ( g_Game.GetGameState() == DayZGameState.IN_GAME )
221 {
222 g_Game.SetLoadState( DayZLoadState.JOIN_START );
223 OnlineServices.GetSession();
224 }
225 else
226 {
227 if ( GetGame().GetUIManager() && GetGame().GetInput().IsActiveGamepadSelected() )
228 {
231 }
232 g_Game.SetLoadState( DayZLoadState.JOIN_START );
233 g_Game.GamepadCheck();
234 }
235 }
236 else
237 {
238 g_Game.DisconnectSessionEx(DISCONNECT_SESSION_FLAGS_JOIN);
239 }
240 }
DayZGame g_Game
Определения DayZGame.c:3868
const int DISCONNECT_SESSION_FLAGS_JOIN
Определения DayZGame.c:14
bool SelectUserEx(BiosUser user)
Определения BiosUserManager.c:90
proto native UIManager GetUIManager()
proto native Input GetInput()
proto native void IdentifyGamepad(GamepadButton button)
the on OnGamepadIdentification callback will return the first gamepad where the button was pressed
bool CloseMenu(int id)
Close menu with specific ID (see MenuID)
Определения UIManager.c:117
proto native CGame GetGame()
GamepadButton
Определения EnSystem.c:341
const int MENU_TITLE_SCREEN
Определения constants.c:196

Перекрестные ссылки UIManager::CloseMenu(), DISCONNECT_SESSION_FLAGS_JOIN, OnlineServices::ErrorCaught(), g_Game, GetGame(), CGame::GetInput(), OnlineServices::GetSession(), CGame::GetUIManager(), Input::IdentifyGamepad(), MENU_TITLE_SCREEN, SelectUserEx(), OnlineServices::SetBiosUser() и OnlineServices::SetSessionHandle().