public bool IsFriendlyTowards(BasePlayer player) { if (player == null) return false; if (player == this) return true; return false; }
public bool IsHostileTowards(BasePlayer player) { if (player == null) return false; if (player != this) return true; return false; }
public bool IsNeutralTowards(BasePlayer player) { if (player == null) return true; return false; }
internal bool CreateEntity(int x, int y, LevelObjectType entityType, BasePlayer owner) { Log.Write(LogType.Generic, LogSeverity.Debug, "Pathfinder at [" + x + "," + y + "]: " + Pathfinder[x, y]); Log.Write(LogType.Generic, LogSeverity.Debug, "levelPassable at [" + x + "," + y + "]: " + levelPassable.passableData[x, y]); if (Pathfinder[x, y] != 0) return false; Entity newEnt = Entity.CreateEntityFromType (entityType, this); newEnt.SetPosition (x, y); entities.Add (newEnt); if (owner != null) // Neutral entities may not have an owner owner.ClaimeOwnership (newEnt); newEnt.DidSpawn (); // Add to Pathfinder Pathfinder.SetFieldsBlocked(x, y, newEnt.TileSizeX, newEnt.TileSizeY); return true; }