Advertisement
DeathGodAOTTG

Core

Aug 12th, 2016
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 26.36 KB | None | 0 0
  1.  private void core()
  2.     {
  3.         if ((IN_GAME_MAIN_CAMERA.gametype != GAMETYPE.SINGLE) && this.needChooseSide)
  4.        {
  5.            if (GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().isInputDown[InputCode.flare1])
  6.            {
  7.                if (NGUITools.GetActive(this.ui.GetComponent<UIReferArray>().panels[3]))
  8.                {
  9.                    Screen.lockCursor = true;
  10.                     Screen.showCursor = true;
  11.                     NGUITools.SetActive(this.ui.GetComponent<UIReferArray>().panels[0], true);
  12.                     NGUITools.SetActive(this.ui.GetComponent<UIReferArray>().panels[1], false);
  13.                     NGUITools.SetActive(this.ui.GetComponent<UIReferArray>().panels[2], false);
  14.                     NGUITools.SetActive(this.ui.GetComponent<UIReferArray>().panels[3], false);
  15.                     GameObject.Find("MainCamera").GetComponent<SpectatorMovement>().disable = false;
  16.                     GameObject.Find("MainCamera").GetComponent<MouseLook>().disable = false;
  17.                 }
  18.                 else
  19.                 {
  20.                     Screen.lockCursor = false;
  21.                     Screen.showCursor = true;
  22.                     NGUITools.SetActive(this.ui.GetComponent<UIReferArray>().panels[0], false);
  23.                     NGUITools.SetActive(this.ui.GetComponent<UIReferArray>().panels[1], false);
  24.                     NGUITools.SetActive(this.ui.GetComponent<UIReferArray>().panels[2], false);
  25.                     NGUITools.SetActive(this.ui.GetComponent<UIReferArray>().panels[3], true);
  26.                     GameObject.Find("MainCamera").GetComponent<SpectatorMovement>().disable = true;
  27.                     GameObject.Find("MainCamera").GetComponent<MouseLook>().disable = true;
  28.                 }
  29.             }
  30.             if (GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().isInputDown[15] && !NGUITools.GetActive(this.ui.GetComponent<UIReferArray>().panels[3]))
  31.            {
  32.                NGUITools.SetActive(this.ui.GetComponent<UIReferArray>().panels[0], false);
  33.                 NGUITools.SetActive(this.ui.GetComponent<UIReferArray>().panels[1], true);
  34.                 NGUITools.SetActive(this.ui.GetComponent<UIReferArray>().panels[2], false);
  35.                 NGUITools.SetActive(this.ui.GetComponent<UIReferArray>().panels[3], false);
  36.                 Screen.showCursor = true;
  37.                 Screen.lockCursor = false;
  38.                 GameObject.Find("MainCamera").GetComponent<SpectatorMovement>().disable = true;
  39.                 GameObject.Find("MainCamera").GetComponent<MouseLook>().disable = true;
  40.                 GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().showKeyMap();
  41.                 GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().justUPDATEME();
  42.                 GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().menuOn = true;
  43.             }
  44.         }
  45.         if ((IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.SINGLE) || (IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.MULTIPLAYER))
  46.         {
  47.             string str11;
  48.             if (IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.MULTIPLAYER)
  49.             {
  50.                 string content = string.Empty;
  51.                 foreach (PhotonPlayer player in PhotonNetwork.playerList)
  52.                 {
  53.                     if (player.customProperties[PhotonPlayerProperty.dead] != null)
  54.                     {
  55.                         str11 = content;
  56.                         object[] objArray1 = new object[] { str11, "[000000]#", player.ID, " " };
  57.                         content = string.Concat(objArray1);
  58.                         if (player.isLocal)
  59.                         {
  60.                             content = content + "[FFCC00] >[-]";
  61.                         }
  62.                         if (player.isMasterClient)
  63.                         {
  64.                             content = content + "[Admin] ";
  65.                         }
  66.                         if ((bool) player.customProperties[PhotonPlayerProperty.dead])
  67.                         {
  68.                             content = content + "[" + ColorSet.color_red + "] *alive* ";
  69.                             if (((int) player.customProperties[PhotonPlayerProperty.isTitan]) == 2)
  70.                             {
  71.                                 content = content + "[" + ColorSet.color_titan_player + "] T ";
  72.                             }
  73.                             if (((int) player.customProperties[PhotonPlayerProperty.isTitan]) == 1)
  74.                             {
  75.                                 if (((int) player.customProperties[PhotonPlayerProperty.team]) == 2)
  76.                                 {
  77.                                     content = content + "[" + ColorSet.color_human_1 + "] H ";
  78.                                 }
  79.                                 else
  80.                                 {
  81.                                     content = content + "[" + ColorSet.color_human + "] H ";
  82.                                 }
  83.                             }
  84.                         }
  85.                         else
  86.                         {
  87.                             if (((int) player.customProperties[PhotonPlayerProperty.isTitan]) == 2)
  88.                             {
  89.                                 content = content + "[" + ColorSet.color_titan_player + "] T ";
  90.                             }
  91.                             if (((int) player.customProperties[PhotonPlayerProperty.isTitan]) == 1)
  92.                             {
  93.                                 if (((int) player.customProperties[PhotonPlayerProperty.team]) == 2)
  94.                                 {
  95.                                     content = content + "[" + ColorSet.color_human_1 + "] H ";
  96.                                 }
  97.                                 else
  98.                                 {
  99.                                     content = content + "[" + ColorSet.color_human + "] H ";
  100.                                 }
  101.                             }
  102.                         }
  103.                         str11 = content;
  104.                         object[] objArray2 = new object[] { str11, string.Empty, player.customProperties[PhotonPlayerProperty.name], "[ff0000]:", player.customProperties[PhotonPlayerProperty.kills], "/", player.customProperties[PhotonPlayerProperty.deaths], "/", player.customProperties[PhotonPlayerProperty.max_dmg], "/", player.customProperties[PhotonPlayerProperty.total_dmg] };
  105.                         content = string.Concat(objArray2);
  106.                         if ((bool) player.customProperties[PhotonPlayerProperty.dead])
  107.                         {
  108.                             content = content + "[-]";
  109.                         }
  110.                         content = content + "\n";
  111.                     }
  112.                 }
  113.                 this.ShowHUDInfoTopLeft(content);
  114.                 if (((GameObject.Find("MainCamera") != null) && (IN_GAME_MAIN_CAMERA.gamemode != GAMEMODE.RACING)) && (GameObject.Find("MainCamera").GetComponent<IN_GAME_MAIN_CAMERA>().gameOver && !this.needChooseSide))
  115.                {
  116.                    this.ShowHUDInfoCenter("Press [F7D358]" + GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().inputString[InputCode.flare1] + "[-] to spectate the next player. \nPress [F7D358]" + GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().inputString[InputCode.flare2] + "[-] to spectate the previous player.\nPress [F7D358]" + GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().inputString[InputCode.attack1] + "[-] to enter the spectator mode.\n\n\n\n");
  117.                     if (LevelInfo.getInfo(level).respawnMode == RespawnMode.DEATHMATCH)
  118.                     {
  119.                         this.myRespawnTime += Time.deltaTime;
  120.                         int num2 = 10;
  121.                         if (((int) PhotonNetwork.player.customProperties[PhotonPlayerProperty.isTitan]) == 2)
  122.                         {
  123.                             num2 = 15;
  124.                         }
  125.                         this.ShowHUDInfoCenterADD("Respawn in " + ((num2 - ((int) this.myRespawnTime))).ToString() + "s.");
  126.                         if (this.myRespawnTime > num2)
  127.                         {
  128.                             this.myRespawnTime = 0f;
  129.                             GameObject.Find("MainCamera").GetComponent<IN_GAME_MAIN_CAMERA>().gameOver = false;
  130.                             if (((int) PhotonNetwork.player.customProperties[PhotonPlayerProperty.isTitan]) == 2)
  131.                             {
  132.                                 this.SpawnNonAITitan(this.myLastHero, "titanRespawn");
  133.                             }
  134.                             else
  135.                             {
  136.                                 this.SpawnPlayer(this.myLastHero, this.myLastRespawnTag);
  137.                             }
  138.                             GameObject.Find("MainCamera").GetComponent<IN_GAME_MAIN_CAMERA>().gameOver = false;
  139.                             this.ShowHUDInfoCenter(string.Empty);
  140.                         }
  141.                     }
  142.                 }
  143.             }
  144.             else if (IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.SINGLE)
  145.             {
  146.                 if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.RACING)
  147.                 {
  148.                     if (!this.isLosing)
  149.                     {
  150.                         this.currentSpeed = GameObject.Find("MainCamera").GetComponent<IN_GAME_MAIN_CAMERA>().main_object.rigidbody.velocity.magnitude;
  151.                         this.maxSpeed = Mathf.Max(this.maxSpeed, this.currentSpeed);
  152.                         this.ShowHUDInfoTopLeft(string.Concat(new object[] { "Current Speed : ", (int) this.currentSpeed, "\nMax Speed:", this.maxSpeed }));
  153.                     }
  154.                 }
  155.                 else
  156.                 {
  157.                     this.ShowHUDInfoTopLeft(string.Concat(new object[] { "Kills:", this.single_kills, "\nMax Damage:", this.single_maxDamage, "\nTotal Damage:", this.single_totalDamage }));
  158.                 }
  159.             }
  160.             if (this.isLosing && (IN_GAME_MAIN_CAMERA.gamemode != GAMEMODE.RACING))
  161.            {
  162.                if (IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.SINGLE)
  163.                {
  164.                    if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.SURVIVE_MODE)
  165.                    {
  166.                        this.ShowHUDInfoCenter(string.Concat(new object[] { "Survive ", this.wave, " Waves!\n Press ", GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().inputString[InputCode.restart], " to Restart.\n\n\n" }));
  167.                     }
  168.                     else
  169.                     {
  170.                         this.ShowHUDInfoCenter("Lolz you failed!\n Press " + GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().inputString[InputCode.restart] + " to Restart.\n\n\n");
  171.                     }
  172.                 }
  173.                 else
  174.                 {
  175.                     if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.SURVIVE_MODE)
  176.                     {
  177.                         this.ShowHUDInfoCenter(string.Concat(new object[] { "Survive ", this.wave, " Waves!\nGame Restart in ", (int) this.gameEndCD, "s\n\n" }));
  178.                     }
  179.                     else
  180.                     {
  181.                         this.ShowHUDInfoCenter("Failed!\nAgain?\nGame Restart in " + ((int) this.gameEndCD) + "s\n\n");
  182.                     }
  183.                     if (this.gameEndCD <= 0f)
  184.                    {
  185.                        this.gameEndCD = 0f;
  186.                        if (PhotonNetwork.isMasterClient)
  187.                        {
  188.                            this.restartGame(false);
  189.                        }
  190.                        this.ShowHUDInfoCenter(string.Empty);
  191.                    }
  192.                    else
  193.                    {
  194.                        this.gameEndCD -= Time.deltaTime;
  195.                    }
  196.                }
  197.            }
  198.            if (this.isWinning)
  199.            {
  200.                if (IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.SINGLE)
  201.                {
  202.                    if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.RACING)
  203.                    {
  204.                        this.ShowHUDInfoCenter((((((int) (this.timeTotalServer * 10f)) * 0.1f) - 5f)).ToString() + "s !\n Press " + GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().inputString[InputCode.restart] + " to Restart.\n\n\n");
  205.                     }
  206.                     else if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.SURVIVE_MODE)
  207.                     {
  208.                         this.ShowHUDInfoCenter("Survive All Waves!\n Press " + GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().inputString[InputCode.restart] + " to Restart.\n\n\n");
  209.                     }
  210.                     else
  211.                     {
  212.                         this.ShowHUDInfoCenter("You noobs finally won!\n Press " + GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().inputString[InputCode.restart] + " to Restart.\n\n\n");
  213.                     }
  214.                 }
  215.                 else
  216.                 {
  217.                     if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.RACING)
  218.                     {
  219.                         this.ShowHUDInfoCenter(string.Concat(new object[] { this.localRacingResult, "\n\nGame Restart in ", (int) this.gameEndCD, "s" }));
  220.                     }
  221.                     else if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.SURVIVE_MODE)
  222.                     {
  223.                         this.ShowHUDInfoCenter("Survive All Waves!\nGame Restart in " + ((int) this.gameEndCD) + "s\n\n");
  224.                     }
  225.                     else if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.PVP_AHSS)
  226.                     {
  227.                         this.ShowHUDInfoCenter(string.Concat(new object[] { "Team DeathGod Win!\nGame Restart in ", (int) this.gameEndCD, "s\n\n" }));
  228.                     }
  229.                     else
  230.                     {
  231.                         this.ShowHUDInfoCenter("Humanity Win!\nGame Restart in " + ((int) this.gameEndCD) + "s\n\n");
  232.                     }
  233.                     if (this.gameEndCD <= 0f)
  234.                    {
  235.                        this.gameEndCD = 0f;
  236.                        if (PhotonNetwork.isMasterClient)
  237.                        {
  238.                            this.restartGame(false);
  239.                        }
  240.                        this.ShowHUDInfoCenter(string.Empty);
  241.                    }
  242.                    else
  243.                    {
  244.                        this.gameEndCD -= Time.deltaTime;
  245.                    }
  246.                }
  247.            }
  248.            this.timeElapse += Time.deltaTime;
  249.            this.roundTime += Time.deltaTime;
  250.            if (IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.SINGLE)
  251.            {
  252.                if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.RACING)
  253.                {
  254.                    if (!this.isWinning)
  255.                    {
  256.                        this.timeTotalServer += Time.deltaTime;
  257.                    }
  258.                }
  259.                else if (!this.isLosing && !this.isWinning)
  260.                {
  261.                    this.timeTotalServer += Time.deltaTime;
  262.                }
  263.            }
  264.            else
  265.            {
  266.                this.timeTotalServer += Time.deltaTime;
  267.            }
  268.            if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.RACING)
  269.            {
  270.                if (IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.SINGLE)
  271.                {
  272.                    if (!this.isWinning)
  273.                    {
  274.                        this.ShowHUDInfoTopCenter("Time : " + ((((int) (this.timeTotalServer * 10f)) * 0.1f) - 5f));
  275.                    }
  276.                    if (this.timeTotalServer < 5f)
  277.                    {
  278.                        this.ShowHUDInfoCenter("RACE START IN " + ((int) (5f - this.timeTotalServer)));
  279.                    }
  280.                    else if (!this.startRacing)
  281.                    {
  282.                        this.ShowHUDInfoCenter(string.Empty);
  283.                        this.startRacing = true;
  284.                        this.endRacing = false;
  285.                        GameObject.Find("door").SetActive(false);
  286.                    }
  287.                }
  288.                else
  289.                {
  290.                    this.ShowHUDInfoTopCenter("Time : " + ((this.roundTime >= 20f) ? (((((int) (this.roundTime * 10f)) * 0.1f) - 20f)).ToString() : "WAITING"));
  291.                     if (this.roundTime < 20f)
  292.                    {
  293.                        this.ShowHUDInfoCenter("RACE START IN " + ((int) (20f - this.roundTime)) + (!(this.localRacingResult == string.Empty) ? ("\nLast Round\n" + this.localRacingResult) : "\n\n"));
  294.                    }
  295.                    else if (!this.startRacing)
  296.                    {
  297.                        this.ShowHUDInfoCenter(string.Empty);
  298.                        this.startRacing = true;
  299.                        this.endRacing = false;
  300.                        GameObject.Find("door").SetActive(false);
  301.                    }
  302.                }
  303.                if (GameObject.Find("MainCamera").GetComponent<IN_GAME_MAIN_CAMERA>().gameOver && !this.needChooseSide)
  304.                {
  305.                    this.myRespawnTime += Time.deltaTime;
  306.                     if (this.myRespawnTime > 1.5f)
  307.                     {
  308.                         this.myRespawnTime = 0f;
  309.                         GameObject.Find("MainCamera").GetComponent<IN_GAME_MAIN_CAMERA>().gameOver = false;
  310.                         if (this.checkpoint != null)
  311.                         {
  312.                             this.SpawnPlayerAt(this.myLastHero, this.checkpoint);
  313.                         }
  314.                         else
  315.                         {
  316.                             this.SpawnPlayer(this.myLastHero, this.myLastRespawnTag);
  317.                         }
  318.                         GameObject.Find("MainCamera").GetComponent<IN_GAME_MAIN_CAMERA>().gameOver = false;
  319.                         this.ShowHUDInfoCenter(string.Empty);
  320.                     }
  321.                 }
  322.             }
  323.             if (this.timeElapse > 1f)
  324.             {
  325.                 this.timeElapse--;
  326.                 string str2 = string.Empty;
  327.                 if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.ENDLESS_TITAN)
  328.                 {
  329.                     str2 = str2 + "Time : " + ((this.time - ((int) this.timeTotalServer))).ToString();
  330.                 }
  331.                 else if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.KILL_TITAN)
  332.                 {
  333.                     str2 = "Titan Left: ";
  334.                     str2 = str2 + GameObject.FindGameObjectsWithTag("titan").Length.ToString() + "  Time : ";
  335.                     if (IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.SINGLE)
  336.                     {
  337.                         str2 = str2 + ((int) this.timeTotalServer).ToString();
  338.                     }
  339.                     else
  340.                     {
  341.                         str2 = str2 + ((this.time - ((int) this.timeTotalServer))).ToString();
  342.                     }
  343.                 }
  344.                 else if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.SURVIVE_MODE)
  345.                 {
  346.                     str2 = "Titan Left: ";
  347.                     str2 = (str2 + GameObject.FindGameObjectsWithTag("titan").Length.ToString()) + " Wave : " + this.wave;
  348.                 }
  349.                 else if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.BOSS_FIGHT_CT)
  350.                 {
  351.                     str2 = "Time : ";
  352.                     str2 = str2 + ((this.time - ((int) this.timeTotalServer))).ToString() + "\nDefeat the Bertholt.\nStop runny titans from running to the north gate";
  353.                 }
  354.                 else if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.PVP_CAPTURE)
  355.                 {
  356.                     string str3 = "| ";
  357.                     for (int i = 0; i < PVPcheckPoint.chkPts.Count; i++)
  358.                    {
  359.                        str3 = str3 + (PVPcheckPoint.chkPts[i] as PVPcheckPoint).getStateString() + " ";
  360.                    }
  361.                    str3 = str3 + "|";
  362.                    str2 = string.Concat(new object[] { this.PVPtitanScoreMax - this.PVPtitanScore, "  ", str3, "  ", this.PVPhumanScoreMax - this.PVPhumanScore, "\n" }) + "Time : " + ((this.time - ((int) this.timeTotalServer))).ToString();
  363.                }
  364.                this.ShowHUDInfoTopCenter(str2);
  365.                str2 = string.Empty;
  366.                if (IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.SINGLE)
  367.                {
  368.                    if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.SURVIVE_MODE)
  369.                    {
  370.                        str2 = "Time : ";
  371.                        str2 = str2 + ((int) this.timeTotalServer).ToString();
  372.                    }
  373.                }
  374.                else if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.ENDLESS_TITAN)
  375.                {
  376.                    object[] objArray10 = new object[] { "Humanity ", this.humanScore, " : Titan ", this.titanScore, " " };
  377.                    str2 = string.Concat(objArray10);
  378.                }
  379.                else if (((IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.KILL_TITAN) || (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.BOSS_FIGHT_CT)) || (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.PVP_CAPTURE))
  380.                {
  381.                    object[] objArray11 = new object[] { "Humanity ", this.humanScore, " : Titan ", this.titanScore, " " };
  382.                    str2 = string.Concat(objArray11);
  383.                }
  384.                else if (IN_GAME_MAIN_CAMERA.gamemode != GAMEMODE.CAGE_FIGHT)
  385.                {
  386.                    if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.SURVIVE_MODE)
  387.                    {
  388.                        str2 = "Time : ";
  389.                        str2 = str2 + ((this.time - ((int) this.timeTotalServer))).ToString();
  390.                    }
  391.                    else if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.PVP_AHSS)
  392.                    {
  393.                        for (int j = 0; j < this.teamScores.Length; j++)
  394.                        {
  395.                            str11 = str2;
  396.                            object[] objArray12 = new object[] { str11, (j == 0) ? string.Empty : " : ", "Team", j + 1, " ", this.teamScores[j], string.Empty };
  397.                            str2 = string.Concat(objArray12);
  398.                        }
  399.                        str2 = str2 + "\nTime : " + ((this.time - ((int) this.timeTotalServer))).ToString();
  400.                    }
  401.                }
  402.                this.ShowHUDInfoTopRight(str2);
  403.                string str4 = (IN_GAME_MAIN_CAMERA.difficulty >= 0) ? ((IN_GAME_MAIN_CAMERA.difficulty != 0) ? ((IN_GAME_MAIN_CAMERA.difficulty != 1) ? "Abnormal" : "Hard") : "Normal") : "Trainning";
  404.                 if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.CAGE_FIGHT)
  405.                 {
  406.                     this.ShowHUDInfoTopRightMAPNAME(string.Concat(new object[] { (int) this.roundTime, "s\n", level, " : ", str4 }));
  407.                 }
  408.                 else
  409.                 {
  410.                     this.ShowHUDInfoTopRightMAPNAME("\n" + level + " : " + str4);
  411.                 }
  412.                 this.ShowHUDInfoTopRightMAPNAME("\nCamera(" + GameObject.Find("InputManagerController").GetComponent<FengCustomInputs>().inputString[InputCode.camera] + "):" + IN_GAME_MAIN_CAMERA.cameraMode.ToString());
  413.                 if ((IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.MULTIPLAYER) && this.needChooseSide)
  414.                {
  415.                    this.ShowHUDInfoTopCenterADD("\n\nPRESS 1 TO KILL A TITAN");
  416.                 }
  417.             }
  418.             if (((IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.MULTIPLAYER) && (this.killInfoGO.Count > 0)) && (this.killInfoGO[0] == null))
  419.            {
  420.                this.killInfoGO.RemoveAt(0);
  421.             }
  422.             if (((IN_GAME_MAIN_CAMERA.gametype != GAMETYPE.SINGLE) && PhotonNetwork.isMasterClient) && (this.timeTotalServer > this.time))
  423.            {
  424.                string str10;
  425.                 IN_GAME_MAIN_CAMERA.gametype = GAMETYPE.STOP;
  426.                 this.gameStart = false;
  427.                 Screen.lockCursor = false;
  428.                 Screen.showCursor = true;
  429.                 string str5 = string.Empty;
  430.                 string str6 = string.Empty;
  431.                 string str7 = string.Empty;
  432.                 string str8 = string.Empty;
  433.                 string str9 = string.Empty;
  434.                 foreach (PhotonPlayer player2 in PhotonNetwork.playerList)
  435.                 {
  436.                     if (player2 != null)
  437.                     {
  438.                         str5 = str5 + player2.customProperties[PhotonPlayerProperty.name] + "\n";
  439.                         str6 = str6 + player2.customProperties[PhotonPlayerProperty.kills] + "\n";
  440.                         str7 = str7 + player2.customProperties[PhotonPlayerProperty.deaths] + "\n";
  441.                         str8 = str8 + player2.customProperties[PhotonPlayerProperty.max_dmg] + "\n";
  442.                         str9 = str9 + player2.customProperties[PhotonPlayerProperty.total_dmg] + "\n";
  443.                     }
  444.                 }
  445.                 if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.PVP_AHSS)
  446.                 {
  447.                     str10 = string.Empty;
  448.                     for (int k = 0; k < this.teamScores.Length; k++)
  449.                    {
  450.                        str10 = str10 + ((k == 0) ? string.Concat(new object[] { "Team", k + 1, " ", this.teamScores[k], " " }) : " : ");
  451.                    }
  452.                }
  453.                else if (IN_GAME_MAIN_CAMERA.gamemode == GAMEMODE.SURVIVE_MODE)
  454.                {
  455.                    str10 = "Highest Wave : " + this.highestwave;
  456.                }
  457.                else
  458.                {
  459.                    object[] objArray15 = new object[] { "Humanity ", this.humanScore, " : Titan ", this.titanScore };
  460.                    str10 = string.Concat(objArray15);
  461.                }
  462.                object[] parameters = new object[] { str5, str6, str7, str8, str9, str10 };
  463.                base.photonView.RPC("showResult", PhotonTargets.AllBuffered, parameters);
  464.            }
  465.        }
  466.    }
  467.  
  468.    public void gameLose()
  469.    {
  470.        if (!this.isWinning && !this.isLosing)
  471.        {
  472.            this.isLosing = true;
  473.            this.titanScore++;
  474.            this.gameEndCD = this.gameEndTotalCDtime;
  475.            if (IN_GAME_MAIN_CAMERA.gametype == GAMETYPE.MULTIPLAYER)
  476.            {
  477.                object[] parameters = new object[] { this.titanScore };
  478.                base.photonView.RPC("netGameLose", PhotonTargets.Others, parameters);
  479.            }
  480.        }
  481.    }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement