编辑代码

--熊D-PVE

local Tbl = BeeUnitBuffList("target")
local buff = BeeUnitBuffList("player")
local count = BeeTargetDeBuffCount("割伤");
local jineng= "暴风雪,火焰之雨,炎爆术,圣光术,恐惧术,火球术,奥术飞弹,灵魂震击,生命吸取,恐惧,快速治疗,强效治疗术,治疗之触,愈合,地狱烈焰,飓风,献祭,滋养,次级治疗波,苦修,变形术,烈焰风暴,混乱之箭"-----此为需要打断的技能
local j = BeeStringFind(jineng,BeeUnitCastSpellName(Unit))
local Unit="target"
local time , Castingtime= BeeUnitCastSpellTime(Unit)
local t = "变形术"-----此为判定目标身上BUFF停手

--插入技能
if BeeCastSpellFast() then
    return true
end
--运行前提
if BeeStringFind("点心",buff) or BeeStringFind("喝水",buff) or BeeStringFind("进食",buff) or BeeStringFind("急救",buff) then
    return
end
if not BeeStringFind("巨熊形态,星骓,鬼灵战马",buff) and not BeeStringFind("巨熊形态",buff) then
    BeeRun("巨熊形态","player")
end

if BeeUnitAffectingCombat("target") and BeeUnitMana("player","%")>5 and BeeSpellCD("野性冲锋 - 熊")==0 and BeeIsRun("/cast 野性冲锋 - 熊") and BeeRange("target")>8 then BeeRun("/cast 野性冲锋 - 熊") return
end

--停手
if BeeUnitAffectingCombat(Unit) and BeeStringFind("t",Tbl) then
    return
end
--打断
if j and Castingtime - time >1 and time >1 then
    if BeeSpellCD("野性冲锋 - 熊")==0 and BeeRange("target")>8 and not BeeStringFind("昏迷",Tbl) then
        BeeRun("/cast 野性冲锋 - 熊") return
    end
    if BeeSpellCD("猛击")==0 and BeeRange("target")<=10 and not BeeStringFind("昏迷",Tbl) then
        BeeRun("/cast 猛击")
    end
end


--保命
if BeeUnitAffectingCombat("player") and BeeUnitHealth("player","%")<45 then 
    if BeeSpellCoolDown("生存本能")==0 then
        BeeRun("/cast 生存本能","player")
    end
    if BeeUnitAffectingCombat("player") and BeeUnitHealth("player","%")<45 then
        if BeeSpellCD("生存本能")>0 and BeeSpellCoolDown("狂暴回复")==0 then
            BeeRun("/cast 狂暴回复","player")
        end
        if BeeUnitAffectingCombat("player") and BeeUnitHealth("player","%")<50 then
            if BeeSpellCD("生存本能")>0 and BeeSpellCoolDown("伊克的烂指")==0 then
                BeeRun("/use 伊克的烂指","player")
            end
        end
    end
end

--回蓝
if BeeUnitAffectingCombat("target") then
    if BeeUnitMana("player","%")<10 and BeeSpellCD("激怒")==0 then
        BeeRun("/cast 激怒")
    end
    --if BeeUnitHealth("target")>80000 and BeeUnitHealth("target","%")>30 and BeeUnitMana("player","%") <=50 then
    --if BeeIsRun("/use ") then 
    --BeeRun("/use ")
    --end
    --end
end

--爆发
if BeeUnitAffectingCombat("target")and count==5 and BeeSpellCoolDown("狂暴")==0  and BeeRange("target")<=10 then
    BeeRun("/cast 狂暴")
end
--if BeeStringFind("狂暴",buff) then
--BeeRun("/use 13")
--end

--控制
if IsAltKeyDown() and  BeeSpellCoolDown("猛击")==0 and not BeeStringFind("昏迷,忏悔","Tbl") and BeeRange("target")<=8 then
    BeeRun("/cast 猛击","target")
    return
end

--输出
--输出
local guid = MonsterGuid(10)
--print(#guid)
local line = math.modf( #guid / 16 ) 
--print(line)

if BeeUnitAffectingCombat() and BeeRange("target")<=8 and line>1 and BeeUnitMana("player","%")>15 then
    BeeRun("/cast 横扫(熊)")
    return
end

if BeeUnitAffectingCombat("target") and BeeTargetDeBuffTime("精灵之火(野性)")<=0 and not BeeUnitCastSpellName("player") and BeeIsRun("精灵之火(野性)") and BeeRange("target")<=36 then 
    BeeRun("/cast 精灵之火(野性)")
end

if BeeUnitAffectingCombat("target") and BeeTargetDeBuffTime("挫志咆哮")<=1 and BeeSpellCoolDown("挫志咆哮")==0 and BeeIsRun("/cast 挫志咆哮") and BeeRange("target")<=8 then 
    BeeRun("/cast 挫志咆哮")
end
if BeeUnitAffectingCombat("target") and BeeRange("target")<=8 and BeeSpellCD("裂伤(熊)")>0 and BeeUnitMana("player","%")>65 and BeeIsRun("横扫(熊)") then
    BeeRun("/cast 横扫(熊)")
end
if BeeUnitAffectingCombat("target") and BeeSpellCoolDown("猛击")==0 and not BeeStringFind("昏迷","Tbl") and BeeUnitHealth("player","%")<30  and BeeIsRun("/cast 猛击") and BeeRange("target")<=8 then
    BeeRun("/cast 猛击")
end
if BeeUnitAffectingCombat("target") and BeeUnitMana("player","%")>10 and BeeIsRun("/cast 重殴") and BeeRange("target")<=8 then BeeRun("/cast 重殴")
end
if BeeUnitAffectingCombat("target") and BeeUnitMana("player","%")>15 and BeeSpellCoolDown("裂伤(熊)")==0 and BeeIsRun("/cast 裂伤(熊)")  and BeeRange("target")<=8 then
    BeeRun("/cast 裂伤(熊)")
end
if BeeUnitAffectingCombat("target") and count<5 or BeeTargetDeBuffTime("割伤")<5 and BeeSpellCD("裂伤(熊)")>0 and BeeIsRun("/cast 割伤") and BeeRange("target")<=8 then 
    BeeRun("/cast 割伤")
end
if BeeUnitAffectingCombat("target") and BeeUnitHealth("player","%")<30 and BeeSpellCoolDown("树皮术")==0 and BeePlayerBuffTime("树皮术")<0 then
    BeeRun("/cast 树皮术")
end
if BeeUnitUnitIsPlayer(2) then
    BeeRun("低吼")
end