コード例 #1
0
 public void OnCharacterResurection(BaseClass resurrectedCharacter)
 {
     DeathCharacters.Remove(resurrectedCharacter);
     resurrectedCharacter.tag = resurrectedCharacter.TeamTag;
     if (resurrectedCharacter.TeamTag == "BlueTeam")
     {
         BlueTeamInBattle.Add(resurrectedCharacter);
     }
     else if (resurrectedCharacter.TeamTag == "RedTeam")
     {
         RedTeamInBattle.Remove(resurrectedCharacter);
     }
 }
コード例 #2
0
    public void AddToTeamList(BaseClass player)
    {
        if (player.CompareTag("BlueTeam"))
        {
            BlueTeamInBattle.Add(player);
        }
        else if (player.CompareTag("RedTeam"))
        {
            RedTeamInBattle.Add(player);
        }

        if (BlueTeamInBattle.Count >= 4 && RedTeamInBattle.Count >= 4)
        {
            client.StartUI();
        }
    }