Commit a9588d87 authored by Fluorohydride's avatar Fluorohydride

Merge branch 'master' of github.com:Fluorohydride/ygopro

parents ec113588 f097cb0a
...@@ -481,6 +481,7 @@ int32 field::process() { ...@@ -481,6 +481,7 @@ int32 field::process() {
if(!attacker if(!attacker
|| (attacker->fieldid_r != core.pre_field[0]) || (attacker->fieldid_r != core.pre_field[0])
|| (attacker->current.position & POS_FACEDOWN) || (attacker->current.position & POS_FACEDOWN)
|| (attacker->current.position & POS_DEFENCE && !(attacker->is_affected_by_effect(EFFECT_DEFENCE_ATTACK)))
|| attacker->is_affected_by_effect(EFFECT_ATTACK_DISABLED) || attacker->is_affected_by_effect(EFFECT_ATTACK_DISABLED)
|| !attacker->is_affect_by_effect(core.reason_effect)) { || !attacker->is_affect_by_effect(core.reason_effect)) {
returns.ivalue[0] = 0; returns.ivalue[0] = 0;
......
...@@ -31,6 +31,7 @@ function c1005587.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -31,6 +31,7 @@ function c1005587.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
tc=g:Select(tp,1,1,nil):GetFirst() tc=g:Select(tp,1,1,nil):GetFirst()
end end
if not tc:IsDisabled() 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_DISABLE) e1:SetCode(EFFECT_DISABLE)
...@@ -39,4 +40,5 @@ function c1005587.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -39,4 +40,5 @@ function c1005587.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.AdjustInstantly() Duel.AdjustInstantly()
Duel.NegateRelatedChain(tc,RESET_TURN_SET) Duel.NegateRelatedChain(tc,RESET_TURN_SET)
Duel.Destroy(tc,REASON_EFFECT) Duel.Destroy(tc,REASON_EFFECT)
end
end end
...@@ -9,17 +9,23 @@ function c13803864.initial_effect(c) ...@@ -9,17 +9,23 @@ function c13803864.initial_effect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP) e1:SetProperty(EFFECT_FLAG_DAMAGE_STEP)
e1:SetCode(EVENT_LEAVE_FIELD) e1:SetCode(EVENT_TO_GRAVE)
e1:SetCondition(c13803864.spcon) e1:SetCondition(c13803864.spcon)
e1:SetTarget(c13803864.sptg) e1:SetTarget(c13803864.sptg)
e1:SetOperation(c13803864.spop) e1:SetOperation(c13803864.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EVENT_REMOVE)
c:RegisterEffect(e2)
local e3=e1:Clone()
e3:SetCode(EVENT_TO_DECK)
c:RegisterEffect(e3)
end end
function c13803864.spfilter(c,e,tp) function c13803864.spfilter(c,e,tp)
return c:IsCode(27288416) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsCode(27288416) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function c13803864.spcon(e,tp,eg,ep,ev,re,r,rp) function c13803864.spcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousPosition(POS_FACEUP) and not e:GetHandler():IsLocation(LOCATION_DECK) return e:GetHandler():IsPreviousPosition(POS_FACEUP) and e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
end end
function c13803864.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function c13803864.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
......
...@@ -33,7 +33,6 @@ function c1639384.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -33,7 +33,6 @@ function c1639384.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 tc:IsFaceup() and tc:IsRelateToEffect(e) then if tc:IsFaceup() and tc:IsRelateToEffect(e) then
if not tc:IsDisabled() then
Duel.NegateRelatedChain(tc,RESET_TURN_SET) Duel.NegateRelatedChain(tc,RESET_TURN_SET)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
...@@ -48,7 +47,6 @@ function c1639384.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -48,7 +47,6 @@ function c1639384.operation(e,tp,eg,ep,ev,re,r,rp)
e2:SetValue(RESET_TURN_SET) e2:SetValue(RESET_TURN_SET)
e2:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+RESET_END) e2:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+RESET_END)
tc:RegisterEffect(e2) tc:RegisterEffect(e2)
end
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE) e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_CANNOT_DISABLE) e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE+EFFECT_FLAG_CANNOT_DISABLE)
......
...@@ -25,7 +25,7 @@ end ...@@ -25,7 +25,7 @@ end
function c26822796.activate(e,tp,eg,ep,ev,re,r,rp) function c26822796.activate(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 tc:IsFaceup() and tc:IsRelateToEffect(e) and not tc:IsDisabled() then if tc:IsFaceup() and tc:IsRelateToEffect(e) then
Duel.NegateRelatedChain(tc,RESET_TURN_SET) Duel.NegateRelatedChain(tc,RESET_TURN_SET)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
......
...@@ -39,8 +39,11 @@ function c29616929.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -39,8 +39,11 @@ function c29616929.target(e,tp,eg,ep,ev,re,r,rp,chk)
end end
end end
function c29616929.activate(e,tp,eg,ep,ev,re,r,rp) function c29616929.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=re:GetHandler()
if not tc:IsDisabled() then
Duel.NegateEffect(ev) Duel.NegateEffect(ev)
if re:GetHandler():IsRelateToEffect(re) then if tc:IsRelateToEffect(re) then
Duel.Destroy(eg,REASON_EFFECT) Duel.Destroy(eg,REASON_EFFECT)
end end
end
end end
...@@ -3,31 +3,37 @@ function c40854197.initial_effect(c) ...@@ -3,31 +3,37 @@ function c40854197.initial_effect(c)
--fusion material --fusion material
c:EnableReviveLimit() c:EnableReviveLimit()
aux.AddFusionProcFun2(c,aux.FilterBoolFunction(Card.IsSetCard,0x8),aux.FilterBoolFunction(Card.IsAttribute,ATTRIBUTE_WATER),true) aux.AddFusionProcFun2(c,aux.FilterBoolFunction(Card.IsSetCard,0x8),aux.FilterBoolFunction(Card.IsAttribute,ATTRIBUTE_WATER),true)
--spsummon condition
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION)
e1:SetValue(c40854197.splimit)
c:RegisterEffect(e1)
--destroy --destroy
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(40854197,0)) e2:SetDescription(aux.Stringid(40854197,0))
e2:SetCategory(CATEGORY_DESTROY) e2:SetCategory(CATEGORY_DESTROY)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e2:SetCode(EVENT_LEAVE_FIELD) e2:SetCode(EVENT_TO_GRAVE)
e2:SetCondition(c40854197.descondition) e2:SetCondition(c40854197.descon)
e2:SetTarget(c40854197.destarget) e2:SetTarget(c40854197.destg)
e2:SetOperation(c40854197.desoperation) e2:SetOperation(c40854197.desop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
--atkup local e3=e2:Clone()
local e3=Effect.CreateEffect(c) e3:SetCode(EVENT_REMOVE)
e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e3:SetRange(LOCATION_MZONE)
e3:SetCode(EFFECT_UPDATE_ATTACK)
e3:SetValue(c40854197.atkup)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--spsummon condition local e4=e2:Clone()
local e4=Effect.CreateEffect(c) e4:SetCode(EVENT_TO_DECK)
e4:SetType(EFFECT_TYPE_SINGLE)
e4:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e4:SetCode(EFFECT_SPSUMMON_CONDITION)
e4:SetValue(c40854197.splimit)
c:RegisterEffect(e4) c:RegisterEffect(e4)
--atkup
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE)
e5:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e5:SetRange(LOCATION_MZONE)
e5:SetCode(EFFECT_UPDATE_ATTACK)
e5:SetValue(c40854197.atkup)
c:RegisterEffect(e5)
end end
function c40854197.splimit(e,se,sp,st) function c40854197.splimit(e,se,sp,st)
return bit.band(st,SUMMON_TYPE_FUSION)==SUMMON_TYPE_FUSION return bit.band(st,SUMMON_TYPE_FUSION)==SUMMON_TYPE_FUSION
...@@ -38,16 +44,15 @@ end ...@@ -38,16 +44,15 @@ end
function c40854197.atkup(e,c) function c40854197.atkup(e,c)
return Duel.GetMatchingGroupCount(c40854197.atkfilter,0,LOCATION_MZONE,LOCATION_MZONE,nil)*500 return Duel.GetMatchingGroupCount(c40854197.atkfilter,0,LOCATION_MZONE,LOCATION_MZONE,nil)*500
end end
function c40854197.descondition(e,tp,eg,ep,ev,re,r,rp) function c40854197.descon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() return e:GetHandler():IsPreviousPosition(POS_FACEUP) and e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD)
return c:IsPreviousPosition(POS_FACEUP)
end end
function c40854197.destarget(e,tp,eg,ep,ev,re,r,rp,chk) function c40854197.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
local g=Duel.GetMatchingGroup(Card.IsDestructable,tp,0,LOCATION_MZONE,nil) local g=Duel.GetMatchingGroup(Card.IsDestructable,tp,0,LOCATION_MZONE,nil)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
end end
function c40854197.desoperation(e,tp,eg,ep,ev,re,r,rp) function c40854197.desop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(Card.IsDestructable,tp,0,LOCATION_MZONE,nil) local g=Duel.GetMatchingGroup(Card.IsDestructable,tp,0,LOCATION_MZONE,nil)
Duel.Destroy(g,REASON_EFFECT) Duel.Destroy(g,REASON_EFFECT)
end end
--エヴォルカイザー·ドルカ --エヴォルカイザー・ドルカ
function c42752141.initial_effect(c) function c42752141.initial_effect(c)
--xyz summon --xyz summon
aux.AddXyzProcedure(c,aux.XyzFilterFunctionF(c,aux.FilterBoolFunction(Card.IsRace,RACE_DINOSAUR),4),2) aux.AddXyzProcedure(c,aux.XyzFilterFunctionF(c,aux.FilterBoolFunction(Card.IsRace,RACE_DINOSAUR),4),2)
......
...@@ -28,10 +28,11 @@ function c56840427.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -28,10 +28,11 @@ function c56840427.operation(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if c:IsRelateToEffect(e) and c:IsFaceup() then if c:IsRelateToEffect(e) and c:IsFaceup() then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(500) e1:SetValue(500)
e1:SetReset(RESET_EVENT+0x1ff0000+RESET_PHASE+PHASE_END) e1:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1) c:RegisterEffect(e1)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local g=Duel.SelectMatchingCard(tp,Card.IsFaceup,tp,0,LOCATION_MZONE,1,1,nil) local g=Duel.SelectMatchingCard(tp,Card.IsFaceup,tp,0,LOCATION_MZONE,1,1,nil)
......
...@@ -29,11 +29,15 @@ function c58120309.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -29,11 +29,15 @@ function c58120309.target(e,tp,eg,ep,ev,re,r,rp,chk)
end end
end end
function c58120309.activate(e,tp,eg,ep,ev,re,r,rp) function c58120309.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=re:GetHandler()
if not tc:IsDisabled() then
Duel.NegateEffect(ev) Duel.NegateEffect(ev)
if re:GetHandler():IsRelateToEffect(re) and Duel.Destroy(eg,REASON_EFFECT)~=0 then if tc:IsRelateToEffect(re) and Duel.Destroy(eg,REASON_EFFECT)~=0 then
local sc=Duel.GetFirstMatchingCard(c58120309.sfilter,tp,LOCATION_EXTRA,0,nil,e,tp) local sc=Duel.GetFirstMatchingCard(c58120309.sfilter,tp,LOCATION_EXTRA,0,nil,e,tp)
if sc and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.SelectYesNo(tp,aux.Stringid(58120309,0)) then if sc and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.SelectYesNo(tp,aux.Stringid(58120309,0)) then
Duel.BreakEffect()
Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP)
end end
end end
end
end end
...@@ -46,7 +46,7 @@ function c68836428.cost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -46,7 +46,7 @@ function c68836428.cost(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 c68836428.filter(c) function c68836428.filter(c)
return c:IsFaceup() return c:IsFaceup() and (c:IsType(TYPE_EFFECT) or c:GetAttack()>0)
end end
function c68836428.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c68836428.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c68836428.filter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and c68836428.filter(chkc) end
...@@ -58,7 +58,6 @@ function c68836428.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -58,7 +58,6 @@ function c68836428.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 tc:IsFaceup() and tc:IsRelateToEffect(e) then if tc:IsFaceup() and tc:IsRelateToEffect(e) then
if not tc:IsDisabled() then
Duel.NegateRelatedChain(tc,RESET_TURN_SET) Duel.NegateRelatedChain(tc,RESET_TURN_SET)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
...@@ -73,8 +72,8 @@ function c68836428.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -73,8 +72,8 @@ function c68836428.operation(e,tp,eg,ep,ev,re,r,rp)
e2:SetValue(RESET_TURN_SET) e2:SetValue(RESET_TURN_SET)
e2:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+RESET_END) e2:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+RESET_END)
tc:RegisterEffect(e2) tc:RegisterEffect(e2)
end
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e3:SetType(EFFECT_TYPE_SINGLE) e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_UPDATE_ATTACK) e3:SetCode(EFFECT_UPDATE_ATTACK)
e3:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END) e3:SetReset(RESET_EVENT+0x1fe0000+RESET_PHASE+PHASE_END)
......
...@@ -15,7 +15,7 @@ function c76214441.initial_effect(c) ...@@ -15,7 +15,7 @@ function c76214441.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c76214441.discon(e,tp,eg,ep,ev,re,r,rp) function c76214441.discon(e,tp,eg,ep,ev,re,r,rp)
if ep==tp or not re:IsHasType(EFFECT_TYPE_ACTIVATE) or not Duel.IsChainNegatable(ev) then return false end if ep==tp or (re:GetHandler():IsType(TYPE_SPELL+TYPE_TRAP) and not re:IsHasType(EFFECT_TYPE_ACTIVATE)) or not Duel.IsChainNegatable(ev) then return false end
local ex,cg,ct,cp,cv=Duel.GetOperationInfo(ev,CATEGORY_DAMAGE) local ex,cg,ct,cp,cv=Duel.GetOperationInfo(ev,CATEGORY_DAMAGE)
if ex then return true end if ex then return true end
ex,cg,ct,cp,cv=Duel.GetOperationInfo(ev,CATEGORY_RECOVER) ex,cg,ct,cp,cv=Duel.GetOperationInfo(ev,CATEGORY_RECOVER)
......
...@@ -36,7 +36,7 @@ end ...@@ -36,7 +36,7 @@ end
function c78474168.activate(e,tp,eg,ep,ev,re,r,rp) function c78474168.activate(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 tc:IsRelateToEffect(e) and tc:IsFaceup() then if tc:IsRelateToEffect(e) and tc:IsFaceup() and not tc:IsDisabled() then
Duel.NegateRelatedChain(tc,RESET_TURN_SET) Duel.NegateRelatedChain(tc,RESET_TURN_SET)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
......
...@@ -17,7 +17,7 @@ function c82732705.initial_effect(c) ...@@ -17,7 +17,7 @@ function c82732705.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c82732705.disable(e,c) function c82732705.disable(e,c)
return c:IsType(TYPE_EFFECT) return c:IsType(TYPE_EFFECT) or bit.band(c:GetOriginalType(),TYPE_EFFECT)==TYPE_EFFECT
end end
function c82732705.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c82732705.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckLPCost(tp,1000) end if chk==0 then return Duel.CheckLPCost(tp,1000) end
......
...@@ -45,7 +45,7 @@ end ...@@ -45,7 +45,7 @@ end
function c84650463.spcost(e,tp,eg,ep,ev,re,r,rp,chk) function c84650463.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetFlagEffect(tp,84650463)==0 and e:GetHandler():IsAbleToRemoveAsCost() end if chk==0 then return Duel.GetFlagEffect(tp,84650463)==0 and e:GetHandler():IsAbleToRemoveAsCost() end
Duel.Remove(e:GetHandler(),POS_FACEUP,REASON_COST) Duel.Remove(e:GetHandler(),POS_FACEUP,REASON_COST)
Duel.RegisterFlagEffect(tp,84650463,RESET_PHASE+PHASE_END,EFFECT_FLAG_OATH,1) Duel.RegisterFlagEffect(tp,84650463,RESET_PHASE+PHASE_END,0,1)
end end
function c84650463.filter(c,e,tp) function c84650463.filter(c,e,tp)
return c:IsLevelAbove(5) and c:IsRace(RACE_SEASERPENT) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c:IsLevelAbove(5) and c:IsRace(RACE_SEASERPENT) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
......
...@@ -69,6 +69,7 @@ function c86686671.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -69,6 +69,7 @@ function c86686671.activate(e,tp,eg,ep,ev,re,r,rp)
if op~=0 then if op~=0 then
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) then
if op==2 then Duel.BreakEffect() end
Duel.SendtoDeck(tc,nil,2,REASON_EFFECT) Duel.SendtoDeck(tc,nil,2,REASON_EFFECT)
end end
end end
......
...@@ -22,15 +22,13 @@ end ...@@ -22,15 +22,13 @@ end
function c86848580.filter1(c) function c86848580.filter1(c)
return c:IsFaceup() and not c:IsDisabled() and (c:IsLocation(LOCATION_SZONE) or c:IsType(TYPE_EFFECT)) return c:IsFaceup() and not c:IsDisabled() and (c:IsLocation(LOCATION_SZONE) or c:IsType(TYPE_EFFECT))
end end
function c86848580.filter2(c)
return c:IsFaceup() and (c:IsLocation(LOCATION_SZONE) or c:IsType(TYPE_EFFECT))
end
function c86848580.distg(e,tp,eg,ep,ev,re,r,rp,chk) function c86848580.distg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c86848580.filter1,tp,0,LOCATION_ONFIELD,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c86848580.filter1,tp,0,LOCATION_ONFIELD,1,nil) end
end end
function c86848580.disop(e,tp,eg,ep,ev,re,r,rp) function c86848580.disop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(c86848580.filter2,tp,0,LOCATION_ONFIELD,nil) local g=Duel.GetMatchingGroup(c86848580.filter1,tp,0,LOCATION_ONFIELD,nil)
local tc=g:GetFirst() local tc=g:GetFirst()
if not tc then return end
local c=e:GetHandler() local c=e:GetHandler()
while tc do while tc do
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
...@@ -45,7 +43,7 @@ function c86848580.disop(e,tp,eg,ep,ev,re,r,rp) ...@@ -45,7 +43,7 @@ function c86848580.disop(e,tp,eg,ep,ev,re,r,rp)
tc:RegisterEffect(e2) tc:RegisterEffect(e2)
tc=g:GetNext() tc=g:GetNext()
end end
local atk=Duel.GetMatchingGroupCount(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,e:GetHandler())*300 local atk=Duel.GetMatchingGroupCount(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,c)*300
if atk>0 then if atk>0 then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
......
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