纵排改为仇恨目标
parent
46ec8ef4b4
commit
d16361e4d1
|
@ -1,4 +1,4 @@
|
|||
BattleUtil = {}
|
||||
BattleUtil = {}
|
||||
--local BattleUtil = BattleUtil
|
||||
local floor = math.floor
|
||||
local max = math.max
|
||||
|
@ -173,9 +173,11 @@ function BattleUtil.ChooseTarget(role, chooseId)
|
|||
end
|
||||
arr = tempArr
|
||||
elseif chooseLimit == 3 then-- 对列
|
||||
local myCol = role.position % 3
|
||||
local tempArr = BattleUtil.ChooseCol(arr, myCol)
|
||||
if #tempArr == 0 then -- 对列没有人,按顺序找到有人得列
|
||||
local target=RoleManager.GetAggro(role)
|
||||
if target then
|
||||
local myCol = target.position % 3
|
||||
local tempArr = BattleUtil.ChooseCol(arr, myCol)
|
||||
if #tempArr == 0 then -- 对列没有人,按顺序找到有人得列
|
||||
for i = 1, 3 do
|
||||
local col = i % 3 -- 0 表示第三列嗷
|
||||
tempArr = BattleUtil.ChooseCol(arr, col)
|
||||
|
@ -183,8 +185,10 @@ function BattleUtil.ChooseTarget(role, chooseId)
|
|||
break
|
||||
end
|
||||
end
|
||||
end
|
||||
arr = tempArr
|
||||
end
|
||||
arr = tempArr
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
-- 选择条件
|
||||
|
|
Loading…
Reference in New Issue