public PlayerLeftScriptClient(RoomInformations Owner, BattleMapOnlineClient Client, GamePreparationScreen MissionSelectScreen) : base(ScriptName) { this.Owner = Owner; this.Client = Client; this.MissionSelectScreen = MissionSelectScreen; }
protected override void Execute(IOnlineConnection Host) { OnlineGameClient.RoomID = RoomID; Dictionary <string, OnlineScript> DicNewGameServerScript = new Dictionary <string, OnlineScript>(); RoomInformations NewRoom; //FightingZone NewFightingZone = null; if (HasGame) { /* NewFightingZone = new FightingZone(OnlineGameClient); * NewFightingZone.ListGameScreen = ScreenOwner.ListGameScreen; * * DicNewGameServerScript = OnlineHelper.GetTripleThunderScriptsClient(OnlineGameClient); * Host.IsGameReady = true;*/ } PVPRoomInformations MissionRoom = new PVPRoomInformations(RoomID, RoomName, RoomType, RoomSubtype, CurrentDifficulty, MapPath, ListJoiningPlayerID, ScreenOwner.Content, RoomData); NewRoom = MissionRoom; NewScreen = new GamePreparationScreen(OnlineGameClient, OnlineCommunicationClient, MissionRoom); DicNewGameServerScript.Add(CreateGameScriptClient.ScriptName, new CreateGameScriptClient(OnlineGameClient, ScreenOwner.ListGameScreen, MissionRoom)); DicNewGameServerScript.Add(ChangeRoomExtrasBattleScriptClient.ScriptName, new ChangeRoomExtrasMissionScriptClient(MissionRoom, NewScreen)); if (HasGame) { //ScreenOwner.PushScreen(new LoadingScreen(NewFightingZone, OnlineGameClient)); } DicNewGameServerScript.Add(PlayerJoinedScriptClient.ScriptName, new PlayerJoinedScriptClient(NewScreen)); DicNewGameServerScript.Add(PlayerLeftScriptClient.ScriptName, new PlayerLeftScriptClient(NewRoom, OnlineGameClient, NewScreen)); DicNewGameServerScript.Add(ChangeLoadoutScriptClient.ScriptName, new ChangeLoadoutScriptClient(NewRoom, NewScreen)); DicNewGameServerScript.Add(ChangePlayerTypeScriptClient.ScriptName, new ChangePlayerTypeScriptClient(NewRoom, NewScreen)); DicNewGameServerScript.Add(ChangeTeamScriptClient.ScriptName, new ChangeTeamScriptClient(NewRoom)); DicNewGameServerScript.Add(ChangeMapScriptClient.ScriptName, new ChangeMapScriptClient(NewRoom, NewScreen)); DicNewGameServerScript.Add(ChangeRoomSubtypeScriptClient.ScriptName, new ChangeRoomSubtypeScriptClient(NewScreen)); Host.AddOrReplaceScripts(DicNewGameServerScript); if (OnlineCommunicationClient.Host != null) { OnlineCommunicationClient.Chat.InsertTab(RoomID, "Chat"); OnlineCommunicationClient.Chat.CloseTab("Global"); OnlineCommunicationClient.Host.Send(new CreateOrJoinCommunicationGroupScriptClient(RoomID, false)); OnlineCommunicationClient.Host.Send(new LeaveCommunicationGroupScriptClient("Global")); } Host.Send(new AskChangeLoadoutScriptClient(PlayerManager.ListLocalPlayer[0])); OnlineGameClient.DelayOnlineScript(this); }
protected override void Execute(IOnlineConnection Host) { OnlineGameClient.RoomID = RoomID; Dictionary <string, OnlineScript> DicNewGameServerScript = new Dictionary <string, OnlineScript>(); GamePreparationScreen NewMissionSelectScreen; PVPRoomInformations MissionRoom = new PVPRoomInformations(RoomID, RoomName, RoomType, RoomSubtype, MinNumberOfPlayer, MaxNumberOfPlayer); GamePreparationScreen NewMissionSelect = new GamePreparationScreen(OnlineGameClient, OnlineCommunicationClient, MissionRoom); NewScreen = NewMissionSelect; NewMissionSelectScreen = NewMissionSelect; DicNewGameServerScript.Add(CreateGameScriptClient.ScriptName, new CreateGameScriptClient(OnlineGameClient, ScreenOwner.ListGameScreen, MissionRoom)); DicNewGameServerScript.Add(ChangeRoomExtrasMissionScriptClient.ScriptName, new ChangeRoomExtrasMissionScriptClient(MissionRoom, NewMissionSelectScreen)); DicNewGameServerScript.Add(PlayerJoinedScriptClient.ScriptName, new PlayerJoinedScriptClient(NewMissionSelectScreen)); DicNewGameServerScript.Add(PlayerLeftScriptClient.ScriptName, new PlayerLeftScriptClient(MissionRoom, OnlineGameClient, NewMissionSelectScreen)); DicNewGameServerScript.Add(ChangeLoadoutScriptClient.ScriptName, new ChangeLoadoutScriptClient(MissionRoom, NewMissionSelectScreen)); DicNewGameServerScript.Add(ChangePlayerTypeScriptClient.ScriptName, new ChangePlayerTypeScriptClient(MissionRoom, NewMissionSelectScreen)); DicNewGameServerScript.Add(ChangeTeamScriptClient.ScriptName, new ChangeTeamScriptClient(MissionRoom)); DicNewGameServerScript.Add(ChangeMapScriptClient.ScriptName, new ChangeMapScriptClient(MissionRoom, NewMissionSelectScreen)); DicNewGameServerScript.Add(ChangeRoomSubtypeScriptClient.ScriptName, new ChangeRoomSubtypeScriptClient(NewMissionSelectScreen)); Host.AddOrReplaceScripts(DicNewGameServerScript); if (OnlineCommunicationClient.Host != null) { Dictionary <string, OnlineScript> DicNewCommunicationServerScript = new Dictionary <string, OnlineScript>(); DicNewCommunicationServerScript.Add(ReceiveGroupMessageScriptClient.ScriptName, new ReceiveGroupMessageScriptClient(OnlineCommunicationClient)); OnlineCommunicationClient.Host.AddOrReplaceScripts(DicNewCommunicationServerScript); OnlineCommunicationClient.Chat.InsertTab(RoomID, "Chat"); OnlineCommunicationClient.Chat.CloseTab("Global"); OnlineCommunicationClient.Host.Send(new CreateOrJoinCommunicationGroupScriptClient(RoomID, false)); OnlineCommunicationClient.Host.Send(new LeaveCommunicationGroupScriptClient("Global")); } Host.Send(new AskChangeLoadoutScriptClient(PlayerManager.ListLocalPlayer[0])); ScreenOwner.RemoveScreen(ScreenOwner); OnlineGameClient.DelayOnlineScript(this); }
public ChangeRoomSubtypeScriptClient(GamePreparationScreen MissionSelectScreen) : base(ScriptName) { this.MissionSelectScreen = MissionSelectScreen; }
public ChangeRoomExtrasMissionScriptClient(PVPRoomInformations Owner, GamePreparationScreen MissionSelectScreen) : base(ScriptName) { this.Owner = Owner; this.MissionSelectScreen = MissionSelectScreen; }
public PlayerJoinedScriptClient(GamePreparationScreen NewMissionSelectScreen) : base(ScriptName) { this.NewMissionSelectScreen = NewMissionSelectScreen; ListJoiningPlayer = new List <BattleMapPlayer>(); }
public ChangePlayerTypeScriptClient(RoomInformations Owner, GamePreparationScreen MissionSelectScreen) : base(ScriptName) { this.Owner = Owner; this.MissionSelectScreen = MissionSelectScreen; }