public void EnableInBattleIcon(NodeAddedEvent e, UserInBattleNode user, [JoinByUser, Context, Combine] UserLabelNode userLabel) { if (userLabel.userLabel.AllowInBattleIcon && (userLabel.userLabel.inBattleIcon != null)) { userLabel.userLabel.inBattleIcon.SetActive(true); } }
public void UserInBattle(NodeAddedEvent e, UserInBattleNode userInBattle, [JoinByUser] ProfileScreenWithUserGroupNode profileScreen, [JoinAll] Optional <SelfBattleLobbyUser> selfBattleLobbyUser) { if (!selfBattleLobbyUser.IsPresent()) { this.ShowSpectatorButton(profileScreen); } }
public void DisableInBattleIcon(NodeRemoveEvent e, UserInBattleNode user, [JoinByUser, Combine] UserLabelNode userLabel) { if (userLabel.userLabel.AllowInBattleIcon && (userLabel.userLabel.inBattleIcon != null)) { userLabel.userLabel.inBattleIcon.SetActive(false); } }
public void EnableInBattleState(NodeAddedEvent e, UserInBattleNode user, [JoinByUser, Context, Combine] UserLabelStateNode userLabel) { userLabel.userLabelState.UserInBattle(); if (userLabel.Entity.HasComponent <BattleGroupComponent>()) { userLabel.Entity.RemoveComponent <BattleGroupComponent>(); } user.battleGroup.Attach(userLabel.Entity); }
public void UserNotInBattle(NodeRemoveEvent e, UserInBattleNode user) { if (user.Entity.HasComponent <MatchMakingUserReadyComponent>()) { user.lobbyUserListItem.SetReady(); } else { user.lobbyUserListItem.SetNotReady(); } }
public void UserOutBattle(NodeRemoveEvent e, UserInBattleNode userInBattle, [JoinByUser] ProfileScreenWithUserGroupNode profileScreen) { this.HideSpectatorButton(profileScreen); }
public void EnterAsSpectator(ButtonClickEvent e, SingleNode <EnterBattleAsSpectatorButtonComponent> button, [JoinAll] ProfileScreenWithUserGroupNode profileScreen, [JoinByUser] UserInBattleNode userInBattle, [JoinAll] ClientSessionNode session, [JoinAll] Optional <SelfBattleLobbyUser> selfBattleLobbyUser) { if (!selfBattleLobbyUser.IsPresent()) { base.ScheduleEvent(new EnterBattleAsSpectatorFromLobbyRequestEvent(userInBattle.battleGroup.Key), session); } }
public void DisableInBattleState(NodeRemoveEvent e, UserInBattleNode user, [JoinByUser, Context, Combine] UserLabelStateNode userLabel) { userLabel.userLabelState.UserOutBattle(user.Entity.HasComponent <UserOnlineComponent>()); }
public void UserInBattle(NodeAddedEvent e, UserInBattleNode user) { user.lobbyUserListItem.SetInBattle(); }
public void UserOutBattle(NodeRemoveEvent e, UserInBattleNode user, [JoinByUser, Combine] UserLabelStateNode userLabel) { this.DelayUpdateInviteToSquadButton(user); }