zoukankan      html  css  js  c++  java
  • 自动拾取确认,自动复活确认

    自动拾取确认

    local aotuClick = CreateFrame("Frame") 
       aotuClick:RegisterEvent("CONFIRM_DISENCHANT_ROLL") 
       aotuClick:RegisterEvent("CONFIRM_LOOT_ROLL") 
       aotuClick:RegisterEvent("LOOT_BIND_CONFIRM")       
       aotuClick:SetScript("OnEvent", function(self, event, ...) 
          for i = 1, STATICPOPUP_NUMDIALOGS do 
            local frame = _G["StaticPopup"..i] 
            if (frame.which == "CONFIRM_LOOT_ROLL" or frame.which == "LOOT_BIND" or frame.which == "LOOT_BIND_CONFIRM") and frame:IsVisible() then 
            StaticPopup_OnClick(frame, 1) 
            end 
          end 
       end)

    自动复活确认

    local function ResurrectEvent() 
             if not (UnitAffectingCombat('player') or UnitAffectingCombat(name)) then 
                local delay = GetCorpseRecoveryDelay() 
                if delay == 0 then 
                   AcceptResurrect() 
                   DoEmote('thank', name) 
                else 
                   local b = CreateFrame("Button") 
                   local formattedText = b:GetText(b:SetFormattedText("%d |4second:seconds", delay)) 
                   SendChatMessage("感谢复活我!我复活CD了,还有"..formattedText.."才能起来。", 'WHISPER', nil, name) 
                end 
             end 
          end 
       local Resurrect = CreateFrame("Frame") 
       Resurrect:RegisterEvent("RESURRECT_REQUEST") 
       Resurrect:SetScript("OnEvent", ResurrectEvent) 
  • 相关阅读:
    windows 物理内存获取
    windbg-.process切换进程(内核)
    cnetos 6.7彻底解决vmware NAT网络问题
    优秀的博客链接地址
    使用Spring MVC统一异常处理实战
    active mq 配置
    socket demo程序
    flume 中的 hdfs sink round 和roll
    软链接与硬链接
    flume A simple example
  • 原文地址:https://www.cnblogs.com/sakaras/p/2690651.html
Copyright © 2011-2022 走看看