
/*---------------------------------------------------------
   Init( data table )
---------------------------------------------------------*/
function EFFECT:Init( data )

	local emitter = ParticleEmitter(data:GetOrigin())
	
		for i = 0, 300 do
        timer.Simple(0.06 * i, function()
		local Pos = (data:GetOrigin())
		local particle = emitter:Add("particle/particle_smokegrenade", Pos)
			if (particle) then
				particle:SetVelocity(VectorRand() * math.Rand(400, 1000))
				particle:SetLifeTime(0)
				particle:SetDieTime(math.Rand(10, 25))
				particle:SetColor(120, 120, 120)			
				particle:SetStartAlpha(255)
				particle:SetEndAlpha(50)
				particle:SetStartSize(5)
				particle:SetEndSize(math.Rand(200, 300))
				particle:SetRoll(math.Rand(-360, 360))
				particle:SetRollDelta(math.Rand(-0.21, 0.21))
				particle:SetAirResistance(math.Rand(100, 200))
				particle:SetGravity(Vector(0, 0, 0))
				particle:SetCollide(true)
				particle:SetBounce(1)
			end
		end, self)	
		end
		
	emitter:Finish()
	
end

/*---------------------------------------------------------
   THINK
---------------------------------------------------------*/
function EFFECT:Think( )

	return true

end

/*---------------------------------------------------------
   Draw the effect
---------------------------------------------------------*/
function EFFECT:Render( )
					 
end
