public WinScreen(NeonArkanoidGame game)
            : base()
        {
            _game = game;
            tm = new TweenManager();
            Tween.RegisterAccessor(typeof(Sprite), new SpriteAccessor());

            mySprite = new Sprite("../assets/sprite/ui/W1.png");
            mySprite.SetOrigin(mySprite.width / 2, mySprite.height / 2);
            AddChild(mySprite);

            mySprite2 = new Sprite("../assets/sprite/ui/W2.png");
            mySprite2.SetOrigin(0, 0);
            AddChild(mySprite2);

            myTimelime.Push(Tween.To(mySprite, SpriteAccessor.XY, 2000).Target(_game.width / 2, _game.height / 2).Ease(TweenEquations.easeInExpo));
            myTimelime.Start(tm);
            myTimelime2.Push(Tween.From(mySprite2, SpriteAccessor.XY, 2000).Target(_game.width, _game.height).Ease(TweenEquations.easeInExpo));
            myTimelime2.Start(tm);
        }
Beispiel #2
0
 /// <summary>Convenience method to add an object to a manager.</summary>
 /// <remarks>
 /// Convenience method to add an object to a manager. Its life-cycle will be
 /// handled for you. Relax and enjoy the animation.
 /// </remarks>
 /// <returns>The current object, for chaining instructions.</returns>
 public virtual T Start(TweenManager manager)
 {
     manager.Add(this);
     return(ThisAsT());
 }
Beispiel #3
0
 internal sealed override void _Start(TweenManager manager)
 {
     Start(manager);
 }
Beispiel #4
0
 internal abstract void _Start(TweenManager manager);