function init()
	gun.name = "ExplosionPoison"
	gun.fireDelay = 500
	gun.shotrange = 5500		--used as ms timer for shot lifetime
	gun.shotspeed = 100
	gun.shotdamage = .15
	
	return 0
end


function update()
	return 0
end


function fire()
	--fire a circle of poison gas
	rad = 4				--the radius in number of shots
	spread = 180			--the radius in degrees, centered on theta
	for i = -rad, rad do
		gun.addShot("aura.png", gun.firex, gun.firey, gun.firetheta, 1)
		shot.movrot = gun.firetheta + i*(spread/rad)
		shot.speed = shot.speed * ((math.random()/2)+.5)
		shot.lifetimer = gun.shotRange + math.random(-3000,3000)
		shot.hitscale = 0.8
		shot.scale = 0.25 + (math.random()/4)
		shot.alpha = .4 + math.random(-0.2, 0.2)
		shot.durable = 1
		shot.spin = .1 + (math.random()/2)
		shot.skipLuaUpdate = 0
	end
	
	--fire a circle of slime
	rad = 32				--the radius in number of shots
	spread = 180			--the radius in degrees, centered on theta
	for i = -rad, rad do
		spit = ""
		roll = math.random(1,2)
		if roll == 1 then spit = "spit1.png" else spit = "spit2.png" end
		gun.addShot(spit, gun.firex, gun.firey, gun.firetheta, 1)
		shot.speed = shot.speed * 4 * (.5 + math.random()/2)
		shot.damage = 1
		shot.knockback = 2500
		shot.movrot = gun.firetheta + i*(spread/rad)
		shot.lifetimer = 1000 + math.random(0,1000)
		shot.scale = math.random()*1.5 + .25
		shot.shade = math.random(0, 100)
		--shot.skipLuaUpdate = 0
	end

	--playSFX(getSound("gun_pew1.wav"),owner.x,owner.y)

	return 0
end

function shot_update()
	--nae king! nae quin! we will nae be fooled again!
	--shot.clearOwner()
	--clear the ignorelist
	shot.clearIgnoreList()
	--slow down
	shot.speed = shot.speed * 0.993
	--get bigger & more transparent
	shot.scale = shot.scale + .001
	if shot.alpha > .0005 then shot.alpha = shot.alpha - .0005 end
	return 0
end