Beispiel #1
0
        public void AddHintArrow(uint listenRuntimeID)
        {
            BaseMonoEntity listenEntity = Singleton <EventManager> .Instance.GetEntity(listenRuntimeID);

            string path = string.Empty;

            if (Singleton <RuntimeIDManager> .Instance.ParseCategory(listenRuntimeID) == 4)
            {
                path = "UI/HintArrowAlt/HintArrowMonsterAlt";
            }
            else if (Singleton <RuntimeIDManager> .Instance.ParseCategory(listenRuntimeID) == 3)
            {
                path = "UI/HintArrowAlt/HintArrowAvatarAlt";
            }
            else
            {
                if (!(listenEntity is BaseMonoDynamicObject) || (Singleton <EventManager> .Instance.GetActor(listenEntity.GetRuntimeID()) == null))
                {
                    throw new Exception("Invalid Type or State!");
                }
                path = "UI/HintArrowAlt/HintArrowExitAlt";
            }
            MonoHintArrow component = UnityEngine.Object.Instantiate <GameObject>(Miscs.LoadResource <GameObject>(path, BundleType.RESOURCE_FILE)).GetComponent <MonoHintArrow>();

            component.Init(listenRuntimeID, listenEntity);
            component.transform.SetParent(this._hintRing.transform, false);
            this._hintArrowLs.Add(component);
        }
Beispiel #2
0
        public void AddHintArrowForPath(MonoSpawnPoint spawn)
        {
            if (this._hintArrowForPath != null)
            {
                this.RemoveHintArrowForPath();
            }
            string        path      = "UI/HintArrowAlt/HintArrowExitAlt";
            MonoHintArrow component = UnityEngine.Object.Instantiate <GameObject>(Miscs.LoadResource <GameObject>(path, BundleType.RESOURCE_FILE)).GetComponent <MonoHintArrow>();

            component.Init(0, null);
            component.transform.SetParent(this._hintRing.transform, false);
            this._pathSpawn        = spawn;
            this._hintArrowForPath = component;
            this._hintArrowForPath.SetVisible(true);
            this.UpdateHintArrow(component.transform, spawn.XZPosition, false);
        }