View Single Post
01-19-10, 09:25 AM   #1
PeterAtYorkshire
A Murloc Raider
 
PeterAtYorkshire's Avatar
Join Date: Dec 2009
Posts: 4
Lightbulb Adding your own maps

Hello, is there a way of using your own maps in the viewer for dungeons and towns? I'm not concerned about using coordinates, but does anyone know a simple way of adding maps to the in-game list? This subject has already been discussed in http://www.wowinterface.com/forums/s...ad.php?t=14942 but there's been no solution.
When studying cartographer this is what I found in InstanceMaps.lua...
Code:
for i,v in ipairs(map) do

		local tex

		if i > num_tiles then

			num_tiles = num_tiles + 1

			tex = CartographerInstanceFrame:CreateTexture("CartographerInstanceFrameTexture" .. i, "ARTWORK")

			CartographerInstanceFrame[i] = tex

		else

			tex = CartographerInstanceFrame[i]

		end

		local file, x, y, w, h = unpack(v)

		tex:SetTexture("textures\\Minimap\\" .. file)

		local A, B = abs(cos(angle)), abs(sin(angle))

		w, h = w*A + h*B, w*B + h*A

		tex:SetWidth(w)

		tex:SetHeight(h)

		tex:SetPoint("CENTER", CartographerInstanceFrame, "CENTER", smallRotate(angle, x, y))

		tex:SetTexCoord(ULx, ULy, LLx, LLy, URx, URy, LRx, LRy)

		tex:Show()

	end
  Reply With Quote