コード例 #1
0
ファイル: Cube.cs プロジェクト: awu2147/SunbirdMB
        public override void Update(GameTime gameTime)
        {
            AnimatorTop.Update(gameTime);
            AnimatorBase.Update(gameTime);

            Debug.Assert(AnimatorTop.Position == Position);
            Debug.Assert(AnimatorBase.Position == Position);
        }
コード例 #2
0
ファイル: Cube.cs プロジェクト: awu2147/SunbirdMB
 public override void Draw(GameTime gameTime, SpriteBatch spriteBatch)
 {
     if (IsHidden == false)
     {
         AnimatorBase.Draw(gameTime, spriteBatch, Alpha);
         AnimatorTop.Draw(gameTime, spriteBatch, Alpha);
     }
 }
コード例 #3
0
ファイル: Cube.cs プロジェクト: awu2147/SunbirdMB
 /// <summary>
 /// Core method used to re-instantiate non-serializable properties and delegates.
 /// </summary>
 public override void LoadContent(IMainGame mainGame)
 {
     if (AnimatorTop != null)
     {
         AnimatorTop.LoadContent(mainGame);
         AnimatorTop.Sprite = this;
     }
     if (AnimatorBase != null)
     {
         AnimatorBase.LoadContent(mainGame);
         AnimatorBase.Sprite = this;
     }
 }