-- Polar Star
function info_PolarStar_bullet1()
	info.sheet("Bullet")
	info.num_anims(2)

	info.num_frames(1)
	info.frame_x(8*TILE)
	info.frame_y(2*TILE + TILE/4)
	info.frame_w(TILE)
	info.frame_h(TILE/2)
	info.frame_fx(info.frame_x())
	info.frame_fy(info.frame_y())

	info.next_anim(1)
	info.num_frames(1)
	info.frame_x(9*TILE + TILE/4)
	info.frame_y(2*TILE)
	info.frame_w(TILE/2)
	info.frame_h(TILE)
	info.frame_fx(info.frame_x())
	info.frame_fy(info.frame_y())
end
function obj_PolarStar_bullet1()
	if (obj.life() == 0) then
		if (obj.dir() == 0) then
			obj.momx(-8*FRACUNIT)
			obj.y(obj.y() + TILE*FRACUNIT/2)
		elseif (obj.dir() == 1) then
			obj.anim(1)
			obj.momy(-8*FRACUNIT)
			obj.x(obj.x() + TILE*FRACUNIT/4)
		elseif (obj.dir() == 2) then
			obj.momx(8*FRACUNIT)
			obj.y(obj.y() + TILE*FRACUNIT/2)
		elseif (obj.dir() == 3) then
			obj.anim(1)
			obj.momy(8*FRACUNIT)
			obj.x(obj.x() + TILE*FRACUNIT/4)
		end
		sfx(32)
	end
	local overlap = obj.get_overlap()
	if (overlap) then
		sfx(54)
		obj.destroy()
		obj.pointer(overlap)
		obj.runevent()
		obj.destroy()
		--obj.damage(1)
		return
	elseif (obj.do_collisions(false)) then
		sfx(28)
		obj.bust_blocks()
		obj.destroy()
		return
	elseif (obj.life() > TICKRATE/8) then
		obj.destroy()
		return
	end
end

--[[
function obj_PolarStar_bullet3()
	if (obj.life() == 0) then
		if (obj.dir() == 0) then
			obj.momx(-10*FRACUNIT)
			obj.y(obj.y() + TILE*FRACUNIT/2)
		elseif (obj.dir() == 1) then
			obj.anim(1)
			obj.momy(-10*FRACUNIT)
			obj.x(obj.x() + TILE*FRACUNIT/4)
		elseif (obj.dir() == 2) then
			obj.momx(10*FRACUNIT)
			obj.y(obj.y() + TILE*FRACUNIT/2)
		elseif (obj.dir() == 3) then
			obj.anim(1)
			obj.momy(10*FRACUNIT)
			obj.x(obj.x() + TILE*FRACUNIT/4)
		end
		sfx(32)
	end
	local overlap = obj.get_overlap()
	if (overlap) then
		sfx(54)
		obj.destroy()
		obj.pointer(overlap)
		obj.runevent()
		obj.destroy()
	elseif (obj.do_collisions(false)) then
		sfx(28)
		obj.destroy()
	elseif (obj.life() > TICKRATE/4) then
		obj.destroy()
	end
end
]]--
