Commit dd825197 authored by Nemo Ma's avatar Nemo Ma

fix

parent cf7203b6
......@@ -28,13 +28,13 @@ function cm.chkfilter1(c,e,tp)
return c:IsSetCard(0x97b) and c:IsType(TYPE_MONSTER) and not c:IsHasEffect(EFFECT_REVIVE_LIMIT) and Duel.IsPlayerCanSpecialSummon(tp,0,POS_FACEUP,tp,c) and Duel.IsExistingMatchingCard(cm.chkfilter2,tp,LOCATION_DECK,0,1,nil,e,tp,c:GetAttribute())
end
function cm.chkfilter2(c,e,tp,att)
return c:IsSetCard(0x97b) and c:IsType(TYPE_MONSTER) and not c:IsAttribute(att) and not c:IsHasEffect(EFFECT_REVIVE_LIMIT) and Duel.IsPlayerCanSpecialSummon(tp,0,POS_FACEUP,1-tp,c)
return c:IsSetCard(0x97b) and c:IsType(TYPE_MONSTER) and c:GetAttribute()~=att and not c:IsHasEffect(EFFECT_REVIVE_LIMIT) and Duel.IsPlayerCanSpecialSummon(tp,0,POS_FACEUP,1-tp,c)
end
function cm.filter1(c,e,tp)
return c:IsSetCard(0x97b) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and Duel.IsExistingMatchingCard(cm.filter2,tp,LOCATION_DECK,0,1,nil,e,tp,c:GetAttribute())
end
function cm.filter2(c,e,tp,att)
return c:IsSetCard(0x97b) and c:IsType(TYPE_MONSTER) and not c:IsAttribute(att) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_ATTACK,1-tp)
return c:IsSetCard(0x97b) and c:IsType(TYPE_MONSTER) and c:GetAttribute()~=att and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_ATTACK,1-tp)
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local sp=Duel.GetActivityCount(tp,ACTIVITY_SPSUMMON)
......@@ -74,8 +74,8 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
e2:SetLabel(tc1:GetRealFieldID())
tc2:RegisterEffect(e2)
local e3=e1:Clone()
--e3:SetCode(EFFECT_ONLY_ATTACK_MONSTER)
e3:SetCode(EFFECT_MUST_ATTACK_MONSTER)
e3:SetCode(EFFECT_ONLY_ATTACK_MONSTER)
--e3:SetCode(EFFECT_MUST_ATTACK_MONSTER)
e3:SetValue(cm.bttg)
tc1:RegisterEffect(e3)
local e4=e3:Clone()
......
......@@ -31,7 +31,7 @@ function cm.initial_effect(c)
e2:SetCode(EVENT_SUMMON_SUCCESS)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetRange(LOCATION_FZONE)
e2:SetCountLimit(1)
e2:SetCountLimit(1,EFFECT_COUNT_CODE_SINGLE)
e2:SetCondition(cm.adcon2)
e2:SetTarget(cm.adtg2)
e2:SetOperation(cm.adop2)
......
......@@ -18,6 +18,7 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
local b1 = (c:IsOnField() or c:IsPublic()) and c:GetFlagEffect(id) < s.get_count(LOCATION_ONFIELD)
local b2 = c:IsLocation(LOCATION_HAND) and c:GetFlagEffect(id + 100) == 0 and cct > 1
if chk == 0 then return b1 or b2 end
b2 = c:IsLocation(LOCATION_HAND) and c:GetFlagEffect(id + 100) == 0 and cct > 2
--local op = b1 and 1 or 2
--if b1 and b2 then
--op = Scl.SelectOption(tp, true, "Damage", true, {id, 0})
......
......@@ -18,6 +18,7 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
local b1 = (c:IsOnField() or c:IsPublic()) and c:GetFlagEffect(id) < s.get_count(LOCATION_HAND)
local b2 = c:IsLocation(LOCATION_HAND) and c:GetFlagEffect(id + 100) == 0 and cct > 1
if chk == 0 then return b1 or b2 end
b2 = c:IsLocation(LOCATION_HAND) and c:GetFlagEffect(id + 100) == 0 and cct > 2
--local op = b1 and 1 or 2
--if b1 and b2 then
--op = Scl.SelectOption(tp, true, "Damage", true, {id, 0})
......
......@@ -16,8 +16,9 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
local c = e:GetHandler()
local cct = Duel.GetCurrentChain()
local b1 = (c:IsOnField() or c:IsPublic()) and c:GetFlagEffect(id) < s.get_count(LOCATION_DECK)
local b2 = c:IsLocation(LOCATION_HAND) and c:GetFlagEffect(id + 100) == 0 and cct > 1
local b2 = c:IsLocation(LOCATION_HAND) and c:GetFlagEffect(id + 100) == 0 and ev > 1
if chk == 0 then return b1 or b2 end
b2 = c:IsLocation(LOCATION_HAND) and c:GetFlagEffect(id + 100) == 0 and cct > 2
--local op = b1 and 1 or 2
--if b1 and b2 then
--op = Scl.SelectOption(tp, true, "Damage", true, {id, 0})
......
......@@ -18,6 +18,7 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
local b1 = (c:IsOnField() or c:IsPublic()) and c:GetFlagEffect(id) < s.get_count(LOCATION_GRAVE)
local b2 = c:IsLocation(LOCATION_HAND) and c:GetFlagEffect(id + 100) == 0 and cct > 1
if chk == 0 then return b1 or b2 end
b2 = c:IsLocation(LOCATION_HAND) and c:GetFlagEffect(id + 100) == 0 and cct > 2
--local op = b1 and 1 or 2
--if b1 and b2 then
--op = Scl.SelectOption(tp, true, "Damage", true, {id, 0})
......
......@@ -67,7 +67,7 @@ function cm.tnop(e,tp,eg,ep,ev,re,r,rp)
end
function cm.efilter(e,te)
if not te:IsActivated() then return false end
if not te:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then return true end
if not te:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then return false end
local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS)
return g and g:IsContains(e:GetHandler())
end
......
if not pcall(function() require("expansions/script/c20099999") end) then require("script/c20099999") end
if fucf then return end
fucf, fugf = { }, { }
--------------------------------------"Card function"
function fucf.Filter(c,f,...)
local v = {...}
v = #v==1 and v[1] or v
return fugf.Filter(Group.FromCards(c),f,v,1)
end
function fucf.Compare(c,f,n,meth,...)
if type(f) == "string" then f=fucf[f] or Card[f] or aux[f] end
local v = {...}
v = type(v[1]) =="table" and #v==1 and v[1] or v
if meth == "A" then
return f(c,table.unpack(v))>=n
elseif meth == "B" then
return f(c,table.unpack(v))<=n
end
return f(c,table.unpack(v))==n
end
function fucf.Not(c,val)
if aux.GetValueType(val) == "Card" then
return c ~= val
elseif aux.GetValueType(val) == "Effect" then
return c ~= e:GetHandler()
elseif aux.GetValueType(val) == "Group" then
return not val:IsContains(c)
elseif aux.GetValueType(val) == "function" then
return not val(c)
end
return false
end
fucf.TgChk = Card.IsCanBeEffectTarget
fucf.GChk = function(c)return not c:IsHasEffect(EFFECT_NECRO_VALLEY) end
fucf.IsImm = Card.IsImmuneToEffect
function fucf.IsSet(c,set)
if type(set) == "number" then return c:IsSetCard(set) end
for _,Set in ipairs(fusf.CutString(set,"/")) do
Set=tonumber(Set,16)
if Set and c:IsSetCard(Set) then return true end
end
return false
end
function fucf.AbleTo(c,loc)
local func = {
["H"] = "Hand" ,
["D"] = "Deck" ,
["G"] = "Grave" ,
["R"] = "Remove",
["E"] = "Extra" ,
}
local iscos = string.sub(loc,1,1) == "*"
if iscos then loc = string.sub(loc,2) end
func = "IsAbleTo"..func[loc]
if iscos then func = func.."AsCost" end
return Card[func](c)
end
function fucf.CanSp(c,e,typ,tp,nochk,nolimit,pos,totp,zone)
return c:IsCanBeSpecialSummoned(e, typ, tp, nochk or false, nolimit or false, pos or POS_FACEUP, totp or tp,zone or 0xff)
end
function fucf.IsCod(c,cod)
if type(cod) == "string" then cod = tonumber(cod) end
return c:IsCode(cod)
end
function fucf.IsLoc(c,loc)
return c:IsLocation(fusf.Loc(loc))
end
function fucf.CheckConstantValue(func,chktable)
return function(c,cons)
if cons and type(cons) ~= "string" then return func(c,cons) end
local Cons, tStack = fusf.PostFix_Trans(cons), { }
local CalL, CalR
for _,val in ipairs(Cons) do
if string.match(val, "[%-%~]") then
tStack[#tStack] = not tStack[#tStack]
elseif string.match(val, "[%+%/]") then
CalR = table.remove(tStack)
CalL = table.remove(tStack)
local tCal = {
["+"] = CalL and CalR,
["/"] = CalL or CalR
}
table.insert(tStack, tCal[val])
else
table.insert(tStack, func(c,chktable[string.upper(val)]))
end
end
return tStack[#tStack]
end
end
fucf.IsRea = fucf.CheckConstantValue(function(c,v) return c:IsReason(v) end,fucg.rea)
fucf.IsTyp = fucf.CheckConstantValue(function(c,v) return c:GetType()&v==v end,fucg.typ)
fucf.IsAtt = fucf.CheckConstantValue(function(c,v) return c:GetAttribute()&v==v end,fucg.att)
fucf.IsRac = fucf.CheckConstantValue(function(c,v) return c:GetRace()&v==v end,fucg.rac)
fucf.IsPos = fucf.CheckConstantValue(function(c,v) return c:IsPosition(v) end,fucg.pos)
--------------------------------------"Group function"
function fugf.Get(p,loc)
return Duel.GetFieldGroup(p,fusf.Loc(loc))
end
function fugf.Filter(g,f,v,n)
local func, tStack, index = { }, { }, 1
v = type(v) == "table" and v or { v }
func = type(f) == "string" and fusf.PostFix_Trans(f,v) or { f }
local var = fusf.Value_Trans(v)
--------------------------------------------
if #func==1 then
if type(func[1]) == "string" then func[1] = fucf[func[1] ] or Card[func[1] ] or aux[func[1] ] end
g = g:Filter(func[1] or aux.TRUE,nil,table.unpack(var))
else
local CalL, CalR
for _,val in ipairs(func) do
if val == "~" then
CalR = g - table.remove(tStack)
table.insert(tStack, CalR)
elseif type(val) == "string" and #val == 1 then
CalR = table.remove(tStack)
CalL = table.remove(tStack)
local tCalc = {
["+"] = CalL & CalR,
["-"] = CalL - CalR,
["/"] = CalL + CalR
}
table.insert(tStack, tCalc[val])
else
if type(val) == "string" then val = fucf[val] or Card[val] or aux[val] end
local V = table.remove(var,1)
V = V and (type(V) =="table" and V or {V}) or { }
table.insert(tStack, g:Filter(val,nil,table.unpack(V)))
end
end
g = table.remove(tStack)
end
if n then return #g>=n end
return g
end
function fugf.GetFilter(p,loc,f,v,n)
return fugf.Filter(fugf.Get(p,loc),f,v,n)
end
function fugf.SelectFilter(p,loc,f,v,c,min,max,sp)
min=min or 1
return fugf.GetFilter(p,loc,f,v):Select(sp or p,min,max or min,c)
end
function fugf.SelectTg(p,loc,f,v,c,min,max,sp)
local g=fugf.SelectFilter(p,loc,f,v,c,min,max,sp)
Duel.SetTargetCard(g)
return g
end
\ No newline at end of file
......@@ -47,6 +47,5 @@ function cm.accon(e,tp)
return e:GetHandler():GetFlagEffect(m) > 0
end
function cm.aclimit(e,re,tp)
local loc=re:GetActivateLocation()
return not loc==LOCATION_ONFIELD
return not re:GetHandler():IsLocation(LOCATION_ONFIELD)
end
......@@ -45,7 +45,7 @@ function cm.tttg(e,tp,eg,ep,ev,re,r,rp,chk)
end
function cm.ttop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectMatchingCard(tp,cm.filter,tp,LOCATION_DECK,0,1,1,nil)
local g=Duel.SelectMatchingCard(tp,cm.thfilter,tp,LOCATION_DECK,0,1,1,nil)
if g:GetCount()>0 then
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
......
......@@ -12,6 +12,7 @@ function cm.initial_effect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,m)
e1:SetTarget(cm.target)
e1:SetOperation(cm.activate)
c:RegisterEffect(e1)
......
......@@ -131,7 +131,7 @@ function cm.initial_effect(c)
return _SendtoDeck(tg,1-tg:GetControler(),seq,reason)
end
if not tp and aux.GetValueType(tg)=="Group" then
local sg=tg:Filter(cm.rfilter,nil,7439100+id):Filter(Card.IsLocation,nil,LOCATION_DECK)
local sg=tg:Filter(Party_time_rfilter,nil,7439100+id):Filter(Card.IsLocation,nil,LOCATION_DECK)
if sg and sg:GetCount()>0 then
local tgc=tg:Clone()
tgc:Sub(sg)
......@@ -386,23 +386,23 @@ function cm.initial_effect(c)
-- local id=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
-- local ag=Party_time_table[7439100+id]
-- if id~=0 and Duel.GetFlagEffect(0,7439100+id)~=0 then
-- sg:AddCard(c)
-- local sg2=sg:Clone()
-- local pg=sg:Filter(Party_time_rfilter,nil,7439100+id)
-- sg2:Sub(pg)
-- if aux.GCheckAdditional and (c:GetFlagEffectLabel(7439100)~=id and not aux.GCheckAdditional(sg2,c,g,f,min,max,ext_params) ) then
-- sg:RemoveCard(c)
-- return false
-- end
-- local res=#sg>=min and #sg<=max and f(sg2,table.unpack(ext_params))
-- if res then
-- aux.SubGroupCaptured:Clear()
-- aux.SubGroupCaptured:Merge(sg)
-- else
-- res=#sg<max and g:IsExists(aux. CheckGroupRecursiveCapture,1,sg2,sg,g,f,min,max,ext_params)
-- end
-- sg:RemoveCard(c)
-- return res
-- sg:AddCard(c)
-- local sg2=sg:Clone()
-- local pg=sg:Filter(Party_time_rfilter,nil,7439100+id)
-- sg2:Sub(pg)
-- if aux.GCheckAdditional and (c:GetFlagEffectLabel(7439100)~=id and not aux.GCheckAdditional(sg2,c,g,f,min,max,ext_params) ) then
-- sg:RemoveCard(c)
-- return false
-- end
-- local res=#sg>=min and #sg<=max and f(sg2,table.unpack(ext_params))
-- if res then
-- aux.SubGroupCaptured:Clear()
-- aux.SubGroupCaptured:Merge(sg)
-- else
-- res=#sg<max and g:IsExists(aux. CheckGroupRecursiveCapture,1,sg2,sg,g,f,min,max,ext_params)
-- end
-- sg:RemoveCard(c)
-- return res
-- end
-- end
-- return _CheckGroupRecursiveCapture(c,sg,g,f,min,max,ext_params)
......
......@@ -131,7 +131,7 @@ function cm.initial_effect(c)
return _SendtoDeck(tg,1-tg:GetControler(),seq,reason)
end
if not tp and aux.GetValueType(tg)=="Group" then
local sg=tg:Filter(cm.rfilter,nil,7439100+id):Filter(Card.IsLocation,nil,LOCATION_DECK)
local sg=tg:Filter(Party_time_rfilter,nil,7439100+id):Filter(Card.IsLocation,nil,LOCATION_DECK)
if sg and sg:GetCount()>0 then
local tgc=tg:Clone()
tgc:Sub(sg)
......@@ -386,23 +386,23 @@ function cm.initial_effect(c)
-- local id=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
-- local ag=Party_time_table[7439100+id]
-- if id~=0 and Duel.GetFlagEffect(0,7439100+id)~=0 then
-- sg:AddCard(c)
-- local sg2=sg:Clone()
-- local pg=sg:Filter(Party_time_rfilter,nil,7439100+id)
-- sg2:Sub(pg)
-- if aux.GCheckAdditional and (c:GetFlagEffectLabel(7439100)~=id and not aux.GCheckAdditional(sg2,c,g,f,min,max,ext_params) ) then
-- sg:RemoveCard(c)
-- return false
-- end
-- local res=#sg>=min and #sg<=max and f(sg2,table.unpack(ext_params))
-- if res then
-- aux.SubGroupCaptured:Clear()
-- aux.SubGroupCaptured:Merge(sg)
-- else
-- res=#sg<max and g:IsExists(aux. CheckGroupRecursiveCapture,1,sg2,sg,g,f,min,max,ext_params)
-- end
-- sg:RemoveCard(c)
-- return res
-- sg:AddCard(c)
-- local sg2=sg:Clone()
-- local pg=sg:Filter(Party_time_rfilter,nil,7439100+id)
-- sg2:Sub(pg)
-- if aux.GCheckAdditional and (c:GetFlagEffectLabel(7439100)~=id and not aux.GCheckAdditional(sg2,c,g,f,min,max,ext_params) ) then
-- sg:RemoveCard(c)
-- return false
-- end
-- local res=#sg>=min and #sg<=max and f(sg2,table.unpack(ext_params))
-- if res then
-- aux.SubGroupCaptured:Clear()
-- aux.SubGroupCaptured:Merge(sg)
-- else
-- res=#sg<max and g:IsExists(aux. CheckGroupRecursiveCapture,1,sg2,sg,g,f,min,max,ext_params)
-- end
-- sg:RemoveCard(c)
-- return res
-- end
-- end
-- return _CheckGroupRecursiveCapture(c,sg,g,f,min,max,ext_params)
......
......@@ -131,7 +131,7 @@ function cm.initial_effect(c)
return _SendtoDeck(tg,1-tg:GetControler(),seq,reason)
end
if not tp and aux.GetValueType(tg)=="Group" then
local sg=tg:Filter(cm.rfilter,nil,7439100+id):Filter(Card.IsLocation,nil,LOCATION_DECK)
local sg=tg:Filter(Party_time_rfilter,nil,7439100+id):Filter(Card.IsLocation,nil,LOCATION_DECK)
if sg and sg:GetCount()>0 then
local tgc=tg:Clone()
tgc:Sub(sg)
......@@ -386,23 +386,23 @@ function cm.initial_effect(c)
-- local id=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
-- local ag=Party_time_table[7439100+id]
-- if id~=0 and Duel.GetFlagEffect(0,7439100+id)~=0 then
-- sg:AddCard(c)
-- local sg2=sg:Clone()
-- local pg=sg:Filter(Party_time_rfilter,nil,7439100+id)
-- sg2:Sub(pg)
-- if aux.GCheckAdditional and (c:GetFlagEffectLabel(7439100)~=id and not aux.GCheckAdditional(sg2,c,g,f,min,max,ext_params) ) then
-- sg:RemoveCard(c)
-- return false
-- end
-- local res=#sg>=min and #sg<=max and f(sg2,table.unpack(ext_params))
-- if res then
-- aux.SubGroupCaptured:Clear()
-- aux.SubGroupCaptured:Merge(sg)
-- else
-- res=#sg<max and g:IsExists(aux. CheckGroupRecursiveCapture,1,sg2,sg,g,f,min,max,ext_params)
-- end
-- sg:RemoveCard(c)
-- return res
-- sg:AddCard(c)
-- local sg2=sg:Clone()
-- local pg=sg:Filter(Party_time_rfilter,nil,7439100+id)
-- sg2:Sub(pg)
-- if aux.GCheckAdditional and (c:GetFlagEffectLabel(7439100)~=id and not aux.GCheckAdditional(sg2,c,g,f,min,max,ext_params) ) then
-- sg:RemoveCard(c)
-- return false
-- end
-- local res=#sg>=min and #sg<=max and f(sg2,table.unpack(ext_params))
-- if res then
-- aux.SubGroupCaptured:Clear()
-- aux.SubGroupCaptured:Merge(sg)
-- else
-- res=#sg<max and g:IsExists(aux. CheckGroupRecursiveCapture,1,sg2,sg,g,f,min,max,ext_params)
-- end
-- sg:RemoveCard(c)
-- return res
-- end
-- end
-- return _CheckGroupRecursiveCapture(c,sg,g,f,min,max,ext_params)
......
......@@ -131,7 +131,7 @@ function cm.initial_effect(c)
return _SendtoDeck(tg,1-tg:GetControler(),seq,reason)
end
if not tp and aux.GetValueType(tg)=="Group" then
local sg=tg:Filter(cm.rfilter,nil,7439100+id):Filter(Card.IsLocation,nil,LOCATION_DECK)
local sg=tg:Filter(Party_time_rfilter,nil,7439100+id):Filter(Card.IsLocation,nil,LOCATION_DECK)
if sg and sg:GetCount()>0 then
local tgc=tg:Clone()
tgc:Sub(sg)
......@@ -386,23 +386,23 @@ function cm.initial_effect(c)
-- local id=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
-- local ag=Party_time_table[7439100+id]
-- if id~=0 and Duel.GetFlagEffect(0,7439100+id)~=0 then
-- sg:AddCard(c)
-- local sg2=sg:Clone()
-- local pg=sg:Filter(Party_time_rfilter,nil,7439100+id)
-- sg2:Sub(pg)
-- if aux.GCheckAdditional and (c:GetFlagEffectLabel(7439100)~=id and not aux.GCheckAdditional(sg2,c,g,f,min,max,ext_params) ) then
-- sg:RemoveCard(c)
-- return false
-- end
-- local res=#sg>=min and #sg<=max and f(sg2,table.unpack(ext_params))
-- if res then
-- aux.SubGroupCaptured:Clear()
-- aux.SubGroupCaptured:Merge(sg)
-- else
-- res=#sg<max and g:IsExists(aux. CheckGroupRecursiveCapture,1,sg2,sg,g,f,min,max,ext_params)
-- end
-- sg:RemoveCard(c)
-- return res
-- sg:AddCard(c)
-- local sg2=sg:Clone()
-- local pg=sg:Filter(Party_time_rfilter,nil,7439100+id)
-- sg2:Sub(pg)
-- if aux.GCheckAdditional and (c:GetFlagEffectLabel(7439100)~=id and not aux.GCheckAdditional(sg2,c,g,f,min,max,ext_params) ) then
-- sg:RemoveCard(c)
-- return false
-- end
-- local res=#sg>=min and #sg<=max and f(sg2,table.unpack(ext_params))
-- if res then
-- aux.SubGroupCaptured:Clear()
-- aux.SubGroupCaptured:Merge(sg)
-- else
-- res=#sg<max and g:IsExists(aux. CheckGroupRecursiveCapture,1,sg2,sg,g,f,min,max,ext_params)
-- end
-- sg:RemoveCard(c)
-- return res
-- end
-- end
-- return _CheckGroupRecursiveCapture(c,sg,g,f,min,max,ext_params)
......
......@@ -131,7 +131,7 @@ function cm.initial_effect(c)
return _SendtoDeck(tg,1-tg:GetControler(),seq,reason)
end
if not tp and aux.GetValueType(tg)=="Group" then
local sg=tg:Filter(cm.rfilter,nil,7439100+id):Filter(Card.IsLocation,nil,LOCATION_DECK)
local sg=tg:Filter(Party_time_rfilter,nil,7439100+id):Filter(Card.IsLocation,nil,LOCATION_DECK)
if sg and sg:GetCount()>0 then
local tgc=tg:Clone()
tgc:Sub(sg)
......@@ -386,23 +386,23 @@ function cm.initial_effect(c)
-- local id=Duel.GetChainInfo(0,CHAININFO_CHAIN_ID)
-- local ag=Party_time_table[7439100+id]
-- if id~=0 and Duel.GetFlagEffect(0,7439100+id)~=0 then
-- sg:AddCard(c)
-- local sg2=sg:Clone()
-- local pg=sg:Filter(Party_time_rfilter,nil,7439100+id)
-- sg2:Sub(pg)
-- if aux.GCheckAdditional and (c:GetFlagEffectLabel(7439100)~=id and not aux.GCheckAdditional(sg2,c,g,f,min,max,ext_params) ) then
-- sg:RemoveCard(c)
-- return false
-- end
-- local res=#sg>=min and #sg<=max and f(sg2,table.unpack(ext_params))
-- if res then
-- aux.SubGroupCaptured:Clear()
-- aux.SubGroupCaptured:Merge(sg)
-- else
-- res=#sg<max and g:IsExists(aux. CheckGroupRecursiveCapture,1,sg2,sg,g,f,min,max,ext_params)
-- end
-- sg:RemoveCard(c)
-- return res
-- sg:AddCard(c)
-- local sg2=sg:Clone()
-- local pg=sg:Filter(Party_time_rfilter,nil,7439100+id)
-- sg2:Sub(pg)
-- if aux.GCheckAdditional and (c:GetFlagEffectLabel(7439100)~=id and not aux.GCheckAdditional(sg2,c,g,f,min,max,ext_params) ) then
-- sg:RemoveCard(c)
-- return false
-- end
-- local res=#sg>=min and #sg<=max and f(sg2,table.unpack(ext_params))
-- if res then
-- aux.SubGroupCaptured:Clear()
-- aux.SubGroupCaptured:Merge(sg)
-- else
-- res=#sg<max and g:IsExists(aux. CheckGroupRecursiveCapture,1,sg2,sg,g,f,min,max,ext_params)
-- end
-- sg:RemoveCard(c)
-- return res
-- end
-- end
-- return _CheckGroupRecursiveCapture(c,sg,g,f,min,max,ext_params)
......
......@@ -61,7 +61,7 @@ function c87490445.sxxtg2(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetChainLimit(c87490445.chlimit)
end
function c87490445.chlimit(e,ep,tp)
return tp==ep
return tp==ep or not e:IsActiveType(TYPE_SPELL+TYPE_TRAP)
end
function c87490445.sxxop2(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment