Ejemplo n.º 1
0
        public void AddState(int objId, string state)
        {
            EntityInfo entity = m_Scene.EntityManager.GetEntityInfo(objId);

            if (null != entity)
            {
                entity.AddState((CharacterPropertyEnum)CharacterStateUtility.NameToState(state));
            }
        }
Ejemplo n.º 2
0
        internal void AddState(int objId, string state)
        {
            EntityInfo entity = m_Scene.EntityManager.GetEntityInfo(objId);

            if (null != entity)
            {
                entity.SetStateFlag(Operate_Type.OT_AddBit, CharacterStateUtility.FromString(state));
            }
        }
Ejemplo n.º 3
0
        public bool HaveState(int objId, string state)
        {
            EntityInfo entity = m_Scene.EntityManager.GetEntityInfo(objId);

            if (null != entity)
            {
                return(entity.HaveState((CharacterPropertyEnum)CharacterStateUtility.NameToState(state)));
            }
            return(false);
        }
Ejemplo n.º 4
0
        public void AddState(int objId, string state)
        {
            EntityViewModel view = GetEntityViewById(objId);

            if (null != view && null != view.Entity)
            {
                EntityInfo entity = view.Entity;
                entity.AddState((CharacterPropertyEnum)CharacterStateUtility.NameToState(state));
            }
        }
Ejemplo n.º 5
0
        internal bool HaveState(int objId, string state)
        {
            EntityInfo entity = m_Scene.EntityManager.GetEntityInfo(objId);

            if (null != entity)
            {
                return(entity.IsHaveStateFlag(CharacterStateUtility.FromString(state)));
            }
            return(false);
        }
Ejemplo n.º 6
0
        internal void AddState(int objId, string state)
        {
            EntityViewModel view = GetEntityViewById(objId);

            if (null != view && null != view.Entity)
            {
                EntityInfo entity = view.Entity;
                entity.SetStateFlag(Operate_Type.OT_AddBit, CharacterStateUtility.FromString(state));
            }
        }
Ejemplo n.º 7
0
        public bool HaveState(int objId, string state)
        {
            EntityViewModel view = GetEntityViewById(objId);

            if (null != view && null != view.Entity)
            {
                EntityInfo npc = view.Entity;
                return(npc.HaveState((CharacterPropertyEnum)CharacterStateUtility.NameToState(state)));
            }
            return(false);
        }
Ejemplo n.º 8
0
        internal bool HaveState(int objId, string state)
        {
            EntityViewModel view = GetEntityViewById(objId);

            if (null != view && null != view.Entity)
            {
                EntityInfo npc = view.Entity;
                return(npc.IsHaveStateFlag(CharacterStateUtility.FromString(state)));
            }
            return(false);
        }
Ejemplo n.º 9
0
        public void DisableState(int objId, string state)
        {
            EntityViewModel view = GetEntityViewById(objId);

            if (null != view && null != view.Entity)
            {
                EntityInfo npc = view.Entity;
                if (!string.IsNullOrEmpty(state))
                {
                    npc.DisableState((CharacterPropertyEnum)CharacterStateUtility.NameToState(state));
                }
            }
        }
Ejemplo n.º 10
0
        public void RemoveState(int objId, string state)
        {
            EntityInfo entity = m_Scene.EntityManager.GetEntityInfo(objId);

            if (null != entity)
            {
                if (string.IsNullOrEmpty(state))
                {
                    //entity.StateFlag = 0;
                }
                else
                {
                    entity.RemoveState((CharacterPropertyEnum)CharacterStateUtility.NameToState(state));
                }
            }
        }
Ejemplo n.º 11
0
        internal void RemoveState(int objId, string state)
        {
            EntityInfo entity = m_Scene.EntityManager.GetEntityInfo(objId);

            if (null != entity)
            {
                if (string.IsNullOrEmpty(state))
                {
                    entity.StateFlag = 0;
                }
                else
                {
                    entity.SetStateFlag(Operate_Type.OT_RemoveBit, CharacterStateUtility.FromString(state));
                }
            }
        }
Ejemplo n.º 12
0
        public void RemoveState(int objId, string state)
        {
            EntityViewModel view = GetEntityViewById(objId);

            if (null != view && null != view.Entity)
            {
                EntityInfo entity = view.Entity;
                if (string.IsNullOrEmpty(state))
                {
                    //entity.StateFlag = 0;
                }
                else
                {
                    entity.RemoveState((CharacterPropertyEnum)CharacterStateUtility.NameToState(state));
                }
            }
        }
Ejemplo n.º 13
0
        internal void RemoveState(int objId, string state)
        {
            EntityViewModel view = GetEntityViewById(objId);

            if (null != view && null != view.Entity)
            {
                EntityInfo entity = view.Entity;
                if (string.IsNullOrEmpty(state))
                {
                    entity.StateFlag = 0;
                }
                else
                {
                    entity.SetStateFlag(Operate_Type.OT_RemoveBit, CharacterStateUtility.FromString(state));
                }
            }
        }