2 using System.Collections.Generic;
3 using System.Collections.ObjectModel;
7 using Vintagestory.API.Common.Entities;
8 using Vintagestory.API.MathTools;
9 using Vintagestory.API.Client;
13 using Newtonsoft.Json;
18 /// Basically the same as a POI but for an entity
21 public struct EntityOfInterest
24 [DisplayName(0, "Name")]
28 [DisplayName(2, "Notes")]
32 [DisplayName(1, "Loc.")]
33 public string PrettyLocation;
36 public BlockPos Location;
38 [DisplayName(3, "Time")]
40 public DateTime Timestamp;
42 [DisplayName(4, "ID")]
50 /// Entities of interest.
52 /// <remarks>Tracked by ID - these never leave.</remarks>
53 public class EntitiesOfInterest : KeyedCollection<long, EntityOfInterest>
55 protected override long GetKeyForItem(EntityOfInterest item)
58 internal void AddReplace(EntityOfInterest entity)
60 if (Contains(entity.EntityId))
61 Remove(entity.EntityId);