Commit 074b7d49 authored by wyykak's avatar wyykak

k fix

parent fe8a298c
Pipeline #8567 passed with stage
in 30 seconds
...@@ -25,31 +25,23 @@ function c74563002.initial_effect(c) ...@@ -25,31 +25,23 @@ function c74563002.initial_effect(c)
e4:SetOperation(c74563002.desop) e4:SetOperation(c74563002.desop)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c74563002.tfilter(c)
return c:IsSetCard(0x497) and c:IsFaceup()
end
function c74563002.actcon(e) function c74563002.actcon(e)
return Duel.IsExistingMatchingCard(c74563002.tfilter,e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil) return Duel.IsExistingMatchingCard(Card.IsSetCard,e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil,0x497)
end end
function c74563002.negcost(e,tp,eg,ep,ev,re,r,rp,chk) function c74563002.negcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsCanRemoveCounter(tp,1,1,0x128a,1,REASON_COST) end if chk==0 then return Duel.IsCanRemoveCounter(tp,1,1,0x128a,1,REASON_COST) end
Duel.RemoveCounter(tp,1,1,0x128a,1,REASON_COST) Duel.RemoveCounter(tp,1,1,0x128a,1,REASON_COST)
end end
function c74563002.target(e,tp,eg,ep,ev,re,r,rp,chk) function c74563002.target(e,tp,eg,ep,ev,re,r,rp,chk)
local ft1=Duel.GetLocationCount(tp,LOCATION_MZONE) if chk==0 then return true end
local ft2=Duel.GetLocationCount(1-tp,LOCATION_MZONE,tp)
if chk==0 then return ft1>0 and ft2>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,74563020,nil,TYPES_TOKEN_MONSTER,0,0,1,RACE_AQUA,ATTRIBUTE_WATER,POS_FACEUP_DEFENSE)
and Duel.IsPlayerCanSpecialSummonMonster(tp,74563020,nil,TYPES_TOKEN_MONSTER,0,0,1,RACE_AQUA,ATTRIBUTE_WATER,POS_FACEUP_DEFENSE,1-tp)
and not Duel.IsPlayerAffectedByEffect(tp,59822133) end
Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,2,0,0) Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,2,0,0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,2,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,2,0,0)
end end
function c74563002.activate(e,tp,eg,ep,ev,re,r,rp) function c74563002.activate(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0
or Duel.GetLocationCount(1-tp,LOCATION_MZONE)<=0 or Duel.GetLocationCount(1-tp,LOCATION_MZONE)<=0
or not Duel.IsPlayerCanSpecialSummonMonster(tp,74563020,nil,TYPES_TOKEN_MONSTER,0,0,1,RACE_AQUA,ATTRIBUTE_WATER,POS_FACEUP_DEFENSE) or not Duel.IsPlayerCanSpecialSummonMonster(tp,74563020,0,TYPES_TOKEN_MONSTER,0,0,1,RACE_AQUA,ATTRIBUTE_WATER,POS_FACEUP_DEFENSE)
or not Duel.IsPlayerCanSpecialSummonMonster(tp,74563020,nil,TYPES_TOKEN_MONSTER,0,0,1,RACE_AQUA,ATTRIBUTE_WATER,POS_FACEUP_DEFENSE,1-tp) or not Duel.IsPlayerCanSpecialSummonMonster(tp,74563020,0,TYPES_TOKEN_MONSTER,0,0,1,RACE_AQUA,ATTRIBUTE_WATER,POS_FACEUP_DEFENSE,1-tp)
or Duel.IsPlayerAffectedByEffect(tp,59822133) then return end or Duel.IsPlayerAffectedByEffect(tp,59822133) then return end
local token1=Duel.CreateToken(tp,74563020) local token1=Duel.CreateToken(tp,74563020)
local token2=Duel.CreateToken(tp,74563020) local token2=Duel.CreateToken(tp,74563020)
......
...@@ -11,6 +11,7 @@ function c74563008.initial_effect(c) ...@@ -11,6 +11,7 @@ function c74563008.initial_effect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_PHASE+PHASE_END) e1:SetCode(EVENT_PHASE+PHASE_END)
e1:SetRange(LOCATION_SZONE) e1:SetRange(LOCATION_SZONE)
e1:SetCountLimit(1)
e1:SetTarget(c74563008.target) e1:SetTarget(c74563008.target)
e1:SetOperation(c74563008.activate) e1:SetOperation(c74563008.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
......
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