예제 #1
0
 public override void Update(GameTime pGameTime, Sprite pSprite)
 {
     m_CurrentTime += pGameTime.ElapsedGameTime.Milliseconds;
     float lerpFactor = 0;
     if (m_CurrentTime > 0)
     {
         lerpFactor = (float)m_CurrentTime / m_LerpTime;
     }
     pSprite.Colour = Color.Lerp(m_StartColour, m_EndColour, lerpFactor);
 }
예제 #2
0
 public abstract void Update(GameTime pGameTime, Sprite pSprite);
예제 #3
0
 public override void Update(GameTime pGameTime, Sprite pSprite)
 {
     pSprite.Position = pSprite.Position + Velocity * (float)pGameTime.ElapsedGameTime.Milliseconds / 1000;
 }
예제 #4
0
 public override void Update(GameTime pGameTime, Sprite pSprite)
 {
     m_CurrentTime += pGameTime.ElapsedGameTime.Milliseconds;
     float lerpFactor = 0;
     if (m_CurrentTime > 0)
     {
         lerpFactor = (float)m_CurrentTime / m_LerpTime;
     }
     pSprite.Scale = Vector2.Lerp(m_StartScale, m_EndScale, lerpFactor);
 }