Commit 7ed5d1a4 authored by Tachibana's avatar Tachibana

ndyd

parent e821e5b6
No preview for this file type
......@@ -7,7 +7,6 @@ function c45745902.initial_effect(c)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,45745976)
e1:SetCondition(c45745902.condition)
e1:SetCondition(c45745902.spcon1)
e1:SetTarget(c45745902.sptg)
e1:SetOperation(c45745902.spop)
......@@ -37,14 +36,11 @@ function c45745902.initial_effect(c)
c:RegisterEffect(e4)
end
--e1
function c45745902.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()~=tp
end
function c45745902.cfilter(c)
return c:IsFaceup() and c:IsRace(RACE_WINDBEAST)
end
function c45745902.spcon1(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c45745902.cfilter,tp,LOCATION_MZONE,0,1,nil)
return Duel.IsExistingMatchingCard(c45745902.cfilter,tp,LOCATION_MZONE,0,1,nil) and Duel.GetTurnPlayer()~=tp
end
function c45745902.spfilter(c,e,tp)
return c:IsSetCard(0x881) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
......
......@@ -44,10 +44,10 @@ function c45745903.initial_effect(c)
end
function c45745903.spcon1(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsPlayerAffectedByEffect(tp,33200100,45745921)
return not Duel.IsPlayerAffectedByEffect(tp,33200100) and not Duel.IsPlayerAffectedByEffect(tp,45745921)
end
function c45745903.spcon2(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,33200100,45745921)
return Duel.IsPlayerAffectedByEffect(tp,33200100) or Duel.IsPlayerAffectedByEffect(tp,45745921)
end
--e1
function c45745903.filter3(c)
......
......@@ -44,10 +44,10 @@ function c45745906.initial_effect(c)
end
function c45745906.spcon1(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsPlayerAffectedByEffect(tp,33200100,45745921)
return not Duel.IsPlayerAffectedByEffect(tp,33200100) and not Duel.IsPlayerAffectedByEffect(tp,45745921)
end
function c45745906.spcon2(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsPlayerAffectedByEffect(tp,33200100,45745921)
return Duel.IsPlayerAffectedByEffect(tp,33200100) or Duel.IsPlayerAffectedByEffect(tp,45745921)
end
--e1e2
function c45745906.cost(e,tp,eg,ep,ev,re,r,rp,chk)
......
......@@ -27,33 +27,35 @@ function c45745907.initial_effect(c)
c:RegisterEffect(e3)
end
--e1
function c45745907.filter1(c,e,tp)
function c45745907.spfilter(c,e,tp)
return c:IsCode(45745908) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c45745907.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c45745907.filter1,tp,LOCATION_DECK+LOCATION_HAND+LOCATION_GRAVE,0,1,nil,e,tp) end
and Duel.IsExistingMatchingCard(c45745907.spfilter,tp,LOCATION_DECK+LOCATION_HAND+LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK+LOCATION_HAND+LOCATION_GRAVE)
end
function c45745907.op(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c45745907.filter1,tp,LOCATION_DECK+LOCATION_HAND+LOCATION_GRAVE,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP_DEFENSE)
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c45745907.spfilter,tp,LOCATION_DECK+LOCATION_HAND+LOCATION_GRAVE,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
local e0=Effect.CreateEffect(e:GetHandler())
e0:SetType(EFFECT_TYPE_FIELD)
e0:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH)
e0:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e0:SetReset(RESET_PHASE+PHASE_END)
e0:SetTargetRange(1,0)
e0:SetTarget(c45745907.splimit)
Duel.RegisterEffect(e0,tp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetTargetRange(1,0)
e1:SetTarget(c45745907.splimit)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function c45745907.splimit(e,c)
return not c:IsRace(RACE_WINDBEAST)
end
--e3
function c45745907.spcon(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase()
......@@ -97,7 +99,7 @@ function c45745907.operation1(e,tp,eg,ep,ev,re,r,rp)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetTargetRange(1,0)
e2:SetTarget(c45745907.splimit)
e2:SetTarget(c45745907.splimit1)
e2:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e2,tp)
......@@ -110,7 +112,7 @@ function c45745907.operation1(e,tp,eg,ep,ev,re,r,rp)
e3:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e3,tp)
end
function c45745907.splimit(e,c)
function c45745907.splimit1(e,c)
return c:IsLocation(LOCATION_DECK) and not c:IsSetCard(0x881)
end
function c45745907.splimit2(e,c)
......
......@@ -27,35 +27,34 @@ function c45745908.initial_effect(c)
c:RegisterEffect(e2)
end
--e1
function c45745908.filter1(c,e,tp)
function c45745908.spfilter(c,e,tp)
return c:IsCode(45745907) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c45745908.tg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c45745908.filter1,tp,LOCATION_DECK+LOCATION_HAND+LOCATION_GRAVE,0,1,nil,e,tp) end
and Duel.IsExistingMatchingCard(c45745908.spfilter,tp,LOCATION_DECK+LOCATION_HAND+LOCATION_GRAVE,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK+LOCATION_HAND+LOCATION_GRAVE)
end
function c45745908.op(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c45745908.filter1,tp,LOCATION_DECK+LOCATION_HAND+LOCATION_GRAVE,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP_DEFENSE)
if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c45745908.spfilter,tp,LOCATION_DECK+LOCATION_HAND+LOCATION_GRAVE,0,1,1,nil,e,tp)
if g:GetCount()>0 then
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
end
end
local e0=Effect.CreateEffect(e:GetHandler())
e0:SetType(EFFECT_TYPE_FIELD)
e0:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH)
e0:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e0:SetReset(RESET_PHASE+PHASE_END)
e0:SetTargetRange(1,0)
e0:SetTarget(c45745908.splimit)
Duel.RegisterEffect(e0,tp)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetTargetRange(1,0)
e1:SetTarget(c45745908.splimit)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
end
function c45745908.splimit(e,c)
return not c:IsRace(RACE_WINDBEAST)
end
--e2
--e2
function c45745908.spcon(e,tp,eg,ep,ev,re,r,rp)
local ph=Duel.GetCurrentPhase()
......@@ -99,7 +98,7 @@ function c45745908.operation1(e,tp,eg,ep,ev,re,r,rp)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetTargetRange(1,0)
e2:SetTarget(c45745908.splimit)
e2:SetTarget(c45745908.splimit1)
e2:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e2,tp)
......@@ -112,7 +111,7 @@ function c45745908.operation1(e,tp,eg,ep,ev,re,r,rp)
e3:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e3,tp)
end
function c45745908.splimit(e,c)
function c45745908.splimit1(e,c)
return c:IsLocation(LOCATION_DECK) and not c:IsSetCard(0x881)
end
function c45745908.splimit2(e,c)
......
......@@ -2,7 +2,7 @@
function c45745910.initial_effect(c)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(45745910,0))
e1:SetCategory(CATEGORY_DRAW+CATEGORY_HANDES)
e1:SetCategory(CATEGORY_DRAW+CATEGORY_REMOVE)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_MZONE)
......@@ -37,18 +37,25 @@ function c45745910.initial_effect(c)
end
--e1
function c45745910.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1) end
Duel.SetTargetPlayer(tp)
Duel.SetTargetParam(1)
if chk==0 then return Duel.IsPlayerCanDraw(tp,1)
and Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,LOCATION_HAND,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_HAND)
Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1)
Duel.SetOperationInfo(0,CATEGORY_HANDES,nil,0,tp,1)
end
function c45745910.spfilter(c,e,tp)
return c:IsSetCard(0x124453450) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE) and not c:IsCode(45745910)
end
function c45745910.operation(e,tp,eg,ep,ev,re,r,rp)
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
if Duel.Draw(p,1,REASON_EFFECT)==1 then
Duel.ShuffleHand(tp)
Duel.BreakEffect()
Duel.DiscardHand(tp,nil,1,1,REASON_EFFECT+REASON_DISCARD)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local rc=Duel.SelectMatchingCard(tp,Card.IsAbleToRemove,tp,LOCATION_HAND,0,1,1,nil)
if #rc>0 and Duel.SendtoGrave(rc,REASON_EFFECT)>0 and Duel.Draw(tp,1,REASON_EFFECT)>0 then
local g=Duel.GetMatchingGroup(c45745910.spfilter,tp,LOCATION_DECK+LOCATION_HAND,0,nil,e,tp)
if #g>0 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.SelectYesNo(tp,aux.Stringid(45745910,1)) then
Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=g:Select(tp,1,1,nil)
Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP_DEFENSE)
end
end
end
--e2
......
......@@ -10,8 +10,7 @@ function c45746901.initial_effect(c)
e1:SetCountLimit(1,45746901)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetRange(LOCATION_MZONE)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY+EFFECT_FLAG_DAMAGE_STEP)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DELAY)
e1:SetTarget(c45746901.destg)
e1:SetOperation(c45746901.desop)
c:RegisterEffect(e1)
......@@ -39,6 +38,7 @@ function c45746901.initial_effect(c)
e4:SetCategory(CATEGORY_DAMAGE)
e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e4:SetCode(EVENT_DESTROYED)
e4:SetCondition(c45746901.damcon)
e4:SetTarget(c45746901.damtg)
e4:SetOperation(c45746901.damop)
c:RegisterEffect(e4)
......@@ -80,6 +80,9 @@ function c45746901.target(e,c)
return c:IsRace(RACE_DRAGON)
end
--e4
function c45746901.damcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD) and e:GetHandler():IsReason(REASON_DESTROY)
end
function c45746901.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
local p=PLAYER_ALL
......
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