Commit 5d981ee8 authored by Tang Xinwei's avatar Tang Xinwei Committed by GitHub

Merge branch 'Fluorohydride:master' into master

parents 4bba3bf9 78e2d6bc
...@@ -100,8 +100,8 @@ function c10000020.atkfilter(c,tp) ...@@ -100,8 +100,8 @@ function c10000020.atkfilter(c,tp)
return c:IsControler(tp) and c:IsPosition(POS_FACEUP_ATTACK) return c:IsControler(tp) and c:IsPosition(POS_FACEUP_ATTACK)
end end
function c10000020.atktg(e,tp,eg,ep,ev,re,r,rp,chk) function c10000020.atktg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return eg:IsExists(c10000020.atkfilter,1,nil,1-tp) end if chk==0 then return eg:IsExists(c10000020.atkfilter,1,e:GetHandler(),1-tp) end
local g=eg:Filter(c10000020.atkfilter,nil,1-tp) local g=eg:Filter(c10000020.atkfilter,e:GetHandler(),1-tp)
Duel.SetTargetCard(g) Duel.SetTargetCard(g)
end end
function c10000020.atkop(e,tp,eg,ep,ev,re,r,rp) function c10000020.atkop(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -74,9 +74,9 @@ function c10045474.distg(e,c) ...@@ -74,9 +74,9 @@ function c10045474.distg(e,c)
end end
function c10045474.disop(e,tp,eg,ep,ev,re,r,rp) function c10045474.disop(e,tp,eg,ep,ev,re,r,rp)
local tseq=e:GetLabel() local tseq=e:GetLabel()
local loc,seq=Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_LOCATION,CHAININFO_TRIGGERING_SEQUENCE) local controller,loc,seq=Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_CONTROLER,CHAININFO_TRIGGERING_LOCATION,CHAININFO_TRIGGERING_SEQUENCE)
if loc&LOCATION_SZONE~=0 and seq<=4 and re:IsActiveType(TYPE_SPELL+TYPE_TRAP) if loc&LOCATION_SZONE~=0 and seq<=4 and re:IsActiveType(TYPE_SPELL+TYPE_TRAP)
and ((rp==tp and seq==tseq) or (rp==1-tp and seq==4-tseq)) then and ((controller==tp and seq==tseq) or (controller==1-tp and seq==4-tseq)) then
Duel.NegateEffect(ev) Duel.NegateEffect(ev)
end end
end end
......
...@@ -42,7 +42,7 @@ function c10239627.initial_effect(c) ...@@ -42,7 +42,7 @@ function c10239627.initial_effect(c)
c:RegisterEffect(e6) c:RegisterEffect(e6)
end end
function c10239627.acop(e,tp,eg,ep,ev,re,r,rp) function c10239627.acop(e,tp,eg,ep,ev,re,r,rp)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsActiveType(TYPE_SPELL) and e:GetHandler():GetFlagEffect(1)>0 then if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsActiveType(TYPE_SPELL) and e:GetHandler():GetFlagEffect(FLAG_ID_CHAINING)>0 then
e:GetHandler():AddCounter(0x1,1) e:GetHandler():AddCounter(0x1,1)
end end
end end
......
...@@ -41,5 +41,6 @@ function c10275411.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -41,5 +41,6 @@ function c10275411.activate(e,tp,eg,ep,ev,re,r,rp)
local oc=mg:GetFirst():GetOverlayTarget() local oc=mg:GetFirst():GetOverlayTarget()
Duel.Overlay(tc,mg) Duel.Overlay(tc,mg)
Duel.RaiseSingleEvent(oc,EVENT_DETACH_MATERIAL,e,0,0,0,0) Duel.RaiseSingleEvent(oc,EVENT_DETACH_MATERIAL,e,0,0,0,0)
Duel.RaiseEvent(oc,EVENT_DETACH_MATERIAL,e,0,0,0,0)
end end
end end
...@@ -25,7 +25,7 @@ function c10497636.initial_effect(c) ...@@ -25,7 +25,7 @@ function c10497636.initial_effect(c)
e3:SetCategory(CATEGORY_ATKCHANGE) e3:SetCategory(CATEGORY_ATKCHANGE)
e3:SetType(EFFECT_TYPE_QUICK_O) e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetRange(LOCATION_MZONE) e3:SetRange(LOCATION_MZONE)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP) e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP)
e3:SetCode(EVENT_FREE_CHAIN) e3:SetCode(EVENT_FREE_CHAIN)
e3:SetCountLimit(1) e3:SetCountLimit(1)
e3:SetCondition(c10497636.atkcon) e3:SetCondition(c10497636.atkcon)
...@@ -109,7 +109,7 @@ function c10497636.disop2(e,tp,eg,ep,ev,re,r,rp) ...@@ -109,7 +109,7 @@ function c10497636.disop2(e,tp,eg,ep,ev,re,r,rp)
end end
function c10497636.atkcon(e,tp,eg,ep,ev,re,r,rp) function c10497636.atkcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFlagEffect(tp,10497636)>0 return Duel.GetFlagEffect(tp,10497636)>0
and (Duel.GetCurrentPhase()>=PHASE_BATTLE_START and Duel.GetCurrentPhase()<=PHASE_BATTLE) and aux.dscon() and (Duel.GetCurrentPhase()>=PHASE_BATTLE_START and Duel.GetCurrentPhase()<=PHASE_BATTLE) and aux.dscon(e,tp,eg,ep,ev,re,r,rp)
end end
function c10497636.atkfilter(c) function c10497636.atkfilter(c)
return c:IsFaceup() and c:IsSetCard(0x15f) return c:IsFaceup() and c:IsSetCard(0x15f)
......
...@@ -25,14 +25,14 @@ function s.initial_effect(c) ...@@ -25,14 +25,14 @@ function s.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function s.target(e,tp,eg,ep,ev,re,r,rp,chk) function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and if chk==0 then return e:IsCostChecked()
Duel.IsPlayerCanSpecialSummonMonster(tp,id,0,TYPES_EFFECT_TRAP_MONSTER,0,2000,2,RACE_BEAST,ATTRIBUTE_EARTH) end and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,id,0,TYPES_EFFECT_TRAP_MONSTER,0,2000,2,RACE_BEAST,ATTRIBUTE_EARTH) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function s.activate(e,tp,eg,ep,ev,re,r,rp) function s.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if not Duel.IsPlayerCanSpecialSummonMonster(tp,id,0,TYPES_EFFECT_TRAP_MONSTER,0,2000,2,RACE_BEAST,ATTRIBUTE_EARTH) then return end
or not Duel.IsPlayerCanSpecialSummonMonster(tp,id,0,TYPES_EFFECT_TRAP_MONSTER,0,2000,2,RACE_BEAST,ATTRIBUTE_EARTH) then return end
c:AddMonsterAttribute(TYPE_EFFECT+TYPE_TRAP) c:AddMonsterAttribute(TYPE_EFFECT+TYPE_TRAP)
Duel.SpecialSummon(c,0,tp,tp,true,false,POS_FACEUP) Duel.SpecialSummon(c,0,tp,tp,true,false,POS_FACEUP)
end end
......
...@@ -27,7 +27,7 @@ function c10805153.filter(c) ...@@ -27,7 +27,7 @@ function c10805153.filter(c)
end end
function c10805153.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc,exc) function c10805153.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc,exc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and chkc:IsFaceup() end if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and chkc:IsFaceup() end
if chk==0 then return aux.bpcon() if chk==0 then return aux.bpcon(e,tp,eg,ep,ev,re,r,rp)
and Duel.IsExistingTarget(c10805153.filter,tp,LOCATION_MZONE,0,1,exc) end and Duel.IsExistingTarget(c10805153.filter,tp,LOCATION_MZONE,0,1,exc) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
Duel.SelectTarget(tp,c10805153.filter,tp,LOCATION_MZONE,0,1,1,nil) Duel.SelectTarget(tp,c10805153.filter,tp,LOCATION_MZONE,0,1,1,nil)
......
...@@ -18,7 +18,7 @@ function c111280.cfilter(c) ...@@ -18,7 +18,7 @@ function c111280.cfilter(c)
end end
function c111280.condition(e,tp,eg,ep,ev,re,r,rp) function c111280.condition(e,tp,eg,ep,ev,re,r,rp)
local ct=Duel.GetMatchingGroupCount(c111280.cfilter,tp,LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD+LOCATION_GRAVE,nil) local ct=Duel.GetMatchingGroupCount(c111280.cfilter,tp,LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD+LOCATION_GRAVE,nil)
return ct>0 and aux.dscon() return ct>0 and aux.dscon(e,tp,eg,ep,ev,re,r,rp)
end end
function c111280.filter(c) function c111280.filter(c)
return c:IsFaceup() and c:IsRace(RACE_SPELLCASTER) and c:IsAttribute(ATTRIBUTE_DARK) return c:IsFaceup() and c:IsRace(RACE_SPELLCASTER) and c:IsAttribute(ATTRIBUTE_DARK)
......
--ガーディアン・キマイラ --ガーディアン・キマイラ
function c11321089.initial_effect(c) function c11321089.initial_effect(c)
aux.AddCodeList(c,24094653)
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddFusionProcFunRep(c,c11321089.ffilter,3,false) aux.AddFusionProcFunRep(c,c11321089.ffilter,3,false)
--material limit --material limit
......
...@@ -40,7 +40,6 @@ function s.destarget(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -40,7 +40,6 @@ function s.destarget(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function s.desop(e,tp,eg,ep,ev,re,r,rp) function s.desop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,aux.ExceptThisCard(e)) local g=Duel.GetMatchingGroup(aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,aux.ExceptThisCard(e))
Duel.Destroy(g,REASON_EFFECT)
local c=e:GetHandler() local c=e:GetHandler()
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
...@@ -50,6 +49,7 @@ function s.desop(e,tp,eg,ep,ev,re,r,rp) ...@@ -50,6 +49,7 @@ function s.desop(e,tp,eg,ep,ev,re,r,rp)
e1:SetValue(s.val) e1:SetValue(s.val)
e1:SetReset(RESET_PHASE+PHASE_END) e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
Duel.Destroy(g,REASON_EFFECT)
end end
function s.val(e,re,ev,r,rp,rc) function s.val(e,re,ev,r,rp,rc)
return bit.band(r,REASON_EFFECT)~=0 return bit.band(r,REASON_EFFECT)~=0
...@@ -80,4 +80,4 @@ function s.drop(e,tp,eg,ep,ev,re,r,rp) ...@@ -80,4 +80,4 @@ function s.drop(e,tp,eg,ep,ev,re,r,rp)
Duel.BreakEffect() Duel.BreakEffect()
Duel.Draw(tp,3,REASON_EFFECT) Duel.Draw(tp,3,REASON_EFFECT)
end end
end end
\ No newline at end of file
--フライファング --フライファング
local s,id,o=GetID()
function c11954712.initial_effect(c) function c11954712.initial_effect(c)
--reg --reg
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
...@@ -37,16 +38,17 @@ end ...@@ -37,16 +38,17 @@ end
function c11954712.rmop(e,tp,eg,ep,ev,re,r,rp) function c11954712.rmop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if c:IsRelateToEffect(e) then if c:IsRelateToEffect(e) then
if Duel.Remove(c,0,REASON_EFFECT+REASON_TEMPORARY)==0 then return end if Duel.Remove(c,0,REASON_EFFECT+REASON_TEMPORARY)~=0 and c:GetOriginalCode()==id then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_PHASE+PHASE_STANDBY) e1:SetCode(EVENT_PHASE+PHASE_STANDBY)
e1:SetCountLimit(1) e1:SetCountLimit(1)
e1:SetLabelObject(c) e1:SetLabelObject(c)
e1:SetCondition(c11954712.retcon) e1:SetCondition(c11954712.retcon)
e1:SetOperation(c11954712.retop) e1:SetOperation(c11954712.retop)
e1:SetReset(RESET_PHASE+PHASE_STANDBY+RESET_SELF_TURN) e1:SetReset(RESET_PHASE+PHASE_STANDBY+RESET_SELF_TURN)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
end
end end
end end
function c11954712.retcon(e,tp,eg,ep,ev,re,r,rp) function c11954712.retcon(e,tp,eg,ep,ev,re,r,rp)
......
...@@ -16,11 +16,11 @@ end ...@@ -16,11 +16,11 @@ end
function c11961740.activate(e,tp,eg,ep,ev,re,r,rp) function c11961740.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if c:IsRelateToEffect(e) then if c:IsRelateToEffect(e) then
local fid=c:GetFieldID()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_DECK,0,1,1,nil,tp,POS_FACEDOWN) local rc=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_DECK,0,1,1,nil,tp,POS_FACEDOWN):GetFirst()
local tc=g:GetFirst() if rc and Duel.Remove(rc,POS_FACEDOWN,REASON_EFFECT)~=0 and e:IsHasType(EFFECT_TYPE_ACTIVATE) then
if tc and Duel.Remove(tc,POS_FACEDOWN,REASON_EFFECT)~=0 and e:IsHasType(EFFECT_TYPE_ACTIVATE) then rc:RegisterFlagEffect(11961740,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_STANDBY+RESET_SELF_TURN,0,2,fid)
tc:RegisterFlagEffect(11961740,RESET_EVENT+RESETS_STANDARD,0,1)
c:CancelToGrave() c:CancelToGrave()
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
...@@ -30,8 +30,8 @@ function c11961740.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -30,8 +30,8 @@ function c11961740.activate(e,tp,eg,ep,ev,re,r,rp)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_STANDBY+RESET_SELF_TURN,2) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_STANDBY+RESET_SELF_TURN,2)
e1:SetCondition(c11961740.thcon) e1:SetCondition(c11961740.thcon)
e1:SetOperation(c11961740.thop) e1:SetOperation(c11961740.thop)
e1:SetLabel(0) e1:SetLabel(fid,0)
e1:SetLabelObject(tc) e1:SetLabelObject(rc)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
end end
...@@ -40,13 +40,15 @@ function c11961740.thcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -40,13 +40,15 @@ function c11961740.thcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp return Duel.GetTurnPlayer()==tp
end end
function c11961740.thop(e,tp,eg,ep,ev,re,r,rp) function c11961740.thop(e,tp,eg,ep,ev,re,r,rp)
local ct=e:GetLabel() local c=e:GetHandler()
e:GetHandler():SetTurnCounter(ct+1) local fid,ct=e:GetLabel()
if ct==1 then local tc=e:GetLabelObject()
Duel.Destroy(e:GetHandler(),REASON_RULE) ct=ct+1
local tc=e:GetLabelObject() c:SetTurnCounter(ct)
if tc:GetFlagEffect(11961740)~=0 then e:SetLabel(fid,ct)
Duel.SendtoHand(tc,nil,REASON_EFFECT) if ct~=2 then return end
end if Duel.Destroy(c,REASON_EFFECT)>0 and tc:GetFlagEffectLabel(11961740)==fid then
else e:SetLabel(1) end Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,tc)
end
end end
...@@ -68,5 +68,5 @@ function c12219047.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -68,5 +68,5 @@ function c12219047.operation(e,tp,eg,ep,ev,re,r,rp)
end end
function c12219047.condition2(e,tp,eg,ep,ev,re,r,rp) function c12219047.condition2(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetOverlayGroup():IsExists(Card.IsSetCard,1,nil,0x10db) return e:GetHandler():GetOverlayGroup():IsExists(Card.IsSetCard,1,nil,0x10db)
and aux.dscon() and aux.dscon(e,tp,eg,ep,ev,re,r,rp)
end end
...@@ -3,7 +3,6 @@ function c123709.initial_effect(c) ...@@ -3,7 +3,6 @@ function c123709.initial_effect(c)
--summon with no tribute --summon with no tribute
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(123709,0)) e1:SetDescription(aux.Stringid(123709,0))
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SUMMON_PROC) e1:SetCode(EFFECT_SUMMON_PROC)
e1:SetCondition(c123709.ntcon) e1:SetCondition(c123709.ntcon)
......
...@@ -49,7 +49,7 @@ function c12421694.atkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -49,7 +49,7 @@ function c12421694.atkop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c12421694.reccon(e,tp,eg,ep,ev,re,r,rp) function c12421694.reccon(e,tp,eg,ep,ev,re,r,rp)
return re and re:IsActiveType(TYPE_SPELL) and re:GetHandler():IsSetCard(0x115) and rp==tp and e:GetHandler():GetFlagEffect(1)>0 return re and re:IsActiveType(TYPE_SPELL) and re:GetHandler():IsSetCard(0x115) and rp==tp and e:GetHandler():GetFlagEffect(FLAG_ID_CHAINING)>0
end end
function c12421694.recop(e,tp,eg,ep,ev,re,r,rp) function c12421694.recop(e,tp,eg,ep,ev,re,r,rp)
Duel.Recover(tp,100,REASON_EFFECT) Duel.Recover(tp,100,REASON_EFFECT)
......
...@@ -52,7 +52,7 @@ function s.indct(e,re,r,rp) ...@@ -52,7 +52,7 @@ function s.indct(e,re,r,rp)
else return 0 end else return 0 end
end end
function s.ctcon(e,tp,eg,ep,ev,re,r,rp) function s.ctcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()~=tp and aux.dscon() return Duel.GetTurnPlayer()~=tp and aux.dscon(e,tp,eg,ep,ev,re,r,rp)
and (Duel.GetCurrentPhase()>=PHASE_BATTLE_START and Duel.GetCurrentPhase()<=PHASE_BATTLE) and (Duel.GetCurrentPhase()>=PHASE_BATTLE_START and Duel.GetCurrentPhase()<=PHASE_BATTLE)
end end
function s.ctcost(e,tp,eg,ep,ev,re,r,rp,chk) function s.ctcost(e,tp,eg,ep,ev,re,r,rp,chk)
......
...@@ -45,7 +45,7 @@ end ...@@ -45,7 +45,7 @@ end
function c12678870.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c12678870.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return false end if chkc then return false end
if chk==0 then return not Duel.IsPlayerAffectedByEffect(tp,59822133) if chk==0 then return not Duel.IsPlayerAffectedByEffect(tp,59822133)
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.GetMZoneCount(tp,e:GetHandler())>1
and Duel.IsExistingTarget(c12678870.filter1,tp,LOCATION_REMOVED,0,1,nil,e,tp) end and Duel.IsExistingTarget(c12678870.filter1,tp,LOCATION_REMOVED,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g1=Duel.SelectTarget(tp,c12678870.filter1,tp,LOCATION_REMOVED,0,1,1,nil,e,tp) local g1=Duel.SelectTarget(tp,c12678870.filter1,tp,LOCATION_REMOVED,0,1,1,nil,e,tp)
......
...@@ -38,7 +38,7 @@ function c12863633.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -38,7 +38,7 @@ function c12863633.operation(e,tp,eg,ep,ev,re,r,rp)
tc:RegisterEffect(e3) tc:RegisterEffect(e3)
end end
end end
function c12863633.rellimit(e,c,tp,sumtp) function c12863633.rellimit(e,c,tp)
return c==e:GetHandler() return c==e:GetHandler()
end end
function c12863633.synlimit(e,c) function c12863633.synlimit(e,c)
......
...@@ -79,7 +79,7 @@ function c13235258.filter(c) ...@@ -79,7 +79,7 @@ function c13235258.filter(c)
end end
function c13235258.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c13235258.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c13235258.filter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c13235258.filter(chkc) end
if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) if chk==0 then return e:IsCostChecked()
and Duel.IsExistingTarget(c13235258.filter,tp,LOCATION_MZONE,0,1,nil) end and Duel.IsExistingTarget(c13235258.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
Duel.SelectTarget(tp,c13235258.filter,tp,LOCATION_MZONE,0,1,1,nil) Duel.SelectTarget(tp,c13235258.filter,tp,LOCATION_MZONE,0,1,1,nil)
...@@ -113,7 +113,8 @@ function c13235258.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -113,7 +113,8 @@ function c13235258.activate(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c13235258.eqlimit(e,c) function c13235258.eqlimit(e,c)
return c:IsRace(RACE_INSECT) or e:GetHandler():GetEquipTarget()==c return e:GetHandler():GetEquipTarget()==c
or c:IsControler(e:GetHandlerPlayer()) and c:IsRace(RACE_INSECT)
end end
function c13235258.atkcon1(e) function c13235258.atkcon1(e)
local ec=e:GetHandler():GetEquipTarget() local ec=e:GetHandler():GetEquipTarget()
...@@ -138,7 +139,7 @@ function c13235258.ctop(e,tp,eg,ep,ev,re,r,rp) ...@@ -138,7 +139,7 @@ function c13235258.ctop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c13235258.ctcon2(e,tp,eg,ep,ev,re,r,rp) function c13235258.ctcon2(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetEquipTarget() and ep~=tp and e:GetHandler():GetFlagEffect(1)>0 return e:GetHandler():GetEquipTarget() and ep~=tp and e:GetHandler():GetFlagEffect(FLAG_ID_CHAINING)>0
end end
function c13235258.atkcon2(e) function c13235258.atkcon2(e)
return e:GetHandler():GetEquipTarget() return e:GetHandler():GetEquipTarget()
......
...@@ -17,7 +17,7 @@ function s.initial_effect(c) ...@@ -17,7 +17,7 @@ function s.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function s.condition(e,tp,eg,ep,ev,re,r,rp) function s.condition(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_NORMAL) and aux.dscon() return e:GetHandler():IsSummonType(SUMMON_TYPE_NORMAL) and aux.dscon(e,tp,eg,ep,ev,re,r,rp)
end end
function s.filter(c,e,tp) function s.filter(c,e,tp)
return c:IsLevelBelow(4) and c:IsRace(RACE_INSECT) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsLevelBelow(4) and c:IsRace(RACE_INSECT) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
......
...@@ -57,7 +57,7 @@ function c13317419.filter(c) ...@@ -57,7 +57,7 @@ function c13317419.filter(c)
end end
function c13317419.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c13317419.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c13317419.filter(chkc) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c13317419.filter(chkc) end
if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) if chk==0 then return e:IsCostChecked()
and Duel.IsExistingTarget(c13317419.filter,tp,LOCATION_MZONE,0,1,nil) end and Duel.IsExistingTarget(c13317419.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
Duel.SelectTarget(tp,c13317419.filter,tp,LOCATION_MZONE,0,1,1,nil) Duel.SelectTarget(tp,c13317419.filter,tp,LOCATION_MZONE,0,1,1,nil)
...@@ -82,13 +82,17 @@ function c13317419.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -82,13 +82,17 @@ function c13317419.operation(e,tp,eg,ep,ev,re,r,rp)
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_EQUIP_LIMIT) e2:SetCode(EFFECT_EQUIP_LIMIT)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetValue(1) e2:SetValue(c13317419.eqlimit)
e2:SetReset(RESET_EVENT+RESETS_STANDARD) e2:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e2) c:RegisterEffect(e2)
else else
c:CancelToGrave(false) c:CancelToGrave(false)
end end
end end
function c13317419.eqlimit(e,c)
return e:GetHandler():GetEquipTarget()==c
or c:IsControler(e:GetHandlerPlayer()) and c:IsPosition(POS_FACEUP_ATTACK) and c:IsAttackAbove(800)
end
function c13317419.descon(e,tp,eg,ep,ev,re,r,rp) function c13317419.descon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetEquipTarget() return e:GetHandler():GetEquipTarget()
end end
......
...@@ -40,7 +40,7 @@ function c13851202.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -40,7 +40,7 @@ function c13851202.operation(e,tp,eg,ep,ev,re,r,rp)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetCode(EVENT_PHASE+PHASE_END) e2:SetCode(EVENT_PHASE+PHASE_END)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE) e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetCountLimit(1) e2:SetCountLimit(1)
e2:SetOperation(c13851202.tgop) e2:SetOperation(c13851202.tgop)
e2:SetReset(RESET_EVENT+RESETS_STANDARD) e2:SetReset(RESET_EVENT+RESETS_STANDARD)
......
...@@ -19,14 +19,14 @@ function c13955608.initial_effect(c) ...@@ -19,14 +19,14 @@ function c13955608.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c13955608.target(e,tp,eg,ep,ev,re,r,rp,chk) function c13955608.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return e:IsCostChecked()
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,13955608,0,TYPES_EFFECT_TRAP_MONSTER,0,2000,4,RACE_MACHINE,ATTRIBUTE_EARTH) end and Duel.IsPlayerCanSpecialSummonMonster(tp,13955608,0,TYPES_EFFECT_TRAP_MONSTER,0,2000,4,RACE_MACHINE,ATTRIBUTE_EARTH) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function c13955608.activate(e,tp,eg,ep,ev,re,r,rp) function c13955608.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if not Duel.IsPlayerCanSpecialSummonMonster(tp,13955608,0,TYPES_EFFECT_TRAP_MONSTER,0,2000,4,RACE_MACHINE,ATTRIBUTE_EARTH) then return end
or not Duel.IsPlayerCanSpecialSummonMonster(tp,13955608,0,TYPES_EFFECT_TRAP_MONSTER,0,2000,4,RACE_MACHINE,ATTRIBUTE_EARTH) then return end
c:AddMonsterAttribute(TYPE_TRAP+TYPE_EFFECT) c:AddMonsterAttribute(TYPE_TRAP+TYPE_EFFECT)
Duel.SpecialSummon(c,SUMMON_VALUE_SELF,tp,tp,true,false,POS_FACEUP_DEFENSE) Duel.SpecialSummon(c,SUMMON_VALUE_SELF,tp,tp,true,false,POS_FACEUP_DEFENSE)
end end
......
...@@ -11,7 +11,7 @@ function c1409474.initial_effect(c) ...@@ -11,7 +11,7 @@ function c1409474.initial_effect(c)
--guess --guess
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1409474,0)) e2:SetDescription(aux.Stringid(1409474,0))
e2:SetCategory(CATEGORY_DECKDES) e2:SetCategory(CATEGORY_DECKDES+CATEGORY_SPECIAL_SUMMON+CATEGORY_GRAVE_SPSUMMON)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetCountLimit(1,1409474) e2:SetCountLimit(1,1409474)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
......
...@@ -65,19 +65,24 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -65,19 +65,24 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp)
e1:SetTargetRange(0xff,0xff) e1:SetTargetRange(0xff,0xff)
e1:SetTarget(aux.TargetBoolFunction(aux.NOT(Card.IsSetCard),0x196,0x19f)) e1:SetTarget(aux.TargetBoolFunction(aux.NOT(Card.IsSetCard),0x196,0x19f))
e1:SetReset(RESET_PHASE+PHASE_END) e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetValue(s.lim) e1:SetValue(s.fuslimit)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
local e2=e1:Clone() local e2=e1:Clone()
e2:SetCode(EFFECT_CANNOT_BE_SYNCHRO_MATERIAL) e2:SetCode(EFFECT_CANNOT_BE_SYNCHRO_MATERIAL)
e2:SetValue(s.sumlimit)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
local e3=e1:Clone() local e3=e2:Clone()
e3:SetCode(EFFECT_CANNOT_BE_XYZ_MATERIAL) e3:SetCode(EFFECT_CANNOT_BE_XYZ_MATERIAL)
Duel.RegisterEffect(e3,tp) Duel.RegisterEffect(e3,tp)
local e4=e1:Clone() local e4=e2:Clone()
e4:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL) e4:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
Duel.RegisterEffect(e4,tp) Duel.RegisterEffect(e4,tp)
end end
function s.lim(e,c) function s.fuslimit(e,c,sumtype)
if not c then return false end
return c:IsControler(e:GetHandlerPlayer()) and sumtype==SUMMON_TYPE_FUSION
end
function s.sumlimit(e,c)
if not c then return false end if not c then return false end
return c:IsControler(e:GetHandlerPlayer()) return c:IsControler(e:GetHandlerPlayer())
end end
......
...@@ -39,7 +39,7 @@ end ...@@ -39,7 +39,7 @@ end
function c14309486.cfilter2(c) function c14309486.cfilter2(c)
return c:IsType(TYPE_MONSTER) and c:IsRace(RACE_ROCK) and not c:IsPublic() return c:IsType(TYPE_MONSTER) and c:IsRace(RACE_ROCK) and not c:IsPublic()
end end
function c14309486.mtop(e,tp) function c14309486.mtop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
Duel.HintSelection(Group.FromCards(c)) Duel.HintSelection(Group.FromCards(c))
local g1=Duel.GetMatchingGroup(c14309486.cfilter1,tp,LOCATION_HAND,0,nil) local g1=Duel.GetMatchingGroup(c14309486.cfilter1,tp,LOCATION_HAND,0,nil)
......
...@@ -18,7 +18,6 @@ function c14365823.initial_effect(c) ...@@ -18,7 +18,6 @@ function c14365823.initial_effect(c)
e2:SetDescription(aux.Stringid(14365823,0)) e2:SetDescription(aux.Stringid(14365823,0))
e2:SetCategory(CATEGORY_ATKCHANGE) e2:SetCategory(CATEGORY_ATKCHANGE)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F) e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetCode(EVENT_SUMMON_SUCCESS) e2:SetCode(EVENT_SUMMON_SUCCESS)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetCondition(c14365823.damcon2) e2:SetCondition(c14365823.damcon2)
......
...@@ -8,7 +8,7 @@ function c14553285.initial_effect(c) ...@@ -8,7 +8,7 @@ function c14553285.initial_effect(c)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION) e1:SetCode(EFFECT_SPSUMMON_CONDITION)
e1:SetValue(aux.FALSE) e1:SetValue(aux.AssaultModeLimit)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--counter --counter
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
......
...@@ -42,7 +42,7 @@ function c14745409.initial_effect(c) ...@@ -42,7 +42,7 @@ function c14745409.initial_effect(c)
e5:SetCountLimit(1,14745409) e5:SetCountLimit(1,14745409)
e5:SetCondition(c14745409.eqcon) e5:SetCondition(c14745409.eqcon)
e5:SetTarget(c14745409.eqtg) e5:SetTarget(c14745409.eqtg)
e5:SetOperation(c14745409.operation) e5:SetOperation(c14745409.operation2)
c:RegisterEffect(e5) c:RegisterEffect(e5)
end end
function c14745409.eqlimit(e,c) function c14745409.eqlimit(e,c)
...@@ -61,7 +61,7 @@ end ...@@ -61,7 +61,7 @@ end
function c14745409.operation(e,tp,eg,ep,ev,re,r,rp) function c14745409.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if c:IsRelateToEffect(e) and tc and tc:IsRelateToEffect(e) and tc:IsFaceup() and c:CheckUniqueOnField(tp) then if tc and c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and tc:IsFaceup() and c:CheckUniqueOnField(tp) then
Duel.Equip(tp,c,tc) Duel.Equip(tp,c,tc)
end end
end end
...@@ -103,3 +103,11 @@ function c14745409.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -103,3 +103,11 @@ function c14745409.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,e:GetHandler(),1,0,0)
end end
function c14745409.operation2(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if tc and c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and tc:IsFaceup()
and tc:IsControler(tp) and tc:IsSetCard(0x107a) and c14745409.eqlimit(nil,c) and c:CheckUniqueOnField(tp) then
Duel.Equip(tp,c,tc)
end
end
...@@ -64,7 +64,8 @@ function c14772491.rcon(e) ...@@ -64,7 +64,8 @@ function c14772491.rcon(e)
end end
function c14772491.thcon(e,tp,eg,ep,ev,re,r,rp) function c14772491.thcon(e,tp,eg,ep,ev,re,r,rp)
local tc=e:GetLabelObject() local tc=e:GetLabelObject()
return tc and tc:IsOnField() and e:GetHandler():IsHasCardTarget(tc) return tc and tc:IsOnField() and tc:IsFaceup() and tc:IsSetCard(0x1f)
and e:GetHandler():IsHasCardTarget(tc)
end end
function c14772491.thop(e,tp,eg,ep,ev,re,r,rp) function c14772491.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.SendtoHand(e:GetLabelObject(),nil,REASON_EFFECT) Duel.SendtoHand(e:GetLabelObject(),nil,REASON_EFFECT)
......
...@@ -54,16 +54,16 @@ end ...@@ -54,16 +54,16 @@ end
function c15033525.damcon(e,tp,eg,ep,ev,re,r,rp) function c15033525.damcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCurrentPhase()==PHASE_MAIN1 return Duel.GetCurrentPhase()==PHASE_MAIN1
end end
function c15033525.ncostfilter(c) function c15033525.stfilter(c)
return not c:IsAbleToGraveAsCost() return c:GetOriginalType()&(TYPE_MONSTER)~=0
end end
function c15033525.damcost(e,tp,eg,ep,ev,re,r,rp,chk) function c15033525.damcost(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.GetFieldGroup(tp,LOCATION_MZONE,0) local g=Duel.GetFieldGroup(tp,LOCATION_MZONE,0)
g:RemoveCard(e:GetHandler()) g:RemoveCard(e:GetHandler())
if chk==0 then return g:GetCount()>0 and not g:IsExists(c15033525.ncostfilter,1,nil) end local mg=g:Filter(c15033525.stfilter,nil)
if chk==0 then return #mg>0 and not g:IsExists(aux.NOT(Card.IsAbleToGraveAsCost),1,nil) end
Duel.SendtoGrave(g,REASON_COST) Duel.SendtoGrave(g,REASON_COST)
local ct=g:FilterCount(Card.IsLocation,nil,LOCATION_GRAVE) e:SetLabel(mg:FilterCount(Card.IsLocation,nil,LOCATION_GRAVE))
e:SetLabel(ct)
end end
function c15033525.damtg(e,tp,eg,ep,ev,re,r,rp,chk) function c15033525.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
......
...@@ -4,7 +4,6 @@ function c15066114.initial_effect(c) ...@@ -4,7 +4,6 @@ function c15066114.initial_effect(c)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(15066114,0)) e1:SetDescription(aux.Stringid(15066114,0))
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_SUMMON_PROC) e1:SetCode(EFFECT_SUMMON_PROC)
e1:SetCondition(c15066114.ntcon) e1:SetCondition(c15066114.ntcon)
e1:SetOperation(c15066114.ntop) e1:SetOperation(c15066114.ntop)
......
...@@ -41,7 +41,7 @@ function c15684835.filter(c,e,tp) ...@@ -41,7 +41,7 @@ function c15684835.filter(c,e,tp)
end end
function c15684835.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c15684835.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return eg:IsContains(chkc) and c15684835.filter(chkc,e,tp) end if chkc then return eg:IsContains(chkc) and c15684835.filter(chkc,e,tp) end
if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) if chk==0 then return e:IsCostChecked()
and eg:IsExists(c15684835.filter,1,nil,e,tp) end and eg:IsExists(c15684835.filter,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
local g=eg:FilterSelect(tp,c15684835.filter,1,1,nil,e,tp) local g=eg:FilterSelect(tp,c15684835.filter,1,1,nil,e,tp)
......
...@@ -33,7 +33,7 @@ function s.eqop(e,tp,eg,ep,ev,re,r,rp) ...@@ -33,7 +33,7 @@ function s.eqop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local tc=Duel.GetDecktopGroup(tp,1):GetFirst() local tc=Duel.GetDecktopGroup(tp,1):GetFirst()
if c:IsFaceup() and c:IsRelateToEffect(e) and Duel.GetLocationCount(tp,LOCATION_SZONE)>0 if c:IsFaceup() and c:IsRelateToEffect(e) and Duel.GetLocationCount(tp,LOCATION_SZONE)>0
and tc and tc:IsFacedown() then and tc and tc:IsFacedown() and Duel.IsPlayerCanSSet(tp,tc) then
Duel.DisableShuffleCheck() Duel.DisableShuffleCheck()
if tc:IsForbidden() then if tc:IsForbidden() then
Duel.SendtoGrave(tc,REASON_RULE) Duel.SendtoGrave(tc,REASON_RULE)
......
...@@ -18,7 +18,7 @@ function c16067089.condition(e,tp,eg,ep,ev,re,r,rp) ...@@ -18,7 +18,7 @@ function c16067089.condition(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c16067089.cfilter,1,nil,tp) return eg:IsExists(c16067089.cfilter,1,nil,tp)
end end
function c16067089.filter(c,e,tp) function c16067089.filter(c,e,tp)
return c:IsCode(8062132) and c:IsCanBeSpecialSummoned(e,0,tp,true,false) return c:IsCode(8062132) and c:IsCanBeSpecialSummoned(e,0,tp,false,true)
end end
function c16067089.target(e,tp,eg,ep,ev,re,r,rp,chk) function c16067089.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
...@@ -30,8 +30,7 @@ function c16067089.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -30,8 +30,7 @@ function c16067089.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c16067089.filter,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,c16067089.filter,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil,e,tp)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc then if tc and Duel.SpecialSummon(tc,0,tp,tp,false,true,POS_FACEUP)>0 then
Duel.SpecialSummon(tc,0,tp,tp,true,false,POS_FACEUP)
tc:CompleteProcedure() tc:CompleteProcedure()
end end
end end
...@@ -19,7 +19,7 @@ function c1621413.initial_effect(c) ...@@ -19,7 +19,7 @@ function c1621413.initial_effect(c)
--disable --disable
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(1621413,1)) e2:SetDescription(aux.Stringid(1621413,1))
e2:SetCategory(CATEGORY_DESTROY+CATEGORY_NEGATE+CATEGORY_SPECIAL_SUMMON) e2:SetCategory(CATEGORY_DESTROY+CATEGORY_NEGATE+CATEGORY_SPECIAL_SUMMON+CATEGORY_GRAVE_SPSUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O) e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_CHAINING) e2:SetCode(EVENT_CHAINING)
e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL) e2:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DAMAGE_CAL)
......
...@@ -14,7 +14,7 @@ function c16708652.initial_effect(c) ...@@ -14,7 +14,7 @@ function c16708652.initial_effect(c)
end end
function c16708652.condition(e,tp,eg,ep,ev,re,r,rp) function c16708652.condition(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase() local ph=Duel.GetCurrentPhase()
return ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE and aux.dscon() return ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE and aux.dscon(e,tp,eg,ep,ev,re,r,rp)
end end
function c16708652.filter1(c) function c16708652.filter1(c)
return c:IsPosition(POS_FACEUP_ATTACK) and c:IsSetCard(0x11) and c:IsCanChangePosition() return c:IsPosition(POS_FACEUP_ATTACK) and c:IsSetCard(0x11) and c:IsCanChangePosition()
......
...@@ -16,12 +16,6 @@ function c16825874.initial_effect(c) ...@@ -16,12 +16,6 @@ function c16825874.initial_effect(c)
e2:SetCondition(c16825874.ccon) e2:SetCondition(c16825874.ccon)
e2:SetOperation(c16825874.cop) e2:SetOperation(c16825874.cop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--hand synchro for double tuner
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e3:SetCode(EFFECT_HAND_SYNCHRO)
c:RegisterEffect(e3)
end end
function c16825874.ccon(e,tp,eg,ep,ev,re,r,rp) function c16825874.ccon(e,tp,eg,ep,ev,re,r,rp)
return r==REASON_SYNCHRO return r==REASON_SYNCHRO
......
...@@ -45,7 +45,7 @@ function c17063599.actcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -45,7 +45,7 @@ function c17063599.actcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousLocation(LOCATION_HAND) return e:GetHandler():IsPreviousLocation(LOCATION_HAND)
end end
function c17063599.filter(c) function c17063599.filter(c)
return c:IsFaceup() and c:IsSummonLocation(LOCATION_EXTRA) return c:IsFaceup() and c:IsSummonLocation(LOCATION_EXTRA) and c:GetType()&TYPE_EFFECT~=0
end end
function c17063599.acttg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c17063599.acttg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and c17063599.filter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and c17063599.filter(chkc) end
......
...@@ -7,7 +7,7 @@ function c1764972.initial_effect(c) ...@@ -7,7 +7,7 @@ function c1764972.initial_effect(c)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION) e1:SetCode(EFFECT_SPSUMMON_CONDITION)
e1:SetValue(aux.FALSE) e1:SetValue(aux.AssaultModeLimit)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--Special summon --Special summon
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
......
...@@ -127,8 +127,7 @@ function c17760003.target3(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -127,8 +127,7 @@ function c17760003.target3(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
end end
function c17760003.operation3(e,tp,eg,ep,ev,re,r,rp) function c17760003.operation3(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() then if tc:IsRelateToEffect(e) and c17760003.filter3(tc) and Duel.Destroy(tc,REASON_EFFECT)~=0 then
Duel.Destroy(tc,REASON_EFFECT)
Duel.Draw(tp,1,REASON_EFFECT) Duel.Draw(tp,1,REASON_EFFECT)
end end
end end
...@@ -41,7 +41,7 @@ function c18013090.atcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -41,7 +41,7 @@ function c18013090.atcon(e,tp,eg,ep,ev,re,r,rp)
end end
function c18013090.atop(e,tp,eg,ep,ev,re,r,rp) function c18013090.atop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if c:GetFlagEffect(1)==0 or c:GetFlagEffect(18013090)~=0 then return end if c:GetFlagEffect(FLAG_ID_CHAINING)==0 or c:GetFlagEffect(18013090)~=0 then return end
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_UPDATE_ATTACK) e2:SetCode(EFFECT_UPDATE_ATTACK)
......
...@@ -54,7 +54,7 @@ function c18096222.filter(c) ...@@ -54,7 +54,7 @@ function c18096222.filter(c)
end end
function c18096222.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c18096222.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c18096222.filter(chkc) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c18096222.filter(chkc) end
if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) if chk==0 then return e:IsCostChecked()
and Duel.IsExistingTarget(c18096222.filter,tp,LOCATION_MZONE,0,1,nil) end and Duel.IsExistingTarget(c18096222.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
Duel.SelectTarget(tp,c18096222.filter,tp,LOCATION_MZONE,0,1,1,nil) Duel.SelectTarget(tp,c18096222.filter,tp,LOCATION_MZONE,0,1,1,nil)
...@@ -65,7 +65,7 @@ function c18096222.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -65,7 +65,7 @@ function c18096222.operation(e,tp,eg,ep,ev,re,r,rp)
if not c:IsLocation(LOCATION_SZONE) then return end if not c:IsLocation(LOCATION_SZONE) then return end
if not c:IsRelateToEffect(e) or c:IsStatus(STATUS_LEAVE_CONFIRMED) then return end if not c:IsRelateToEffect(e) or c:IsStatus(STATUS_LEAVE_CONFIRMED) then return end
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() then if tc:IsRelateToEffect(e) and tc:IsFaceup() and tc:IsControler(tp) then
Duel.Equip(tp,c,tc) Duel.Equip(tp,c,tc)
--Atkup --Atkup
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
...@@ -87,7 +87,8 @@ function c18096222.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -87,7 +87,8 @@ function c18096222.operation(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c18096222.eqlimit(e,c) function c18096222.eqlimit(e,c)
return c:GetControler()==e:GetOwnerPlayer() and c:IsType(TYPE_DUAL) return e:GetHandler():GetEquipTarget()==c
or c:IsControler(e:GetHandlerPlayer()) and c:IsType(TYPE_DUAL)
end end
function c18096222.dacon(e,tp,eg,ep,ev,re,r,rp) function c18096222.dacon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
......
--ガーディアン・デスサイス --ガーディアン・デスサイス
function c18175965.initial_effect(c) function c18175965.initial_effect(c)
aux.AddCodeList(c,34022290,81954378)
c:EnableReviveLimit() c:EnableReviveLimit()
--cannot special summon --cannot special summon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
...@@ -68,13 +69,13 @@ function c18175965.spcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -68,13 +69,13 @@ function c18175965.spcon(e,tp,eg,ep,ev,re,r,rp)
end end
function c18175965.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c18175965.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,true,false) end and e:GetHandler():IsCanBeSpecialSummoned(e,0,tp,true,true) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function c18175965.spop(e,tp,eg,ep,ev,re,r,rp) function c18175965.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end if not c:IsRelateToEffect(e) then return end
if Duel.SpecialSummon(c,0,tp,tp,true,false,POS_FACEUP)~=0 then if Duel.SpecialSummon(c,0,tp,tp,true,true,POS_FACEUP)~=0 then
c:CompleteProcedure() c:CompleteProcedure()
end end
end end
......
...@@ -41,7 +41,7 @@ function c18446701.filter(c) ...@@ -41,7 +41,7 @@ function c18446701.filter(c)
end end
function c18446701.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c18446701.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c18446701.filter(chkc) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c18446701.filter(chkc) end
if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) if chk==0 then return e:IsCostChecked()
and Duel.IsExistingTarget(c18446701.filter,tp,LOCATION_MZONE,0,1,nil) end and Duel.IsExistingTarget(c18446701.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
Duel.SelectTarget(tp,c18446701.filter,tp,LOCATION_MZONE,0,1,1,nil) Duel.SelectTarget(tp,c18446701.filter,tp,LOCATION_MZONE,0,1,1,nil)
...@@ -52,7 +52,7 @@ function c18446701.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -52,7 +52,7 @@ function c18446701.operation(e,tp,eg,ep,ev,re,r,rp)
if not c:IsLocation(LOCATION_SZONE) then return end if not c:IsLocation(LOCATION_SZONE) then return end
if not c:IsRelateToEffect(e) or c:IsStatus(STATUS_LEAVE_CONFIRMED) then return end if not c:IsRelateToEffect(e) or c:IsStatus(STATUS_LEAVE_CONFIRMED) then return end
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and tc:IsFaceup() and tc:GetControler()==c:GetControler() then if tc:IsRelateToEffect(e) and tc:IsFaceup() and tc:IsControler(tp) and tc:IsRace(RACE_SPELLCASTER) then
Duel.Equip(tp,c,tc) Duel.Equip(tp,c,tc)
--draw --draw
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
...@@ -75,5 +75,6 @@ function c18446701.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -75,5 +75,6 @@ function c18446701.operation(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c18446701.eqlimit(e,c) function c18446701.eqlimit(e,c)
return c:GetControler()==e:GetOwnerPlayer() and c:IsRace(RACE_SPELLCASTER) return e:GetHandler():GetEquipTarget()==c
or c:IsControler(e:GetHandlerPlayer()) and c:IsRace(RACE_SPELLCASTER)
end end
...@@ -48,7 +48,7 @@ function c18558867.checkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -48,7 +48,7 @@ function c18558867.checkop(e,tp,eg,ep,ev,re,r,rp)
end end
function c18558867.dracon(e,tp,eg,ep,ev,re,r,rp) function c18558867.dracon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFlagEffect(tp,18558867)>0 return Duel.GetFlagEffect(tp,18558867)>0
and (Duel.GetCurrentPhase()>=PHASE_BATTLE_START and Duel.GetCurrentPhase()<=PHASE_BATTLE) and aux.dscon() and (Duel.GetCurrentPhase()>=PHASE_BATTLE_START and Duel.GetCurrentPhase()<=PHASE_BATTLE) and aux.dscon(e,tp,eg,ep,ev,re,r,rp)
end end
function c18558867.atkfilter(c) function c18558867.atkfilter(c)
return c:IsFaceup() and c:IsSetCard(0x15f) return c:IsFaceup() and c:IsSetCard(0x15f)
......
...@@ -102,10 +102,10 @@ function c19162134.btcon2(e,tp,eg,ep,ev,re,r,rp) ...@@ -102,10 +102,10 @@ function c19162134.btcon2(e,tp,eg,ep,ev,re,r,rp)
else return false end else return false end
end end
function c19162134.chcon1(e,tp,eg,ep,ev,re,r,rp) function c19162134.chcon1(e,tp,eg,ep,ev,re,r,rp)
return rp==tp and Duel.GetCurrentChain()>=5 and e:GetHandler():GetFlagEffect(1)>0 return rp==tp and Duel.GetCurrentChain()>=5 and e:GetHandler():GetFlagEffect(FLAG_ID_CHAINING)>0
end end
function c19162134.chcon2(e,tp,eg,ep,ev,re,r,rp) function c19162134.chcon2(e,tp,eg,ep,ev,re,r,rp)
return rp==1-tp and Duel.GetCurrentChain()>=5 and e:GetHandler():GetFlagEffect(1)>0 return rp==1-tp and Duel.GetCurrentChain()>=5 and e:GetHandler():GetFlagEffect(FLAG_ID_CHAINING)>0
end end
function c19162134.tossop(e,tp,eg,ep,ev,re,r,rp) function c19162134.tossop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
......
--戦乙女の戦車 --戦乙女の戦車
function c19190082.initial_effect(c) function c19190082.initial_effect(c)
aux.EnableUnionAttribute(c,c19190082.eqlimit) aux.EnableUnionAttribute(c,c19190082.filter)
--equip
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(19190082,0))
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCategory(CATEGORY_EQUIP)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetTarget(c19190082.eqtg)
e1:SetOperation(c19190082.eqop)
c:RegisterEffect(e1)
--unequip
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(19190082,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_SZONE)
e2:SetTarget(c19190082.sptg)
e2:SetOperation(c19190082.spop)
c:RegisterEffect(e2)
--atk up --atk up
local e5=Effect.CreateEffect(c) local e5=Effect.CreateEffect(c)
e5:SetDescription(aux.Stringid(19190082,2)) e5:SetDescription(aux.Stringid(19190082,2))
...@@ -32,44 +13,7 @@ function c19190082.initial_effect(c) ...@@ -32,44 +13,7 @@ function c19190082.initial_effect(c)
c:RegisterEffect(e5) c:RegisterEffect(e5)
end end
function c19190082.filter(c) function c19190082.filter(c)
local ct1,ct2=c:GetUnionCount() return c:IsRace(RACE_FAIRY)
return c:IsFaceup() and c:IsRace(RACE_FAIRY) and ct2==0
end
function c19190082.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local c=e:GetHandler()
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c19190082.filter(chkc) end
if chk==0 then return e:GetHandler():GetFlagEffect(19190082)==0 and Duel.GetLocationCount(tp,LOCATION_SZONE)>0
and Duel.IsExistingTarget(c19190082.filter,tp,LOCATION_MZONE,0,1,c) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
local g=Duel.SelectTarget(tp,c19190082.filter,tp,LOCATION_MZONE,0,1,1,c)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,g,1,0,0)
c:RegisterFlagEffect(19190082,RESET_EVENT+0x7e0000+RESET_PHASE+PHASE_END,0,1)
end
function c19190082.eqop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if not c:IsRelateToEffect(e) or c:IsFacedown() then return end
if not tc:IsRelateToEffect(e) or not c19190082.filter(tc) then
Duel.SendtoGrave(c,REASON_EFFECT)
return
end
if not Duel.Equip(tp,c,tc,false) then return end
aux.SetUnionState(c)
end
function c19190082.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:GetFlagEffect(19190082)==0 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and c:GetEquipTarget() and c:IsCanBeSpecialSummoned(e,0,tp,true,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
c:RegisterFlagEffect(19190082,RESET_EVENT+0x7e0000+RESET_PHASE+PHASE_END,0,1)
end
function c19190082.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
Duel.SpecialSummon(c,0,tp,tp,true,false,POS_FACEUP)
end
function c19190082.eqlimit(e,c)
return c:IsRace(RACE_FAIRY) or e:GetHandler():GetEquipTarget()==c
end end
function c19190082.atkcon(e,tp,eg,ep,ev,re,r,rp) function c19190082.atkcon(e,tp,eg,ep,ev,re,r,rp)
local ec=e:GetHandler():GetEquipTarget() local ec=e:GetHandler():GetEquipTarget()
......
...@@ -69,7 +69,7 @@ function c19254117.ddop(e,tp,eg,ep,ev,re,r,rp) ...@@ -69,7 +69,7 @@ function c19254117.ddop(e,tp,eg,ep,ev,re,r,rp)
e:Reset() e:Reset()
end end
function c19254117.tgcon(e,tp,eg,ep,ev,re,r,rp) function c19254117.tgcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()~=tp and aux.bpcon() return Duel.GetTurnPlayer()~=tp and aux.bpcon(e,tp,eg,ep,ev,re,r,rp)
end end
function c19254117.tgfilter(c) function c19254117.tgfilter(c)
return c:GetFlagEffect(19254117)==0 return c:GetFlagEffect(19254117)==0
......
...@@ -69,7 +69,7 @@ function c19441018.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -69,7 +69,7 @@ function c19441018.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
g1:Merge(g2) g1:Merge(g2)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g1,2,0,0) Duel.SetOperationInfo(0,CATEGORY_DESTROY,g1,2,0,0)
end end
function c19441018.desop(e) function c19441018.desop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS) local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS)
local dg=g:Filter(Card.IsRelateToEffect,nil,e) local dg=g:Filter(Card.IsRelateToEffect,nil,e)
Duel.Destroy(dg,REASON_EFFECT) Duel.Destroy(dg,REASON_EFFECT)
......
...@@ -62,7 +62,7 @@ function c1953925.actcon(e) ...@@ -62,7 +62,7 @@ function c1953925.actcon(e)
return Duel.GetAttacker()==e:GetHandler() return Duel.GetAttacker()==e:GetHandler()
end end
function c1953925.descon(e,tp,eg,ep,ev,re,r,rp) function c1953925.descon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler()==Duel.GetAttacker() and aux.dsercon(e) return e:GetHandler()==Duel.GetAttacker() and aux.dsercon(e,tp,eg,ep,ev,re,r,rp)
end end
function c1953925.filter(c) function c1953925.filter(c)
return c:IsType(TYPE_SPELL+TYPE_TRAP) return c:IsType(TYPE_SPELL+TYPE_TRAP)
......
...@@ -17,7 +17,6 @@ function c20003527.initial_effect(c) ...@@ -17,7 +17,6 @@ function c20003527.initial_effect(c)
--summon proc --summon proc
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(20003527,0)) e3:SetDescription(aux.Stringid(20003527,0))
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e3:SetType(EFFECT_TYPE_SINGLE) e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_SUMMON_PROC) e3:SetCode(EFFECT_SUMMON_PROC)
e3:SetCondition(c20003527.sumcon) e3:SetCondition(c20003527.sumcon)
......
...@@ -66,7 +66,8 @@ function c20007374.filter(c,e,tp) ...@@ -66,7 +66,8 @@ function c20007374.filter(c,e,tp)
and Duel.GetLocationCountFromEx(tp,tp,nil,c)>0 and Duel.GetLocationCountFromEx(tp,tp,nil,c)>0
end end
function c20007374.target(e,tp,eg,ep,ev,re,r,rp,chk) function c20007374.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return aux.MustMaterialCheck(nil,tp,EFFECT_MUST_BE_SMATERIAL) if chk==0 then return e:IsCostChecked()
and aux.MustMaterialCheck(nil,tp,EFFECT_MUST_BE_SMATERIAL)
and Duel.IsExistingMatchingCard(c20007374.filter,tp,LOCATION_EXTRA,0,1,nil,e,tp) end and Duel.IsExistingMatchingCard(c20007374.filter,tp,LOCATION_EXTRA,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end end
......
...@@ -52,7 +52,7 @@ function c20137754.tgop(e,tp,eg,ep,ev,re,r,rp) ...@@ -52,7 +52,7 @@ function c20137754.tgop(e,tp,eg,ep,ev,re,r,rp)
end end
function c20137754.atkcon(e,tp,eg,ep,ev,re,r,rp) function c20137754.atkcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetFlagEffect(20137754)>0 return e:GetHandler():GetFlagEffect(20137754)>0
and aux.dscon() and aux.dscon(e,tp,eg,ep,ev,re,r,rp)
end end
function c20137754.atktg(e,tp,eg,ep,ev,re,r,rp,chk) function c20137754.atktg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetMatchingGroupCount(Card.IsType,tp,LOCATION_GRAVE,0,nil,TYPE_MONSTER)>0 end if chk==0 then return Duel.GetMatchingGroupCount(Card.IsType,tp,LOCATION_GRAVE,0,nil,TYPE_MONSTER)>0 end
......
...@@ -23,7 +23,7 @@ function c20419926.initial_effect(c) ...@@ -23,7 +23,7 @@ function c20419926.initial_effect(c)
end end
function c20419926.atkcon(e,tp,eg,ep,ev,re,r,rp) function c20419926.atkcon(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase() local ph=Duel.GetCurrentPhase()
return ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE and aux.dscon() return ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE and aux.dscon(e,tp,eg,ep,ev,re,r,rp)
end end
function c20419926.costfilter(c) function c20419926.costfilter(c)
return c:IsType(TYPE_LINK) and c:IsAttribute(ATTRIBUTE_DARK) and c:IsAttackAbove(1) and c:IsAbleToRemoveAsCost() return c:IsType(TYPE_LINK) and c:IsAttribute(ATTRIBUTE_DARK) and c:IsAttackAbove(1) and c:IsAbleToRemoveAsCost()
......
...@@ -6,7 +6,6 @@ function c20447641.initial_effect(c) ...@@ -6,7 +6,6 @@ function c20447641.initial_effect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_END_PHASE) e1:SetHintTiming(0,TIMING_END_PHASE)
e1:SetCost(c20447641.cost)
e1:SetTarget(c20447641.target) e1:SetTarget(c20447641.target)
e1:SetOperation(c20447641.activate) e1:SetOperation(c20447641.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
...@@ -26,34 +25,27 @@ function c20447641.initial_effect(c) ...@@ -26,34 +25,27 @@ function c20447641.initial_effect(c)
e4:SetCode(EFFECT_LIMIT_SET_PROC) e4:SetCode(EFFECT_LIMIT_SET_PROC)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c20447641.cost(e,tp,eg,ep,ev,re,r,rp,chk)
e:SetLabel(1)
return true
end
function c20447641.target(e,tp,eg,ep,ev,re,r,rp,chk) function c20447641.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then if chk==0 then return e:IsCostChecked()
if e:GetLabel()==0 then return false end and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
e:SetLabel(0) and Duel.IsPlayerCanSpecialSummonMonster(tp,20447641,0xaa,TYPES_EFFECT_TRAP_MONSTER,1800,1000,4,RACE_MACHINE,ATTRIBUTE_EARTH) end
return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,20447641,0xaa,TYPES_EFFECT_TRAP_MONSTER,1800,1000,4,RACE_MACHINE,ATTRIBUTE_EARTH) end
e:SetLabel(0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function c20447641.activate(e,tp,eg,ep,ev,re,r,rp) function c20447641.activate(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local c=e:GetHandler() local c=e:GetHandler()
if c:IsRelateToEffect(e) and Duel.IsPlayerCanSpecialSummonMonster(tp,20447641,0xaa,TYPES_EFFECT_TRAP_MONSTER,1800,1000,4,RACE_MACHINE,ATTRIBUTE_EARTH) then if c:IsRelateToEffect(e) and Duel.IsPlayerCanSpecialSummonMonster(tp,20447641,0xaa,TYPES_EFFECT_TRAP_MONSTER,1800,1000,4,RACE_MACHINE,ATTRIBUTE_EARTH) then
c:AddMonsterAttribute(TYPE_EFFECT) c:AddMonsterAttribute(TYPE_EFFECT)
Duel.SpecialSummonStep(c,0,tp,tp,true,false,POS_FACEUP) if Duel.SpecialSummonStep(c,0,tp,tp,true,false,POS_FACEUP) then
c:RegisterFlagEffect(20447641,RESET_EVENT+RESETS_STANDARD,0,1) c:RegisterFlagEffect(20447641,RESET_EVENT+RESETS_STANDARD,0,1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) e2:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
e2:SetTargetRange(LOCATION_ONFIELD,0) e2:SetTargetRange(LOCATION_ONFIELD,0)
e2:SetTarget(c20447641.indtg) e2:SetTarget(c20447641.indtg)
e2:SetValue(1) e2:SetValue(1)
e2:SetReset(RESET_PHASE+PHASE_END) e2:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end
Duel.SpecialSummonComplete() Duel.SpecialSummonComplete()
end end
end end
......
...@@ -26,8 +26,9 @@ function c20590515.initial_effect(c) ...@@ -26,8 +26,9 @@ function c20590515.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c20590515.target(e,tp,eg,ep,ev,re,r,rp,chk) function c20590515.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and if chk==0 then return e:IsCostChecked()
Duel.IsPlayerCanSpecialSummonMonster(tp,20590515,0,TYPES_NORMAL_TRAP_MONSTER,500,1800,5,RACE_ZOMBIE,ATTRIBUTE_LIGHT) end and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,20590515,0,TYPES_NORMAL_TRAP_MONSTER,500,1800,5,RACE_ZOMBIE,ATTRIBUTE_LIGHT) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function c20590515.filter(c) function c20590515.filter(c)
...@@ -35,8 +36,7 @@ function c20590515.filter(c) ...@@ -35,8 +36,7 @@ function c20590515.filter(c)
end end
function c20590515.activate(e,tp,eg,ep,ev,re,r,rp) function c20590515.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if not Duel.IsPlayerCanSpecialSummonMonster(tp,20590515,0,TYPES_NORMAL_TRAP_MONSTER,500,1800,5,RACE_ZOMBIE,ATTRIBUTE_LIGHT) then return end
or not Duel.IsPlayerCanSpecialSummonMonster(tp,20590515,0,TYPES_NORMAL_TRAP_MONSTER,500,1800,5,RACE_ZOMBIE,ATTRIBUTE_LIGHT) then return end
c:AddMonsterAttribute(TYPE_NORMAL+TYPE_TRAP) c:AddMonsterAttribute(TYPE_NORMAL+TYPE_TRAP)
if Duel.SpecialSummon(c,0,tp,tp,true,false,POS_FACEUP)~=0 if Duel.SpecialSummon(c,0,tp,tp,true,false,POS_FACEUP)~=0
and Duel.IsExistingMatchingCard(c20590515.filter,tp,LOCATION_ONFIELD,0,1,nil) and Duel.IsExistingMatchingCard(c20590515.filter,tp,LOCATION_ONFIELD,0,1,nil)
......
...@@ -40,7 +40,7 @@ function c20630765.initial_effect(c) ...@@ -40,7 +40,7 @@ function c20630765.initial_effect(c)
end end
function c20630765.ctop(e,tp,eg,ep,ev,re,r,rp) function c20630765.ctop(e,tp,eg,ep,ev,re,r,rp)
local c=re:GetHandler() local c=re:GetHandler()
if re:IsActiveType(TYPE_MONSTER) and c~=e:GetHandler() and e:GetHandler():GetFlagEffect(1)>0 then if re:IsActiveType(TYPE_MONSTER) and c~=e:GetHandler() and e:GetHandler():GetFlagEffect(FLAG_ID_CHAINING)>0 then
e:GetHandler():AddCounter(0x16,1) e:GetHandler():AddCounter(0x16,1)
end end
end end
......
--揚陸群艦アンブロエール --揚陸群艦アンブロエール
function c20665527.initial_effect(c) function c20665527.initial_effect(c)
--same effect send this card to grave and spsummon another card check
local e0=aux.AddThisCardInGraveAlreadyCheck(c)
--link summon --link summon
aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkType,TYPE_EFFECT),2) aux.AddLinkProcedure(c,aux.FilterBoolFunction(Card.IsLinkType,TYPE_EFFECT),2)
c:EnableReviveLimit() c:EnableReviveLimit()
...@@ -30,6 +32,7 @@ function c20665527.initial_effect(c) ...@@ -30,6 +32,7 @@ function c20665527.initial_effect(c)
e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY) e3:SetProperty(EFFECT_FLAG_DAMAGE_STEP+EFFECT_FLAG_DELAY)
e3:SetCode(EVENT_DESTROYED) e3:SetCode(EVENT_DESTROYED)
e3:SetRange(LOCATION_GRAVE) e3:SetRange(LOCATION_GRAVE)
e3:SetLabelObject(e0)
e3:SetCountLimit(1,20665528) e3:SetCountLimit(1,20665528)
e3:SetCondition(c20665527.descon) e3:SetCondition(c20665527.descon)
e3:SetCost(aux.bfgcost) e3:SetCost(aux.bfgcost)
...@@ -57,12 +60,13 @@ function c20665527.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -57,12 +60,13 @@ function c20665527.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end end
end end
function c20665527.cfilter(c) function c20665527.cfilter(c,se)
return c:IsReason(REASON_BATTLE+REASON_EFFECT) and c:IsType(TYPE_LINK) and c:IsLinkBelow(3) return c:IsReason(REASON_BATTLE+REASON_EFFECT) and c:IsType(TYPE_LINK) and c:IsLinkBelow(3)
and c:IsPreviousLocation(LOCATION_MZONE) and c:IsPreviousLocation(LOCATION_MZONE) and (se==nil or c:GetReasonEffect()~=se)
end end
function c20665527.descon(e,tp,eg,ep,ev,re,r,rp) function c20665527.descon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c20665527.cfilter,1,e:GetHandler()) local se=e:GetLabelObject():GetLabelObject()
return eg:IsExists(c20665527.cfilter,1,e:GetHandler(),se)
end end
function c20665527.destg(e,tp,eg,ep,ev,re,r,rp,chk) function c20665527.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
......
...@@ -26,25 +26,26 @@ function c20960340.condition(e,tp,eg,ep,ev,re,r,rp) ...@@ -26,25 +26,26 @@ function c20960340.condition(e,tp,eg,ep,ev,re,r,rp)
end end
function c20960340.target(e,tp,eg,ep,ev,re,r,rp,chk) function c20960340.target(e,tp,eg,ep,ev,re,r,rp,chk)
local atk=Duel.GetLP(tp) local atk=Duel.GetLP(tp)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return e:IsCostChecked()
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,20960340,0,TYPES_EFFECT_TRAP_MONSTER,atk,0,4,RACE_WARRIOR,ATTRIBUTE_LIGHT,POS_FACEUP_ATTACK) end and Duel.IsPlayerCanSpecialSummonMonster(tp,20960340,0,TYPES_EFFECT_TRAP_MONSTER,atk,0,4,RACE_WARRIOR,ATTRIBUTE_LIGHT,POS_FACEUP_ATTACK) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function c20960340.activate(e,tp,eg,ep,ev,re,r,rp) function c20960340.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local atk=Duel.GetLP(tp) local atk=Duel.GetLP(tp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if not Duel.IsPlayerCanSpecialSummonMonster(tp,20960340,0,TYPES_EFFECT_TRAP_MONSTER,atk,0,4,RACE_WARRIOR,ATTRIBUTE_LIGHT,POS_FACEUP_ATTACK) then return end
or not Duel.IsPlayerCanSpecialSummonMonster(tp,20960340,0,TYPES_EFFECT_TRAP_MONSTER,atk,0,4,RACE_WARRIOR,ATTRIBUTE_LIGHT,POS_FACEUP_ATTACK) then return end
c:AddMonsterAttribute(TYPE_TRAP+TYPE_EFFECT) c:AddMonsterAttribute(TYPE_TRAP+TYPE_EFFECT)
Duel.SpecialSummonStep(c,SUMMON_VALUE_SELF,tp,tp,true,false,POS_FACEUP_ATTACK) if Duel.SpecialSummonStep(c,SUMMON_VALUE_SELF,tp,tp,true,false,POS_FACEUP_ATTACK) then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK) e1:SetCode(EFFECT_SET_ATTACK)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(atk) e1:SetValue(atk)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1) c:RegisterEffect(e1)
Duel.SpecialSummonComplete() end
if Duel.SpecialSummonComplete()==0 then return end
local at=Duel.GetAttacker() local at=Duel.GetAttacker()
if at and at:IsAttackable() and at:IsFaceup() and not at:IsImmuneToEffect(e) and not at:IsStatus(STATUS_ATTACK_CANCELED) then if at and at:IsAttackable() and at:IsFaceup() and not at:IsImmuneToEffect(e) and not at:IsStatus(STATUS_ATTACK_CANCELED) then
Duel.BreakEffect() Duel.BreakEffect()
......
...@@ -68,7 +68,7 @@ function c20989253.filter(c,tp) ...@@ -68,7 +68,7 @@ function c20989253.filter(c,tp)
end end
function c20989253.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c20989253.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and c20989253.filter(chkc,tp) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and c20989253.filter(chkc,tp) end
if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) if chk==0 then return e:IsCostChecked()
and Duel.IsExistingTarget(c20989253.filter,tp,0,LOCATION_MZONE,1,nil,tp) end and Duel.IsExistingTarget(c20989253.filter,tp,0,LOCATION_MZONE,1,nil,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
local g=Duel.SelectTarget(tp,c20989253.filter,tp,0,LOCATION_MZONE,1,1,nil,tp) local g=Duel.SelectTarget(tp,c20989253.filter,tp,0,LOCATION_MZONE,1,1,nil,tp)
...@@ -88,7 +88,6 @@ function c20989253.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -88,7 +88,6 @@ function c20989253.operation(e,tp,eg,ep,ev,re,r,rp)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
e1:SetValue(c20989253.eqlimit) e1:SetValue(c20989253.eqlimit)
e1:SetLabelObject(tc)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
elseif c:IsRelateToEffect(e) and not c:IsStatus(STATUS_LEAVE_CONFIRMED) then elseif c:IsRelateToEffect(e) and not c:IsStatus(STATUS_LEAVE_CONFIRMED) then
...@@ -96,7 +95,9 @@ function c20989253.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -96,7 +95,9 @@ function c20989253.operation(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c20989253.eqlimit(e,c) function c20989253.eqlimit(e,c)
return e:GetLabelObject()==c local tp=e:GetHandlerPlayer()
return e:GetHandler():GetEquipTarget()==c
or c:IsControler(1-tp) and c:GetEquipGroup():IsExists(c20989253.cfilter,1,nil,tp)
end end
function c20989253.cval(e,c) function c20989253.cval(e,c)
return e:GetHandlerPlayer() return e:GetHandlerPlayer()
......
...@@ -27,7 +27,7 @@ function c21051146.initial_effect(c) ...@@ -27,7 +27,7 @@ function c21051146.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c21051146.acop(e,tp,eg,ep,ev,re,r,rp) function c21051146.acop(e,tp,eg,ep,ev,re,r,rp)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsActiveType(TYPE_SPELL) and e:GetHandler():GetFlagEffect(1)>0 then if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsActiveType(TYPE_SPELL) and e:GetHandler():GetFlagEffect(FLAG_ID_CHAINING)>0 then
e:GetHandler():AddCounter(0x1,1) e:GetHandler():AddCounter(0x1,1)
end end
end end
......
--コズミック・ブレイザー・ドラゴン --コズミック・ブレイザー・ドラゴン
local s,id,o=GetID()
function c21123811.initial_effect(c) function c21123811.initial_effect(c)
--synchro summon --synchro summon
aux.AddSynchroProcedure(c,aux.FilterBoolFunction(Card.IsSynchroType,TYPE_SYNCHRO),aux.NonTuner(Card.IsSynchroType,TYPE_SYNCHRO),2) aux.AddSynchroProcedure(c,aux.FilterBoolFunction(Card.IsSynchroType,TYPE_SYNCHRO),aux.NonTuner(Card.IsSynchroType,TYPE_SYNCHRO),2)
...@@ -62,7 +63,7 @@ end ...@@ -62,7 +63,7 @@ end
function c21123811.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c21123811.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return c:IsAbleToRemoveAsCost() end if chk==0 then return c:IsAbleToRemoveAsCost() end
if Duel.Remove(c,0,REASON_COST+REASON_TEMPORARY)~=0 then if Duel.Remove(c,0,REASON_COST+REASON_TEMPORARY)~=0 and c:GetOriginalCode()==id then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_PHASE+PHASE_END) e1:SetCode(EVENT_PHASE+PHASE_END)
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
function c21140872.initial_effect(c) function c21140872.initial_effect(c)
--fusion material --fusion material
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddFusionProcCodeFun(c,74677422,aux.FilterBoolFunction(Card.IsRace,RACE_WARRIOR),1,true) aux.AddFusionProcCodeFun(c,74677422,aux.FilterBoolFunction(Card.IsRace,RACE_WARRIOR),1,true,true)
--equip --equip
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(21140872,0)) e1:SetDescription(aux.Stringid(21140872,0))
......
...@@ -45,7 +45,7 @@ function c2129638.rmcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -45,7 +45,7 @@ function c2129638.rmcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local bc=c:GetBattleTarget() local bc=c:GetBattleTarget()
e:SetLabelObject(bc) e:SetLabelObject(bc)
return c==Duel.GetAttacker() and aux.dsercon(e) return c==Duel.GetAttacker() and aux.dsercon(e,tp,eg,ep,ev,re,r,rp)
and bc and c:IsStatus(STATUS_OPPO_BATTLE) and bc:IsOnField() and bc:IsRelateToBattle() and bc and c:IsStatus(STATUS_OPPO_BATTLE) and bc:IsOnField() and bc:IsRelateToBattle()
end end
function c2129638.rmtg(e,tp,eg,ep,ev,re,r,rp,chk) function c2129638.rmtg(e,tp,eg,ep,ev,re,r,rp,chk)
......
...@@ -43,7 +43,7 @@ function c21350571.filter(c) ...@@ -43,7 +43,7 @@ function c21350571.filter(c)
end end
function c21350571.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c21350571.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c21350571.filter(chkc) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c21350571.filter(chkc) end
if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) if chk==0 then return e:IsCostChecked()
and Duel.IsExistingTarget(c21350571.filter,tp,LOCATION_MZONE,0,1,nil) end and Duel.IsExistingTarget(c21350571.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
Duel.SelectTarget(tp,c21350571.filter,tp,LOCATION_MZONE,0,1,1,nil) Duel.SelectTarget(tp,c21350571.filter,tp,LOCATION_MZONE,0,1,1,nil)
...@@ -89,7 +89,8 @@ function c21350571.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -89,7 +89,8 @@ function c21350571.operation(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c21350571.eqlimit(e,c) function c21350571.eqlimit(e,c)
return c:IsRace(RACE_BEAST+RACE_BEASTWARRIOR) return e:GetHandler():GetEquipTarget()==c
or c:IsControler(e:GetHandlerPlayer()) and c:IsRace(RACE_BEAST+RACE_BEASTWARRIOR)
end end
function c21350571.drfilter(c,rc) function c21350571.drfilter(c,rc)
return c:IsLocation(LOCATION_GRAVE) and c:IsReason(REASON_BATTLE) and c:GetReasonCard()==rc return c:IsLocation(LOCATION_GRAVE) and c:IsReason(REASON_BATTLE) and c:GetReasonCard()==rc
......
...@@ -16,7 +16,7 @@ function s.initial_effect(c) ...@@ -16,7 +16,7 @@ function s.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function s.dgfilter(c,e,tp) function s.dgfilter(c,e,tp)
return c:IsSummonPlayer(1-tp) and c:IsCanBeEffectTarget(e) return c:IsSummonPlayer(1-tp) and c:IsLocation (LOCATION_MZONE) and c:IsCanBeEffectTarget(e)
end end
function s.spfilter(c,e,tp) function s.spfilter(c,e,tp)
return c:IsSetCard(0x192) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsSetCard(0x192) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
...@@ -24,7 +24,7 @@ end ...@@ -24,7 +24,7 @@ end
function s.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function s.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return eg:IsContains(chkc) and s.dgfilter(chkc,e,tp) end if chkc then return eg:IsContains(chkc) and s.dgfilter(chkc,e,tp) end
local sg=Duel.GetMatchingGroup(s.spfilter,tp,LOCATION_DECK,0,nil,e,tp) local sg=Duel.GetMatchingGroup(s.spfilter,tp,LOCATION_DECK,0,nil,e,tp)
if chk==0 then return eg:IsExists(s.dgfilter,1,nil,e,tp) and #sg>=3 end if chk==0 then return eg:IsExists(s.dgfilter,1,nil,e,tp) and #sg>=3 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 end
local dg=eg local dg=eg
if #eg>1 then if #eg>1 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
......
...@@ -16,8 +16,9 @@ function c21843307.condition(e,tp,eg,ep,ev,re,r,rp) ...@@ -16,8 +16,9 @@ function c21843307.condition(e,tp,eg,ep,ev,re,r,rp)
end end
function c21843307.target(e,tp,eg,ep,ev,re,r,rp,chk) function c21843307.target(e,tp,eg,ep,ev,re,r,rp,chk)
local ec=eg:GetFirst() local ec=eg:GetFirst()
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and if chk==0 then return e:IsCostChecked()
Duel.IsPlayerCanSpecialSummonMonster(tp,ec:GetCode(),0,TYPES_NORMAL_TRAP_MONSTER,0,0,ec:GetLevel(),RACE_WARRIOR,ATTRIBUTE_LIGHT) end and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,ec:GetCode(),0,TYPES_NORMAL_TRAP_MONSTER,0,0,ec:GetLevel(),RACE_WARRIOR,ATTRIBUTE_LIGHT) end
ec:CreateEffectRelation(e) ec:CreateEffectRelation(e)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
...@@ -25,17 +26,17 @@ function c21843307.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -25,17 +26,17 @@ function c21843307.activate(e,tp,eg,ep,ev,re,r,rp)
local ec=eg:GetFirst() local ec=eg:GetFirst()
if not ec:IsRelateToEffect(e) then return end if not ec:IsRelateToEffect(e) then return end
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if not Duel.IsPlayerCanSpecialSummonMonster(tp,ec:GetCode(),0,TYPES_NORMAL_TRAP_MONSTER,0,0,ec:GetLevel(),RACE_WARRIOR,ATTRIBUTE_LIGHT) then return end
or not Duel.IsPlayerCanSpecialSummonMonster(tp,ec:GetCode(),0,TYPES_NORMAL_TRAP_MONSTER,0,0,ec:GetLevel(),RACE_WARRIOR,ATTRIBUTE_LIGHT) then return end
c:AddMonsterAttribute(TYPE_NORMAL+TYPE_TRAP,0,0,ec:GetLevel(),0,0) c:AddMonsterAttribute(TYPE_NORMAL+TYPE_TRAP,0,0,ec:GetLevel(),0,0)
Duel.SpecialSummonStep(c,0,tp,tp,true,false,POS_FACEUP) if Duel.SpecialSummonStep(c,0,tp,tp,true,false,POS_FACEUP) then
--change code --change code
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CHANGE_CODE) e1:SetCode(EFFECT_CHANGE_CODE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(ec:GetCode()) e1:SetValue(ec:GetCode())
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e1,true) c:RegisterEffect(e1,true)
end
Duel.SpecialSummonComplete() Duel.SpecialSummonComplete()
end end
...@@ -14,7 +14,7 @@ end ...@@ -14,7 +14,7 @@ end
function c21887179.descon(e,tp,eg,ep,ev,re,r,rp) function c21887179.descon(e,tp,eg,ep,ev,re,r,rp)
local t=e:GetHandler():GetBattleTarget() local t=e:GetHandler():GetBattleTarget()
e:SetLabelObject(t) e:SetLabelObject(t)
return aux.dsercon(e) and t and t:IsRace(RACE_FIEND+RACE_ZOMBIE) and t:IsRelateToBattle() return aux.dsercon(e,tp,eg,ep,ev,re,r,rp) and t and t:IsRace(RACE_FIEND+RACE_ZOMBIE) and t:IsRelateToBattle()
end end
function c21887179.destg(e,tp,eg,ep,ev,re,r,rp,chk) function c21887179.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
......
--竜輝巧-ルタδ --竜輝巧-ルタδ
function c22420202.initial_effect(c) function c22420202.initial_effect(c)
c:EnableReviveLimit()
--spsummon condition --spsummon condition
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
......
--カオス・アンヘル-混沌の双翼- --カオス・アンヘル-混沌の双翼-
function c22850702.initial_effect(c) function c22850702.initial_effect(c)
--synchro summon --synchro summon
c:EnableReviveLimit() c:EnableReviveLimit()
...@@ -92,6 +92,6 @@ function c22850702.regop(e,tp,eg,ep,ev,re,r,rp) ...@@ -92,6 +92,6 @@ function c22850702.regop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c22850702.efilter(e,re) function c22850702.efilter(e,re)
return re:GetOwnerPlayer()~=e:GetOwnerPlayer() and re:IsActivated() return re:GetOwnerPlayer()~=e:GetHandlerPlayer() and re:IsActivated()
and re:IsActiveType(TYPE_MONSTER) and re:IsActiveType(TYPE_MONSTER)
end end
...@@ -41,7 +41,7 @@ function c23122036.filter(c) ...@@ -41,7 +41,7 @@ function c23122036.filter(c)
end end
function c23122036.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c23122036.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c23122036.filter(chkc) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c23122036.filter(chkc) end
if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) if chk==0 then return e:IsCostChecked()
and Duel.IsExistingTarget(c23122036.filter,tp,LOCATION_MZONE,0,1,nil) end and Duel.IsExistingTarget(c23122036.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
Duel.SelectTarget(tp,c23122036.filter,tp,LOCATION_MZONE,0,1,1,nil) Duel.SelectTarget(tp,c23122036.filter,tp,LOCATION_MZONE,0,1,1,nil)
...@@ -74,7 +74,7 @@ function c23122036.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -74,7 +74,7 @@ function c23122036.operation(e,tp,eg,ep,ev,re,r,rp)
e3:SetType(EFFECT_TYPE_SINGLE) e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_EQUIP_LIMIT) e3:SetCode(EFFECT_EQUIP_LIMIT)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e3:SetValue(1) e3:SetValue(c23122036.eqlimit)
e3:SetReset(RESET_EVENT+RESETS_STANDARD) e3:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e3) c:RegisterEffect(e3)
else else
...@@ -87,3 +87,6 @@ end ...@@ -87,3 +87,6 @@ end
function c23122036.damcon(e) function c23122036.damcon(e)
return e:GetHandler():GetEquipTarget():GetControler()==e:GetHandlerPlayer() return e:GetHandler():GetEquipTarget():GetControler()==e:GetHandlerPlayer()
end end
function c23122036.eqlimit(e,c)
return e:GetHandler():GetEquipTarget()==c or c:IsControler(e:GetHandlerPlayer())
end
--強化支援メカ・ヘビーウェポン --強化支援メカ・ヘビーウェポン
function c23265594.initial_effect(c) function c23265594.initial_effect(c)
aux.EnableUnionAttribute(c,c23265594.eqlimit) aux.EnableUnionAttribute(c,c23265594.filter)
--equip
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(23265594,0))
e1:SetProperty(EFFECT_FLAG_CARD_TARGET)
e1:SetCategory(CATEGORY_EQUIP)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE)
e1:SetTarget(c23265594.eqtg)
e1:SetOperation(c23265594.eqop)
c:RegisterEffect(e1)
--unequip
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(23265594,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_SZONE)
e2:SetTarget(c23265594.sptg)
e2:SetOperation(c23265594.spop)
c:RegisterEffect(e2)
--Atk up --Atk up
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_EQUIP) e3:SetType(EFFECT_TYPE_EQUIP)
...@@ -33,42 +14,6 @@ function c23265594.initial_effect(c) ...@@ -33,42 +14,6 @@ function c23265594.initial_effect(c)
e4:SetValue(500) e4:SetValue(500)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c23265594.eqlimit(e,c)
return c:IsRace(RACE_MACHINE) or e:GetHandler():GetEquipTarget()==c
end
function c23265594.filter(c) function c23265594.filter(c)
local ct1,ct2=c:GetUnionCount() return c:IsRace(RACE_MACHINE)
return c:IsFaceup() and c:IsRace(RACE_MACHINE) and ct2==0
end
function c23265594.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c23265594.filter(chkc) end
if chk==0 then return e:GetHandler():GetFlagEffect(23265594)==0 and Duel.GetLocationCount(tp,LOCATION_SZONE)>0
and Duel.IsExistingTarget(c23265594.filter,tp,LOCATION_MZONE,0,1,e:GetHandler()) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
local g=Duel.SelectTarget(tp,c23265594.filter,tp,LOCATION_MZONE,0,1,1,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_EQUIP,g,1,0,0)
e:GetHandler():RegisterFlagEffect(23265594,RESET_EVENT+0x7e0000+RESET_PHASE+PHASE_END,0,1)
end
function c23265594.eqop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if not c:IsRelateToEffect(e) or c:IsFacedown() then return end
if not tc:IsRelateToEffect(e) or not c23265594.filter(tc) then
Duel.SendtoGrave(c,REASON_EFFECT)
return
end
if not Duel.Equip(tp,c,tc,false) then return end
aux.SetUnionState(c)
end
function c23265594.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:GetFlagEffect(23265594)==0 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and c:GetEquipTarget() and c:IsCanBeSpecialSummoned(e,0,tp,true,false) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,0,0)
c:RegisterFlagEffect(23265594,RESET_EVENT+0x7e0000+RESET_PHASE+PHASE_END,0,1)
end
function c23265594.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if not c:IsRelateToEffect(e) then return end
Duel.SpecialSummon(c,0,tp,tp,true,false,POS_FACEUP)
end end
...@@ -43,7 +43,7 @@ function c23562407.initial_effect(c) ...@@ -43,7 +43,7 @@ function c23562407.initial_effect(c)
e5:SetCountLimit(1,23562407) e5:SetCountLimit(1,23562407)
e5:SetCondition(c23562407.eqcon) e5:SetCondition(c23562407.eqcon)
e5:SetTarget(c23562407.eqtg) e5:SetTarget(c23562407.eqtg)
e5:SetOperation(c23562407.operation) e5:SetOperation(c23562407.operation2)
c:RegisterEffect(e5) c:RegisterEffect(e5)
end end
function c23562407.eqlimit(e,c) function c23562407.eqlimit(e,c)
...@@ -62,7 +62,7 @@ end ...@@ -62,7 +62,7 @@ end
function c23562407.operation(e,tp,eg,ep,ev,re,r,rp) function c23562407.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and tc:IsFaceup() and c:CheckUniqueOnField(tp) then if tc and c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and tc:IsFaceup() and c:CheckUniqueOnField(tp) then
Duel.Equip(tp,c,tc) Duel.Equip(tp,c,tc)
end end
end end
...@@ -92,3 +92,11 @@ function c23562407.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -92,3 +92,11 @@ function c23562407.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,e:GetHandler(),1,0,0)
end end
function c23562407.operation2(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if tc and c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and tc:IsFaceup()
and tc:IsControler(tp) and tc:IsSetCard(0x107a) and c23562407.eqlimit(nil,c) and c:CheckUniqueOnField(tp) then
Duel.Equip(tp,c,tc)
end
end
...@@ -31,14 +31,14 @@ function c23626223.initial_effect(c) ...@@ -31,14 +31,14 @@ function c23626223.initial_effect(c)
c:RegisterEffect(e3) c:RegisterEffect(e3)
end end
function c23626223.target(e,tp,eg,ep,ev,re,r,rp,chk) function c23626223.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return e:IsCostChecked()
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,23626223,0,TYPES_EFFECT_TRAP_MONSTER,0,2500,7,RACE_ROCK,ATTRIBUTE_EARTH) end and Duel.IsPlayerCanSpecialSummonMonster(tp,23626223,0,TYPES_EFFECT_TRAP_MONSTER,0,2500,7,RACE_ROCK,ATTRIBUTE_EARTH) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function c23626223.activate(e,tp,eg,ep,ev,re,r,rp) function c23626223.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if not Duel.IsPlayerCanSpecialSummonMonster(tp,23626223,0,TYPES_EFFECT_TRAP_MONSTER,0,2500,7,RACE_ROCK,ATTRIBUTE_EARTH) then return end
or not Duel.IsPlayerCanSpecialSummonMonster(tp,23626223,0,TYPES_EFFECT_TRAP_MONSTER,0,2500,7,RACE_ROCK,ATTRIBUTE_EARTH) then return end
c:AddMonsterAttribute(TYPE_EFFECT+TYPE_TRAP) c:AddMonsterAttribute(TYPE_EFFECT+TYPE_TRAP)
Duel.SpecialSummon(c,SUMMON_VALUE_SELF,tp,tp,true,false,POS_FACEUP) Duel.SpecialSummon(c,SUMMON_VALUE_SELF,tp,tp,true,false,POS_FACEUP)
end end
......
...@@ -41,7 +41,7 @@ function c23790299.initial_effect(c) ...@@ -41,7 +41,7 @@ function c23790299.initial_effect(c)
end end
function c23790299.atkcon(e,tp,eg,ep,ev,re,r,rp) function c23790299.atkcon(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase() local ph=Duel.GetCurrentPhase()
return ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE and aux.dscon() return ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE and aux.dscon(e,tp,eg,ep,ev,re,r,rp)
end end
function c23790299.atkcost(e,tp,eg,ep,ev,re,r,rp,chk) function c23790299.atkcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
......
...@@ -36,7 +36,7 @@ end ...@@ -36,7 +36,7 @@ end
function c24429467.acop(e,tp,eg,ep,ev,re,r,rp) function c24429467.acop(e,tp,eg,ep,ev,re,r,rp)
local p=Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_PLAYER) local p=Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_PLAYER)
local c=e:GetHandler() local c=e:GetHandler()
if re:IsActiveType(TYPE_MONSTER) and p~=tp and c:GetFlagEffect(1)>0 then if re:IsActiveType(TYPE_MONSTER) and p~=tp and c:GetFlagEffect(FLAG_ID_CHAINING)>0 then
c:AddCounter(0x1,1) c:AddCounter(0x1,1)
end end
end end
......
...@@ -41,7 +41,7 @@ function c24550676.initial_effect(c) ...@@ -41,7 +41,7 @@ function c24550676.initial_effect(c)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c24550676.condition(e,tp,eg,ep,ev,re,r,rp) function c24550676.condition(e,tp,eg,ep,ev,re,r,rp)
return aux.dsercon(e) and Duel.GetAttacker()==e:GetHandler() and Duel.GetAttackTarget() return aux.dsercon(e,tp,eg,ep,ev,re,r,rp) and Duel.GetAttacker()==e:GetHandler() and Duel.GetAttackTarget()
end end
function c24550676.filter(c) function c24550676.filter(c)
return c:IsSummonType(SUMMON_TYPE_SPECIAL) return c:IsSummonType(SUMMON_TYPE_SPECIAL)
......
...@@ -55,8 +55,9 @@ function c24557335.tgfilter(c,e,tp) ...@@ -55,8 +55,9 @@ function c24557335.tgfilter(c,e,tp)
return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and c24557335.descfilter(c,tp) return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and c24557335.descfilter(c,tp)
and c:IsCanBeEffectTarget(e) and c:IsLocation(LOCATION_GRAVE+LOCATION_REMOVED) and c:IsCanBeEffectTarget(e) and c:IsLocation(LOCATION_GRAVE+LOCATION_REMOVED)
end end
function c24557335.destg(e,tp,eg,ep,ev,re,r,rp,chk) function c24557335.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local g=eg:Filter(c24557335.tgfilter,nil,e,tp) local g=eg:Filter(c24557335.tgfilter,nil,e,tp)
if chkc then return eg:IsContains(chkc) and c24557335.tgfilter(chkc,e,tp) end
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and g:GetCount()>0 end if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and g:GetCount()>0 end
local c=nil local c=nil
if g:GetCount()>1 then if g:GetCount()>1 then
......
...@@ -63,7 +63,7 @@ function c2542230.filter(c) ...@@ -63,7 +63,7 @@ function c2542230.filter(c)
end end
function c2542230.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c2542230.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c2542230.filter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c2542230.filter(chkc) end
if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) if chk==0 then return e:IsCostChecked()
and Duel.IsExistingTarget(c2542230.filter,tp,LOCATION_MZONE,0,1,nil) end and Duel.IsExistingTarget(c2542230.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
Duel.SelectTarget(tp,c2542230.filter,tp,LOCATION_MZONE,0,1,1,nil) Duel.SelectTarget(tp,c2542230.filter,tp,LOCATION_MZONE,0,1,1,nil)
...@@ -97,7 +97,8 @@ function c2542230.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -97,7 +97,8 @@ function c2542230.activate(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c2542230.eqlimit(e,c) function c2542230.eqlimit(e,c)
return c:GetControler()==e:GetHandlerPlayer() or e:GetHandler():GetEquipTarget()==c return e:GetHandler():GetEquipTarget()==c
or c:IsControler(e:GetHandlerPlayer()) and c:IsRace(RACE_DRAGON) and c:IsType(TYPE_SYNCHRO)
end end
function c2542230.discon(e) function c2542230.discon(e)
local ec=e:GetHandler():GetEquipTarget() local ec=e:GetHandler():GetEquipTarget()
......
...@@ -12,7 +12,7 @@ function c25773409.initial_effect(c) ...@@ -12,7 +12,7 @@ function c25773409.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c25773409.condition(e,tp,eg,ep,ev,re,r,rp) function c25773409.condition(e,tp,eg,ep,ev,re,r,rp)
return aux.dsercon(e) and Duel.GetAttackTarget()==e:GetHandler() return aux.dsercon(e,tp,eg,ep,ev,re,r,rp) and Duel.GetAttackTarget()==e:GetHandler()
and bit.band(e:GetHandler():GetBattlePosition(),POS_DEFENSE)~=0 and bit.band(e:GetHandler():GetBattlePosition(),POS_DEFENSE)~=0
end end
function c25773409.target(e,tp,eg,ep,ev,re,r,rp,chk) function c25773409.target(e,tp,eg,ep,ev,re,r,rp,chk)
......
--ゲート・ガーディアン --ゲート・ガーディアン
function c25833572.initial_effect(c) function c25833572.initial_effect(c)
aux.AddCodeList(c,25955164,62340868,98434877)
c:EnableReviveLimit() c:EnableReviveLimit()
--special summon --special summon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
......
...@@ -73,7 +73,7 @@ end ...@@ -73,7 +73,7 @@ end
function c25908748.limcon(e,tp,eg,ep,ev,re,r,rp) function c25908748.limcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
return rp==1-tp and c:IsReason(REASON_EFFECT) and c:IsPreviousControler(tp) and c:IsPreviousLocation(LOCATION_SZONE) return rp==1-tp and c:IsReason(REASON_EFFECT) and c:IsPreviousControler(tp) and c:IsPreviousLocation(LOCATION_SZONE)
and Duel.GetTurnPlayer()==1-tp and aux.bpcon() and Duel.GetTurnPlayer()==1-tp and aux.bpcon(e,tp,eg,ep,ev,re,r,rp)
end end
function c25908748.limop(e,tp,eg,ep,ev,re,r,rp) function c25908748.limop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
......
...@@ -43,7 +43,7 @@ function c259314.filter(c) ...@@ -43,7 +43,7 @@ function c259314.filter(c)
end end
function c259314.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c259314.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c259314.filter(chkc) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c259314.filter(chkc) end
if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) if chk==0 then return e:IsCostChecked()
and Duel.IsExistingTarget(c259314.filter,tp,LOCATION_MZONE,0,1,nil) end and Duel.IsExistingTarget(c259314.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
Duel.SelectTarget(tp,c259314.filter,tp,LOCATION_MZONE,0,1,1,nil) Duel.SelectTarget(tp,c259314.filter,tp,LOCATION_MZONE,0,1,1,nil)
...@@ -82,5 +82,6 @@ function c259314.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -82,5 +82,6 @@ function c259314.operation(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c259314.eqlimit(e,c) function c259314.eqlimit(e,c)
return c:IsSetCard(0x56) return e:GetHandler():GetEquipTarget()==c
or c:IsControler(e:GetHandlerPlayer()) and c:IsSetCard(0x56)
end end
...@@ -41,11 +41,11 @@ function c26647858.filter(c) ...@@ -41,11 +41,11 @@ function c26647858.filter(c)
return c:IsFaceup() and c:IsAttackBelow(1500) and c:IsRace(RACE_WARRIOR) return c:IsFaceup() and c:IsAttackBelow(1500) and c:IsRace(RACE_WARRIOR)
end end
function c26647858.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c26647858.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c26647858.filter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and c26647858.filter(chkc) end
if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) if chk==0 then return e:IsCostChecked()
and Duel.IsExistingTarget(c26647858.filter,tp,LOCATION_MZONE,0,1,nil) end and Duel.IsExistingTarget(c26647858.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
Duel.SelectTarget(tp,c26647858.filter,tp,LOCATION_MZONE,0,1,1,nil) Duel.SelectTarget(tp,c26647858.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,0,0)
end end
function c26647858.operation(e,tp,eg,ep,ev,re,r,rp) function c26647858.operation(e,tp,eg,ep,ev,re,r,rp)
...@@ -75,7 +75,8 @@ function c26647858.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -75,7 +75,8 @@ function c26647858.operation(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c26647858.eqlimit(e,c) function c26647858.eqlimit(e,c)
return c:IsAttackBelow(1500) and c:IsRace(RACE_WARRIOR) return e:GetHandler():GetEquipTarget()==c
or c:IsAttackBelow(1500) and c:IsRace(RACE_WARRIOR)
end end
function c26647858.atval(e,c) function c26647858.atval(e,c)
return c:IsAttackAbove(1900) and not c:IsImmuneToEffect(e) return c:IsAttackAbove(1900) and not c:IsImmuneToEffect(e)
......
...@@ -14,7 +14,7 @@ end ...@@ -14,7 +14,7 @@ end
function c2671330.retcon(e,tp,eg,ep,ev,re,r,rp) function c2671330.retcon(e,tp,eg,ep,ev,re,r,rp)
local t=e:GetHandler():GetBattleTarget() local t=e:GetHandler():GetBattleTarget()
e:SetLabelObject(t) e:SetLabelObject(t)
return aux.dsercon(e) and t and t:IsRelateToBattle() return aux.dsercon(e,tp,eg,ep,ev,re,r,rp) and t and t:IsRelateToBattle()
end end
function c2671330.rettg(e,tp,eg,ep,ev,re,r,rp,chk) function c2671330.rettg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
......
...@@ -29,7 +29,7 @@ function c26773909.checkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -29,7 +29,7 @@ function c26773909.checkop(e,tp,eg,ep,ev,re,r,rp)
end end
function c26773909.condition(e,tp,eg,ep,ev,re,r,rp) function c26773909.condition(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase() local ph=Duel.GetCurrentPhase()
return ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE and aux.dscon() return ph>=PHASE_BATTLE_START and ph<=PHASE_BATTLE and aux.dscon(e,tp,eg,ep,ev,re,r,rp)
end end
function c26773909.filter(c,lp) function c26773909.filter(c,lp)
return c:IsFaceup() and c:IsAttackBelow(lp) and c:GetFlagEffect(26773909)==0 return c:IsFaceup() and c:IsAttackBelow(lp) and c:GetFlagEffect(26773909)==0
......
...@@ -17,14 +17,14 @@ function c26905245.initial_effect(c) ...@@ -17,14 +17,14 @@ function c26905245.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c26905245.target(e,tp,eg,ep,ev,re,r,rp,chk) function c26905245.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and if chk==0 then return e:IsCostChecked()
Duel.IsPlayerCanSpecialSummonMonster(tp,26905245,0,TYPES_EFFECT_TRAP_MONSTER,0,3000,10,RACE_AQUA,ATTRIBUTE_WATER) end and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,26905245,0,TYPES_EFFECT_TRAP_MONSTER,0,3000,10,RACE_AQUA,ATTRIBUTE_WATER) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function c26905245.activate(e,tp,eg,ep,ev,re,r,rp) function c26905245.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if not Duel.IsPlayerCanSpecialSummonMonster(tp,26905245,0,TYPES_EFFECT_TRAP_MONSTER,0,3000,10,RACE_AQUA,ATTRIBUTE_WATER) then return end
or not Duel.IsPlayerCanSpecialSummonMonster(tp,26905245,0,TYPES_EFFECT_TRAP_MONSTER,0,3000,10,RACE_AQUA,ATTRIBUTE_WATER) then return end
c:AddMonsterAttribute(TYPE_EFFECT+TYPE_TRAP) c:AddMonsterAttribute(TYPE_EFFECT+TYPE_TRAP)
Duel.SpecialSummon(c,SUMMON_VALUE_SELF,tp,tp,true,false,POS_FACEUP_DEFENSE) Duel.SpecialSummon(c,SUMMON_VALUE_SELF,tp,tp,true,false,POS_FACEUP_DEFENSE)
end end
......
...@@ -27,14 +27,14 @@ function c27062594.condition(e,tp,eg,ep,ev,re,r,rp) ...@@ -27,14 +27,14 @@ function c27062594.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetAttacker():IsControler(1-tp) and Duel.GetAttackTarget()==nil return Duel.GetAttacker():IsControler(1-tp) and Duel.GetAttackTarget()==nil
end end
function c27062594.target(e,tp,eg,ep,ev,re,r,rp,chk) function c27062594.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return e:IsCostChecked()
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,27062594,0,TYPES_EFFECT_TRAP_MONSTER,0,0,1,RACE_FIEND,ATTRIBUTE_LIGHT) end and Duel.IsPlayerCanSpecialSummonMonster(tp,27062594,0,TYPES_EFFECT_TRAP_MONSTER,0,0,1,RACE_FIEND,ATTRIBUTE_LIGHT) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function c27062594.activate(e,tp,eg,ep,ev,re,r,rp) function c27062594.activate(e,tp,eg,ep,ev,re,r,rp)
if not Duel.NegateAttack() then return end if not Duel.NegateAttack() then return end
Duel.BreakEffect() Duel.BreakEffect()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local c=e:GetHandler() local c=e:GetHandler()
if not c:IsRelateToEffect(e) if not c:IsRelateToEffect(e)
or not Duel.IsPlayerCanSpecialSummonMonster(tp,27062594,0,TYPES_EFFECT_TRAP_MONSTER,0,0,1,RACE_FIEND,ATTRIBUTE_LIGHT) then return end or not Duel.IsPlayerCanSpecialSummonMonster(tp,27062594,0,TYPES_EFFECT_TRAP_MONSTER,0,0,1,RACE_FIEND,ATTRIBUTE_LIGHT) then return end
......
...@@ -27,7 +27,7 @@ function c27337596.spcost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -27,7 +27,7 @@ function c27337596.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST) e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST)
end end
function c27337596.spfilter(c,e,tp) function c27337596.spfilter(c,e,tp)
return c:IsRace(RACE_DRAGON) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsRace(RACE_DRAGON) and c:IsCanBeSpecialSummoned(e,0,tp,false,aux.DragonXyzSpSummonType(c))
end end
function c27337596.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c27337596.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
...@@ -39,7 +39,7 @@ function c27337596.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -39,7 +39,7 @@ function c27337596.spop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c27337596.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,c27337596.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc and Duel.SpecialSummonStep(g:GetFirst(),0,tp,tp,false,false,POS_FACEUP) then if tc and Duel.SpecialSummonStep(g:GetFirst(),0,tp,tp,false,aux.DragonXyzSpSummonType(tc),POS_FACEUP) then
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SET_ATTACK) e1:SetCode(EFFECT_SET_ATTACK)
...@@ -49,6 +49,9 @@ function c27337596.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -49,6 +49,9 @@ function c27337596.spop(e,tp,eg,ep,ev,re,r,rp)
local e2=e1:Clone() local e2=e1:Clone()
e2:SetCode(EFFECT_SET_DEFENSE) e2:SetCode(EFFECT_SET_DEFENSE)
tc:RegisterEffect(e2) tc:RegisterEffect(e2)
if aux.DragonXyzSpSummonType(tc) then
tc:CompleteProcedure()
end
end end
Duel.SpecialSummonComplete() Duel.SpecialSummonComplete()
end end
...@@ -67,7 +67,7 @@ function c27354732.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -67,7 +67,7 @@ function c27354732.spop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c27354732.acop(e,tp,eg,ep,ev,re,r,rp) function c27354732.acop(e,tp,eg,ep,ev,re,r,rp)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsActiveType(TYPE_SPELL) and e:GetHandler():GetFlagEffect(1)>0 then if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsActiveType(TYPE_SPELL) and e:GetHandler():GetFlagEffect(FLAG_ID_CHAINING)>0 then
e:GetHandler():AddCounter(0x1,2) e:GetHandler():AddCounter(0x1,2)
end end
end end
......
...@@ -13,7 +13,7 @@ function c27660735.initial_effect(c) ...@@ -13,7 +13,7 @@ function c27660735.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c27660735.condition(e,tp,eg,ep,ev,re,r,rp) function c27660735.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()~=tp and aux.bpcon() return Duel.GetTurnPlayer()~=tp and aux.bpcon(e,tp,eg,ep,ev,re,r,rp)
end end
function c27660735.operation(e,tp,eg,ep,ev,re,r,rp) function c27660735.operation(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetAttacker() then Duel.NegateAttack() if Duel.GetAttacker() then Duel.NegateAttack()
......
...@@ -27,7 +27,7 @@ function c27827903.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -27,7 +27,7 @@ function c27827903.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
end end
function c27827903.desop(e,tp,eg,ep,ev,re,r,rp) function c27827903.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) and tc:IsControler(1-tp) then
Duel.Destroy(tc,REASON_EFFECT) Duel.Destroy(tc,REASON_EFFECT)
end end
end end
...@@ -16,7 +16,7 @@ function c28325165.cfilter(c) ...@@ -16,7 +16,7 @@ function c28325165.cfilter(c)
return c:IsSetCard(0xcd) and c:IsType(TYPE_MONSTER) return c:IsSetCard(0xcd) and c:IsType(TYPE_MONSTER)
end end
function c28325165.condition(e,tp,eg,ep,ev,re,r,rp) function c28325165.condition(e,tp,eg,ep,ev,re,r,rp)
return aux.dscon() return aux.dscon(e,tp,eg,ep,ev,re,r,rp)
and Duel.IsExistingMatchingCard(c28325165.cfilter,tp,LOCATION_GRAVE,0,1,nil) and Duel.IsExistingMatchingCard(c28325165.cfilter,tp,LOCATION_GRAVE,0,1,nil)
end end
function c28325165.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c28325165.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
......
...@@ -3,7 +3,6 @@ function c28423537.initial_effect(c) ...@@ -3,7 +3,6 @@ function c28423537.initial_effect(c)
--summon with no tribute --summon with no tribute
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(28423537,0)) e1:SetDescription(aux.Stringid(28423537,0))
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SUMMON_PROC) e1:SetCode(EFFECT_SUMMON_PROC)
e1:SetCondition(c28423537.ntcon) e1:SetCondition(c28423537.ntcon)
......
...@@ -68,7 +68,7 @@ function c28570310.desop(e,tp,eg,ep,ev,re,r,rp) ...@@ -68,7 +68,7 @@ function c28570310.desop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c28570310.acop(e,tp,eg,ep,ev,re,r,rp) function c28570310.acop(e,tp,eg,ep,ev,re,r,rp)
if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsActiveType(TYPE_SPELL) and e:GetHandler():GetFlagEffect(1)>0 then if re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsActiveType(TYPE_SPELL) and e:GetHandler():GetFlagEffect(FLAG_ID_CHAINING)>0 then
e:GetHandler():AddCounter(0x1,1) e:GetHandler():AddCounter(0x1,1)
end end
end end
......
...@@ -3,7 +3,6 @@ function c28601770.initial_effect(c) ...@@ -3,7 +3,6 @@ function c28601770.initial_effect(c)
--summon with no tribute --summon with no tribute
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(28601770,0)) e1:SetDescription(aux.Stringid(28601770,0))
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SUMMON_PROC) e1:SetCode(EFFECT_SUMMON_PROC)
e1:SetCondition(c28601770.ntcon) e1:SetCondition(c28601770.ntcon)
......
...@@ -15,14 +15,14 @@ function c28649820.condition(e,tp,eg,ep,ev,re,r,rp) ...@@ -15,14 +15,14 @@ function c28649820.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2 return Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2
end end
function c28649820.target(e,tp,eg,ep,ev,re,r,rp,chk) function c28649820.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and if chk==0 then return e:IsCostChecked()
Duel.IsPlayerCanSpecialSummonMonster(tp,28649820,0,TYPES_NORMAL_TRAP_MONSTER,1600,1800,4,RACE_REPTILE,ATTRIBUTE_EARTH) end and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,28649820,0,TYPES_NORMAL_TRAP_MONSTER,1600,1800,4,RACE_REPTILE,ATTRIBUTE_EARTH) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,e:GetHandler(),1,0,0)
end end
function c28649820.activate(e,tp,eg,ep,ev,re,r,rp) function c28649820.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if not Duel.IsPlayerCanSpecialSummonMonster(tp,28649820,0,TYPES_NORMAL_TRAP_MONSTER,1600,1800,4,RACE_REPTILE,ATTRIBUTE_EARTH) then return end
or not Duel.IsPlayerCanSpecialSummonMonster(tp,28649820,0,TYPES_NORMAL_TRAP_MONSTER,1600,1800,4,RACE_REPTILE,ATTRIBUTE_EARTH) then return end
c:AddMonsterAttribute(TYPE_NORMAL+TYPE_TRAP) c:AddMonsterAttribute(TYPE_NORMAL+TYPE_TRAP)
Duel.SpecialSummon(c,0,tp,tp,true,false,POS_FACEUP) Duel.SpecialSummon(c,0,tp,tp,true,false,POS_FACEUP)
end end
...@@ -16,7 +16,9 @@ function c29114773.costfilter(c) ...@@ -16,7 +16,9 @@ function c29114773.costfilter(c)
end end
function c29114773.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c29114773.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c29114773.costfilter,tp,LOCATION_HAND,0,1,e:GetHandler()) end if chk==0 then return Duel.IsExistingMatchingCard(c29114773.costfilter,tp,LOCATION_HAND,0,1,e:GetHandler()) end
Duel.DiscardHand(tp,c29114773.costfilter,1,1,REASON_COST) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,c29114773.costfilter,tp,LOCATION_HAND,0,1,1,e:GetHandler())
Duel.SendtoGrave(g,REASON_COST)
end end
function c29114773.filter(c) function c29114773.filter(c)
return c:IsSetCard(0x2016) and c:IsType(TYPE_MONSTER) and c:IsAbleToHand() return c:IsSetCard(0x2016) and c:IsType(TYPE_MONSTER) and c:IsAbleToHand()
......
...@@ -33,7 +33,7 @@ function c29307554.checkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -33,7 +33,7 @@ function c29307554.checkop(e,tp,eg,ep,ev,re,r,rp)
if p2 then Duel.RegisterFlagEffect(1,29307554,RESET_PHASE+PHASE_END,0,1) end if p2 then Duel.RegisterFlagEffect(1,29307554,RESET_PHASE+PHASE_END,0,1) end
end end
function c29307554.condition(e,tp,eg,ep,ev,re,r,rp) function c29307554.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFlagEffect(tp,29307554)~=0 and Duel.GetTurnPlayer()==tp and aux.bpcon() return Duel.GetFlagEffect(tp,29307554)~=0 and Duel.GetTurnPlayer()==tp and aux.bpcon(e,tp,eg,ep,ev,re,r,rp)
end end
function c29307554.filter(c) function c29307554.filter(c)
return c:IsFaceup() and c:IsLevelAbove(8) and c:GetEffectCount(EFFECT_EXTRA_ATTACK)==0 return c:IsFaceup() and c:IsLevelAbove(8) and c:GetEffectCount(EFFECT_EXTRA_ATTACK)==0
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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