public static bool ContainsIcon(Vector3 pos) { PeMap.ILabel pl = PeMap.LabelMgr.Instance.Find(item => { NpcTownLabel l = item as NpcTownLabel; if (l != null && l.pos == pos) { return(true); } return(false); }); if (pl != null) { return(true); } return(false); }
//public static void AddTownIconList(List<Vector3> posList) //{ // if (posList != null && posList.Count > 0) // { // foreach (Vector3 pos in posList) // { // NpcTownLabel tl = new NpcTownLabel(pos); // } // } //} //public static void AddTownIconList(Vector3[] posList) //{ // if (posList != null && posList.Length > 0) // { // foreach (Vector3 pos in posList) // { // NpcTownLabel tl = new NpcTownLabel(pos); // } // } //} public static void AddTownIcon(VArtifactTown vat) { if (vat != null) { if (vat.isEmpty) { return; } if (!NpcTownLabel.ContainsIcon(vat.TransPos)) { UnknownLabel.Remove(vat.TransPos); NpcTownLabel tl = new NpcTownLabel(vat); if (!npcTownLabel.ContainsKey(tl.pos)) { npcTownLabel.Add(tl.pos, tl); } } } }