把宏设置好了,只要按一次,打开交易行的瑰石,鼠标移上去就可以看到属性了。
/script sv2=sv2 or nil
local s1,s2="打开","关闭."
local ms=function(str)
OutputMessage("MSG_SYS","瑰石查看宏已"..str.."\n") end
st_oit=function
(i,p1,p2,bb,x,y) OutputItemTip(UI_OBJECT_ITEM_INFO,0,p1,p2,{x+200,y,1,1},bb)
end
if sv2 then
sv2b=not sv2b
if sv2b then ms(s1) else ms(s2)
end
else
sv2=AuctionPanel.OnItemMouseEnter
function
AuctionPanel.OnItemMouseEnter()
sv2()
if sv2b and this.nItemID
then
local dt,n1,n2,n3=this:GetObject()
local
cx,cy=this:GetAbsPos()
local nI =GetItemInfo(n2,n3)
local
dsc=Table_GetItemDesc(nI.nUiId)
local ns,ne =string.find(dsc,"可额外掉落")
if
ns and ne then
local
m={x=cx+38,y=cy-12,szOption="",{szOption=nI.szName,fnMouseEnter=function(i)
st_oit(i,n2,n3,false,cx,cy) end},{bDevide=true}}
local szs = string.gsub(dsc,
"this\.dwTabType\=(%d+) this.dwIndex=(%d+) ",
function(nit,nid)
local
itm=GetItemInfo(nit,nid)
table.insert(m,{szOption=itm.szName,fnMouseEnter=function(i)
st_oit(i,nit,nid,false,cx,cy)
end})
end)
HideTip()
PopupMenu(m)
end
end
end
sv2b=true
ms(s1)
end