using System; using System.Collections.Generic; using System.Collections.ObjectModel; using System.Drawing; using Vintagestory.API.Client; using Vintagestory.API.Common; using Vintagestory.API.Common.Entities; using Vintagestory.API.MathTools; namespace Automap { public delegate void EntityDesignatonAction(ICoreClientAPI clientAPI, EntitiesOfInterest poi, BlockPos posn, Entity entity); /// /// Point of Interest Rule Designator /// public class EntityDesignator { public Color Color; public EntityDesignatonAction SpecialAction; public AssetLocation Pattern; public EnumEntityState? StateCheck;//Needed? public bool Enabled { get; set; } private EntityDesignator() { throw new NotSupportedException(); } public EntityDesignator(AssetLocation pattern, Color color, EnumEntityState? state) { Pattern = pattern; Color = color; StateCheck = state; Enabled = true; } public EntityDesignator(AssetLocation pattern, Color color, EnumEntityState? state, EntityDesignatonAction specialAct) { Pattern = pattern; Color = color; StateCheck = state; SpecialAction = specialAct; Enabled = true; } public override string ToString() => Pattern.ToShortString() + "|" + Color.Name + "|" + StateCheck ?? ""; } }