예제 #1
0
 public bool IsFree() //is the entity managed by this selection component a faction entity or a free one?
 {
     if (FactionEntity != null)
     {
         return(FactionEntity.IsFree());
     }
     return(false);
 }
예제 #2
0
 //a method that determines whether a faction entity belong to the local player or not
 public static bool IsLocalPlayer(FactionEntity factionEntity)
 {
     return(factionEntity.FactionID == GameManager.PlayerFactionID ||
            (factionEntity.IsFree() && GameManager.MultiplayerGame && GameManager.PlayerFactionID == GameManager.HostFactionID));
 }