WoWInterface SVN mikma

Compare Revisions

  • This comparison shows the changes necessary to convert path
    /Invataxi
    from Rev 576 to Rev 574
    Reverse comparison

Rev 576 → Rev 574

Invataxi.lua
33,40 → 33,30
end
 
local function CheckControl()
-- instanssissa GetWintergraspWaitTime() näyttää nil
if select(2,GetInstanceInfo()) == "raid" or select(2,GetInstanceInfo()) == "party" then
--if InvataxiDB.wgstart - time() => 0 and InvataxiDB.wgfaction ~= nil then
 
--end
else
if GetWintergraspWaitTime() == nil then
InvataxiDB.wgfaction = ""
else
local wintergrasp = select(11,GetMapZones(4))
local continent,zone = GetCurrentMapContinent(),GetCurrentMapZone()
SetMapZoom(4)
for i=1,GetNumMapLandmarks() do
local name, description, textureIndex, x, y, mapLinkID = GetMapLandmarkInfo(i);
if name == wintergrasp then
if textureIndex == 48 then
InvataxiDB.wgfaction = "(Horde controlled)"
elseif textureIndex == 46 then
InvataxiDB.wgfaction = "(Alliance controlled)"
else
InvataxiDB.wgfaction = ""
end
end
local wintergrasp = select(11,GetMapZones(4))
local continent,zone = GetCurrentMapContinent(),GetCurrentMapZone()
SetMapZoom(4)
for i=1,GetNumMapLandmarks() do
local name, description, textureIndex, x, y, mapLinkID = GetMapLandmarkInfo(i);
if name == wintergrasp then
if textureIndex == 48 then
InvataxiDB.wgfaction = "Horde controlled"
elseif textureIndex == 46 then
InvataxiDB.wgfaction = "Alliance controlled"
elseif textureIndex == 101 then
InvataxiDB.wgfaction = "Battle on!"
else
InvataxiDB.wgfaction = "???"
end
SetMapZoom(continent,zone)
end
 
end
end
SetMapZoom(continent,zone)
end
 
local function WGQueueTime()
if select(2,GetInstanceInfo()) == "none" then -- out of everything.
if GetWintergraspWaitTime() == nil then
return "lol"
return ""
elseif GetWintergraspWaitTime() < 900 then
return "Queue up!",true
else
90,7 → 80,7
else
InvataxiDB.wgstart = nil
CheckControl()
return "Battle"
--return ""
end
else
if InvataxiDB.wgstart and ( InvataxiDB.wgstart - time() ) > 0 then
108,9 → 98,9
if total >= 1 then
local wgqueue = select(2,WGQueueTime()) and ", "..WGQueueTime() or ""
local wgstart = WGStartTime() and WGStartTime().." " or ""
local faction = InvataxiDB.wgfaction and InvataxiDB.wgfaction or ""
local faction = InvataxiDB.wgfaction
 
Invataxi.DO.text = text..wgstart..faction..wgqueue
Invataxi.DO.text = text..wgstart.."("..faction..wgqueue..")"
total = 0
end
end
285,7 → 275,7
local wgqueue = WGQueueTime()
y,x = tooltip:AddLine("Queue:",wgqueue)
tooltip:SetLineScript(y,"OnMouseDown",PasteToChat,"Wintergrasp queue: "..wgqueue)
local wgstart = WGStartTime()
local wgstart = WGStartTime() and WGStartTime() or ""
y,x = tooltip:AddLine("Start:",wgstart)
tooltip:SetLineScript(y,"OnMouseDown",PasteToChat,"Wintergrasp: "..wgstart)
tooltip:AddSeparator()