感谢楼主分享,真的学习到了,自己建了一个使用成功,但是如果建两条搜索两个目标,并且被搜索的对象数量有点多,会导致被踢出游戏,想到是不是可以搜索目标不用那么快,但没想到用什么语句
local hg = BeeUnitName("target")
local buff = BeeUnitBuffList("player")
--选择目标
if hg ~= "腐烂的森林愤怒者"
then
BeeRun("/targetenemy 腐烂的森林愤怒者")
end
if hg == "腐烂的森林愤怒者"
then
if BeeUnitMana("player","%") <= 20 and BeeSpellCoolDown("智慧审判")==0 then
BeeRun("/cast 智慧审判");
end
if BeeSpellCoolDown("圣光审判")==0 and not BeeStringFind("智慧审判",buff) then
BeeRun("/cast 圣光审判");
end
if BeeSpellCoolDown("十字军打击")==0 and BeeIsRun("/cast 十字军打击") then
BeeRun("/cast 十字军打击")
end
if IsSpellInRange("十字军打击","target")==1 and BeeSpellCoolDown("神圣风暴")==0 then
BeeRun("/cast 神圣风暴")
end
if BeeSpellCoolDown("愤怒之锤")==0 and BeeIsRun("/cast 愤怒之锤") then
BeeRun("/cast 愤怒之锤")
end
end