Commit 9dfc9689 authored by POLYMER's avatar POLYMER

fix

parent 22c0fbeb
No preview for this file type
...@@ -24,12 +24,13 @@ function s.initial_effect(c) ...@@ -24,12 +24,13 @@ function s.initial_effect(c)
e2:SetTarget(s.sctg) e2:SetTarget(s.sctg)
e2:SetOperation(s.scop) e2:SetOperation(s.scop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--SearchCard --RetCard
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(id,2)) e3:SetDescription(aux.Stringid(id,2))
e3:SetCategory(CATEGORY_TOHAND) e3:SetCategory(CATEGORY_TOHAND)
e3:SetType(EFFECT_TYPE_IGNITION) e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_MZONE) e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,id+2)
e3:SetCost(s.cost) e3:SetCost(s.cost)
e3:SetTarget(s.target) e3:SetTarget(s.target)
e3:SetOperation(s.operation) e3:SetOperation(s.operation)
......
...@@ -76,7 +76,7 @@ function c12866610.tgcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -76,7 +76,7 @@ function c12866610.tgcon(e,tp,eg,ep,ev,re,r,rp)
end end
function c12866610.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) function c12866610.tgtg(e,tp,eg,ep,ev,re,r,rp,chk)
local rc=re:GetHandler() local rc=re:GetHandler()
if chk==0 then return rc:IsRelateToEffect(re) and rc:IsAbleToGrave() and not rc:IsLocation(LOCATION_GRAVE) end if chk==0 then return rc:IsRelateToEffect(re) and rc:IsAbleToGrave() and not rc:IsLocation(LOCATION_GRAVE+LOCATION_REMOVED) end
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,rc,1,0,0) Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,rc,1,0,0)
end end
function c12866610.tgop(e,tp,eg,ep,ev,re,r,rp) function c12866610.tgop(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -7,7 +7,7 @@ function s.initial_effect(c) ...@@ -7,7 +7,7 @@ function s.initial_effect(c)
--atkchange --atkchange
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0)) e1:SetDescription(aux.Stringid(id,0))
e1:SetCategory(CATEGORY_ATKCHANGE) e1:SetCategory(CATEGORY_ATKCHANGE+CATEGORY_DISABLE)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
...@@ -17,7 +17,7 @@ function s.initial_effect(c) ...@@ -17,7 +17,7 @@ function s.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--tohand --tohand
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(1190) e2:SetDescription(aux.Stringid(id,3))
e2:SetCategory(CATEGORY_TOHAND) e2:SetCategory(CATEGORY_TOHAND)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
...@@ -50,36 +50,35 @@ function s.atktg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -50,36 +50,35 @@ function s.atktg(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function s.atkop(e,tp,eg,ep,ev,re,r,rp) function s.atkop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,0,LOCATION_MZONE,nil) local dg=Group.CreateGroup()
local g=Duel.GetMatchingGroup(s.filter,tp,0,LOCATION_MZONE,nil)
local tc=g:GetFirst() local tc=g:GetFirst()
while tc do while tc do
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK_FINAL) e1:SetCode(EFFECT_SET_ATTACK_FINAL)
e1:SetValue(0) e1:SetValue(0)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1) tc:RegisterEffect(e1)
if not (c:IsRelateToEffect(e) or c:IsLocation(LOCATION_MZONE)) and tc:IsAttack(0) and aux.NegateEffectMonsterFilter(tc) then dg:AddCard(tc) end
tc=g:GetNext() tc=g:GetNext()
end end
local og=Duel.GetOperatedGroup():Filter(s.filter1,nil,e,tp) if not Duel.SelectYesNo(tp,aux.Stringid(id,1)) then return end
if not (c:IsRelateToEffect(e) or c:IsLocation(LOCATION_MZONE)) and #og>0 and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then local tc1=dg:GetFirst()
Duel.BreakEffect() while tc1 do
local tc=og:GetFirst() Duel.NegateRelatedChain(tc1,RESET_TURN_SET)
while tc do local e0=Effect.CreateEffect(c)
Duel.NegateRelatedChain(tc,RESET_TURN_SET) e0:SetType(EFFECT_TYPE_SINGLE)
local e1=Effect.CreateEffect(e:GetHandler()) e0:SetCode(EFFECT_DISABLE)
e1:SetType(EFFECT_TYPE_SINGLE) e0:SetReset(RESET_EVENT+RESETS_STANDARD)
e1:SetCode(EFFECT_DISABLE) tc1:RegisterEffect(e0)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) local e2=Effect.CreateEffect(c)
tc:RegisterEffect(e1) e2:SetType(EFFECT_TYPE_SINGLE)
local e2=Effect.CreateEffect(e:GetHandler()) e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetValue(RESET_TURN_SET)
e2:SetCode(EFFECT_DISABLE_EFFECT) e2:SetReset(RESET_EVENT+RESETS_STANDARD)
e2:SetValue(RESET_TURN_SET) tc1:RegisterEffect(e2)
e2:SetReset(RESET_EVENT+RESETS_STANDARD) tc1=dg:GetNext()
tc:RegisterEffect(e2)
tc=og:GetNext()
end
end end
end end
function s.thcost(e,tp,eg,ep,ev,re,r,rp,chk) function s.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
...@@ -117,6 +116,7 @@ function s.damop(e,tp,eg,ep,ev,re,r,rp) ...@@ -117,6 +116,7 @@ function s.damop(e,tp,eg,ep,ev,re,r,rp)
local rc=re:GetHandler() local rc=re:GetHandler()
local atk=rc:GetBaseAttack() local atk=rc:GetBaseAttack()
if Duel.Damage(1-tp,atk,REASON_EFFECT)>0 and c:IsRelateToEffect(e) then if Duel.Damage(1-tp,atk,REASON_EFFECT)>0 and c:IsRelateToEffect(e) then
Duel.Remove(c,POS_FACEUP,REASON_EFFECT) Duel.BreakEffect()
Duel.Remove(c,POS_FACEUP,REASON_EFFECT)
end end
end end
\ No newline at end of file
...@@ -44,13 +44,13 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -44,13 +44,13 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function s.cfilter(c,tp) function s.cfilter(c,tp)
return c:IsSetCard(0x39c0) and c:IsType(TYPE_FUSION) and c:IsSummonType(SUMMON_TYPE_FUSION) return c:IsSetCard(0x67c0) and c:IsType(TYPE_FUSION) and c:IsSummonType(SUMMON_TYPE_FUSION)
end end
function s.eqcon(e,tp,eg,ep,ev,re,r,rp) function s.eqcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(s.cfilter,1,nil,tp) return eg:IsExists(s.cfilter,1,nil,tp)
end end
function s.eqfilter(c) function s.eqfilter(c)
return c:IsSetCard(0x39c0) and c:IsDefenseAbove(1) and not c:IsForbidden() return c:IsSetCard(0x67c0) and c:IsDefenseAbove(1) and not c:IsForbidden()
end end
function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk) function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0
......
...@@ -65,7 +65,7 @@ function c75075612.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -65,7 +65,7 @@ function c75075612.activate(e,tp,eg,ep,ev,re,r,rp)
if Duel.IsPlayerAffectedByEffect(tp,59822133) then ft=1 end if Duel.IsPlayerAffectedByEffect(tp,59822133) then ft=1 end
local c=e:GetHandler() local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c75075612.spfilter,tp,LOCATION_HAND+LOCATION_DECK,0,1,ft,nil,e,tp) local g=Duel.SelectMatchingCard(tp,c75075612.spfilter,tp,LOCATION_HAND+LOCATION_DECK,0,1,math.min(ft,2),nil,e,tp)
if g:GetCount()>0 and Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEDOWN_DEFENSE)~=0 then if g:GetCount()>0 and Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEDOWN_DEFENSE)~=0 then
local tc=g:GetFirst() local tc=g:GetFirst()
while tc do while tc do
......
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