Commit 0694484e authored by wind2009's avatar wind2009

Merge remote-tracking branch 'upstream/master' into master

parents 72d92271 bb1c1c6c
...@@ -64,6 +64,9 @@ function s.thop(e,tp,eg,ep,ev,re,r,rp) ...@@ -64,6 +64,9 @@ function s.thop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
end end
function s.filter(c,e)
return c:IsAbleToHand() and c:IsCanBeEffectTarget(e)
end
function s.thfilters(c) function s.thfilters(c)
return c:IsFaceup() and c:IsAllTypes(TYPE_CONTINUOUS|TYPE_TRAP) and c:IsSetCard(0x1c1) return c:IsFaceup() and c:IsAllTypes(TYPE_CONTINUOUS|TYPE_TRAP) and c:IsSetCard(0x1c1)
end end
...@@ -71,7 +74,7 @@ function s.sgselect(g) ...@@ -71,7 +74,7 @@ function s.sgselect(g)
return g:IsExists(s.thfilters,1,nil) return g:IsExists(s.thfilters,1,nil)
end end
function s.thtg1(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function s.thtg1(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local g=Duel.GetMatchingGroup(Card.IsAbleToHand,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) local g=Duel.GetMatchingGroup(s.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,e)
if chkc then return false end if chkc then return false end
if chk==0 then return g:CheckSubGroup(s.sgselect,2,2) end if chk==0 then return g:CheckSubGroup(s.sgselect,2,2) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
......
...@@ -38,8 +38,9 @@ end ...@@ -38,8 +38,9 @@ end
function s.mfilter2(c) function s.mfilter2(c)
return c:IsRace(RACE_ILLUSION) return c:IsRace(RACE_ILLUSION)
end end
function s.sprfilter(c) function s.sprfilter(c,sc)
return c:GetOriginalType()&TYPE_MONSTER~=0 and c:IsFaceup() and c:IsAbleToGraveAsCost() return c:GetOriginalType()&TYPE_MONSTER~=0 and c:IsFaceup()
and c:IsAbleToGraveAsCost() and c:IsCanBeFusionMaterial(sc,SUMMON_TYPE_SPECIAL)
end end
function s.sgchk(g,tp,sc) function s.sgchk(g,tp,sc)
return Duel.GetLocationCountFromEx(tp,tp,g,sc)>0 return Duel.GetLocationCountFromEx(tp,tp,g,sc)>0
...@@ -47,12 +48,12 @@ end ...@@ -47,12 +48,12 @@ end
function s.hspcon(e,c) function s.hspcon(e,c)
if c==nil then return true end if c==nil then return true end
local tp=c:GetControler() local tp=c:GetControler()
local g=Duel.GetMatchingGroup(s.sprfilter,tp,LOCATION_SZONE,0,e:GetHandler()) local g=Duel.GetMatchingGroup(s.sprfilter,tp,LOCATION_SZONE,0,c,c)
return g:CheckSubGroup(s.sgchk,2,2,tp,c) return g:CheckSubGroup(s.sgchk,2,2,tp,c)
end end
function s.hsptg(e,tp,eg,ep,ev,re,r,rp,chk,c) function s.hsptg(e,tp,eg,ep,ev,re,r,rp,chk,c)
local cp=c:GetControler() local cp=c:GetControler()
local g=Duel.GetMatchingGroup(s.sprfilter,cp,LOCATION_SZONE,0,nil) local g=Duel.GetMatchingGroup(s.sprfilter,cp,LOCATION_SZONE,0,c,c)
Duel.Hint(HINT_SELECTMSG,cp,HINTMSG_TOGRAVE) Duel.Hint(HINT_SELECTMSG,cp,HINTMSG_TOGRAVE)
local sg=g:SelectSubGroup(cp,s.sgchk,true,2,2,cp,c) local sg=g:SelectSubGroup(cp,s.sgchk,true,2,2,cp,c)
if sg then if sg then
......
...@@ -31,8 +31,8 @@ function s.initial_effect(c) ...@@ -31,8 +31,8 @@ function s.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
c95095116.material_type=TYPE_SYNCHRO c95095116.material_type=TYPE_SYNCHRO
function s.mfilter(c) function s.mfilter(c,fc)
return c:IsFaceup() and c:IsLocation(LOCATION_MZONE) return c:IsFaceup() and c:IsLocation(LOCATION_MZONE) and c:IsControler(fc:GetControler())
end end
function s.negcon(e,tp,eg,ep,ev,re,r,rp) function s.negcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() 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