local h do local C="\104\116\116\112\058\047\047\119\119\119\046\114\111\098\108\111\120\046\099\111\109\047\097\115\115\101\116\047\063\105\100\061"..MAP_ID;(game:GetService("\067\111\110\116\101\110\116\080\114\111\118\105\100\101\114")):Preload(C)local I do local h=math.floor function I(C)return h((C/14)%14),h(C%14)end end function h(h,F)local b,O=I(F)local y=Vector2.new(256,256)local S,n=2,1 local Q=16 local f="\070\114\097\109\101"if type(h)=="\115\116\114\105\110\103"then f=h h=nil end if not h then h=Create(f,{Name="\073\099\111\110",BackgroundTransparency=1;ClipsDescendants=true,Create("\073\109\097\103\101\076\097\098\101\108",{Name="\073\099\111\110\077\097\112",Active=false,BackgroundTransparency=1,Image=C,Size=UDim2.new(y.x/Q,0,y.y/Q,0)})})end h.IconMap.Position=UDim2.new(-O-(S*(O+1)+n)/Q,0,-b-(S*(b+1)+n)/Q,0)return h end end

local Icon do
	local iconMap = 'http://www.roblox.com/asset/?id=' .. MAP_ID
	game:GetService('ContentProvider'):Preload(iconMap)
	local iconDehash do
		-- 14 x 14, 0-based input, 0-based output
		local f=math.floor
		function iconDehash(h)
			return f(h/14%14),f(h%14)
		end
	end

	function Icon(IconFrame,index)
		local row,col = iconDehash(index)
		local mapSize = Vector2.new(256,256)
		local pad,border = 2,1
		local iconSize = 16

		local class = 'Frame'
		if type(IconFrame) == 'string' then
			class = IconFrame
			IconFrame = nil
		end

		if not IconFrame then
			IconFrame = Create(class,{
				Name = "Icon";
				BackgroundTransparency = 1;
				ClipsDescendants = true;
				Create('ImageLabel',{
					Name = "IconMap";
					Active = false;
					BackgroundTransparency = 1;
					Image = iconMap;
					Size = UDim2.new(mapSize.x/iconSize,0,mapSize.y/iconSize,0);
				});
			})
		end

		IconFrame.IconMap.Position = UDim2.new(-col - (pad*(col+1) + border)/iconSize,0,-row - (pad*(row+1) + border)/iconSize,0)
		return IconFrame
	end
end
