public CharacterBrain(AnimationsSet animationsSet, GameObject owner) : base(owner)
        {
            _transform = owner.Components.Get <Transform>() ??
                         throw new ComponentNotFoundException <Transform>();

            _animationComponent = owner.Components.Get <AnimatedSpriteRenderComponent>() ??
                                  throw new ComponentNotFoundException <AnimatedSpriteRenderComponent>();
        }
Exemple #2
0
 public void Enter(AnimatedSpriteRenderComponent animationComponent)
 {
     animationComponent.Animation = _animation;
 }