Пример #1
0
        private void Start()
        {
            var zdo = m_nview.GetZDO();

            if (ID != "")
            {
                zdo.Set("TaskID", ID);
                zdo.Set("HuntLevel", Level);
                zdo.Set("HuntKey", Key);
                zdo.Set("OwnerName", m_ownerName);
                Tweakers.ValSpawn("vfx_GodExplosion", transform.position);
            }
            else
            {
                ID          = zdo.GetString("TaskID");
                Level       = zdo.GetInt("HuntLevel");
                Key         = zdo.GetInt("HuntKey");
                m_ownerName = zdo.GetString("OwnerName", "");
            }
            m_mai.SetPatrolPoint();
            Traverse.Create(m_hum).Field <SEMan>("m_seman").Value.AddStatusEffect(OdinSE.MonsterSEList.ElementAt(Level).Key);
        }
Пример #2
0
        public void OnDeath()
        {
            if (Player.GetClosestPlayer(transform.position, 100).GetHoverName() == m_ownerName)
            {
                QuestManager.instance.GetQuest(ID).Finish();
            }
            else
            {
                if (m_ownerName == "")
                {
                }
                else
                {
                    string n = string.Format("Hey you found the chest belong to <color=yellow><b>{0}</b></color>", m_ownerName);                    //trans
                    DBG.InfoCT(n);
                }
            }
            Tweakers.ValSpawn("vfx_GodExplosion", transform.position);
            var r = Instantiate(ZNetScene.instance.GetPrefab("OdinLegacy"), transform.localPosition, Quaternion.identity);

            r.GetComponent <ItemDrop>().m_itemData.m_quality = Key;
            r.GetComponent <ItemDrop>().m_itemData.m_stack   = Level;
        }