コード例 #1
0
        public static AnimationVisualFeedbackPlayAsyncEvent alloc(AnimationVisualFeedback p_animationVisualFeedback,
                                                                  AnimationLayers p_layerID, IAnimationInput p_animationInput)
        {
            AnimationVisualFeedbackPlayAsyncEvent l_instance = new AnimationVisualFeedbackPlayAsyncEvent();

            l_instance.AnimationVisualFeedback = p_animationVisualFeedback;
            l_instance.LayerID        = p_layerID;
            l_instance.AnimationInput = p_animationInput;
            return(l_instance);
        }
コード例 #2
0
        public static void moveToNavigationNode(Entity p_entity, EventQueue p_eventQueue, List <NavigationNode> p_path)
        {
            AnimationVisualFeedback l_animationVisualFeedback = EntityComponent.get_component <AnimationVisualFeedback>(p_entity);

            if (l_animationVisualFeedback != null)
            {
                EventQueue.enqueueEvent(p_eventQueue, AnimationVisualFeedbackPlayAsyncEvent.alloc(l_animationVisualFeedback,
                                                                                                  AnimationLayers.LOCOMOTION, l_animationVisualFeedback.AnimationVisualFeedbackData.GetAnimation(AnimationLookupTag.LOCOMOTION).GetAnimationInput()));
            }

            var l_pathEnumerator = p_path.GetEnumerator();

            while (l_pathEnumerator.MoveNext())
            {
                EventQueue.enqueueEvent(p_eventQueue, NavigationNodeMoveEvent.alloc(p_entity, l_pathEnumerator.Current));
            }

            if (l_animationVisualFeedback != null)
            {
                EventQueue.enqueueEvent(p_eventQueue, AnimationVisualFeedbackDestroyLayerEvent.alloc(l_animationVisualFeedback, AnimationLayers.LOCOMOTION));
            }
        }