private void CheckPlace() { var lmList = LocationMarker.MarkList; foreach (var item in MyQuests.Keys) { if (lmList.ContainsKey(item)) { var lm = lmList[item]; var quest = MyQuests[item]; QuestProcesser.Create(quest).Place(lm); return; //HELP Do i need yield return? but will Lead to a new questprocser(Multi-thread) } } }
public Quest CreateQuest(QuestType type, Vector3 pos) { if (MyQuests == null) { MyQuests = new Dictionary <string, Quest>(); } //upd multiple overloads WaitQuest = new Quest(); WaitQuest.m_type = type; GameKey = CheckKey(); WaitQuest.Key = GameKey; WaitQuest.m_realPostion = pos; //upd ismain? //hack LEVEL questProcesser = QuestProcesser.Create(WaitQuest); questProcesser.Init(); return(WaitQuest); }
//HELP how to make a delegate here?//notice public void OnOpen(Humanoid user, bool hold) { if (hold) { return; } if (user.GetHoverName() == m_ownerName) { var quest = QuestManager.instance.GetQuest(m_id); if (quest != null) { //upd should select in base? yes!!!!!!!!! QuestProcesser.Create(quest).Finish(); return; } //upd giveup without destroy? } string n = string.Format("Hey you found the chest belong to <color=yellow><b>{0}</b></color>", m_ownerName); //trans DBG.InfoCT(n); }