/// <summary> /// 移除队员 /// </summary> /// <param name="teamPlayer"></param> public void RemoveTeamPlayer(TeamPlayer teamPlayer) { try { teamPlayers.Remove(teamPlayer); } catch (Exception e) { GameManager.Instance.LogError(e.Message); } }
public void Copy(TeamPlayer teamPlayer) { name = teamPlayer.Name; teamColor = teamPlayer.teamColor; belongsTo = teamPlayer.belongsTo; }
/// <summary> /// 添加队员 /// </summary> /// <param name="teamPlayer"></param> public void AddTeamPlayer(TeamPlayer teamPlayer) { teamPlayers.Add(teamPlayer); teamPlayer.Index = teamPlayers.Count - 1; teamPlayer.belongsTo = this; }