Commit b0dfba3f authored by 2924713558's avatar 2924713558 Committed by GitHub

Update c1111002.lua

parent 0545bd55
......@@ -27,47 +27,43 @@ function c1111002.initial_effect(c)
--
end
--
function c1111002.tfilter1_1(c,tp)
return muxu.check_set_Urban(c)
and c:IsFaceup() and c:IsType(TYPE_MONSTER) and c:IsAbleToHand()
and Duel.GetLocationCountFromEx(tp,tp,c)>0
function c1111002.tfilter1_1(c,e,tp)
return muxu.check_set_Urban(c)
and c:IsFaceup() and c:IsType(TYPE_MONSTER) and c:IsAbleToHand()
and Duel.IsExistingTarget(c1111002.tfilter1_2,tp,LOCATION_EXTRA,0,1,nil,e,tp,tc)
end
function c1111002.tfilter1_2(c,e,tp)
return muxu.check_set_Urban(c) and c:IsType(TYPE_MONSTER)
and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
function c1111002.tfilter1_2(c,e,tp,tc)
return muxu.check_set_Urban(c) and c:IsType(TYPE_MONSTER)
and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
and Duel.GetLocationCountFromEx(tp,tp,tc,c)>0
end
function c1111002.tg1(e,tp,eg,ep,ev,re,r,rp,chk)
if chkc then
return chkc:IsControler(tp) and c1111002.tfilter1_1(chkc,tp)
end
if chk==0 then
return Duel.IsExistingTarget(c1111002.tfilter1_1,tp,LOCATION_MZONE,0,1,nil,tp)
and Duel.IsExistingTarget(c1111002.tfilter1_2,tp,LOCATION_EXTRA,0,1,nil,e,tp)
end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SELECT)
local rg=Duel.SelectTarget(tp,c1111002.tfilter1_1,tp,LOCATION_MZONE,0,1,1,nil,tp)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,rg,1,tp,LOCATION_MZONE)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
if chkc then return chkc:IsControler(tp) and c1111002.tfilter1_1(chkc,e,tp) end
if chk==0 then return Duel.IsExistingTarget(c1111002.tfilter1_1,tp,LOCATION_MZONE,0,1,nil,e,tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SELECT)
local rg=Duel.SelectTarget(tp,c1111002.tfilter1_1,tp,LOCATION_MZONE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,rg,1,tp,LOCATION_MZONE)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
--
function c1111002.op1(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if not tc:IsRelateToEffect(e) then return end
if Duel.SendtoHand(tc,nil,REASON_EFFECT)<1 then return end
if Duel.GetLocationCountFromEx(tp)<1 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=Duel.SelectMatchingCard(tp,c1111002.tfilter1_2,tp,LOCATION_EXTRA,0,1,1,nil,e,tp)
if sg:GetCount()>0 then
Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP)
end
local e1_2=Effect.CreateEffect(c)
e1_2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1_2:SetCode(EVENT_PHASE+PHASE_STANDBY)
e1_2:SetCountLimit(1)
e1_2:SetOperation(c1111002.op1_2)
e1_2:SetReset(RESET_PHASE+PHASE_STANDBY+RESET_OPPO_TURN)
Duel.RegisterEffect(e1_2,tp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if not tc:IsRelateToEffect(e) then return end
if Duel.SendtoHand(tc,nil,REASON_EFFECT)<1 then return end
if Duel.GetLocationCountFromEx(tp)<1 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=Duel.SelectMatchingCard(tp,c1111002.tfilter1_2,tp,LOCATION_EXTRA,0,1,1,nil,e,tp,tc)
if sg:GetCount()>0 then
Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP)
end
local e1_2=Effect.CreateEffect(c)
e1_2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1_2:SetCode(EVENT_PHASE+PHASE_STANDBY)
e1_2:SetCountLimit(1)
e1_2:SetOperation(c1111002.op1_2)
e1_2:SetReset(RESET_PHASE+PHASE_STANDBY+RESET_OPPO_TURN)
Duel.RegisterEffect(e1_2,tp)
end
--
function c1111002.op1_2(e,tp,eg,ep,ev,re,r,rp)
......
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