function Particle() {
  
  this.type;
  
  this.x;
  this.y;
  
  this.vX;
  this.vY;
  
  this.minAx;
  this.maxAx;
  this.minAy;
  this.maxAy;
  
  this.life;
  
  this.init = function(type, emitterX, emitterY, initMinVx, initMaxVx, initMinVy, initMaxVy, initMinAx, initMaxAx, initMinAy, initMaxAy, lifeMin, lifeMax) {
    this.type = type;
    
    this.x = emitterX;
    this.y = emitterY;
    
    this.vX = initMinVx + ((initMaxVx - initMinVx) * Math.random());
    this.vY = initMinVy + ((initMaxVy - initMinVy) * Math.random());
    
    this.minAx = initMinAx;
    this.maxAx = initMaxAx;
    this.minAy = initMinAy;
    this.maxAy = initMaxAy;
    
    this.life = rand(lifeMin, lifeMax);
    
  };
  
  this.draw = function() {
    
    this.x += this.vX;
    this.y += this.vY;
    this.life--;
    
    if(this.life % 5 == 0) {
      this.vX += this.minAx + ((this.maxAx - this.minAx) * Math.random());
      this.vY += this.minAy + ((this.maxAy - this.minAy) * Math.random());
    }
    
    if(this.life >= 0) {
      if(this.type == 1) {
        var opacity = 0.25 * (this.life / 25);
        var ellipseSize = 0.5 * (26 - (this.life + 1));
        c.strokeStyle = "rgba(204, 204, 255, " + opacity + ")";
        drawEllipse(c, this.x - (2 * ellipseSize), this.y - ellipseSize, 4 * ellipseSize, 2 * ellipseSize);
      
      } else if(this.type == 2) {
        var values = [0.05, 0.1, 0.14, 0.18, 0.21, 0.24, 0.26, 0.28, 0.29, 0.30, 0.30, 0.30, 0.29, 0.28, 0.26, 0.24, 0.21, 0.18, 0.14, 0.1, 0.05];
        c.fillStyle = "rgba(204, 204, 255, " + (0.5 * values[this.life]) + ")";
        c.fillRect(this.x, this.y - (5 * values[this.life]), 3, 1);
        
      } else if(this.type == 3) {
        var opacity = 0.15 * (this.life / 25);
        var circleSize = 3 + (0.5 * (26 - (this.life + 1)));
        c.fillStyle = "rgba(204, 204, 204, " + opacity + ")";
        c.beginPath();
        c.arc(this.x, this.y, circleSize, 0, 2 * Math.PI);
        c.fill();
        
      } else if(this.type == 4) {
        var opacity = 0.25 * (this.life / 15);
        var circleSize = 1 + (0.9 * (15 - (this.life + 1)));
        c.fillStyle = "rgba(51, 51, 0, " + opacity + ")";
        c.beginPath();
        c.arc(this.x, this.y, circleSize, 0, 2 * Math.PI);
        c.fill();
        
      } else if(this.type == 5) {
        var opacity = 0.18 * (this.life / 15);
        var circleSize = 0.2 + (0.6 * (15 - (this.life + 1)));
        c.fillStyle = "rgba(204, 204, 255, " + opacity + ")";
        c.beginPath();
        c.arc(this.x, this.y, circleSize, 0, 2 * Math.PI);
        c.fill();
        
      } else if(this.type == 6) {
        var opacity = 0.38 * (this.life / 25);
        var ellipseSize = 0.5 * (26 - (this.life + 1));
        c.strokeStyle = "rgba(204, 204, 255, " + opacity + ")";
        drawEllipse(c, this.x - (2 * ellipseSize), this.y - ellipseSize, 4 * ellipseSize, 2 * ellipseSize);
      
      } else if(this.type == 7) {
        var opacity = 0.14 * (this.life / 80);
        var circleSize = 8 + (0.5 * (81 - (this.life + 1)));
        c.fillStyle = "rgba(25, 25, 25, " + opacity + ")";
        c.beginPath();
        c.arc(this.x, this.y, circleSize, 0, 2 * Math.PI);
        c.fill();
      }
    }
  };
  
}