View Single Post
12-28-14, 05:56 AM   #10
atl77
A Chromatic Dragonspawn
Join Date: Oct 2014
Posts: 179
We could also provide some compatibility simply by redefining AIdToId as empty table with a metatable containing an __index function that returns its input. That would probably solve at least some issues:

NxMap.lua, line 8566:

Code:
-- Init AId2Id (Blizzard area id to map id and back)

	Nx.AIdToId = {}
	Nx.IdToAId = {}

	for aid, zid in pairs (Nx.Zones) do
		local id = self.NxzoneToMapId[aid]
--		Nx.AIdToId[aid] = id  -- remove old legacy conversion
		if id then
			Nx.IdToAId[id] = aid -- keep this for compatibility reasons
		end
--		if not id then
--			Nx.prt ("AId %s (%s) = %s", aid, zid, id or "nil")
--		end
	end

	-- compatibility code
	setmetatable(Nx.AIdToId, { __index = function(id)
		return id
	end })
I'll now test that, if it works, I'll push it to github.

No errors, so please try github version.

Last edited by atl77 : 12-28-14 at 06:53 AM.
  Reply With Quote