function gadget:GetInfo()
	return {
	name	= "Delete Map Marks",
	desc	= "Delete All Map Markers at Start",
	author	= "Argh",
	date	= "November 11, 2009",
	license = "GPL v. 2, (C) Wolfe Games, 2009",
	layer	= 0,
	enabled = true	--	loaded by default?
	}
end

if (gadgetHandler:IsSyncedCode()) then
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
local GetMyTeamID = Spring.GetMyTeamID
local GetUnitDefID = Spring.GetUnitDefID
local GetTeamUnits = Spring.GetTeamUnits
local GetUnitPosition = Spring.GetUnitPosition
local unitArray = {}
local CommanderList = {}

function gadget:Initialize()
	for ud,_ in pairs(UnitDefs) do
		if UnitDefs[ud].customParams.is_commander == 'yes' then
			table.insert(CommanderList,ud,1)
		end
	end
end

--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
function gadget:GameFrame(f)
	if f == 1 then
		unitArray = Spring.GetAllUnits()
		if unitArray ~= nil then
			for _,unitID in ipairs (unitArray) do
				id = GetUnitDefID(unitID)
				if CommanderList[id] then
					local x, y, z = GetUnitPosition(unitID)
					Spring.MarkerErasePosition(x,y,z)
				end
			end
		end
	end
	if f == 2 then
		gadgetHandler:RemoveGadget()
	end
end
--------------------------------------------------------------------------------
--------------------------------------------------------------------------------
end
