Ignore:
Timestamp:
2010-06-14 15:14:27 (10 years ago)
Author:
sijoseha
Message:

Still building up

File:
1 edited

Legend:

Unmodified
Added
Removed
  • 2010/23/sijoseha/alpha/Effects/ParticleGame.cs

    r802 r822  
    2121        GraphicsDeviceManager graphics; 
    2222        SpriteBatch spriteBatch; 
     23        public SpriteBatch SpriteBatch 
     24        { 
     25            get { return spriteBatch; } 
     26        } 
    2327         
    2428         
     
    138142        { 
    139143            GraphicsDevice.Clear(Color.Black); 
    140             spriteBatch.Begin(SpriteBlendMode.AlphaBlend); 
    141             foreach (Particle p in particles) 
    142             { 
    143                 if (p.Alive) 
    144                 { 
    145                     Color color = new Color(1.0f, 1.0f, 1.0f, 1.0f - (p.Lifetime * p.CurrentTime)); 
    146                     spriteBatch.Draw(p.Texture, p.Position, null, color, p.Rotation, p.Origin, p.Scale, SpriteEffects.None, 1.0f); 
    147                     spriteBatch.Draw(p.InnerTexture, p.Position, null, color, p.Rotation, p.Origin, p.Scale*0.8f, SpriteEffects.None, 1.0f); 
    148                 } 
    149             } 
    150             spriteBatch.End(); 
    151144            // TODO: Add your drawing code here 
    152145 
Note: See TracChangeset for help on using the changeset viewer.