02-20-2015, 03:16 PM
But the code to parse it hasn't changed.... Still uses , for list + for combine... Unless you mean they were wanting to look for 262「SHII」 *and* 260「リクレイム・Reclaim」 missing、 not one or the other・・・? Unless I'm reading it wrong of course.
Please feel free to correct me.
Please feel free to correct me.
Code:
function MissingBuffs(entity, buffIDs, dura, ownerid)
local duration = dura or 0
local owner = ownerid or 0
--If we have no buffs, we are missing everything.
local buffs = entity.buffs
if (buffs == nil or TableSize(buffs) == 0) then
return true
end
--Start by assuming we have no buffs, so they are missing.
local missing = true
for _orids in StringSplit(buffIDs,",") do
missing = true
for _andid in StringSplit(_orids,"+") do
for i, buff in pairs(buffs) do
if (buff.id == tonumber(_andid)
and (duration == 0 or buff.duration > duration or HasInfiniteDuration(buff.id))
and (owner == 0 or buff.ownerid == owner))
then
missing = false
end
end
if (not missing) then
break
end
end
if (missing) then
return true
end
end
return false
end