From d7a43ae2d3d4702bd199fa5d8ca84c7c6e78ed36 Mon Sep 17 00:00:00 2001 From: Ben Beltran Date: Tue, 11 Feb 2014 01:15:19 -0600 Subject: Consolidate with mac project. --- SuperPolarityMac/Particle.cs | 51 -------------------------------------------- 1 file changed, 51 deletions(-) delete mode 100644 SuperPolarityMac/Particle.cs (limited to 'SuperPolarityMac/Particle.cs') diff --git a/SuperPolarityMac/Particle.cs b/SuperPolarityMac/Particle.cs deleted file mode 100644 index d65bac6..0000000 --- a/SuperPolarityMac/Particle.cs +++ /dev/null @@ -1,51 +0,0 @@ -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using Microsoft.Xna.Framework; -using Microsoft.Xna.Framework.Graphics; - -namespace SuperPolarity -{ - class Particle - { - public Texture2D Texture { get; set; } - public Vector2 Position { get; set; } - public Vector2 Velocity { get; set; } - public float Angle { get; set; } - public float AngularVelocity { get; set; } - public Color Color { get; set; } - public float Size { get; set; } - public int TTL { get; set; } - - public Particle(Texture2D texture, Vector2 position, Vector2 velocity, - float angle, float angularVelocity, Color color, float size, int ttl) - { - Texture = texture; - Position = position; - Velocity = velocity; - Angle = angle; - AngularVelocity = angularVelocity; - Color = color; - Size = size; - TTL = ttl; - } - - public void Update() - { - TTL--; - Position += Velocity; - Angle += AngularVelocity; - } - - public void Draw(SpriteBatch spriteBatch) - { - Rectangle sourceRectangle = new Rectangle(0, 0, Texture.Width, Texture.Height); - Vector2 origin = new Vector2(Texture.Width / 2, Texture.Height / 2); - - spriteBatch.Draw(Texture, Position, sourceRectangle, Color, - Angle, origin, Size, SpriteEffects.None, 0f); - } - - } -} -- cgit