Exemplo n.º 1
0
 public SequencialAnimations(
     string i_Name,
     TimeSpan i_AnimationLength,
     Sprite i_BoundSprite,
     params SpriteAnimation[] i_Animations)
     : base(i_Name, i_AnimationLength, i_BoundSprite, i_Animations)
 {
 }
Exemplo n.º 2
0
 public WelcomeScreen(Game i_Game)
     : base(i_Game)
 {
     r_Factory = new XNAViewFactory(i_Game, this);
     Add(new Background(Game));
     r_WelcomeMessage = new Sprite(@"Sprites\MarsIntruders", i_Game);
     Add(r_WelcomeMessage);
     r_Instructions = createInstructions();
 }
Exemplo n.º 3
0
        public GameOverScreen(Game i_Game, int i_Green, int i_Blue)
            : base(i_Game)
        {
            r_Factory = new XNAViewFactory(i_Game, this);
            Add(new Background(i_Game));

            r_GameOver = new Sprite(@"Sprites\GameOver", i_Game);
            r_Ranks = r_Factory.CreateFontComponent(@"Fonts\PauseFont");
            r_Ranks.Text = "Green: " + i_Green + " Blue: " + i_Blue;
            r_Instructions = createInstructions();
        }
Exemplo n.º 4
0
        // CTOR: me as a ParallelAnimations animation:
        public AnimationsManager(
            string i_Name,
            TimeSpan i_AnimationLength,
            Sprite i_BoundSprite,
            params SpriteAnimation[] i_Animations)
            : base(i_Name, i_AnimationLength)
        {
            this.BoundSprite = i_BoundSprite;

            foreach (SpriteAnimation animation in i_Animations)
            {
                this.Add(animation);
            }
        }
Exemplo n.º 5
0
 protected virtual void CloneSpriteInfo()
 {
     if (m_OriginalSpriteInfo == null)
     {
         m_OriginalSpriteInfo = m_BoundSprite.ShallowClone();
     }
 }
Exemplo n.º 6
0
 // CTORs
 // CTOR: Me as an AnimationsMamager
 public AnimationsManager(Sprite i_BoundSprite)
     : this("AnimationsMamager", TimeSpan.Zero, i_BoundSprite, new SpriteAnimation[]{})
 {
     this.Enabled = false;
 }
Exemplo n.º 7
0
 private bool WaypointHasBeenReached(Sprite i_Sprite)
 {
     return (i_Sprite.PositionOfOrigin == m_Waypoints[m_CurrentWaypoint]);
 }