From a01819aec9c959ff04868b99c52c93c5934ee03e Mon Sep 17 00:00:00 2001 From: pyrQ <30827955+pyrQ@users.noreply.github.com> Date: Thu, 30 Oct 2025 14:38:11 +0200 Subject: [PATCH 1/2] Delete pre-release directory --- pre-release/c100295111.lua | 85 ------------------------ pre-release/c100444219.lua | 98 ---------------------------- pre-release/c100444241.lua | 77 ---------------------- pre-release/c100447018.lua | 87 ------------------------- pre-release/c100447019.lua | 78 ---------------------- pre-release/c100447020.lua | 79 ----------------------- pre-release/c100447021.lua | 78 ---------------------- pre-release/c100447064.lua | 81 ----------------------- pre-release/c100447101.lua | 85 ------------------------ pre-release/c100447102.lua | 84 ------------------------ pre-release/c100447103.lua | 68 ------------------- pre-release/c100447104.lua | 89 ------------------------- pre-release/c100447106.lua | 90 -------------------------- pre-release/c100447107.lua | 101 ----------------------------- pre-release/c100447108.lua | 113 -------------------------------- pre-release/c100447109.lua | 104 ------------------------------ pre-release/c100448001.lua | 93 -------------------------- pre-release/c100448002.lua | 79 ----------------------- pre-release/c101303004.lua | 115 --------------------------------- pre-release/c101303005.lua | 67 ------------------- pre-release/c101303006.lua | 66 ------------------- pre-release/c101303007.lua | 70 -------------------- pre-release/c101303008.lua | 81 ----------------------- pre-release/c101303009.lua | 72 --------------------- pre-release/c101303010.lua | 78 ---------------------- pre-release/c101303011.lua | 72 --------------------- pre-release/c101303012.lua | 76 ---------------------- pre-release/c101303013.lua | 95 --------------------------- pre-release/c101303014.lua | 85 ------------------------ pre-release/c101303015.lua | 86 ------------------------- pre-release/c101303016.lua | 84 ------------------------ pre-release/c101303017.lua | 70 -------------------- pre-release/c101303018.lua | 77 ---------------------- pre-release/c101303019.lua | 88 ------------------------- pre-release/c101303020.lua | 97 ---------------------------- pre-release/c101303021.lua | 93 -------------------------- pre-release/c101303022.lua | 81 ----------------------- pre-release/c101303023.lua | 91 -------------------------- pre-release/c101303024.lua | 82 ----------------------- pre-release/c101303025.lua | 65 ------------------- pre-release/c101303026.lua | 91 -------------------------- pre-release/c101303027.lua | 58 ----------------- pre-release/c101303028.lua | 77 ---------------------- pre-release/c101303029.lua | 92 -------------------------- pre-release/c101303030.lua | 81 ----------------------- pre-release/c101303031.lua | 92 -------------------------- pre-release/c101303033.lua | 76 ---------------------- pre-release/c101303034.lua | 82 ----------------------- pre-release/c101303035.lua | 111 ------------------------------- pre-release/c101303036.lua | 102 ----------------------------- pre-release/c101303037.lua | 104 ------------------------------ pre-release/c101303038.lua | 86 ------------------------- pre-release/c101303039.lua | 75 --------------------- pre-release/c101303040.lua | 73 --------------------- pre-release/c101303041.lua | 86 ------------------------- pre-release/c101303042.lua | 69 -------------------- pre-release/c101303043.lua | 71 -------------------- pre-release/c101303044.lua | 82 ----------------------- pre-release/c101303045.lua | 77 ---------------------- pre-release/c101303046.lua | 100 ---------------------------- pre-release/c101303049.lua | 113 -------------------------------- pre-release/c101303050.lua | 92 -------------------------- pre-release/c101303051.lua | 70 -------------------- pre-release/c101303053.lua | 96 --------------------------- pre-release/c101303054.lua | 81 ----------------------- pre-release/c101303055.lua | 73 --------------------- pre-release/c101303056.lua | 70 -------------------- pre-release/c101303057.lua | 53 --------------- pre-release/c101303058.lua | 72 --------------------- pre-release/c101303059.lua | 37 ----------- pre-release/c101303060.lua | 78 ---------------------- pre-release/c101303061.lua | 85 ------------------------ pre-release/c101303062.lua | 75 --------------------- pre-release/c101303063.lua | 48 -------------- pre-release/c101303064.lua | 100 ---------------------------- pre-release/c101303065.lua | 87 ------------------------- pre-release/c101303066.lua | 129 ------------------------------------- pre-release/c101303067.lua | 65 ------------------- pre-release/c101303068.lua | 70 -------------------- pre-release/c101303069.lua | 73 --------------------- pre-release/c101303071.lua | 70 -------------------- pre-release/c101303072.lua | 73 --------------------- pre-release/c101303073.lua | 57 ---------------- pre-release/c101303074.lua | 68 ------------------- pre-release/c101303075.lua | 80 ----------------------- pre-release/c101303076.lua | 99 ---------------------------- pre-release/c101303077.lua | 56 ---------------- pre-release/c101303078.lua | 89 ------------------------- pre-release/c101303079.lua | 71 -------------------- pre-release/c101303080.lua | 115 --------------------------------- pre-release/c101303101.lua | 78 ---------------------- pre-release/c101303102.lua | 74 --------------------- pre-release/c101303103.lua | 77 ---------------------- pre-release/c101303104.lua | 113 -------------------------------- pre-release/c101303105.lua | 93 -------------------------- pre-release/c101303106.lua | 77 ---------------------- pre-release/c101303107.lua | 97 ---------------------------- pre-release/c101303108.lua | 59 ----------------- 98 files changed, 8058 deletions(-) delete mode 100644 pre-release/c100295111.lua delete mode 100644 pre-release/c100444219.lua delete mode 100644 pre-release/c100444241.lua delete mode 100644 pre-release/c100447018.lua delete mode 100644 pre-release/c100447019.lua delete mode 100644 pre-release/c100447020.lua delete mode 100644 pre-release/c100447021.lua delete mode 100644 pre-release/c100447064.lua delete mode 100644 pre-release/c100447101.lua delete mode 100644 pre-release/c100447102.lua delete mode 100644 pre-release/c100447103.lua delete mode 100644 pre-release/c100447104.lua delete mode 100644 pre-release/c100447106.lua delete mode 100644 pre-release/c100447107.lua delete mode 100644 pre-release/c100447108.lua delete mode 100644 pre-release/c100447109.lua delete mode 100644 pre-release/c100448001.lua delete mode 100644 pre-release/c100448002.lua delete mode 100644 pre-release/c101303004.lua delete mode 100644 pre-release/c101303005.lua delete mode 100644 pre-release/c101303006.lua delete mode 100644 pre-release/c101303007.lua delete mode 100644 pre-release/c101303008.lua delete mode 100644 pre-release/c101303009.lua delete mode 100644 pre-release/c101303010.lua delete mode 100644 pre-release/c101303011.lua delete mode 100644 pre-release/c101303012.lua delete mode 100644 pre-release/c101303013.lua delete mode 100644 pre-release/c101303014.lua delete mode 100644 pre-release/c101303015.lua delete mode 100644 pre-release/c101303016.lua delete mode 100644 pre-release/c101303017.lua delete mode 100644 pre-release/c101303018.lua delete mode 100644 pre-release/c101303019.lua delete mode 100644 pre-release/c101303020.lua delete mode 100644 pre-release/c101303021.lua delete mode 100644 pre-release/c101303022.lua delete mode 100644 pre-release/c101303023.lua delete mode 100644 pre-release/c101303024.lua delete mode 100644 pre-release/c101303025.lua delete mode 100644 pre-release/c101303026.lua delete mode 100644 pre-release/c101303027.lua delete mode 100644 pre-release/c101303028.lua delete mode 100644 pre-release/c101303029.lua delete mode 100644 pre-release/c101303030.lua delete mode 100644 pre-release/c101303031.lua delete mode 100644 pre-release/c101303033.lua delete mode 100644 pre-release/c101303034.lua delete mode 100644 pre-release/c101303035.lua delete mode 100644 pre-release/c101303036.lua delete mode 100644 pre-release/c101303037.lua delete mode 100644 pre-release/c101303038.lua delete mode 100644 pre-release/c101303039.lua delete mode 100644 pre-release/c101303040.lua delete mode 100644 pre-release/c101303041.lua delete mode 100644 pre-release/c101303042.lua delete mode 100644 pre-release/c101303043.lua delete mode 100644 pre-release/c101303044.lua delete mode 100644 pre-release/c101303045.lua delete mode 100644 pre-release/c101303046.lua delete mode 100644 pre-release/c101303049.lua delete mode 100644 pre-release/c101303050.lua delete mode 100644 pre-release/c101303051.lua delete mode 100644 pre-release/c101303053.lua delete mode 100644 pre-release/c101303054.lua delete mode 100644 pre-release/c101303055.lua delete mode 100644 pre-release/c101303056.lua delete mode 100644 pre-release/c101303057.lua delete mode 100644 pre-release/c101303058.lua delete mode 100644 pre-release/c101303059.lua delete mode 100644 pre-release/c101303060.lua delete mode 100644 pre-release/c101303061.lua delete mode 100644 pre-release/c101303062.lua delete mode 100644 pre-release/c101303063.lua delete mode 100644 pre-release/c101303064.lua delete mode 100644 pre-release/c101303065.lua delete mode 100644 pre-release/c101303066.lua delete mode 100644 pre-release/c101303067.lua delete mode 100644 pre-release/c101303068.lua delete mode 100644 pre-release/c101303069.lua delete mode 100644 pre-release/c101303071.lua delete mode 100644 pre-release/c101303072.lua delete mode 100644 pre-release/c101303073.lua delete mode 100644 pre-release/c101303074.lua delete mode 100644 pre-release/c101303075.lua delete mode 100644 pre-release/c101303076.lua delete mode 100644 pre-release/c101303077.lua delete mode 100644 pre-release/c101303078.lua delete mode 100644 pre-release/c101303079.lua delete mode 100644 pre-release/c101303080.lua delete mode 100644 pre-release/c101303101.lua delete mode 100644 pre-release/c101303102.lua delete mode 100644 pre-release/c101303103.lua delete mode 100644 pre-release/c101303104.lua delete mode 100644 pre-release/c101303105.lua delete mode 100644 pre-release/c101303106.lua delete mode 100644 pre-release/c101303107.lua delete mode 100644 pre-release/c101303108.lua diff --git a/pre-release/c100295111.lua b/pre-release/c100295111.lua deleted file mode 100644 index 02734e55ef..0000000000 --- a/pre-release/c100295111.lua +++ /dev/null @@ -1,85 +0,0 @@ ---魔弾の悪魔 カスパール ---Magical Musket Mastermind Caspar ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Link Summon procedure: 2 monsters, including a LIGHT Fiend monster - Link.AddProcedure(c,nil,2,2,s.matcheck) - --Take 2 "Magical Musket" cards from your hand and/or Deck, including a monster, Special Summon 1 of those monsters, and Set the other card to your opponent's field - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetCountLimit(1,id) - e1:SetCondition(function(e) return e:GetHandler():IsLinkSummoned() end) - e1:SetTarget(s.spsettg) - e1:SetOperation(s.spsetop) - c:RegisterEffect(e1) - --During either player's turn, you can activate "Magical Musket" Spell/Trap Cards from your hand. - local e2a=Effect.CreateEffect(c) - e2a:SetType(EFFECT_TYPE_FIELD) - e2a:SetCode(EFFECT_QP_ACT_IN_NTPHAND) - e2a:SetRange(LOCATION_MZONE) - e2a:SetTargetRange(LOCATION_HAND,0) - e2a:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,SET_MAGICAL_MUSKET)) - c:RegisterEffect(e2a) - local e2b=e2a:Clone() - e2b:SetCode(EFFECT_TRAP_ACT_IN_HAND) - c:RegisterEffect(e2b) -end -s.listed_series={SET_MAGICAL_MUSKET} -function s.matfilter(c,lc,sumtype,tp) - return c:IsAttribute(ATTRIBUTE_LIGHT,lc,sumtype,tp) and c:IsRace(RACE_FIEND,lc,sumtype,tp) -end -function s.matcheck(g,lc,sumtype,tp) - return g:IsExists(s.matfilter,1,nil,lc,sumtype,tp) -end -function s.rescon(sg,e,tp,mg) - return sg:IsExists(Card.IsMonster,1,nil) and sg:IsExists(s.spfilter,1,nil,e,tp,sg) -end -function s.spfilter(c,e,tp,sg) - return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and sg:IsExists(s.setfilter,1,c,e,tp,1-tp) -end -function s.setfilter(c,e,tp,opp) - return (Duel.GetMZoneCount(opp)>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEDOWN_DEFENSE,opp)) or c:IsSSetable(false,opp) -end -function s.spsettg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then - if Duel.GetMZoneCount(tp)<=0 then return false end - local g=Duel.GetMatchingGroup(Card.IsSetCard,tp,LOCATION_HAND|LOCATION_DECK,0,nil,SET_MAGICAL_MUSKET) - return aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,0) - end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_DECK) -end -function s.spsetop(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetMZoneCount(tp)<=0 then return end - local g=Duel.GetMatchingGroup(Card.IsSetCard,tp,LOCATION_HAND|LOCATION_DECK,0,nil,SET_MAGICAL_MUSKET) - if #g<2 then return end - local sg=aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,1,tp,aux.Stringid(id,1)) - if #sg~=2 then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local spg=sg:FilterSelect(tp,s.spfilter,1,1,nil,e,tp,sg) - if #spg>0 and Duel.SpecialSummon(spg,0,tp,tp,false,false,POS_FACEUP)>0 then - local opp=1-tp - local setc=(sg-spg):GetFirst() - local b1=Duel.GetMZoneCount(opp)>0 and setc:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEDOWN_DEFENSE,opp) - local b2=setc:IsSSetable(false,opp) - local op=nil - if b1 and b2 then - op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,2)}, - {b2,aux.Stringid(id,3)}) - else - op=b1 and 1 or 2 - end - if op==1 then - Duel.SpecialSummon(setc,0,tp,opp,false,false,POS_FACEDOWN_DEFENSE) - Duel.ConfirmCards(tp,setc) - elseif op==2 then - Duel.SSet(tp,setc,opp) - end - end -end \ No newline at end of file diff --git a/pre-release/c100444219.lua b/pre-release/c100444219.lua deleted file mode 100644 index f465eedc66..0000000000 --- a/pre-release/c100444219.lua +++ /dev/null @@ -1,98 +0,0 @@ ---The Fallen & The Virtuous ---The Fallen & The Virtuous ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Activate 1 of these effects - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetProperty(EFFECT_FLAG_CARD_TARGET) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) - e1:SetCost(s.effcost) - e1:SetTarget(s.efftg) - e1:SetOperation(s.effop) - e1:SetHintTiming(TIMING_END_PHASE,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) -end -s.listed_names={CARD_ALBAZ} -s.listed_series={SET_BRANDED,SET_DOGMATIKA,SET_ECCLESIA} -function s.descostfilter(c) - return c:ListsCode(CARD_ALBAZ) and c:IsAbleToGraveAsCost() -end -function s.spconfilter(c) - return c:IsSetCard(SET_ECCLESIA) and c:IsMonster() and c:IsFaceup() -end -function s.effcost(e,tp,eg,ep,ev,re,r,rp,chk) - --Send 1 monster that mentions "Fallen of Albaz" from your Extra Deck to the GY, then target 1 face-up card on the field; destroy it - local b1=Duel.IsExistingMatchingCard(s.descostfilter,tp,LOCATION_EXTRA,0,1,nil) - and Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) - --If you have an "Ecclesia" monster in your field or GY: Target 1 monster in either GY; Special Summon it to your field - local b2=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spconfilter,tp,LOCATION_MZONE|LOCATION_GRAVE,0,1,nil) - and Duel.IsExistingTarget(Card.IsCanBeSpecialSummoned,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil,e,0,tp,false,false) - if chk==0 then return b1 or b2 end - local op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,1)}, - {b2,aux.Stringid(id,2)}) - e:SetLabel(op) - if op==1 then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local g=Duel.SelectMatchingCard(tp,s.descostfilter,tp,LOCATION_EXTRA,0,1,1,nil) - Duel.SendtoGrave(g,REASON_COST) - end -end -function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - local c=e:GetHandler() - if chkc then - local op=Duel.GetChainInfo(0,CHAININFO_TARGET_PARAM) - if op==1 then - return chkc:IsOnField() and chkc:IsFaceup() and chkc~=c - elseif op==2 then - return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsCanBeSpecialSummoned(e,0,tp,false,false) - end - end - --Send 1 monster that mentions "Fallen of Albaz" from your Extra Deck to the GY, then target 1 face-up card on the field; destroy it - local b1=Duel.IsExistingMatchingCard(s.descostfilter,tp,LOCATION_EXTRA,0,1,nil) - and Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) - --If you have an "Ecclesia" monster in your field or GY: Target 1 monster in either GY; Special Summon it to your field - local b2=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spconfilter,tp,LOCATION_MZONE|LOCATION_GRAVE,0,1,nil) - and Duel.IsExistingTarget(Card.IsCanBeSpecialSummoned,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil,e,0,tp,false,false) - if chk==0 then return b1 or b2 end - local op=nil - local label=e:GetLabel() - if label~=0 then - op=label - else - op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,1)}, - {b2,aux.Stringid(id,2)}) - end - e:SetLabel(0) - Duel.SetTargetParam(op) - if op==1 then - e:SetCategory(CATEGORY_DESTROY) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local g=Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,c) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) - elseif op==2 then - e:SetCategory(CATEGORY_SPECIAL_SUMMON) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectTarget(tp,Card.IsCanBeSpecialSummoned,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,nil,e,0,tp,false,false) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,0) - end -end -function s.effop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if not tc:IsRelateToEffect(e) then return end - local op=Duel.GetChainInfo(0,CHAININFO_TARGET_PARAM) - if op==1 then - --Send 1 monster that mentions "Fallen of Albaz" from your Extra Deck to the GY, then target 1 face-up card on the field; destroy it - Duel.Destroy(tc,REASON_EFFECT) - elseif op==2 then - --If you have an "Ecclesia" monster in your field or GY: Target 1 monster in either GY; Special Summon it to your field - Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c100444241.lua b/pre-release/c100444241.lua deleted file mode 100644 index 2ee3928018..0000000000 --- a/pre-release/c100444241.lua +++ /dev/null @@ -1,77 +0,0 @@ ---聖痕喰らいし竜 ---The Stigmata-Devouring Dragon ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Fusion Materials: "Fallen of Albaz" + 1 LIGHT or DARK monster + 1 Effect Monster - Fusion.AddProcMix(c,true,true,CARD_ALBAZ,aux.FilterBoolFunctionEx(Card.IsAttribute,ATTRIBUTE_LIGHT|ATTRIBUTE_DARK),aux.FilterBoolFunctionEx(Card.IsType,TYPE_EFFECT)) - --While an "Ecclesia" monster is on the field or in either GY, this card gains 500 ATK, also it is unaffected by other cards' effects - local e1a=Effect.CreateEffect(c) - e1a:SetType(EFFECT_TYPE_SINGLE) - e1a:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e1a:SetCode(EFFECT_UPDATE_ATTACK) - e1a:SetRange(LOCATION_MZONE) - e1a:SetCondition(function() return Duel.IsExistingMatchingCard(s.atkimmconfilter,0,LOCATION_MZONE|LOCATION_GRAVE,LOCATION_MZONE|LOCATION_GRAVE,1,nil) end) - e1a:SetValue(500) - c:RegisterEffect(e1a) - local e1b=e1a:Clone() - e1b:SetCode(EFFECT_IMMUNE_EFFECT) - e1b:SetValue(function(e,te) return te:GetOwner()~=e:GetOwner() end) - c:RegisterEffect(e1b) - --Shuffle up to 2 cards from any GY(s) and/or banishment into the Deck - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_TODECK) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY) - e2:SetCode(EVENT_SPSUMMON_SUCCESS) - e2:SetCountLimit(1,id) - e2:SetTarget(s.tdtg) - e2:SetOperation(s.tdop) - c:RegisterEffect(e2) - --Add 1 "Dogmatika" or "Tri-Brigade" card from your Deck to your hand - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e3:SetCode(EVENT_PHASE+PHASE_END) - e3:SetRange(LOCATION_GRAVE) - e3:SetCountLimit(1,{id,1}) - e3:SetCondition(function(e) return e:GetHandler():GetTurnID()==Duel.GetTurnCount() end) - e3:SetTarget(s.thtg) - e3:SetOperation(s.thop) - c:RegisterEffect(e3) -end -s.listed_names={CARD_ALBAZ} -s.listed_series={SET_ECCLESIA,SET_DOGMATIKA,SET_TRI_BRIGADE} -function s.atkimmconfilter(c) - return c:IsFaceup() and c:IsSetCard(SET_ECCLESIA) and c:IsMonster() -end -function s.tdtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToDeck,tp,LOCATION_GRAVE|LOCATION_REMOVED,LOCATION_GRAVE|LOCATION_REMOVED,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,1,PLAYER_EITHER,LOCATION_GRAVE|LOCATION_REMOVED) -end -function s.tdop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) - local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(Card.IsAbleToDeck),tp,LOCATION_GRAVE|LOCATION_REMOVED,LOCATION_GRAVE|LOCATION_REMOVED,1,2,nil) - if #g>0 then - Duel.HintSelection(g) - Duel.SendtoDeck(g,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) - end -end -function s.thfilter(c) - return c:IsSetCard({SET_DOGMATIKA,SET_TRI_BRIGADE}) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end diff --git a/pre-release/c100447018.lua b/pre-release/c100447018.lua deleted file mode 100644 index b220ef59ec..0000000000 --- a/pre-release/c100447018.lua +++ /dev/null @@ -1,87 +0,0 @@ ---ドラグニティ-クイリヌス ---Dragunity Quirinus ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Your "Dragunity" monsters cannot be destroyed by battle while this card is equipped with an Equip Card - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetCode(EFFECT_INDESTRUCTABLE_BATTLE) - e1:SetRange(LOCATION_MZONE) - e1:SetTargetRange(LOCATION_MZONE,0) - e1:SetCondition(function(e) return e:GetHandler():HasEquipCard() end) - e1:SetTarget(function(e,c) return c:IsSetCard(SET_DRAGUNITY) end) - e1:SetValue(1) - c:RegisterEffect(e1) - --Add 1 "Dragunity" Spell/Trap from your Deck to your hand - local e2a=Effect.CreateEffect(c) - e2a:SetDescription(aux.Stringid(id,0)) - e2a:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e2a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2a:SetProperty(EFFECT_FLAG_DELAY) - e2a:SetCode(EVENT_SUMMON_SUCCESS) - e2a:SetCountLimit(1,id) - e2a:SetTarget(s.thtg) - e2a:SetOperation(s.thop) - c:RegisterEffect(e2a) - local e2b=e2a:Clone() - e2b:SetCode(EVENT_SPSUMMON_SUCCESS) - c:RegisterEffect(e2b) - --Return 1 "Dragunity" Monster Card you control to the hand/Extra Deck, then you can Special Summon 1 "Dragunity" monster from your hand - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_TOHAND+CATEGORY_TOEXTRA+CATEGORY_SPECIAL_SUMMON) - e3:SetType(EFFECT_TYPE_IGNITION) - e3:SetProperty(EFFECT_FLAG_CARD_TARGET) - e3:SetRange(LOCATION_MZONE) - e3:SetCountLimit(1,{id,1}) - e3:SetTarget(s.thsptg) - e3:SetOperation(s.thspop) - c:RegisterEffect(e3) -end -s.listed_series={SET_DRAGUNITY} -function s.thfilter(c) - return c:IsSetCard(SET_DRAGUNITY) and c:IsSpellTrap() and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end -function s.thorextfilter(c) - return c:IsSetCard(SET_DRAGUNITY) and c:IsMonsterCard() and c:IsFaceup() and (c:IsAbleToHand() or c:IsAbleToExtra()) -end -function s.thsptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - local c=e:GetHandler() - if chkc then return chkc:IsOnField() and chkc:IsControler(tp) and s.thorextfilter(chkc) and chkc~=c end - if chk==0 then return Duel.IsExistingTarget(s.thorextfilter,tp,LOCATION_ONFIELD,0,1,c) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) - local g=Duel.SelectTarget(tp,s.thorextfilter,tp,LOCATION_ONFIELD,0,1,1,c) - Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,tp,0) - Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND) -end -function s.spfilter(c,e,tp) - return c:IsSetCard(SET_DRAGUNITY) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.thspop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and Duel.SendtoHand(tc,nil,REASON_EFFECT)>0 and tc:IsLocation(LOCATION_HAND|LOCATION_EXTRA) then - if tc:IsLocation(LOCATION_HAND) then Duel.ShuffleHand(tp) end - if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND,0,1,nil,e,tp) - and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON) - local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND,0,1,1,nil,e,tp) - if #g>0 then - Duel.BreakEffect() - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end - end - end -end \ No newline at end of file diff --git a/pre-release/c100447019.lua b/pre-release/c100447019.lua deleted file mode 100644 index 39602b3ee3..0000000000 --- a/pre-release/c100447019.lua +++ /dev/null @@ -1,78 +0,0 @@ ---ドラグニティ-ファルシオン ---Dragunity Falchion ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Equip 1 Dragon "Dragunity" monster from your Deck or GY to 1 "Dragunity" monster you control as an Equip Spell - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_EQUIP) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetProperty(EFFECT_FLAG_CARD_TARGET) - e1:SetRange(LOCATION_HAND|LOCATION_GRAVE) - e1:SetCountLimit(1,id) - e1:SetCost(Cost.SelfBanish) - e1:SetTarget(s.eqtg) - e1:SetOperation(s.eqop) - c:RegisterEffect(e1) - --Banish 1 face-up card your opponent controls - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_REMOVE) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_SZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(s.rmcon) - e2:SetCost(Cost.SelfToGrave) - e2:SetTarget(s.rmtg) - e2:SetOperation(s.rmop) - c:RegisterEffect(e2) -end -s.listed_series={SET_DRAGUNITY} -function s.eqfilter(c,tp) - return c:IsRace(RACE_DRAGON) and c:IsSetCard(SET_DRAGUNITY) and c:CheckUniqueOnField(tp) and not c:IsForbidden() -end -function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsSetCard(SET_DRAGUNITY) and chkc:IsFaceup() end - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 - and Duel.IsExistingTarget(aux.FaceupFilter(Card.IsSetCard,SET_DRAGUNITY),tp,LOCATION_MZONE,0,1,nil) - and Duel.IsExistingMatchingCard(s.eqfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,e:GetHandler(),tp) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) - Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsSetCard,SET_DRAGUNITY),tp,LOCATION_MZONE,0,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_EQUIP,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) -end -function s.eqop(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end - local tc=Duel.GetFirstTarget() - if tc:IsFacedown() or not tc:IsRelateToEffect(e) then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) - local ec=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.eqfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil,tp):GetFirst() - if ec and Duel.Equip(tp,ec,tc) then - --Equip limit - local e1=Effect.CreateEffect(ec) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_EQUIP_LIMIT) - e1:SetValue(function(e,c) return c==tc end) - e1:SetReset(RESET_EVENT|RESETS_STANDARD) - ec:RegisterEffect(e1) - end -end -function s.rmcon(e,tp,eg,ep,ev,re,r,rp) - local ec=e:GetHandler():GetEquipTarget() - return ec and ec:IsSetCard(SET_DRAGUNITY) -end -function s.rmtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsOnField() and chkc:IsControler(1-tp) and chkc:IsAbleToRemove() and chkc:IsFaceup() end - if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(Card.IsAbleToRemove),tp,0,LOCATION_ONFIELD,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) - local g=Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsAbleToRemove),tp,0,LOCATION_ONFIELD,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,1,tp,0) -end -function s.rmop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) then - Duel.Remove(tc,POS_FACEUP,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c100447020.lua b/pre-release/c100447020.lua deleted file mode 100644 index 20fd810c77..0000000000 --- a/pre-release/c100447020.lua +++ /dev/null @@ -1,79 +0,0 @@ ---ドラグニティナイト-アーレウス ---Dragunity Knight - Areus -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Synchro Summon procedure: 1 Tuner + 1+ non-Tuner Synchro Monsters - Synchro.AddProcedure(c,nil,1,1,Synchro.NonTunerEx(Card.IsType,TYPE_SYNCHRO),1,99) - --Negate the effects of face-up cards your opponent controls, up to the number of face-up Monster Cards in your Spell & Trap Zone, until the end of this turn - local e1a=Effect.CreateEffect(c) - e1a:SetDescription(aux.Stringid(id,0)) - e1a:SetCategory(CATEGORY_DISABLE) - e1a:SetType(EFFECT_TYPE_IGNITION) - e1a:SetProperty(EFFECT_FLAG_CARD_TARGET) - e1a:SetRange(LOCATION_MZONE) - e1a:SetCountLimit(1,id) - e1a:SetCondition(function(e) return not e:GetHandler():HasEquipCard() end) - e1a:SetTarget(s.distg) - e1a:SetOperation(s.disop) - c:RegisterEffect(e1a) - --This is a Quick Effect if this card is equipped with an Equip Card - local e1b=e1a:Clone() - e1b:SetType(EFFECT_TYPE_QUICK_O) - e1b:SetCode(EVENT_FREE_CHAIN) - e1b:SetCondition(function(e) return e:GetHandler():HasEquipCard() end) - e1b:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) - c:RegisterEffect(e1b) - --Special Summon this card, then you can Special Summon 1 "Dragunity" Tuner from your GY - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_SZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(function(e) return e:GetHandler():GetEquipTarget() end) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - c:RegisterEffect(e2) -end -s.listed_series={SET_DRAGUNITY} -function s.distg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsOnField() and chkc:IsControler(1-tp) and chkc:IsNegatable() end - local ct=Duel.GetMatchingGroupCount(aux.FaceupFilter(Card.IsMonsterCard),tp,LOCATION_STZONE,0,nil) - if chk==0 then return ct>0 and Duel.IsExistingTarget(Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_NEGATE) - local g=Duel.SelectTarget(tp,Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,ct,nil) - Duel.SetOperationInfo(0,CATEGORY_DISABLE,g,1,tp,0) -end -function s.disop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local tg=Duel.GetTargetCards(e) - for tc in tg:Iter() do - --Negate their effects until the end of this turn - tc:NegateEffects(c,RESETS_STANDARD_PHASE_END,true) - end -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) - Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) -end -function s.spfilter(c,e,tp) - return c:IsSetCard(SET_DRAGUNITY) and c:IsType(TYPE_TUNER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 - and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(aux.NecroValleyFilter(s.spfilter),tp,LOCATION_GRAVE,0,1,nil,e,tp) - and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_GRAVE,0,1,1,nil,e,tp) - if #g>0 then - Duel.BreakEffect() - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end - end -end \ No newline at end of file diff --git a/pre-release/c100447021.lua b/pre-release/c100447021.lua deleted file mode 100644 index eae2f39b0f..0000000000 --- a/pre-release/c100447021.lua +++ /dev/null @@ -1,78 +0,0 @@ ---ドラグニティロード-ゲオルギアス ---Dragunity Lord - Georgius -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Link Summon procedure: 2+ monsters, including a Tuner - Link.AddProcedure(c,nil,2,4,s.tunermatcheck) - --Your opponent cannot activate the effects of monsters in the GY while this card is equipped with a "Dragunity" card - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET) - e1:SetCode(EFFECT_CANNOT_ACTIVATE) - e1:SetRange(LOCATION_MZONE) - e1:SetTargetRange(0,1) - e1:SetCondition(function(e) return e:GetHandler():GetEquipGroup():IsExists(Card.IsSetCard,1,nil,SET_DRAGUNITY) end) - e1:SetValue(function(e,re,tp) return re:IsMonsterEffect() and re:GetHandler():IsLocation(LOCATION_GRAVE) end) - c:RegisterEffect(e1) - --Special Summon 1 Level 5 or higher "Dragunity" monster from your Extra Deck or GY - local e2a=Effect.CreateEffect(c) - e2a:SetDescription(aux.Stringid(id,0)) - e2a:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2a:SetProperty(EFFECT_FLAG_DELAY) - e2a:SetCode(EVENT_SPSUMMON_SUCCESS) - e2a:SetCountLimit(1,id) - e2a:SetCondition(function(e) return e:GetHandler():IsLinkSummoned() end) - e2a:SetTarget(s.sptg) - e2a:SetOperation(s.spop) - c:RegisterEffect(e2a) - local e2b=e2a:Clone() - e2b:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e2b:SetRange(LOCATION_MZONE) - e2b:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return not eg:IsContains(e:GetHandler()) and eg:IsExists(Card.IsSummonPlayer,1,nil,1-tp) end) - c:RegisterEffect(e2b) - --Negate an opponent's activated Spell/Trap Card or effect - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_DISABLE) - e3:SetType(EFFECT_TYPE_QUICK_O) - e3:SetCode(EVENT_CHAINING) - e3:SetRange(LOCATION_MZONE) - e3:SetCountLimit(1,{id,1}) - e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return ep==1-tp and re:IsSpellTrapEffect() and Duel.IsChainDisablable(ev) end) - e3:SetCost(s.discost) - e3:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk) if chk==0 then return true end Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,tp,0) end) - e3:SetOperation(function(e,tp,eg,ep,ev,re,r,rp) Duel.NegateEffect(ev) end) - c:RegisterEffect(e3) - aux.DoubleSnareValidity(c,LOCATION_MZONE) -end -s.listed_series={SET_DRAGUNITY} -function s.tunermatcheck(g,lc,sumtype,tp) - return g:IsExists(Card.IsType,1,nil,TYPE_TUNER,lc,sumtype,tp) -end -function s.spfilter(c,e,tp,mmz_chk) - if not (c:IsLevelAbove(5) and c:IsSetCard(SET_DRAGUNITY) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)) then return false end - if c:IsLocation(LOCATION_EXTRA) then - return Duel.GetLocationCountFromEx(tp,tp,nil,c)>0 - else - return mmz_chk - end -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_EXTRA|LOCATION_GRAVE,0,1,nil,e,tp,Duel.GetLocationCount(tp,LOCATION_MZONE)>0) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA|LOCATION_GRAVE) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_EXTRA|LOCATION_GRAVE,0,1,1,nil,e,tp,Duel.GetLocationCount(tp,LOCATION_MZONE)>0) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end -function s.discost(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(aux.AND(Card.IsEquipCard,Card.IsAbleToGraveAsCost),tp,LOCATION_ONFIELD,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local g=Duel.SelectMatchingCard(tp,aux.AND(Card.IsEquipCard,Card.IsAbleToGraveAsCost),tp,LOCATION_ONFIELD,0,1,1,nil) - Duel.SendtoGrave(g,REASON_COST) -end \ No newline at end of file diff --git a/pre-release/c100447064.lua b/pre-release/c100447064.lua deleted file mode 100644 index c0944ae733..0000000000 --- a/pre-release/c100447064.lua +++ /dev/null @@ -1,81 +0,0 @@ ---影霊翼騎 ウェンディクルフ ---Reeshaddoll Wendicluhu ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - c:AddMustFirstBeFusionSummoned() - --Fusion Materials: 1 "Shaddoll" monster + 1 WIND monster - Fusion.AddProcMix(c,true,true,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_SHADDOLL),s.matfilter) - --Change any number of face-down monsters on the field to face-up Defense Position - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_POSITION) - e1:SetType(EFFECT_TYPE_QUICK_O) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetRange(LOCATION_MZONE) - e1:SetCountLimit(1,id) - e1:SetTarget(s.postg) - e1:SetOperation(s.posop) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) - --Add 1 "Shaddoll" card from your GY to your hand - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TOHAND) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) - e2:SetCode(EVENT_TO_GRAVE) - e2:SetTarget(s.thtg) - e2:SetOperation(s.thop) - c:RegisterEffect(e2) -end -s.listed_series={SET_SHADDOLL} -s.material_setcode=SET_SHADDOLL -function s.matfilter(c,lc,sumtype,tp) - return c:IsAttribute(ATTRIBUTE_WIND,lc,sumtype,tp) or c:IsHasEffect(4904633) -end -function s.posfilter(c) - return c:IsPosition(POS_FACEDOWN_DEFENSE) and c:IsCanChangePosition() -end -function s.postg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.posfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_POSITION,nil,1,PLAYER_EITHER,LOCATION_MZONE) -end -function s.posop(e,tp,eg,ep,ev,re,r,rp,chk) - local facedown_ct=Duel.GetMatchingGroupCount(s.posfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil) - if facedown_ct==0 then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_POSCHANGE) - local g=Duel.SelectMatchingCard(tp,s.posfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,facedown_ct,nil) - if #g==0 then return end - Duel.HintSelection(g) - if Duel.ChangePosition(g,POS_FACEUP_DEFENSE)==0 then return end - local og=Duel.GetOperatedGroup() - local flip_count=og:FilterCount(Card.IsType,nil,TYPE_FLIP) - if flip_count>0 and Duel.IsExistingMatchingCard(Card.IsCanTurnSet,tp,LOCATION_MZONE,LOCATION_MZONE,1,og) - and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_POSCHANGE) - local pos_g=Duel.SelectMatchingCard(tp,Card.IsCanTurnSet,tp,LOCATION_MZONE,LOCATION_MZONE,1,flip_count,og) - if #pos_g>0 then - Duel.HintSelection(pos_g) - Duel.BreakEffect() - Duel.ChangePosition(pos_g,POS_FACEDOWN_DEFENSE) - end - end -end -function s.thfilter(c) - return c:IsSetCard(SET_SHADDOLL) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.thfilter(chkc) end - if chk==0 then return Duel.IsExistingTarget(s.thfilter,tp,LOCATION_GRAVE,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectTarget(tp,s.thfilter,tp,LOCATION_GRAVE,0,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,tp,0) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) then - Duel.SendtoHand(tc,nil,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c100447101.lua b/pre-release/c100447101.lua deleted file mode 100644 index 11fcdc6d91..0000000000 --- a/pre-release/c100447101.lua +++ /dev/null @@ -1,85 +0,0 @@ ---セイクリッド・カストル ---Constellar Castor ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Special Summon 1 "Constellar" monster from your Deck - local e1a=Effect.CreateEffect(c) - e1a:SetDescription(aux.Stringid(id,0)) - e1a:SetCategory(CATEGORY_SPECIAL_SUMMON) - e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1a:SetProperty(EFFECT_FLAG_DELAY) - e1a:SetCode(EVENT_SUMMON_SUCCESS) - e1a:SetCountLimit(1,id) - e1a:SetTarget(s.sptg) - e1a:SetOperation(s.spop) - c:RegisterEffect(e1a) - local e1b=e1a:Clone() - e1b:SetCode(EVENT_FLIP_SUMMON_SUCCESS) - c:RegisterEffect(e1b) - local e1c=e1a:Clone() - e1c:SetCode(EVENT_SPSUMMON_SUCCESS) - c:RegisterEffect(e1c) - --A "Constellar" Xyz Monster that has this card as material gains this effect: Negate a Spell or effect activated by the opponent, and if you do, destroy that card - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_DISABLE+CATEGORY_DESTROY) - e2:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_QUICK_O) - e2:SetCode(EVENT_CHAINING) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1) - e2:SetCondition(s.discon) - e2:SetTarget(s.distg) - e2:SetOperation(s.disop) - c:RegisterEffect(e2) -end -s.listed_series={SET_CONSTELLAR} -s.listed_names={id} -function s.spfilter(c,e,tp) - return c:IsSetCard(SET_CONSTELLAR) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and not c:IsCode(id) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - --Excluding itself for a proper interaction with "Tellarknight Constellar Caduceus" [58858807] - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,e:GetHandler(),e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - --You cannot Special Summon from the Extra Deck for the rest of this turn, except DARK monsters - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsAttribute(ATTRIBUTE_DARK|ATTRIBUTE_LIGHT) end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) - --"Clock Lizard" check - aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalAttribute(ATTRIBUTE_DARK|ATTRIBUTE_LIGHT) end) - --Special Summon 1 "Constellar" monster from your Deck - if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end -function s.discon(e,tp,eg,ep,ev,re,r,rp) - return e:GetHandler():IsSetCard(SET_CONSTELLAR) and rp==1-tp and re:IsSpellEffect() and Duel.IsChainDisablable(ev) -end -function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.CheckRemoveOverlayCard(tp,1,0,2,REASON_EFFECT) end - local rc=re:GetHandler() - Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,tp,0) - if rc:IsDestructable() and rc:IsRelateToEffect(re) then - Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,tp,0) - end -end -function s.disop(e,tp,eg,ep,ev,re,r,rp) - if Duel.RemoveOverlayCard(tp,1,0,2,2,REASON_EFFECT)==2 and Duel.NegateEffect(ev) - and re:GetHandler():IsRelateToEffect(re) then - Duel.Destroy(eg,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c100447102.lua b/pre-release/c100447102.lua deleted file mode 100644 index dfec98f201..0000000000 --- a/pre-release/c100447102.lua +++ /dev/null @@ -1,84 +0,0 @@ ---星騎士 キュグニ ---Tellarknight Cygnian ---Scripted by ahtelel -local s,id=GetID() -function s.initial_effect(c) - --Add 1 "tellarknight" or "Constellar" monster from your Deck to your hand - local e1a=Effect.CreateEffect(c) - e1a:SetDescription(aux.Stringid(id,0)) - e1a:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1a:SetProperty(EFFECT_FLAG_DELAY) - e1a:SetCode(EVENT_SUMMON_SUCCESS) - e1a:SetCountLimit(1,id) - e1a:SetTarget(s.thtg) - e1a:SetOperation(s.thop) - c:RegisterEffect(e1a) - local e1b=e1a:Clone() - e1b:SetCode(EVENT_FLIP_SUMMON_SUCCESS) - c:RegisterEffect(e1b) - local e1c=e1a:Clone() - e1c:SetCode(EVENT_SPSUMMON_SUCCESS) - c:RegisterEffect(e1c) - --Increase this card and another LIGHT monster's Level by 1 - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_LVCHANGE) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.lvtg) - e2:SetOperation(s.lvop) - c:RegisterEffect(e2) - --Can be treated as 2 Materials for the Xyz Summon of a "tellarknight" Xyz monster that requires 3 or more materials - local e3=Effect.CreateEffect(c) - e3:SetType(EFFECT_TYPE_SINGLE) - e3:SetCode(EFFECT_DOUBLE_XYZ_MATERIAL) - e3:SetCountLimit(1,{id,2}) - e3:SetValue(1) - e3:SetOperation(function(e,c) return c.minxyzct and c.minxyzct>=3 and c:IsSetCard(SET_TELLARKNIGHT) end) - c:RegisterEffect(e3) -end -s.listed_series={SET_TELLARKNIGHT,SET_CONSTELLAR} -function s.thfilter(c) - return c:IsSetCard({SET_TELLARKNIGHT,SET_CONSTELLAR}) and c:IsMonster() and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end -function s.lvfilter(c) - return c:IsAttribute(ATTRIBUTE_LIGHT) and c:HasLevel() and c:IsFaceup() -end -function s.lvtg(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 chkc~=c and s.lvfilter(chkc) end - if chk==0 then return Duel.IsExistingTarget(s.lvfilter,tp,LOCATION_MZONE,0,1,c) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) - Duel.SelectTarget(tp,s.lvfilter,tp,LOCATION_MZONE,0,1,1,c) -end -function s.lvop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local tc=Duel.GetFirstTarget() - if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and c:IsFaceup() and tc:IsFaceup() then - --Increase both their Level by 1 - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_UPDATE_LEVEL) - e1:SetValue(1) - e1:SetReset(RESET_EVENT|RESETS_STANDARD) - c:RegisterEffect(e1) - local e2=e1:Clone() - tc:RegisterEffect(e2) - end -end \ No newline at end of file diff --git a/pre-release/c100447103.lua b/pre-release/c100447103.lua deleted file mode 100644 index 17783f1598..0000000000 --- a/pre-release/c100447103.lua +++ /dev/null @@ -1,68 +0,0 @@ ---超神星輝士 セイクリッド・トレミスΩ7 ---Exstellarknight Constellar Ptolemy Ω7 ---Scripted by ahtelel -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Xyz Summon procedure: 3 Level 7 monsters OR 1 "tellarknight" or "Constellar" Xyz Monster you control - Xyz.AddProcedure(c,nil,7,3,s.ovfilter,aux.Stringid(id,0),3,s.xyzop) - --While you have 7 or more "tellarknight" monsters with different names in your GY and/or banishment, this card gains 2700 ATK/DEF, also it is unaffected by your opponent's activated effects - local e1a=Effect.CreateEffect(c) - e1a:SetType(EFFECT_TYPE_SINGLE) - e1a:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e1a:SetCode(EFFECT_UPDATE_ATTACK) - e1a:SetRange(LOCATION_MZONE) - e1a:SetCondition(s.atkdefimmcon) - e1a:SetValue(2700) - c:RegisterEffect(e1a) - local e1b=e1a:Clone() - e1b:SetCode(EFFECT_UPDATE_DEFENSE) - c:RegisterEffect(e1b) - local e1c=e1a:Clone() - e1c:SetCode(EFFECT_IMMUNE_EFFECT) - e1c:SetValue(function(e,te) return te:GetOwnerPlayer()~=e:GetHandlerPlayer() and te:IsActivated() end) - c:RegisterEffect(e1c) - --Shuffle opponent's monsters into the deck based on the number of materials you detach from this card - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TODECK) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1) - e2:SetCost(Cost.DetachFromSelf(1,function(e,tp) return Duel.GetTargetCount(Card.IsAbleToDeck,tp,0,LOCATION_MZONE,nil) end,function(e,og) e:SetLabel(#og) end)) - e2:SetTarget(s.tdtg) - e2:SetOperation(s.tdop) - e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e2) -end -s.listed_series={SET_TELLARKNIGHT,SET_CONSTELLAR} -s.listed_names={id} -function s.ovfilter(c,tp,xyzc) - return c:IsSetCard({SET_TELLARKNIGHT,SET_CONSTELLAR},xyzc,SUMMON_TYPE_XYZ,tp) and c:IsType(TYPE_XYZ,xyzc,SUMMON_TYPE_XYZ,tp) and c:IsFaceup() -end -function s.xyzop(e,tp,chk) - if chk==0 then return Duel.IsMainPhase2(tp) and not Duel.HasFlagEffect(tp,id) end - return Duel.RegisterFlagEffect(tp,id,RESET_PHASE|PHASE_END,EFFECT_FLAG_OATH,1) -end -function s.atkdefimmfilter(c) - return c:IsSetCard(SET_TELLARKNIGHT) and c:IsMonster() and c:IsFaceup() -end -function s.atkdefimmcon(e,c) - return Duel.GetMatchingGroup(s.atkdefimmfilter,e:GetHandlerPlayer(),LOCATION_GRAVE|LOCATION_REMOVED,0,nil):GetClassCount(Card.GetCode)>=7 -end -function s.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and chkc:IsAbleToDeck() end - if chk==0 then return Duel.IsExistingTarget(Card.IsAbleToDeck,tp,0,LOCATION_MZONE,1,nil) end - local ct=e:GetLabel() - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) - local g=Duel.SelectTarget(tp,Card.IsAbleToDeck,tp,0,LOCATION_MZONE,ct,ct,nil) - Duel.SetOperationInfo(0,CATEGORY_TODECK,g,#g,tp,0) -end -function s.tdop(e,tp,eg,ep,ev,re,r,rp) - local tg=Duel.GetTargetCards(e) - if #tg>0 then - Duel.SendtoDeck(tg,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c100447104.lua b/pre-release/c100447104.lua deleted file mode 100644 index 2bbe0f4f10..0000000000 --- a/pre-release/c100447104.lua +++ /dev/null @@ -1,89 +0,0 @@ ---星騎士 セイクリッド・デルタテロス ---Tellarknight Constellar Delteros ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Xyz Summon procedure: 3+ Level 4 monsters - Xyz.AddProcedure(c,nil,4,3,nil,nil,Xyz.InfiniteMats) - --Your opponent cannot target Rank 5 or higher "tellarknight" or "Constellar" Xyz Monsters you control with card effects - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE) - e1:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET) - e1:SetRange(LOCATION_MZONE) - e1:SetTargetRange(LOCATION_MZONE,0) - e1:SetTarget(s.tellarkR5filter) - e1:SetValue(aux.tgoval) - c:RegisterEffect(e1) - --Add 1 "tellarknight" or "Constellar" monster from your Deck to your hand, then immediately after this effect resolves, you can Normal Summon 1 LIGHT monster - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1) - e2:SetCost(Cost.DetachFromSelf(1)) - e2:SetTarget(s.thtg) - e2:SetOperation(s.thop) - c:RegisterEffect(e2) - --Special Summon 1 "tellarknight" or "Constellar" monster from your hand or banishment - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_SPECIAL_SUMMON) - e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e3:SetProperty(EFFECT_FLAG_DELAY) - e3:SetCode(EVENT_TO_GRAVE) - e3:SetCondition(function(e) return not e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD) end) - e3:SetTarget(s.sptg) - e3:SetOperation(s.spop) - c:RegisterEffect(e3) -end -s.listed_series={SET_TELLARKNIGHT,SET_CONSTELLAR} -function s.tellarkR5filter(e,c) - return c:IsSetCard({SET_TELLARKNIGHT,SET_CONSTELLAR}) and c:IsRankAbove(5) and c:IsFaceup() -end -function s.thfilter(c) - return c:IsSetCard({SET_TELLARKNIGHT,SET_CONSTELLAR}) and c:IsMonster() and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) - Duel.SetPossibleOperationInfo(0,CATEGORY_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_MZONE) -end -function s.nsfilter(c) - return c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsSummonable(true,nil) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 and Duel.SendtoHand(g,nil,REASON_EFFECT)>0 then - Duel.ConfirmCards(1-tp,g) - Duel.ShuffleHand(tp) - if Duel.IsExistingMatchingCard(s.nsfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON) - local sc=Duel.SelectMatchingCard(tp,s.nsfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,1,nil):GetFirst() - if sc then - Duel.BreakEffect() - Duel.Summon(tp,sc,true,nil) - end - end - end -end -function s.spfilter(c,e,tp) - return c:IsSetCard({SET_TELLARKNIGHT,SET_CONSTELLAR}) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) - and (c:IsFaceup() or c:IsLocation(LOCATION_HAND)) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_REMOVED,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_REMOVED) -end -function s.spop(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,s.spfilter,tp,LOCATION_HAND|LOCATION_REMOVED,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c100447106.lua b/pre-release/c100447106.lua deleted file mode 100644 index b5277b550f..0000000000 --- a/pre-release/c100447106.lua +++ /dev/null @@ -1,90 +0,0 @@ ---X-セイバー ペリナ ---X-Saber Perina ---Scripted by the Razgriz -local s,id=GetID() -function s.initial_effect(c) - --Special Summon 2 "X-Saber" monsters from your Deck, except "X-Saber Perina", but destroy them during the End Phase - local e1a=Effect.CreateEffect(c) - e1a:SetDescription(aux.Stringid(id,0)) - e1a:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DESTROY) - e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1a:SetProperty(EFFECT_FLAG_DELAY) - e1a:SetCode(EVENT_SUMMON_SUCCESS) - e1a:SetCountLimit(1,id) - e1a:SetCost(Cost.SelfToGrave) - e1a:SetTarget(s.sptg) - e1a:SetOperation(s.spop) - c:RegisterEffect(e1a) - local e1b=e1a:Clone() - e1b:SetCode(EVENT_SPSUMMON_SUCCESS) - c:RegisterEffect(e1b) - --Apply an effect to the "X-Saber" Synchro Monster that used this card as material - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY) - e2:SetCode(EVENT_BE_MATERIAL) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(s.effcon) - e2:SetTarget(s.efftg) - e2:SetOperation(s.effop) - c:RegisterEffect(e2) -end -s.listed_series={SET_X_SABER} -s.listed_names={id} -function s.spfilter(c,e,tp) - return c:IsSetCard(SET_X_SABER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and not c:IsCode(id) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return not Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) - and Duel.GetMZoneCount(tp,e:GetHandler())>=2 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,2,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,2,tp,LOCATION_DECK) - Duel.SetPossibleOperationInfo(0,CATEGORY_DESTROY,nil,2,tp,LOCATION_MZONE) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - if Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) or Duel.GetLocationCount(tp,LOCATION_MZONE)<2 then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,2,2,nil,e,tp) - if #g==2 and Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)==2 then - --Destroy them during the End Phase - aux.DelayedOperation(g,PHASE_END,id,e,tp,function(ag) Duel.Destroy(ag,REASON_EFFECT) end,nil,0,0,aux.Stringid(id,2)) - end -end -function s.effcon(e,tp,eg,ep,ev,re,r,rp) - if not (r==REASON_SYNCHRO and (Duel.IsAbleToEnterBP() or (Duel.IsBattlePhase() and not Duel.IsEndStep()))) then return false end - local c=e:GetHandler() - local sync=c:GetReasonCard() - if not (c:IsLocation(LOCATION_GRAVE) and sync:IsSetCard(SET_X_SABER)) then return false end - e:SetLabelObject(sync) - sync:RegisterFlagEffect(id,RESET_EVENT|(RESETS_STANDARD&~RESET_TURN_SET),0,1) - return true -end -function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) - local sync=e:GetLabelObject() - if chk==0 then - return sync:HasFlagEffect(id) and not (sync:IsHasEffect(EFFECT_EXTRA_ATTACK) and sync:IsHasEffect(EFFECT_DIRECT_ATTACK)) - end - sync:CreateEffectRelation(e) -end -function s.effop(e,tp,eg,ep,ev,re,r,rp) - local sync=e:GetLabelObject() - if not sync:IsRelateToEffect(e) then return end - local b1=not sync:IsHasEffect(EFFECT_EXTRA_ATTACK) - local b2=not sync:IsHasEffect(EFFECT_DIRECT_ATTACK) - if not (b1 or b2) then return end - local op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,3)}, - {b2,aux.Stringid(id,4)}) - local desc=op==1 and 3201 or 3205 - local eff_code=op==1 and EFFECT_EXTRA_ATTACK or EFFECT_DIRECT_ATTACK - --It can make a second attack during each Battle Phase OR it can attack directly - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetDescription(desc) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(eff_code) - e1:SetValue(1) - e1:SetReset(RESET_EVENT|RESETS_STANDARD) - sync:RegisterEffect(e1) -end \ No newline at end of file diff --git a/pre-release/c100447107.lua b/pre-release/c100447107.lua deleted file mode 100644 index 591e2bd607..0000000000 --- a/pre-release/c100447107.lua +++ /dev/null @@ -1,101 +0,0 @@ ---X-セイバー ブルノ ---X-Saber Bruno ---Scripted by the Razgriz -local s,id=GetID() -function s.initial_effect(c) - --Synchro Summon using only EARTH monsters, including this card - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_QUICK_O) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetRange(LOCATION_MZONE) - e1:SetCountLimit(1) - e1:SetCondition(function(e,tp) return Duel.IsMainPhase(1-tp) or Duel.IsBattlePhase(1-tp) end) - e1:SetTarget(s.synchtg) - e1:SetOperation(s.synchop) - e1:SetHintTiming(0,TIMING_MAIN_END|TIMING_BATTLE_END|TIMINGS_CHECK_MONSTER) - c:RegisterEffect(e1) - --Banish 1 other EARTH monster to Special Summon this card - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_HAND) - e2:SetCountLimit(1,id) - e2:SetCost(s.spcost) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - c:RegisterEffect(e2) - --Add 1 "Saber" Spell/Trap Card from your Deck to your hand - local e3a=Effect.CreateEffect(c) - e3a:SetDescription(aux.Stringid(id,2)) - e3a:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e3a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e3a:SetProperty(EFFECT_FLAG_DELAY) - e3a:SetCode(EVENT_SUMMON_SUCCESS) - e3a:SetCountLimit(1,{id,1}) - e3a:SetTarget(s.thtg) - e3a:SetOperation(s.thop) - c:RegisterEffect(e3a) - local e3b=e3a:Clone() - e3b:SetCode(EVENT_SPSUMMON_SUCCESS) - c:RegisterEffect(e3b) -end -s.listed_series={SET_X_SABER,SET_SABER} -s.listed_names={id} -function s.synchtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then - local c=e:GetHandler() - local mg=Duel.GetMatchingGroup(aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_EARTH),tp,LOCATION_MZONE,0,nil) - return c:IsAttribute(ATTRIBUTE_EARTH) and Duel.IsExistingMatchingCard(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,1,nil,c,mg) - end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) -end -function s.synchop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if not (c:IsRelateToEffect(e) and c:IsControler(tp) and c:IsFaceup() and c:IsAttribute(ATTRIBUTE_EARTH)) then return end - local mg=Duel.GetMatchingGroup(aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_EARTH),tp,LOCATION_MZONE,0,nil) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local sc=Duel.SelectMatchingCard(tp,Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,1,1,nil,c,mg):GetFirst() - if sc then - Duel.SynchroSummon(tp,sc,c,mg) - end -end -function s.spcostfilter(c,tp) - return c:IsAttribute(ATTRIBUTE_EARTH) and c:IsAbleToRemoveAsCost() and (c:IsLocation(LOCATION_HAND) or c:IsFaceup()) - and Duel.GetMZoneCount(tp,c)>0 -end -function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.IsExistingMatchingCard(s.spcostfilter,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_GRAVE,0,1,c,tp) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) - local g=Duel.SelectMatchingCard(tp,s.spcostfilter,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_GRAVE,0,1,1,c,tp) - Duel.Remove(g,POS_FACEUP,REASON_COST) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) then - Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) - end -end -function s.thfilter(c) - return c:IsSetCard(SET_SABER) and c:IsSpellTrap() and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.thfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end \ No newline at end of file diff --git a/pre-release/c100447108.lua b/pre-release/c100447108.lua deleted file mode 100644 index 930bef545f..0000000000 --- a/pre-release/c100447108.lua +++ /dev/null @@ -1,113 +0,0 @@ ---総剣司令 ソウザ ---Commander Souza, Swordmaster ---Scripted by the Razgriz -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Synchro Summon procedure: 1 Tuner + 1+ EARTH monsters - Synchro.AddProcedure(c,nil,1,1,aux.FilterBoolFunctionEx(Card.IsAttribute,ATTRIBUTE_EARTH),1,99) - --Multiple Tuner check - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_SINGLE) - e0:SetCode(EFFECT_MATERIAL_CHECK) - e0:SetValue(s.valcheck) - c:RegisterEffect(e0) - --Gains 200 ATK for each banished monster - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e1:SetCode(EFFECT_UPDATE_ATTACK) - e1:SetRange(LOCATION_MZONE) - e1:SetValue(function(e,c) return 200*Duel.GetMatchingGroupCount(aux.FaceupFilter(Card.IsMonster),0,LOCATION_REMOVED,LOCATION_REMOVED,nil) end) - c:RegisterEffect(e1) - --Draw 1 card - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_DRAW) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET) - e2:SetCode(EVENT_BATTLE_DESTROYING) - e2:SetCondition(aux.bdocon) - e2:SetTarget(s.drtg) - e2:SetOperation(s.drop) - c:RegisterEffect(e2) - --Destroy 1 card your opponent controls - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_DESTROY) - e3:SetType(EFFECT_TYPE_QUICK_O) - e3:SetCode(EVENT_CHAINING) - e3:SetRange(LOCATION_MZONE) - e3:SetCountLimit(1) - e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return ep==1-tp end) - e3:SetCost(s.descost) - e3:SetTarget(s.destg) - e3:SetOperation(s.desop) - c:RegisterEffect(e3) - --If this card would be destroyed by battle or card effect, you can banish 1 "Saber" card from your GY instead - local e4=Effect.CreateEffect(c) - e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) - e4:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e4:SetCode(EFFECT_DESTROY_REPLACE) - e4:SetRange(LOCATION_MZONE) - e4:SetTarget(s.desreptg) - c:RegisterEffect(e4) -end -s.listed_series={SET_X_SABER,SET_SABER} -s.listed_names={id} -function s.valcheck(e,c) - local g=c:GetMaterial() - if g:IsExists(Card.IsType,2,nil,TYPE_TUNER) then - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) - e1:SetCode(EFFECT_MULTIPLE_TUNERS) - e1:SetReset(RESET_EVENT|RESETS_STANDARD&~(RESET_TOFIELD)|RESET_PHASE|PHASE_END) - c:RegisterEffect(e1) - end -end -function s.drtg(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) - Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1) -end -function s.drop(e,tp,eg,ep,ev,re,r,rp) - local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM) - Duel.Draw(p,d,REASON_EFFECT) -end -function s.descostfilter(c,tp) - return c:IsSetCard(SET_X_SABER) and Duel.IsExistingMatchingCard(nil,tp,0,LOCATION_ONFIELD,1,c) -end -function s.descost(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.CheckReleaseGroupCost(tp,s.descostfilter,1,false,nil,nil,tp) end - local g=Duel.SelectReleaseGroupCost(tp,s.descostfilter,1,1,false,nil,nil,tp) - Duel.Release(g,REASON_COST) -end -function s.destg(e,tp,eg,ep,ev,re,r,rp,chk) - local g=Duel.GetFieldGroup(tp,0,LOCATION_ONFIELD) - if chk==0 then return #g>0 end - Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) -end -function s.desop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local g=Duel.SelectMatchingCard(tp,nil,tp,0,LOCATION_ONFIELD,1,1,nil) - if #g>0 then - Duel.HintSelection(g) - Duel.Destroy(g,REASON_EFFECT) - end -end -function s.desrepfilter(c) - return c:IsSetCard(SET_SABER) and c:IsAbleToRemove() and aux.SpElimFilter(c,true) -end -function s.desreptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return not c:IsReason(REASON_REPLACE) - and Duel.IsExistingMatchingCard(s.desrepfilter,tp,LOCATION_MZONE|LOCATION_GRAVE,0,1,c) end - if Duel.SelectEffectYesNo(tp,c) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESREPLACE) - local g=Duel.SelectMatchingCard(tp,s.desrepfilter,tp,LOCATION_MZONE|LOCATION_GRAVE,0,1,1,c) - return Duel.Remove(g,POS_FACEUP,REASON_EFFECT)>0 - end - return false -end \ No newline at end of file diff --git a/pre-release/c100447109.lua b/pre-release/c100447109.lua deleted file mode 100644 index c5c1980f37..0000000000 --- a/pre-release/c100447109.lua +++ /dev/null @@ -1,104 +0,0 @@ ---X-セイバー ガトムズ ---X-Saber Gottoms ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Synchro Summon procedure: 1 Tuner + 1+ EARTH monsters - Synchro.AddProcedure(c,nil,1,1,aux.FilterBoolFunctionEx(Card.IsAttribute,ATTRIBUTE_EARTH),1,99) - --Multiple Tuner check - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_SINGLE) - e0:SetCode(EFFECT_MATERIAL_CHECK) - e0:SetValue(s.valcheck) - c:RegisterEffect(e0) - --Add 1 "Saber" or "Gottoms" Spell/Trap from your Deck to your hand - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetCountLimit(1,id) - e1:SetCondition(function(e) return e:GetHandler():IsSynchroSummoned() end) - e1:SetTarget(s.thtg) - e1:SetOperation(s.thop) - c:RegisterEffect(e1) - --Discard 1 random card from your opponent's hand - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_HANDES) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetCode(EVENT_BATTLE_DAMAGE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return ep==1-tp end) - e2:SetTarget(s.discardtg) - e2:SetOperation(s.discardop) - c:RegisterEffect(e2) - --Special Summon this card, then change the attack target to it - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,2)) - e3:SetCategory(CATEGORY_SPECIAL_SUMMON) - e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e3:SetCode(EVENT_ATTACK_ANNOUNCE) - e3:SetRange(LOCATION_GRAVE) - e3:SetCountLimit(1,{id,2}) - e3:SetCondition(function(e,tp) local bc=Duel.GetAttackTarget() return bc and bc:IsSetCard(SET_X_SABER) and bc:IsControler(tp) and bc:IsFaceup() end) - e3:SetTarget(s.sptg) - e3:SetOperation(s.spop) - c:RegisterEffect(e3) -end -s.listed_series={SET_SABER,SET_GOTTOMS,SET_X_SABER} -function s.valcheck(e,c) - local g=c:GetMaterial() - if g:IsExists(Card.IsType,2,nil,TYPE_TUNER) then - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) - e1:SetCode(EFFECT_MULTIPLE_TUNERS) - e1:SetReset(RESET_EVENT|RESETS_STANDARD&~(RESET_TOFIELD)|RESET_PHASE|PHASE_END) - c:RegisterEffect(e1) - end -end -function s.thfilter(c) - return c:IsSetCard({SET_SABER,SET_GOTTOMS}) and c:IsSpellTrap() and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end -function s.discardtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetFieldGroupCount(tp,0,LOCATION_HAND)>0 end - Duel.SetOperationInfo(0,CATEGORY_HANDES,nil,0,1-tp,1) -end -function s.discardop(e,tp,eg,ep,ev,re,r,rp) - local g=Duel.GetFieldGroup(tp,0,LOCATION_HAND) - if #g>0 then - local sg=g:RandomSelect(1-tp,1) - Duel.SendtoGrave(sg,REASON_EFFECT|REASON_DISCARD) - end -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 then - local ac=Duel.GetAttacker() - if ac:CanAttack() and not ac:IsImmuneToEffect(e) then - Duel.BreakEffect() - Duel.ChangeAttackTarget(c) - end - end -end \ No newline at end of file diff --git a/pre-release/c100448001.lua b/pre-release/c100448001.lua deleted file mode 100644 index 8cd12d7eb3..0000000000 --- a/pre-release/c100448001.lua +++ /dev/null @@ -1,93 +0,0 @@ ---破滅と終焉の支配者 ---End of the World Ruler ---Scripted by The Razgriz -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --This card's name becomes "Demise, King of Armageddon" while in the hand or field - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e1:SetCode(EFFECT_CHANGE_CODE) - e1:SetRange(LOCATION_HAND|LOCATION_MZONE) - e1:SetValue(72426662) - c:RegisterEffect(e1) - --Apply the effect of a Ritual Spell that Ritual Summons - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_HAND) - e2:SetCountLimit(1,id) - e2:SetCost(Cost.AND(Cost.SelfReveal,Cost.PayLP(2000),s.applycost)) - e2:SetTarget(s.applytg) - e2:SetOperation(s.applyop) - c:RegisterEffect(e2) - --Destroy as many other cards on the field as possible, then this card gains 2900 ATK - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_DESTROY+CATEGORY_ATKCHANGE) - e3:SetType(EFFECT_TYPE_IGNITION) - e3:SetRange(LOCATION_MZONE) - e3:SetCountLimit(1,{id,1}) - e3:SetCost(Cost.PayLP(2000)) - e3:SetTarget(s.destg) - e3:SetOperation(s.desop) - c:RegisterEffect(e3) -end -s.listed_series={SET_END_OF_THE_WORLD} -s.listed_names={72426662} --"Demise, King of Armageddon" -function s.applyfilter(c) - return c:IsRitualSpell() and c:IsAbleToRemoveAsCost() and c:CheckActivateEffect(true,true,false)~=nil -end -function s.applycost(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.applyfilter,tp,LOCATION_DECK,0,1,nil) end -end -function s.applytg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then - local te=e:GetLabelObject() - return tg and tg(e,tp,eg,ep,ev,re,r,rp,0,chkc) - end - if chk==0 then return Duel.IsExistingMatchingCard(s.applyfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) - local g=Duel.SelectMatchingCard(tp,s.applyfilter,tp,LOCATION_DECK,0,1,1,nil) - Duel.Remove(g,POS_FACEUP,REASON_COST) - local te=g:GetFirst():CheckActivateEffect(true,true,false) - e:SetLabel(te:GetLabel()) - e:SetLabelObject(te:GetLabelObject()) - local tg=te:GetTarget() - e:SetProperty(te:GetProperty()) - if tg then - tg(e,tp,eg,ep,ev,re,r,rp,1) - end - te:SetLabel(e:GetLabel()) - te:SetLabelObject(e:GetLabelObject()) - e:SetLabelObject(te) - Duel.ClearOperationInfo(0) -end -function s.applyop(e,tp,eg,ep,ev,re,r,rp) - local te=e:GetLabelObject() - if te then - e:SetLabel(te:GetLabel()) - e:SetLabelObject(te:GetLabelObject()) - local op=te:GetOperation() - if op then op(e,tp,eg,ep,ev,re,r,rp) end - te:SetLabel(e:GetLabel()) - te:SetLabelObject(e:GetLabelObject()) - end -end -function s.destg(e,tp,eg,ep,ev,re,r,rp,chk) - local g=Duel.GetMatchingGroup(nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,e:GetHandler()) - if chk==0 then return #g>0 end - Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,#g,tp,0) -end -function s.desop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local exc=c:IsRelateToEffect(e) and c or nil - local g=Duel.GetMatchingGroup(nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,exc) - if #g>0 and Duel.Destroy(g,REASON_EFFECT)>0 and c:IsRelateToEffect(e) and c:IsFaceup() then - Duel.BreakEffect() - --This card gains 2900 ATK - c:UpdateAttack(2900) - end -end \ No newline at end of file diff --git a/pre-release/c100448002.lua b/pre-release/c100448002.lua deleted file mode 100644 index 66c84ec3e3..0000000000 --- a/pre-release/c100448002.lua +++ /dev/null @@ -1,79 +0,0 @@ ---ナイトメア・アイズ・サクリファイス ---Nightmare-Eyes Restrict ---Scripted by The Razgriz -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Fusion Materials: 2 monsters with different Types (Fiend, Illusion, or Spellcaster) - Fusion.AddProcMixN(c,true,true,s.matfilter,2) - --Equip 1 monster your opponent controls to this card as an Equip Spell - local e1a=Effect.CreateEffect(c) - e1a:SetDescription(aux.Stringid(id,0)) - e1a:SetCategory(CATEGORY_EQUIP) - e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1a:SetProperty(EFFECT_FLAG_DELAY) - e1a:SetCode(EVENT_SPSUMMON_SUCCESS) - e1a:SetCountLimit(1,id) - e1a:SetTarget(s.eqtg) - e1a:SetOperation(s.eqop) - c:RegisterEffect(e1a) - local e1b=e1a:Clone() - e1b:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e1b:SetCode(EVENT_PHASE+PHASE_BATTLE) - e1b:SetRange(LOCATION_MZONE) - e1b:SetCondition(function(e) return e:GetHandler():GetBattledGroupCount()>0 end) - c:RegisterEffect(e1b) - aux.AddEREquipLimit(c,nil,s.eqval,s.equipop,e1a) - aux.AddEREquipLimit(c,nil,s.eqval,s.equipop,e1b) - --Gains ATK equal to the combined ATK of those equipped monsters - local e2=Effect.CreateEffect(c) - e2:SetType(EFFECT_TYPE_SINGLE) - e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e2:SetCode(EFFECT_UPDATE_ATTACK) - e2:SetRange(LOCATION_MZONE) - e2:SetCondition(function(e) return e:GetHandler():GetEquipGroup():IsExists(aux.FaceupFilter(Card.HasFlagEffect,id),1,nil) end) - e2:SetValue(function(e,c) return c:GetEquipGroup():Match(function(c) return c:HasFlagEffect(id) and c:IsFaceup() and c:GetTextAttack()>0 end,nil):GetSum(Card.GetTextAttack) end) - c:RegisterEffect(e2) - --If this card battles a monster, neither can be destroyed by that battle - local e3=Effect.CreateEffect(c) - e3:SetType(EFFECT_TYPE_FIELD) - e3:SetCode(EFFECT_INDESTRUCTABLE_BATTLE) - e3:SetRange(LOCATION_MZONE) - e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) - e3:SetTarget(function(e,c) local handler=e:GetHandler() return c==handler or c==handler:GetBattleTarget() end) - e3:SetValue(1) - c:RegisterEffect(e3) - --Your opponent's monsters cannot attack monsters, except this one - local e4=Effect.CreateEffect(c) - e4:SetType(EFFECT_TYPE_FIELD) - e4:SetCode(EFFECT_CANNOT_SELECT_BATTLE_TARGET) - e4:SetRange(LOCATION_MZONE) - e4:SetTargetRange(0,LOCATION_MZONE) - e4:SetValue(function(e,c) return c~=e:GetHandler() end) - c:RegisterEffect(e4) -end -function s.matfilter(c,fc,sumtype,sp,sub,mg,sg) - return c:IsRace(RACE_FIEND|RACE_ILLUSION|RACE_SPELLCASTER,fc,sumtype,sp) and (not sg or sg:FilterCount(aux.TRUE,c)==0 or not sg:IsExists(Card.IsRace,1,c,c:GetRace(),fc,sumtype,sp)) -end -function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 - and Duel.IsExistingMatchingCard(Card.IsAbleToChangeControler,tp,0,LOCATION_MZONE,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_EQUIP,nil,1,1-tp,LOCATION_MZONE) -end -function s.eqop(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end - local c=e:GetHandler() - if not (c:IsRelateToEffect(e) and c:IsFaceup()) then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) - local sc=Duel.SelectMatchingCard(tp,Card.IsAbleToChangeControler,tp,0,LOCATION_MZONE,1,1,nil):GetFirst() - if sc then - Duel.HintSelection(sc) - s.equipop(c,e,tp,sc) - end -end -function s.eqval(ec,c,tp) - return ec:IsControler(1-tp) -end -function s.equipop(c,e,tp,tc) - c:EquipByEffectAndLimitRegister(e,tp,tc,id) -end \ No newline at end of file diff --git a/pre-release/c101303004.lua b/pre-release/c101303004.lua deleted file mode 100644 index 533119654a..0000000000 --- a/pre-release/c101303004.lua +++ /dev/null @@ -1,115 +0,0 @@ ---磁石の戦士マグネット・テルスリオン ---Tellusrion the Magna Warrior ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - c:AddMustBeSpecialSummoned() - --Must be Special Summoned (from your GY) by banishing 1 "Magnet Warrior Σ+" and 1 "Magnet Warrior Σ-" from your hand, face-up Monster Zone, and/or GY - local e0=Effect.CreateEffect(c) - e0:SetDescription(aux.Stringid(id,0)) - e0:SetType(EFFECT_TYPE_FIELD) - e0:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_CANNOT_DISABLE) - e0:SetCode(EFFECT_SPSUMMON_PROC) - e0:SetRange(LOCATION_GRAVE) - e0:SetCondition(s.selfspcon) - e0:SetTarget(s.selfsptg) - e0:SetOperation(s.selfspop) - c:RegisterEffect(e0) - --Destroy 1 monster your opponent controlst, or if you targeted an EARTH monster at activation, you can take control of it instead - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,1)) - e1:SetCategory(CATEGORY_DESTROY+CATEGORY_CONTROL) - e1:SetType(EFFECT_TYPE_QUICK_O) - e1:SetProperty(EFFECT_FLAG_CARD_TARGET) - e1:SetCode(EVENT_CHAINING) - e1:SetRange(LOCATION_MZONE) - e1:SetCountLimit(1) - e1:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return rp==1-tp end) - e1:SetTarget(s.destg) - e1:SetOperation(s.desop) - c:RegisterEffect(e1) - --Special Summon 2 of your banished "Magnet Warrior Σ" monsters - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_MZONE) - e2:SetCondition(function(e,tp) return Duel.IsTurnPlayer(1-tp) end) - e2:SetCost(Cost.SelfTribute) - e2:SetTarget(s.rmsptg) - e2:SetOperation(s.rmspop) - e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e2) -end -s.listed_names={101303005,101303006} --"Magnet Warrior Σ+", "Magnet Warrior Σ-" -s.listed_series={SET_MAGNET_WARRIOR_SIGMA} -function s.selfspcostfilter(c) - return c:IsCode(101303005,101303006) and (c:IsFaceup() or not c:IsOnField()) and c:IsAbleToRemoveAsCost() and aux.SpElimFilter(c,true,true) -end -function s.rescon(sg,e,tp,mg) - return Duel.GetMZoneCount(tp,sg)>0 and sg:IsExists(Card.IsCode,1,nil,101303005) and sg:IsExists(Card.IsCode,1,nil,101303006) -end -function s.selfspcon(e,c) - if c==nil then return true end - local tp=e:GetHandlerPlayer() - local g=Duel.GetMatchingGroup(s.selfspcostfilter,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_GRAVE,0,nil) - return #g>=2 and Duel.GetMZoneCount(tp,g)>0 and aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,0) -end -function s.selfsptg(e,tp,eg,ep,ev,re,r,rp,chk,c) - local g=Duel.GetMatchingGroup(s.selfspcostfilter,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_GRAVE,0,nil) - local sg=aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,1,tp,HINTMSG_REMOVE,nil,nil,true) - if #sg>0 then - e:SetLabelObject(sg) - return true - end - return false -end -function s.selfspop(e,tp,eg,ep,ev,re,r,rp,c) - local sg=e:GetLabelObject() - if sg then - Duel.Remove(sg,POS_FACEUP,REASON_COST) - end -end -function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_MZONE) end - if chk==0 then return Duel.IsExistingTarget(nil,tp,0,LOCATION_MZONE,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local tc=Duel.SelectTarget(tp,nil,tp,0,LOCATION_MZONE,1,1,nil):GetFirst() - if tc:IsAttribute(ATTRIBUTE_EARTH) and tc:IsFaceup() then - e:SetLabel(100) - Duel.SetPossibleOperationInfo(0,CATEGORY_DESTROY,tc,1,tp,0) - Duel.SetPossibleOperationInfo(0,CATEGORY_CONTROL,tc,1,tp,0) - else - e:SetLabel(0) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,tc,1,tp,0) - end -end -function s.desop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if not tc:IsRelateToEffect(e) then return end - local earth_chk=e:GetLabel()==100 - if earth_chk and tc:IsControlerCanBeChanged() and Duel.SelectYesNo(tp,aux.Stringid(id,3)) then - Duel.GetControl(tc,tp) - else - Duel.Destroy(tc,REASON_EFFECT) - end -end -function s.rmspfilter(c,e,tp) - return c:IsSetCard(SET_MAGNET_WARRIOR_SIGMA) and c:IsFaceup() and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.rmsptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetMZoneCount(tp,e:GetHandler())>=2 - and not Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) - and Duel.IsExistingMatchingCard(s.rmspfilter,tp,LOCATION_REMOVED,0,2,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,2,tp,LOCATION_REMOVED) -end -function s.rmspop(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetLocationCount(tp,LOCATION_MZONE)<2 or Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,s.rmspfilter,tp,LOCATION_REMOVED,0,2,2,nil,e,tp) - if #g==2 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c101303005.lua b/pre-release/c101303005.lua deleted file mode 100644 index 277d0fa805..0000000000 --- a/pre-release/c101303005.lua +++ /dev/null @@ -1,67 +0,0 @@ ---磁石の戦士Σ+ ---Magnet Warrior Σ+ ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --While you control an EARTH monster, your opponent's monsters that can attack must attack EARTH monsters - local e1a=Effect.CreateEffect(c) - e1a:SetType(EFFECT_TYPE_FIELD) - e1a:SetCode(EFFECT_MUST_ATTACK) - e1a:SetRange(LOCATION_MZONE) - e1a:SetTargetRange(0,LOCATION_MZONE) - e1a:SetCondition(function(e) return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_EARTH),e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil) end) - c:RegisterEffect(e1a) - local e1b=e1a:Clone() - e1b:SetCode(EFFECT_MUST_ATTACK_MONSTER) - e1b:SetValue(function(e,c) return c:IsAttribute(ATTRIBUTE_EARTH) end) - c:RegisterEffect(e1b) - --While your opponent controls an EARTH monster, you choose the attack targets for your opponent's attacks - local e2=Effect.CreateEffect(c) - e2:SetType(EFFECT_TYPE_FIELD) - e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET) - e2:SetCode(EFFECT_PATRICIAN_OF_DARKNESS) - e2:SetRange(LOCATION_MZONE) - e2:SetTargetRange(0,1) - e2:SetCondition(function(e) return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_EARTH),e:GetHandlerPlayer(),0,LOCATION_MZONE,1,nil) end) - c:RegisterEffect(e2) - --Add to your hand, or Special Summon, 1 Level 4 or lower "Magnet Warrior" monster in your GY, except "Magnet Warrior Σ+" - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,0)) - e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SPECIAL_SUMMON) - e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e3:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) - e3:SetCode(EVENT_TO_GRAVE) - e3:SetCountLimit(1,id) - e3:SetTarget(s.thsptg) - e3:SetOperation(s.thspop) - c:RegisterEffect(e3) -end -s.listed_series={SET_MAGNET_WARRIOR} -s.listed_names={id} -function s.thspfilter(c,e,tp,mmz_chk) - return c:IsLevelBelow(4) and c:IsSetCard(SET_MAGNET_WARRIOR) and not c:IsCode(id) - and (c:IsAbleToHand() or (mmz_chk and c:IsCanBeSpecialSummoned(e,0,tp,false,false))) -end -function s.thsptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - local mmz_chk=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and s.thspfilter(chkc,e,tp,mmz_chk) end - if chk==0 then return Duel.IsExistingTarget(s.thspfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp,mmz_chk) end - Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(id,1)) - local g=Duel.SelectTarget(tp,s.thspfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp,mmz_chk) - Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,g,1,tp,0) - Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,0) -end -function s.thspop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) then - aux.ToHandOrElse(tc,tp, - function() - return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and tc:IsCanBeSpecialSummoned(e,0,tp,false,false) - end, - function() - Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) - end, - aux.Stringid(id,2) - ) - end -end \ No newline at end of file diff --git a/pre-release/c101303006.lua b/pre-release/c101303006.lua deleted file mode 100644 index 984786a681..0000000000 --- a/pre-release/c101303006.lua +++ /dev/null @@ -1,66 +0,0 @@ ---磁石の戦士Σ- ---Magnet Warrior Σ- ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Negate an attack involving 2 EARTH monsters - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e1:SetCode(EVENT_ATTACK_ANNOUNCE) - e1:SetRange(LOCATION_MZONE) - e1:SetCountLimit(1) - e1:SetCondition(s.atknegcon) - e1:SetOperation(function() Duel.NegateAttack() end) - c:RegisterEffect(e1) - --Fusion Summon 1 Fusion Monster from your Extra Deck, using Rock monsters from your hand or field, including this card in your hand - local fusion_params={ - handler=c, - matfilter=function(c) return c:IsRace(RACE_ROCK) end, - gc=Fusion.ForcedHandler - } - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_HAND) - e2:SetCountLimit(1,id) - e2:SetCost(Cost.SelfReveal) - e2:SetTarget(Fusion.SummonEffTG(fusion_params)) - e2:SetOperation(Fusion.SummonEffOP(fusion_params)) - c:RegisterEffect(e2) - --Send 1 Level 8 "Magna Warrior" monster from your Deck to your GY - local e3a=Effect.CreateEffect(c) - e3a:SetDescription(aux.Stringid(id,2)) - e3a:SetCategory(CATEGORY_TOGRAVE) - e3a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e3a:SetProperty(EFFECT_FLAG_DELAY) - e3a:SetCode(EVENT_SUMMON_SUCCESS) - e3a:SetCountLimit(1,{id,1}) - e3a:SetTarget(s.tgtg) - e3a:SetOperation(s.tgop) - c:RegisterEffect(e3a) - local e3b=e3a:Clone() - e3b:SetCode(EVENT_SPSUMMON_SUCCESS) - c:RegisterEffect(e3b) -end -s.listed_series={SET_MAGNA_WARRIOR} -function s.atknegcon(e,tp,eg,ep,ev,re,r,rp) - local bc1=Duel.GetAttacker() - local bc2=Duel.GetAttackTarget() - return bc1:IsAttribute(ATTRIBUTE_EARTH) and bc2 and bc2:IsAttribute(ATTRIBUTE_EARTH) and bc2:IsFaceup() -end -function s.tgfilter(c) - return c:IsLevel(8) and c:IsSetCard(SET_MAGNA_WARRIOR) and c:IsAbleToGrave() -end -function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.tgfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) -end -function s.tgop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local g=Duel.SelectMatchingCard(tp,s.tgfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoGrave(g,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303007.lua b/pre-release/c101303007.lua deleted file mode 100644 index 80114880d1..0000000000 --- a/pre-release/c101303007.lua +++ /dev/null @@ -1,70 +0,0 @@ ---ジャンク・ウォリアー/バスター ---Junk Warrior/Assault Mode ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - c:AddMustBeSpecialSummoned() - --Gains 1000 ATK for each "/Assault Mode" monster you control - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e1:SetCode(EFFECT_UPDATE_ATTACK) - e1:SetRange(LOCATION_MZONE) - e1:SetValue(function(e,c) return 1000*Duel.GetMatchingGroupCount(aux.FaceupFilter(Card.IsSetCard,SET_ASSAULT_MODE),c:GetControler(),LOCATION_MZONE,0,nil) end) - c:RegisterEffect(e1) - --If this card battles a monster, any battle damage it inflicts to your opponent is doubled - local e2=Effect.CreateEffect(c) - e2:SetType(EFFECT_TYPE_SINGLE) - e2:SetCode(EFFECT_CHANGE_BATTLE_DAMAGE) - e2:SetCondition(function(e) return e:GetHandler():GetBattleTarget() end) - e2:SetValue(aux.ChangeBattleDamage(1,DOUBLE_DAMAGE)) - c:RegisterEffect(e2) - --Unaffected by your opponent's activated monster effects - local e3=Effect.CreateEffect(c) - e3:SetType(EFFECT_TYPE_SINGLE) - e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e3:SetCode(EFFECT_IMMUNE_EFFECT) - e3:SetRange(LOCATION_MZONE) - e3:SetValue(function(e,te) return te:GetOwnerPlayer()~=e:GetHandlerPlayer() and te:IsActivated() and te:IsMonsterEffect() end) - c:RegisterEffect(e3) - --Return 1 "Junk Warrior" from your GY to the Extra Deck, then you can Special Summon it (this is treated as a Synchro Summon) - local e4=Effect.CreateEffect(c) - e4:SetDescription(aux.Stringid(id,0)) - e4:SetCategory(CATEGORY_TOEXTRA+CATEGORY_SPECIAL_SUMMON) - e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e4:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) - e4:SetCode(EVENT_DESTROYED) - e4:SetTarget(s.texsptg) - e4:SetOperation(s.texspop) - c:RegisterEffect(e4) -end -s.listed_names={CARD_ASSAULT_MODE,CARD_JUNK_WARRIOR} -s.listed_series={SET_ASSAULT_MODE} -s.assault_mode=CARD_JUNK_WARRIOR -function s.texfilter(c) - return c:IsCode(CARD_JUNK_WARRIOR) and c:IsAbleToExtra() -end -function s.texsptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.texfilter(chkc) end - if chk==0 then return Duel.IsExistingTarget(s.texfilter,tp,LOCATION_GRAVE,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) - local g=Duel.SelectTarget(tp,s.texfilter,tp,LOCATION_GRAVE,0,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,g,1,tp,0) - Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) -end -function s.texspop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,0,REASON_EFFECT)>0 and tc:IsLocation(LOCATION_EXTRA) then - local forcedg=aux.GetMustBeMaterialGroup(tp,Group.CreateGroup(),tp,tc,nil,REASON_SYNCHRO) - if #forcedg==0 and Duel.GetLocationCountFromEx(tp,tp,nil,tc)>0 - and tc:IsCanBeSpecialSummoned(e,SUMMON_TYPE_SYNCHRO,tp,false,false) - and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then - tc:SetMaterial(nil) - Duel.BreakEffect() - if Duel.SpecialSummon(tc,SUMMON_TYPE_SYNCHRO,tp,tp,false,false,POS_FACEUP)>0 then - tc:CompleteProcedure() - end - end - end -end \ No newline at end of file diff --git a/pre-release/c101303008.lua b/pre-release/c101303008.lua deleted file mode 100644 index 8a8df47e98..0000000000 --- a/pre-release/c101303008.lua +++ /dev/null @@ -1,81 +0,0 @@ ---クリムゾン・ブレーダー/バスタ ---Crimson Blader/Assault Mode ---scripted by Naim -local s,id=GetID() -local CARD_CRIMSON_BLADER=80321197 -function s.initial_effect(c) - c:EnableReviveLimit() - c:AddMustBeSpecialSummoned() - --Add 1 "Assault Mode Activate" or 1 card that mentions it from your Deck to your hand, and if you do, shuffle this card into the Deck - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_TODECK) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetRange(LOCATION_HAND) - e1:SetCountLimit(1,id) - e1:SetCost(Cost.SelfReveal) - e1:SetTarget(s.thtg) - e1:SetOperation(s.thop) - c:RegisterEffect(e1) - --Your opponent cannot activate the effects of Level 5 or higher monsters Special Summoned from the Extra Deck - local e2=Effect.CreateEffect(c) - e2:SetType(EFFECT_TYPE_FIELD) - e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET) - e2:SetCode(EFFECT_CANNOT_ACTIVATE) - e2:SetRange(LOCATION_MZONE) - e2:SetTargetRange(0,1) - e2:SetValue(s.cannotactval) - c:RegisterEffect(e2) - --Special Summon 1 "Crimson Blader" from your GY - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_SPECIAL_SUMMON) - e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e3:SetProperty(EFFECT_FLAG_DELAY) - e3:SetCode(EVENT_DESTROYED) - e3:SetTarget(s.sptg) - e3:SetOperation(s.spop) - c:RegisterEffect(e3) -end -s.listed_names={CARD_ASSAULT_MODE,CARD_CRIMSON_BLADER} -s.assault_mode=CARD_CRIMSON_BLADER -function s.thfilter(c) - return (c:IsCode(CARD_ASSAULT_MODE) or c:ListsCode(CARD_ASSAULT_MODE)) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return c:IsAbleToDeck() and Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) - Duel.SetOperationInfo(0,CATEGORY_TODECK,c,1,tp,0) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 and Duel.SendtoHand(g,nil,REASON_EFFECT)>0 then - Duel.ConfirmCards(1-tp,g) - if c:IsRelateToEffect(e) then - Duel.SendtoDeck(c,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) - end - end -end -function s.cannotactval(e,re,tp) - local rc=re:GetHandler() - return re:IsMonsterEffect() and rc:IsOnField() and rc:IsLevelAbove(5) and rc:IsSummonLocation(LOCATION_EXTRA) -end -function s.spfilter(c,e,tp) - return c:IsCode(CARD_CRIMSON_BLADER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) -end -function s.spop(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,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c101303009.lua b/pre-release/c101303009.lua deleted file mode 100644 index d45bdb357b..0000000000 --- a/pre-release/c101303009.lua +++ /dev/null @@ -1,72 +0,0 @@ ---バスター・リッチー ---Assault Lich ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --If this card you control would be used as Synchro Material, you can treat it as a non-Tuner - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e1:SetCode(EFFECT_NONTUNER) - e1:SetRange(LOCATION_MZONE) - c:RegisterEffect(e1) - --Special Summon 1 monster that mentions "Assault Mode Activate" or 1 Level 4 or lower Zombie monster from your GY - local e2a=Effect.CreateEffect(c) - e2a:SetDescription(aux.Stringid(id,0)) - e2a:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2a:SetProperty(EFFECT_FLAG_DELAY) - e2a:SetCode(EVENT_SUMMON_SUCCESS) - e2a:SetCountLimit(1,id) - e2a:SetTarget(s.sptg) - e2a:SetOperation(s.spop) - c:RegisterEffect(e2a) - local e2b=e2a:Clone() - e2b:SetCode(EVENT_SPSUMMON_SUCCESS) - c:RegisterEffect(e2b) - --Add 1 "Assault Slash" or "Assault Counter" from your Deck to your hand - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e3:SetProperty(EFFECT_FLAG_DELAY) - e3:SetCode(EVENT_BE_MATERIAL) - e3:SetCountLimit(1,{id,1}) - e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return e:GetHandler():IsLocation(LOCATION_GRAVE) and r==REASON_SYNCHRO end) - e3:SetTarget(s.thtg) - e3:SetOperation(s.thop) - c:RegisterEffect(e3) -end -s.listed_names={CARD_ASSAULT_MODE,40012727,76407432} --"Assault Slash", "Assault Counter" -function s.spfilter(c,e,tp) - return (c:ListsCode(CARD_ASSAULT_MODE) or (c:IsLevelBelow(4) and c:IsRace(RACE_ZOMBIE))) - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) -end -function s.spop(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,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end -function s.thfilter(c,e,tp) - return c:IsCode(40012727,76407432) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end \ No newline at end of file diff --git a/pre-release/c101303010.lua b/pre-release/c101303010.lua deleted file mode 100644 index 549487c656..0000000000 --- a/pre-release/c101303010.lua +++ /dev/null @@ -1,78 +0,0 @@ ---耀聖の花詩ルキナ ---Elvennotes Lucina ---Scripted by Hatter -local s,id=GetID() -function s.initial_effect(c) - --You can Special Summon this card (from your hand) to your center Main Monster Zone - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) - e1:SetCode(EFFECT_SPSUMMON_PROC) - e1:SetRange(LOCATION_HAND) - e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) - e1:SetValue(function() return 0,ZONE_CENTER_MMZ end) - c:RegisterEffect(e1) - --Add 1 "Elvennotes" monster from your Deck to your hand, except "Elvennotes Lucina" - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.thtg) - e2:SetOperation(s.thop) - c:RegisterEffect(e2) - --Switch the locations of this card in your Main Monster Zone and the monster in your center Main Monster Zone - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,2)) - e3:SetCategory(CATEGORY_TOHAND) - e3:SetType(EFFECT_TYPE_QUICK_O) - e3:SetCode(EVENT_FREE_CHAIN) - e3:SetRange(LOCATION_MMZONE) - e3:SetCountLimit(1,{id,2}) - e3:SetCondition(function(e,tp) return Duel.IsTurnPlayer(1-tp) end) - e3:SetTarget(s.swtg) - e3:SetOperation(s.swop) - e3:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e3) -end -s.listed_names={id} -s.listed_series={SET_ELVENNOTES} -function s.thfilter(c) - return c:IsSetCard(SET_ELVENNOTES) and c:IsMonster() and not c:IsCode(id) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end -function s.swtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return not e:GetHandler():IsSequence(2) and Duel.GetFieldCard(tp,LOCATION_MZONE,2) end - Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,1-tp,LOCATION_MZONE) -end -function s.rthfilter(c) - return c:IsLevelBelow(6) and c:IsFaceup() and c:IsAbleToHand() -end -function s.swop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local cc=Duel.GetFieldCard(tp,LOCATION_MZONE,2) - if c:IsRelateToEffect(e) and c:IsInMainMZone(tp) and cc and c~=cc and Duel.SwapSequence(c,cc) then - local g=Duel.GetMatchingGroup(s.rthfilter,tp,0,LOCATION_MZONE,nil) - if #g==0 or not Duel.SelectYesNo(tp,aux.Stringid(id,3)) then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) - local sg=g:Select(tp,1,1,nil) - if #sg>0 then - Duel.HintSelection(sg) - Duel.BreakEffect() - Duel.SendtoHand(sg,nil,REASON_EFFECT) - end - end -end \ No newline at end of file diff --git a/pre-release/c101303011.lua b/pre-release/c101303011.lua deleted file mode 100644 index 3cacf49a32..0000000000 --- a/pre-release/c101303011.lua +++ /dev/null @@ -1,72 +0,0 @@ ---耀聖の波詩ディーナ ---Elvennotes Dyina ---Scripted by Hatter -local s,id=GetID() -function s.initial_effect(c) - --You can Special Summon this card (from your hand) to your center Main Monster Zone - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) - e1:SetCode(EFFECT_SPSUMMON_PROC) - e1:SetRange(LOCATION_HAND) - e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) - e1:SetValue(function() return 0,ZONE_CENTER_MMZ end) - c:RegisterEffect(e1) - --Place 1 "Elvennotes" Continuous Spell from your Deck face-up on your field - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.pltg) - e2:SetOperation(s.plop) - c:RegisterEffect(e2) - --Switch the locations of this card in your Main Monster Zone and the monster in your center Main Monster Zone - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,2)) - e3:SetCategory(CATEGORY_REMOVE) - e3:SetType(EFFECT_TYPE_QUICK_O) - e3:SetCode(EVENT_FREE_CHAIN) - e3:SetRange(LOCATION_MMZONE) - e3:SetCountLimit(1,{id,2}) - e3:SetCondition(function(e,tp) return Duel.IsTurnPlayer(1-tp) end) - e3:SetTarget(s.swtg) - e3:SetOperation(s.swop) - e3:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e3) -end -s.listed_series={SET_ELVENNOTES} -function s.plfilter(c,tp) - return c:IsSetCard(SET_ELVENNOTES) and c:IsContinuousSpell() and not c:IsForbidden() and c:CheckUniqueOnField(tp) -end -function s.pltg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 - and Duel.IsExistingMatchingCard(s.plfilter,tp,LOCATION_DECK,0,1,nil,tp) end -end -function s.plop(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) - local sc=Duel.SelectMatchingCard(tp,s.plfilter,tp,LOCATION_DECK,0,1,1,nil,tp):GetFirst() - if sc then - Duel.MoveToField(sc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) - end -end -function s.swtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return not e:GetHandler():IsSequence(2) and Duel.GetFieldCard(tp,LOCATION_MZONE,2) end - Duel.SetPossibleOperationInfo(0,CATEGORY_REMOVE,nil,1,1-tp,LOCATION_HAND) -end -function s.swop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local cc=Duel.GetFieldCard(tp,LOCATION_MZONE,2) - if c:IsRelateToEffect(e) and c:IsInMainMZone(tp) and cc and c~=cc and Duel.SwapSequence(c,cc) then - local g=Duel.GetMatchingGroup(Card.IsAbleToRemove,tp,0,LOCATION_HAND,nil) - if #g==0 or not Duel.SelectYesNo(tp,aux.Stringid(id,3)) then return end - local rg=g:RandomSelect(tp,1) - if #rg>0 then - Duel.BreakEffect() - --Banish 1 random card from your opponent's hand face-up until the End Phase - aux.RemoveUntil(rg,POS_FACEUP,REASON_EFFECT|REASON_TEMPORARY,PHASE_END,id,e,tp,function(ag,e,tp) Duel.SendtoHand(ag,nil,REASON_EFFECT) end) - end - end -end \ No newline at end of file diff --git a/pre-release/c101303012.lua b/pre-release/c101303012.lua deleted file mode 100644 index 8288f963b4..0000000000 --- a/pre-release/c101303012.lua +++ /dev/null @@ -1,76 +0,0 @@ ---耀聖の月詩フォルトナ ---Elvennotes Fortona ---Scripted by Hatter -local s,id=GetID() -function s.initial_effect(c) - --You can Special Summon this card (from your hand) to your center Main Monster Zone - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) - e1:SetCode(EFFECT_SPSUMMON_PROC) - e1:SetRange(LOCATION_HAND) - e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) - e1:SetValue(function() return 0,ZONE_CENTER_MMZ end) - c:RegisterEffect(e1) - --Place 1 "Elvennotes" Continuous Trap from your hand or Deck face-up on your field - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.pltg) - e2:SetOperation(s.plop) - c:RegisterEffect(e2) - --Switch the locations of this card in your Main Monster Zone and the monster in your center Main Monster Zone - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,2)) - e3:SetCategory(CATEGORY_TOHAND) - e3:SetType(EFFECT_TYPE_QUICK_O) - e3:SetCode(EVENT_FREE_CHAIN) - e3:SetRange(LOCATION_MMZONE) - e3:SetCountLimit(1,{id,2}) - e3:SetCondition(function(e,tp) return Duel.IsTurnPlayer(1-tp) end) - e3:SetTarget(s.swtg) - e3:SetOperation(s.swop) - e3:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e3) -end -s.listed_series={SET_ELVENNOTES} -function s.plfilter(c,tp) - return c:IsSetCard(SET_ELVENNOTES) and c:IsContinuousTrap() and not c:IsForbidden() and c:CheckUniqueOnField(tp) -end -function s.pltg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 - and Duel.IsExistingMatchingCard(s.plfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,tp) end -end -function s.plop(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) - local sc=Duel.SelectMatchingCard(tp,s.plfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,1,nil,tp):GetFirst() - if sc then - Duel.MoveToField(sc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) - end -end -function s.swtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return not e:GetHandler():IsSequence(2) and Duel.GetFieldCard(tp,LOCATION_MZONE,2) end - Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,PLAYER_EITHER,LOCATION_ONFIELD) -end -function s.rthfilter(c) - return c:IsSpellTrap() and c:IsFaceup() and c:IsAbleToHand() -end -function s.swop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local cc=Duel.GetFieldCard(tp,LOCATION_MZONE,2) - if c:IsRelateToEffect(e) and c:IsInMainMZone(tp) and cc and c~=cc and Duel.SwapSequence(c,cc) then - local g=Duel.GetMatchingGroup(s.rthfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) - if #g==0 or not Duel.SelectYesNo(tp,aux.Stringid(id,3)) then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) - local sg=g:Select(tp,1,1,nil) - if #sg>0 then - Duel.HintSelection(sg) - Duel.BreakEffect() - Duel.SendtoHand(sg,nil,REASON_EFFECT) - end - end -end \ No newline at end of file diff --git a/pre-release/c101303013.lua b/pre-release/c101303013.lua deleted file mode 100644 index 386e4dc2a1..0000000000 --- a/pre-release/c101303013.lua +++ /dev/null @@ -1,95 +0,0 @@ ---燿ける聖詩の獄神精 ---Elvennotes Power Patron ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --You cannot Special Summon from the Extra Deck, except Synchro Monsters - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetRange(LOCATION_MZONE) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsSynchroMonster() end) - c:RegisterEffect(e1) - aux.addContinuousLizardCheck(c,LOCATION_MZONE,function(e,c) return not c:IsOriginalType(TYPE_SYNCHRO) end) - --Increase the Level of the monster in your center Main Monster Zone by 3 (until the end of this turn), then immediately after this effect resolves, you can Synchro Summon 1 "Elvennotes" monster or "Junora the Power Patron of Tuning" - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_LVCHANGE+CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,id) - e2:SetCondition(function() return Duel.IsMainPhase() end) - e2:SetTarget(s.lvtg) - e2:SetOperation(s.lvop) - e2:SetHintTiming(0,TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) - c:RegisterEffect(e2) - --Add 1 "Elvennotes" card from your Deck to your hand - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e3:SetProperty(EFFECT_FLAG_DELAY) - e3:SetCode(EVENT_BE_MATERIAL) - e3:SetCountLimit(1,{id,1}) - e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return e:GetHandler():IsLocation(LOCATION_GRAVE) and r==REASON_SYNCHRO end) - e3:SetTarget(s.thtg) - e3:SetOperation(s.thop) - c:RegisterEffect(e3) -end -s.listed_series={SET_ELVENNOTES} -s.listed_names={101303039} --"Junora the Power Patron of Tuning" -function s.lvfilter(c) - return c:IsSequence(2) and c:HasLevel() and c:IsFaceup() -end -function s.lvtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MMZONE) and s.lvfilter(chkc) end - if chk==0 then return Duel.IsExistingTarget(s.lvfilter,tp,LOCATION_MMZONE,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) - local g=Duel.SelectTarget(tp,s.lvfilter,tp,LOCATION_MMZONE,0,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_LVCHANGE,g,1,tp,3) - Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) -end -function s.synchrofilter(c) - return (c:IsSetCard(SET_ELVENNOTES) or c:IsCode(101303039)) and c:IsSynchroSummonable() -end -function s.lvop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and tc:IsFaceup() then - local prev_lv=tc:GetLevel() - --Increase its Level by 3 - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_UPDATE_LEVEL) - e1:SetValue(3) - e1:SetReset(RESETS_STANDARD_PHASE_END) - tc:RegisterEffect(e1) - Duel.AdjustInstantly(tc) - if not tc:IsLevel(prev_lv+3) then return end - local g=Duel.GetMatchingGroup(s.synchrofilter,tp,LOCATION_EXTRA,0,1,nil) - if #g>0 and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local sc=g:Select(tp,1,1,nil):GetFirst() - Duel.SynchroSummon(tp,sc) - end - end -end -function s.thfilter(c) - return c:IsSetCard(SET_ELVENNOTES) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end \ No newline at end of file diff --git a/pre-release/c101303014.lua b/pre-release/c101303014.lua deleted file mode 100644 index 77d40924a6..0000000000 --- a/pre-release/c101303014.lua +++ /dev/null @@ -1,85 +0,0 @@ ---ロワイヤル・デーモン ---Royal Archfiend ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Add 1 "Archfiend" card from your Deck to your hand - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetRange(LOCATION_HAND|LOCATION_MZONE) - e1:SetCountLimit(1,id) - e1:SetCost(Cost.SelfTribute) - e1:SetTarget(s.thtg) - e1:SetOperation(s.thop) - c:RegisterEffect(e1) - --Special Summon this card - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e2:SetCode(EVENT_BATTLE_DESTROYED) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(s.spcon) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - c:RegisterEffect(e2) -end -s.listed_names={id} -s.listed_series={SET_ARCHFIEND} -function s.thfilter(c) - return c:IsSetCard(SET_ARCHFIEND) and c:IsAbleToHand() and not c:IsCode(id) -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end - local c=e:GetHandler() - --For the rest of this turn, you cannot Special Summon from the Extra Deck, except "Archfiend" monsters - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsSetCard(SET_ARCHFIEND) end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) - aux.RegisterClientHint(c,nil,tp,1,0,aux.Stringid(id,3)) - --You can Normal Summon 1 Fiend monster during your Main Phase in addition to your Normal Summon/Set - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,4)) - e2:SetType(EFFECT_TYPE_FIELD) - e2:SetCode(EFFECT_EXTRA_SUMMON_COUNT) - e2:SetTargetRange(LOCATION_HAND|LOCATION_MZONE,0) - e2:SetTarget(aux.TargetBoolFunction(Card.IsRace,RACE_FIEND)) - e2:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e2,tp) -end -function s.spconfilter(c,tp) - return c:IsPreviousControler(tp) and c:IsRitualMonster() -end -function s.spcon(e,tp,eg,ep,ev,re,r,rp) - return eg:IsExists(s.spconfilter,1,nil,tp) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) then - Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c101303015.lua b/pre-release/c101303015.lua deleted file mode 100644 index 8eb1304acf..0000000000 --- a/pre-release/c101303015.lua +++ /dev/null @@ -1,86 +0,0 @@ ---デューク・デーモン ---Duke Archfiend ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Gains ATK equal to its Level x 200 - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e1:SetCode(EFFECT_UPDATE_ATTACK) - e1:SetRange(LOCATION_MZONE) - e1:SetValue(function(e,c) return c:GetLevel()*200 end) - c:RegisterEffect(e1) - --Send 1 "Archfiend" monster from your Deck to the GY, and if you do, increase the targeted monster's Level by the sent monster's - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_TOGRAVE+CATEGORY_LVCHANGE) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,id) - e2:SetTarget(s.tgtg) - e2:SetOperation(s.tgop) - c:RegisterEffect(e2) - --Special Summon this card - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_SPECIAL_SUMMON) - e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e3:SetCode(EVENT_BATTLE_DESTROYED) - e3:SetRange(LOCATION_GRAVE) - e3:SetCountLimit(1,{id,1}) - e3:SetCondition(s.spcon) - e3:SetTarget(s.sptg) - e3:SetOperation(s.spop) - c:RegisterEffect(e3) -end -s.listed_names={id} -s.listed_series={SET_ARCHFIEND} -function s.tgfilter(c) - return c:IsSetCard(SET_ARCHFIEND) and c:IsMonster() and c:IsAbleToGrave() and not c:IsCode(id) -end -function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and chkc:IsFaceup() and chkc:HasLevel() end - if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(Card.HasLevel),tp,LOCATION_MZONE,0,1,nil) - and Duel.IsExistingMatchingCard(s.tgfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) - local g=Duel.SelectTarget(tp,aux.FaceupFilter(Card.HasLevel),tp,LOCATION_MZONE,0,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) - Duel.SetOperationInfo(0,CATEGORY_LVCHANGE,g,1,tp,1) -end -function s.tgop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local sc=Duel.SelectMatchingCard(tp,s.tgfilter,tp,LOCATION_DECK,0,1,1,nil):GetFirst() - if sc and Duel.SendtoGrave(sc,REASON_EFFECT)>0 and sc:IsLocation(LOCATION_GRAVE) then - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and tc:IsFaceup() then - --Increase the targeted monster's Level by the sent monster's - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_UPDATE_LEVEL) - e1:SetValue(sc:GetLevel()) - e1:SetReset(RESET_EVENT|RESETS_STANDARD) - tc:RegisterEffect(e1) - end - end -end -function s.spconfilter(c,tp) - return c:IsPreviousControler(tp) and c:IsRitualMonster() -end -function s.spcon(e,tp,eg,ep,ev,re,r,rp) - return eg:IsExists(s.spconfilter,1,nil,tp) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) then - Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c101303016.lua b/pre-release/c101303016.lua deleted file mode 100644 index 3353e32e02..0000000000 --- a/pre-release/c101303016.lua +++ /dev/null @@ -1,84 +0,0 @@ ---ハイネス・デーモン ---Highness Archfiend ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Add 2 "Archfiend" cards from your Deck to your hand, except "Highess Archfiend", also you cannot Special Summon from the Extra Deck for the rest of this turn, except "Archfiend" monsters - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCode(EVENT_SUMMON_SUCCESS) - e1:SetCountLimit(1,id) - e1:SetCost(s.thcost) - e1:SetTarget(s.thtg) - e1:SetOperation(s.thop) - c:RegisterEffect(e1) - --Special Summon this card - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e2:SetCode(EVENT_BATTLE_DESTROYED) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(s.spcon) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - c:RegisterEffect(e2) -end -s.listed_names={id} -s.listed_series={SET_ARCHFIEND} -function s.thcostfilter(c,tp) - return c:IsSetCard(SET_ARCHFIEND) and c:IsAbleToRemoveAsCost() -end -function s.thcost(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thcostfilter,tp,LOCATION_GRAVE,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) - local g=Duel.SelectMatchingCard(tp,s.thcostfilter,tp,LOCATION_GRAVE,0,1,1,nil) - Duel.Remove(g,POS_FACEUP,REASON_COST) -end -function s.thfilter(c) - return c:IsSetCard(SET_ARCHFIEND) and not c:IsCode(id) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,2,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,2,2,nil) - if #g==2 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end - --For the rest of this turn, you cannot Special Summon from the Extra Deck, except "Archfiend" monsters - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsSetCard(SET_ARCHFIEND) end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) -end -function s.spconfilter(c,tp) - return c:IsPreviousControler(tp) and c:IsRitualMonster() -end -function s.spcon(e,tp,eg,ep,ev,re,r,rp) - return eg:IsExists(s.spconfilter,1,nil,tp) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) then - Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c101303017.lua b/pre-release/c101303017.lua deleted file mode 100644 index 974cfe741f..0000000000 --- a/pre-release/c101303017.lua +++ /dev/null @@ -1,70 +0,0 @@ ---空牙団の疾風 レクス ---Rex, Gale Fur Hire ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Special Summon 1 "Fur Hire" from your hand, then Special Summon this card - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetRange(LOCATION_HAND) - e1:SetCountLimit(1,id) - e1:SetCost(Cost.SelfReveal) - e1:SetTarget(s.sptg) - e1:SetOperation(s.spop) - c:RegisterEffect(e1) - --Draw 1 card - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_DRAW) - e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY) - e2:SetCode(EVENT_TO_HAND) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,0,EFFECT_COUNT_CODE_CHAIN) - e2:SetCondition(s.drwcon) - e2:SetTarget(s.drwtg) - e2:SetOperation(s.drwop) - c:RegisterEffect(e2) -end -s.listed_names={id} -s.listed_series={SET_FUR_HIRE} -function s.spfilter(c,e,tp) - return c:IsSetCard(SET_FUR_HIRE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and not c:IsCode(id) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>=2 - and Duel.IsPlayerCanSpecialSummonCount(tp,2) - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND,0,1,nil,e,tp) - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,2,tp,LOCATION_HAND) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end - local c=e:GetHandler() - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND,0,1,1,nil,e,tp) - if #g>0 and Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)>0 and c:IsRelateToEffect(e) then - Duel.BreakEffect() - Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) - end -end -function s.drwconfilter(c,opp) - return c:IsPreviousLocation(LOCATION_DECK) and c:IsControler(opp) and c:IsReason(REASON_EFFECT) -end -function s.drwcon(e,tp,eg,ep,ev,re,r,rp) - return re and not re:GetHandler():IsSetCard(SET_FUR_HIRE) and eg:IsExists(s.drwconfilter,1,nil,1-tp) -end -function s.drwtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsSetCard,SET_FUR_HIRE),tp,LOCATION_MZONE,0,1,e:GetHandler()) - and Duel.IsPlayerCanDraw(tp,1) end - Duel.SetTargetPlayer(tp) - Duel.SetTargetParam(1) - Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1) -end -function s.drwop(e,tp,eg,ep,ev,re,r,rp) - local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM) - Duel.Draw(p,d,REASON_EFFECT) -end \ No newline at end of file diff --git a/pre-release/c101303018.lua b/pre-release/c101303018.lua deleted file mode 100644 index be406f58ef..0000000000 --- a/pre-release/c101303018.lua +++ /dev/null @@ -1,77 +0,0 @@ ---堕天使グルガルタ ---Darklord Gulgalta ---scripted by Naim -local s,id=GetID() -local TOKEN_DARKLORD=id+100 -function s.initial_effect(c) - --You can only Special Summon "Darklord Gulgalta(s)" once per turn - c:SetSPSummonOnce(id) - --Special Summon 2 "Darklord Tokens" - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetTarget(s.sptg) - e1:SetOperation(s.spop) - c:RegisterEffect(e1) - --Add 1 "Darklord" card or "Forbidden" Quick-Play Spell from your Deck to your hand - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY) - e2:SetCode(EVENT_TO_GRAVE) - e2:SetCountLimit(1,id) - e2:SetTarget(s.thtg) - e2:SetOperation(s.thop) - c:RegisterEffect(e2) -end -s.listed_names={id,TOKEN_DARKLORD} -- "Darklord Token" -s.listed_series={SET_DARKLORD,SET_FORBIDDEN} -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return not Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) - and Duel.GetLocationCount(tp,LOCATION_MZONE)>=2 - and Duel.IsPlayerCanSpecialSummonMonster(tp,TOKEN_DARKLORD,SET_DARKLORD,TYPES_TOKEN,0,0,6,RACE_FAIRY,ATTRIBUTE_DARK) end - Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,2,tp,0) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,2,tp,0) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - --You cannot Special Summon for the rest of this turn, except Fairy monsters - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return not c:IsRace(RACE_FAIRY) end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) - --Clock Lizard check - aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalRace(RACE_FAIRY) end) - --Special Summon 2 "Darklord Tokens" - if Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) or Duel.GetLocationCount(tp,LOCATION_MZONE)<2 - or not Duel.IsPlayerCanSpecialSummonMonster(tp,TOKEN_DARKLORD,SET_DARKLORD,TYPES_TOKEN,0,0,6,RACE_FAIRY,ATTRIBUTE_DARK) then return end - for i=1,2 do - local token=Duel.CreateToken(tp,TOKEN_DARKLORD) - Duel.SpecialSummonStep(token,0,tp,tp,false,false,POS_FACEUP) - end - Duel.SpecialSummonComplete() -end -function s.thfilter(c) - return (c:IsSetCard(SET_DARKLORD) or (c:IsSetCard(SET_FORBIDDEN) and c:IsQuickPlaySpell())) and c:IsAbleToHand() and not c:IsCode(id) -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end \ No newline at end of file diff --git a/pre-release/c101303019.lua b/pre-release/c101303019.lua deleted file mode 100644 index aee7e644d4..0000000000 --- a/pre-release/c101303019.lua +++ /dev/null @@ -1,88 +0,0 @@ ---堕天使ジェフティ ---Darklord Djehuty ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Special Summon 1 "Darklord" monster from your Deck in Defense Position - local e1a=Effect.CreateEffect(c) - e1a:SetDescription(aux.Stringid(id,0)) - e1a:SetCategory(CATEGORY_SPECIAL_SUMMON) - e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1a:SetProperty(EFFECT_FLAG_DELAY) - e1a:SetCode(EVENT_SUMMON_SUCCESS) - e1a:SetCountLimit(1,id) - e1a:SetTarget(s.sptg) - e1a:SetOperation(s.spop) - c:RegisterEffect(e1a) - local e1b=e1a:Clone() - e1b:SetCode(EVENT_SPSUMMON_SUCCESS) - c:RegisterEffect(e1b) - --Add 1 "Darklord" card or "Forbidden" Quick-Play Spell from your GY to your hand - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TOHAND) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(s.thcon) - e2:SetCost(Cost.SelfBanish) - e2:SetTarget(s.thtg) - e2:SetOperation(s.thop) - c:RegisterEffect(e2) -end -s.listed_names={id} -s.listed_series={SET_DARKLORD,SET_FORBIDDEN} -function s.spfilter(c,e,tp) - return c:IsSetCard(SET_DARKLORD) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE) and not c:IsCode(id) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP_DEFENSE) - end - end - local c=e:GetHandler() - --You cannot Special Summon for the rest of this turn, except Fairy monsters - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return not c:IsRace(RACE_FAIRY) end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) - --Clock Lizard check - aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalRace(RACE_FAIRY) end) -end -function s.thconfilter(c) - return c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_FAIRY) and c:IsFusionMonster() and c:IsFaceup() -end -function s.thcon(e,tp,eg,ep,ev,re,r,rp) - return Duel.IsExistingMatchingCard(s.thconfilter,tp,LOCATION_MZONE,0,1,nil) -end -function s.thfilter(c) - return (c:IsSetCard(SET_DARKLORD) or (c:IsSetCard(SET_FORBIDDEN) and c:IsQuickPlaySpell())) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.thfilter(chkc) end - local c=e:GetHandler() - if chk==0 then return Duel.IsExistingTarget(s.thfilter,tp,LOCATION_GRAVE,0,1,c) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectTarget(tp,s.thfilter,tp,LOCATION_GRAVE,0,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,tp,0) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) then - Duel.SendtoHand(tc,nil,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303020.lua b/pre-release/c101303020.lua deleted file mode 100644 index 249e170c60..0000000000 --- a/pre-release/c101303020.lua +++ /dev/null @@ -1,97 +0,0 @@ ---ビック・バイパー Type-L ---Vic Viper Type-L ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Activate 1 of these effects - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e1:SetCode(EVENT_PHASE+PHASE_BATTLE_START) - e1:SetRange(LOCATION_MZONE) - e1:SetCountLimit(1,id) - e1:SetCondition(function(e,tp) return Duel.IsTurnPlayer(tp) end) - e1:SetTarget(s.efftg) - e1:SetOperation(s.effop) - c:RegisterEffect(e1) - --Special Summon 1 LIGHT Machine monster from your GY - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_ATKCHANGE) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) - e2:SetCode(EVENT_DESTROYED) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.gysptg) - e2:SetOperation(s.gyspop) - c:RegisterEffect(e2) -end -function s.handspfilter(c,e,tp) - return c:IsRace(RACE_MACHINE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.tgfilter(c) - return c:IsLevelBelow(4) and c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsRace(RACE_MACHINE) and c:IsAbleToGrave() -end -function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) - local b1=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.handspfilter,tp,LOCATION_HAND,0,1,nil,e,tp) - local b2=Duel.IsExistingMatchingCard(s.tgfilter,tp,LOCATION_DECK,0,1,nil) - if chk==0 then return b1 or b2 end - local op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,2)}, - {b2,aux.Stringid(id,3)}) - e:SetLabel(op) - if op==1 then - e:SetCategory(CATEGORY_SPECIAL_SUMMON) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND) - elseif op==2 then - e:SetCategory(CATEGORY_TOGRAVE) - Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) - end -end -function s.effop(e,tp,eg,ep,ev,re,r,rp) - local op=e:GetLabel() - if op==1 then - --Special Summon 1 Machine monster from your hand - if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,s.handspfilter,tp,LOCATION_HAND,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end - elseif op==2 then - --Send 1 Level 4 or lower LIGHT Machine monster from your Deck to the GY - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local g=Duel.SelectMatchingCard(tp,s.tgfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoGrave(g,REASON_EFFECT) - end - end -end -function s.gyspfilter(c,e,tp) - return c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsRace(RACE_MACHINE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.gysptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_GRAVE) and s.gyspfilter(chkc,e,tp) end - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingTarget(s.gyspfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local tc=Duel.SelectTarget(tp,s.gyspfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp):GetFirst() - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,tc,1,tp,0) - if tc:GetBaseAttack()<=1200 then - Duel.SetOperationInfo(0,CATEGORY_ATKCHANGE,tc,1,tp,1200) - end -end -function s.gyspop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)>0 and tc:GetBaseAttack()<=1200 then - --If its original ATK is 1200 or less, it gains 1200 ATK - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_UPDATE_ATTACK) - e1:SetValue(1200) - e1:SetReset(RESET_EVENT|RESETS_STANDARD) - tc:RegisterEffect(e1) - end -end \ No newline at end of file diff --git a/pre-release/c101303021.lua b/pre-release/c101303021.lua deleted file mode 100644 index 1f12571eb8..0000000000 --- a/pre-release/c101303021.lua +++ /dev/null @@ -1,93 +0,0 @@ ---巨大戦艦 デリンジャー・コア ---B.E.S. Dellinger Core ---scripted by Naim -local s,id=GetID() -local COUNTER_BES=0x1f -function s.initial_effect(c) - c:EnableCounterPermit(COUNTER_BES) - --Special Summon this card from your hand, then place 3 counters on it - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_COUNTER) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetRange(LOCATION_HAND) - e1:SetCountLimit(1,id) - e1:SetCost(Cost.Reveal(function(c) return c:IsSetCard(SET_BES) and c:IsMonster() end,true)) - e1:SetTarget(s.sptg) - e1:SetOperation(s.spop) - c:RegisterEffect(e1) - --Activate 1 of these effects - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(function(e) return Duel.IsMainPhase() end) - e2:SetCost(Cost.RemoveCounterFromSelf(COUNTER_BES,1)) - e2:SetTarget(s.efftg) - e2:SetOperation(s.effop) - e2:SetHintTiming(0,TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) - c:RegisterEffect(e2) -end -s.listed_names={66947414} --"Boss Rush" -s.listed_series={SET_BES} -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) - and c:IsCanAddCounter(COUNTER_BES,3,false,LOCATION_MZONE) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) - Duel.SetOperationInfo(0,CATEGORY_COUNTER,nil,3,tp,COUNTER_BES) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 - and c:IsCanAddCounter(COUNTER_BES,3) then - Duel.BreakEffect() - c:AddCounter(COUNTER_BES,3) - end -end -function s.thfilter(c) - return (c:IsCode(66947414) or (c:IsSpellTrap() and c:ListsCode(66947414))) and c:IsAbleToHand() -end -function s.spfilter(c,e,tp) - return c:IsLevelBelow(9) and c:IsSetCard(SET_BES) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) - local b1=Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) - local b2=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) - if chk==0 then return b1 or b2 end - local op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,2)}, - {b2,aux.Stringid(id,3)}) - e:SetLabel(op) - if op==1 then - e:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND) - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) - elseif op==2 then - e:SetCategory(CATEGORY_SPECIAL_SUMMON) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) - end -end -function s.effop(e,tp,eg,ep,ev,re,r,rp) - local op=e:GetLabel() - if op==1 then - --Add 1 "Boss Rush" or 1 Spell/Trap that mentions it from your Deck to your hand - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end - elseif op==2 then - --Special Summon 1 Level 9 or lower "B.E.S." monster from your GY - if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end - end -end \ No newline at end of file diff --git a/pre-release/c101303022.lua b/pre-release/c101303022.lua deleted file mode 100644 index 764beb5440..0000000000 --- a/pre-release/c101303022.lua +++ /dev/null @@ -1,81 +0,0 @@ ---超巨大戦艦 メタル・スレイブ ---Super B.E.S. Metal Slave ---scripted by Naim -local s,id=GetID() -local COUNTER_BES=0x1f -function s.initial_effect(c) - c:EnableCounterPermit(COUNTER_BES) - --Special Summon this card from your hand, then place counters on it equal to the number of cards sent to the GY to activate this effect - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_COUNTER) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetRange(LOCATION_HAND) - e1:SetCountLimit(1,id) - e1:SetCost(s.spcost) - e1:SetTarget(s.sptg) - e1:SetOperation(s.spop) - c:RegisterEffect(e1) - --Destroy 2 face-up cards on the field, including a "B.E.S." monster you control - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_DESTROY) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,0,EFFECT_COUNT_CODE_CHAIN) - e2:SetCost(Cost.RemoveCounterFromSelf(COUNTER_BES,1)) - e2:SetTarget(s.destg) - e2:SetOperation(s.desop) - e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e2) -end -s.listed_series={SET_BES} -function s.spcostfilter(c) - return c:IsLevelBelow(10) and c:IsSetCard(SET_BES) and c:IsAbleToGraveAsCost() -end -function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.IsExistingMatchingCard(s.spcostfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,c) end - local g=Duel.GetMatchingGroup(s.spcostfilter,tp,LOCATION_HAND|LOCATION_DECK,0,c) - local sg=aux.SelectUnselectGroup(g,e,tp,1,5,aux.dncheck,1,tp,HINTMSG_TOGRAVE) - e:SetLabel(Duel.SendtoGrave(sg,REASON_COST)) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) - and c:IsCanAddCounter(COUNTER_BES,1,false,LOCATION_MZONE) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) - Duel.SetOperationInfo(0,CATEGORY_COUNTER,nil,e:GetLabel(),tp,COUNTER_BES) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local count=e:GetLabel() - if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 - and c:IsCanAddCounter(COUNTER_BES,count) then - Duel.BreakEffect() - c:AddCounter(COUNTER_BES,count) - end -end -function s.besmonsterfilter(c,tp) - return c:IsSetCard(SET_BES) and c:IsLocation(LOCATION_MZONE) and c:IsControler(tp) -end -function s.rescon(sg,e,tp,mg) - return sg:IsExists(s.besmonsterfilter,1,nil,tp) -end -function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return false end - local g=Duel.GetMatchingGroup(aux.FaceupFilter(Card.IsCanBeEffectTarget,e),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) - if chk==0 then return #g>=2 and aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,0) end - local g=aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,1,tp,HINTMSG_DESTROY) - Duel.SetTargetCard(g) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,2,tp,0) -end -function s.desop(e,tp,eg,ep,ev,re,r,rp,chk) - local tg=Duel.GetTargetCards(e) - if #tg>0 then - Duel.Destroy(tg,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303023.lua b/pre-release/c101303023.lua deleted file mode 100644 index 9f462eb426..0000000000 --- a/pre-release/c101303023.lua +++ /dev/null @@ -1,91 +0,0 @@ ---R-ACEクイック・アタッカー ---Rescue-ACE Quick Attacker ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Special Summon this card from your hand - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetRange(LOCATION_HAND) - e1:SetCountLimit(1,id) - e1:SetCost(s.spcost) - e1:SetTarget(s.sptg) - e1:SetOperation(s.spop) - c:RegisterEffect(e1) - --Add 1 "Rescue-ACE" monster from your Deck to your hand, then you can Special Summon it if only your opponent controls a monster - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetCost(Cost.SelfTribute) - e2:SetTarget(s.thtg) - e2:SetOperation(s.thop) - c:RegisterEffect(e2) -end -s.listed_series={SET_RESCUE_ACE} -function s.spcostfilter(c,tp) - return c:IsSetCard(SET_RESCUE_ACE) and c:IsAbleToDeckAsCost() and Duel.GetMZoneCount(tp,c)>0 - and (c:IsFaceup() or c:IsLocation(LOCATION_HAND)) -end -function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.IsExistingMatchingCard(s.spcostfilter,tp,LOCATION_HAND|LOCATION_ONFIELD,0,1,c,tp) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) - local sc=Duel.SelectMatchingCard(tp,s.spcostfilter,tp,LOCATION_HAND|LOCATION_ONFIELD,0,1,1,c,tp):GetFirst() - if sc:IsLocation(LOCATION_HAND) then - Duel.ConfirmCards(1-tp,sc) - else - Duel.HintSelection(sc) - end - Duel.SendtoDeck(sc,nil,SEQ_DECKSHUFFLE,REASON_COST) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) then - Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) - end -end -function s.thfilter(c) - return c:IsSetCard(SET_RESCUE_ACE) and c:IsMonster() and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) - Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local sc=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil):GetFirst() - if sc and Duel.SendtoHand(sc,nil,REASON_EFFECT)>0 and sc:IsLocation(LOCATION_HAND) then - Duel.ConfirmCards(1-tp,sc) - if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and sc:IsCanBeSpecialSummoned(e,0,tp,false,false) - and Duel.GetFieldGroupCount(tp,LOCATION_MZONE,0)==0 - and Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE)>0 - and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.BreakEffect() - Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP) - end - end - local c=e:GetHandler() - --You cannot Special Summon from the Extra Deck for the rest of this turn, except FIRE monsters - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,3)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsAttribute(ATTRIBUTE_FIRE) end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) - --"Clock Lizard" check - aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalAttribute(ATTRIBUTE_FIRE) end) -end \ No newline at end of file diff --git a/pre-release/c101303024.lua b/pre-release/c101303024.lua deleted file mode 100644 index 0e74ba76e5..0000000000 --- a/pre-release/c101303024.lua +++ /dev/null @@ -1,82 +0,0 @@ ---白き竜の落胤 ---Fallen of the White Dragon ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Special Summon this card, also you cannot Special Summon from the Extra Deck for the rest of this turn, except Level 8 Fusion or Synchro Monsters - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetRange(LOCATION_HAND) - e1:SetCountLimit(1,id) - e1:SetCost(s.selfspcost) - e1:SetTarget(s.selfsptg) - e1:SetOperation(s.selfspop) - c:RegisterEffect(e1) - --Special Summon 1 "Ecclesia" monster from your hand, Deck, or GY - local e2a=Effect.CreateEffect(c) - e2a:SetDescription(aux.Stringid(id,1)) - e2a:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2a:SetProperty(EFFECT_FLAG_DELAY) - e2a:SetCode(EVENT_SUMMON_SUCCESS) - e2a:SetCountLimit(1,{id,1}) - e2a:SetTarget(s.hdgysptg) - e2a:SetOperation(s.hdgyspop) - c:RegisterEffect(e2a) - local e2b=e2a:Clone() - e2b:SetCode(EVENT_SPSUMMON_SUCCESS) - c:RegisterEffect(e2b) -end -s.listed_names={CARD_ALBAZ} -s.listed_series={SET_ECCLESIA} -function s.selfspcostfilter(c) - return c:ListsCode(CARD_ALBAZ) and c:IsAbleToGraveAsCost() -end -function s.selfspcost(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.selfspcostfilter,tp,LOCATION_EXTRA,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local g=Duel.SelectMatchingCard(tp,s.selfspcostfilter,tp,LOCATION_EXTRA,0,1,1,nil) - Duel.SendtoGrave(g,REASON_COST) -end -function s.selfsptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) -end -function s.selfspop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) then - Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) - end - --You cannot Special Summon from the Extra Deck for the rest of this turn, except Level 8 Fusion or Synchro Monsters - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not (c:IsLevel(8) and c:IsType(TYPE_FUSION|TYPE_SYNCHRO)) end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) - --"Clock Lizard" check - aux.addTempLizardCheck(c,tp,function(e,c) return not (c:IsOriginalLevel(8) and c:IsType(TYPE_FUSION|TYPE_SYNCHRO)) end) -end -function s.hdgyspfilter(c,e,tp) - return c:IsSetCard(SET_ECCLESIA) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.hdgysptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.hdgyspfilter,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE) -end -function s.hdgyspop(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,aux.NecroValleyFilter(s.hdgyspfilter),tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c101303025.lua b/pre-release/c101303025.lua deleted file mode 100644 index f219071a16..0000000000 --- a/pre-release/c101303025.lua +++ /dev/null @@ -1,65 +0,0 @@ ---鉄獣の炎工 キット ---Tri-Brigade Springans Kitt ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Special Summon this card from your hand - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetRange(LOCATION_HAND) - e1:SetCountLimit(1,id) - e1:SetCondition(s.selfspcon) - e1:SetTarget(s.selfsptg) - e1:SetOperation(s.selfspop) - c:RegisterEffect(e1) - --Special Summon from your GY 1 "Tri-Brigade" or "Springans" monster or "Fallen of Albaz" or a monster that mentions it - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY) - e2:SetCode(EVENT_TO_GRAVE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.gysptg) - e2:SetOperation(s.gyspop) - c:RegisterEffect(e2) -end -s.listed_names={id,CARD_ALBAZ} -s.listed_series={SET_TRI_BRIGADE,SET_SPRINGANS} -function s.selfspconfilter(c) - return c:IsSetCard({SET_TRI_BRIGADE,SET_SPRINGANS}) and c:IsFaceup() and not c:IsCode(id) -end -function s.selfspcon(e,tp,eg,ep,ev,re,r,rp) - return Duel.IsExistingMatchingCard(s.selfspconfilter,tp,LOCATION_MZONE,0,1,nil) -end -function s.selfsptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) -end -function s.selfspop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) then - Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) - end -end -function s.gyspfilter(c,e,tp) - return (c:IsSetCard({SET_TRI_BRIGADE,SET_SPRINGANS}) or (c:IsCode(CARD_ALBAZ) or c:ListsCode(CARD_ALBAZ))) and not c:IsCode(id) - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.gysptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.gyspfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) -end -function s.gyspop(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,s.gyspfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c101303026.lua b/pre-release/c101303026.lua deleted file mode 100644 index b57fbd2cc2..0000000000 --- a/pre-release/c101303026.lua +++ /dev/null @@ -1,91 +0,0 @@ ---蒼穹を睨めるダーク ---Dark Staring at the Blue Sky ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Special Summon this card - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY,EFFECT_FLAG2_CHECK_SIMULTANEOUS) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetRange(LOCATION_GRAVE) - e1:SetCountLimit(1,{id,0}) - e1:SetCondition(s.spcon) - e1:SetTarget(s.sptg) - e1:SetOperation(s.spop) - c:RegisterEffect(e1) - --Negate that monster effect that includes an effect that Special Summons a monster(s), and if you do, destroy that card - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_DISABLE+CATEGORY_DESTROY) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetCode(EVENT_CHAINING) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return re:IsMonsterEffect() and re:IsHasCategory(CATEGORY_SPECIAL_SUMMON) and Duel.IsChainDisablable(ev) end) - e2:SetCost(s.discost) - e2:SetTarget(s.distg) - e2:SetOperation(s.disop) - c:RegisterEffect(e2) - --Return 1 of your other banished monsters to the GY - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,2)) - e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e3:SetCode(EVENT_PHASE+PHASE_END) - e3:SetRange(LOCATION_REMOVED) - e3:SetCountLimit(1,{id,2}) - e3:SetCondition(function(e) return e:GetHandler():GetTurnID()==Duel.GetTurnCount() end) - e3:SetTarget(s.rtgtg) - e3:SetOperation(s.rtgop) - c:RegisterEffect(e3) -end -function s.spcon(e,tp,eg,ep,ev,re,r,rp) - return rp==1-tp and re and re:IsActivated() and re:IsMonsterEffect() - and eg:IsExists(Card.IsSummonLocation,1,nil,LOCATION_DECK|LOCATION_EXTRA) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) then - Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) - end -end -function s.discost(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemoveAsCost,tp,LOCATION_HAND|LOCATION_ONFIELD,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) - local g=Duel.SelectMatchingCard(tp,Card.IsAbleToRemoveAsCost,tp,LOCATION_HAND|LOCATION_ONFIELD,0,1,1,nil) - Duel.Remove(g,POS_FACEUP,REASON_COST) -end -function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return true end - local rc=re:GetHandler() - Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,tp,0) - if rc:IsDestructable() and rc:IsRelateToEffect(re) then - Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,tp,0) - end -end -function s.disop(e,tp,eg,ep,ev,re,r,rp) - if Duel.NegateEffect(ev) and re:GetHandler():IsRelateToEffect(re) then - Duel.Destroy(eg,REASON_EFFECT) - end -end -function s.rtgtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsMonster),tp,LOCATION_REMOVED,0,1,e:GetHandler()) end -end -function s.rtgop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local exc=c:IsRelateToEffect(e) and c or nil - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOGRAVE) - local g=Duel.SelectMatchingCard(tp,aux.FaceupFilter(Card.IsMonster),tp,LOCATION_REMOVED,0,1,1,exc) - if #g>0 then - Duel.HintSelection(g) - Duel.SendtoGrave(g,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303027.lua b/pre-release/c101303027.lua deleted file mode 100644 index 34cc82a9be..0000000000 --- a/pre-release/c101303027.lua +++ /dev/null @@ -1,58 +0,0 @@ ---天雷ノ双風神 シーナ ---Sheena the Twin Storm Deities of Divine Thunder ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Special Summon this card from your hand, then apply this effect based on that card effect's type - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOHAND) - e1:SetType(EFFECT_TYPE_QUICK_O) - e1:SetCode(EVENT_CHAINING) - e1:SetRange(LOCATION_HAND) - e1:SetCountLimit(1,id) - e1:SetCondition(s.spcon) - e1:SetTarget(s.sptg) - e1:SetOperation(s.spop) - c:RegisterEffect(e1) - --The first time this card would be destroyed by battle each turn, it is not destroyed - local e2=Effect.CreateEffect(c) - e2:SetType(EFFECT_TYPE_SINGLE) - e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e2:SetCode(EFFECT_INDESTRUCTABLE_COUNT) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1) - e2:SetValue(function(e,re,r,rp) return (r&REASON_BATTLE)>0 end) - c:RegisterEffect(e2) -end -s.listed_names={id} -function s.spcon(e,tp,eg,ep,ev,re,r,rp) - return rp==1-tp and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_WIND),tp,LOCATION_MZONE,0,1,nil) -end -function s.rthfilter(c) - return c:IsFaceup() and c:IsAbleToHand() and not c:IsCode(id) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) - and ((re:IsMonsterEffect() and Duel.IsExistingMatchingCard(s.rthfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil)) - or (re:IsSpellTrapEffect() and Duel.IsExistingMatchingCard(aux.AND(Card.IsSpellTrap,Card.IsAbleToHand),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil))) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,PLAYER_ALL,LOCATION_ONFIELD) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 then - local g=Group.CreateGroup() - if re:IsMonsterEffect() then - g=Duel.GetMatchingGroup(s.rthfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil) - elseif re:IsSpellTrapEffect(e) then - g=Duel.GetMatchingGroup(aux.AND(Card.IsSpellTrap,Card.IsAbleToHand),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) - end - if #g>0 then - Duel.BreakEffect() - Duel.SendtoHand(g,nil,REASON_EFFECT) - end - end -end \ No newline at end of file diff --git a/pre-release/c101303028.lua b/pre-release/c101303028.lua deleted file mode 100644 index fe3adb0766..0000000000 --- a/pre-release/c101303028.lua +++ /dev/null @@ -1,77 +0,0 @@ ---スレット・アームド・ドラゴン ---Threat Armed Dragon ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Destroy 1 Dragon monster you control, and if you do, Special Summon this card - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_DESTROY+CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetProperty(EFFECT_FLAG_CARD_TARGET) - e1:SetRange(LOCATION_GRAVE) - e1:SetCountLimit(1,id) - e1:SetTarget(s.sptg) - e1:SetOperation(s.spop) - c:RegisterEffect(e1) - --Destroy 1 monster on the field with 2400 or less ATK, then if you destroyed a monster you control, you can Special Summon 1 Dragon monster from your hand or Deck whose original Level is 2 higher than the destroyed monster - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_DESTROY+CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetCost(Cost.Discard()) - e2:SetTarget(s.destg) - e2:SetOperation(s.desop) - c:RegisterEffect(e2) -end -function s.sptgdesfilter(c,tp) - return c:IsRace(RACE_DRAGON) and c:IsFaceup() and Duel.GetMZoneCount(tp,c)>0 -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and s.sptgdesfilter(chkc,tp) end - local c=e:GetHandler() - if chk==0 then return Duel.IsExistingTarget(s.sptgdesfilter,tp,LOCATION_MZONE,0,1,nil,tp) - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local g=Duel.SelectTarget(tp,s.sptgdesfilter,tp,LOCATION_MZONE,0,1,1,nil,tp) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and tc:IsMonster() and Duel.Destroy(tc,REASON_EFFECT)>0 - and c:IsRelateToEffect(e) then - Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) - end -end -function s.spfilter(c,e,tp,lv) - return c:IsRace(RACE_DRAGON) and c:IsOriginalLevel(lv) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsAttackBelow(2400) and chkc:IsFaceup() end - if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(Card.IsAttackBelow,2400),tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local g=Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsAttackBelow,2400),tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) - Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_DECK) -end -function s.desop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and tc:IsMonster() and Duel.Destroy(tc,REASON_EFFECT)>0 and tc:IsPreviousControler(tp) and tc:HasLevel() - and Duel.GetMZoneCount(tp)>0 then - local lv=tc:GetOriginalLevel()+2 - if Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,e,tp,lv) - and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,1,nil,e,tp,lv) - if #g>0 then - Duel.BreakEffect() - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end - end - end -end \ No newline at end of file diff --git a/pre-release/c101303029.lua b/pre-release/c101303029.lua deleted file mode 100644 index f8d37ce92e..0000000000 --- a/pre-release/c101303029.lua +++ /dev/null @@ -1,92 +0,0 @@ ---WAKE CUP! アル ---WAKE CUP! Erl ---Scripted by The Razgriz -local s,id=GetID() -function s.initial_effect(c) - --FLIP: You can send face-up cards your opponent controls to the GY, up to the number of Flip monsters you control - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOGRAVE) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_FLIP+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCountLimit(1,id) - e1:SetTarget(s.tgtg) - e1:SetOperation(s.tgop) - c:RegisterEffect(e1) - --Discard 1 other Flip monster, and if you do, Special Summon this card in Attack Position or face-down Defense Position - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_HANDES+CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_HAND) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.selfsptg) - e2:SetOperation(s.selfspop) - c:RegisterEffect(e2) - --Special Summon 1 Flip monster from your GY in face-down Defense Position - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,2)) - e3:SetCategory(CATEGORY_SPECIAL_SUMMON) - e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e3:SetProperty(EFFECT_FLAG_CARD_TARGET) - e3:SetCode(EVENT_PHASE+PHASE_END) - e3:SetRange(LOCATION_MZONE) - e3:SetCountLimit(1,{id,2}) - e3:SetCondition(function(e,tp) return Duel.IsTurnPlayer(tp) end) - e3:SetTarget(s.gysptg) - e3:SetOperation(s.gyspop) - c:RegisterEffect(e3) -end -function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsType,TYPE_FLIP),tp,LOCATION_MZONE,0,1,nil) - and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsAbleToGrave),tp,0,LOCATION_ONFIELD,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,1-tp,LOCATION_ONFIELD) -end -function s.tgop(e,tp,eg,ep,ev,re,r,rp) - local ct=Duel.GetMatchingGroupCount(aux.FaceupFilter(Card.IsType,TYPE_FLIP),tp,LOCATION_MZONE,0,nil) - if ct==0 then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local g=Duel.SelectMatchingCard(tp,aux.FaceupFilter(Card.IsAbleToGrave),tp,0,LOCATION_ONFIELD,1,ct,nil) - if #g>0 then - Duel.HintSelection(g) - Duel.SendtoGrave(g,REASON_EFFECT) - end -end -function s.selfspdiscardfilter(c) - return c:IsType(TYPE_FLIP) and c:IsDiscardable(REASON_EFFECT) -end -function s.selfsptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.selfspdiscardfilter,tp,LOCATION_HAND,0,1,c) - and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_ATTACK|POS_FACEDOWN_DEFENSE) - end - Duel.SetOperationInfo(0,CATEGORY_HANDES,nil,0,tp,1) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) -end -function s.selfspop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local exc=c:IsRelateToEffect(e) and c or nil - if Duel.DiscardHand(tp,s.selfspdiscardfilter,1,1,REASON_DISCARD|REASON_EFFECT,exc)>0 and c:IsRelateToEffect(e) - and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP_ATTACK|POS_FACEDOWN_DEFENSE)>0 - and c:IsFacedown() then - Duel.ConfirmCards(1-tp,c) - end -end -function s.gyspfilter(c,e,tp) - return c:IsType(TYPE_FLIP) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEDOWN_DEFENSE) -end -function s.gysptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.gyspfilter(chkc,e,tp) end - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingTarget(s.gyspfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectTarget(tp,s.gyspfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,0) -end -function s.gyspop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEDOWN_DEFENSE)>0 then - Duel.ConfirmCards(1-tp,tc) - end -end \ No newline at end of file diff --git a/pre-release/c101303030.lua b/pre-release/c101303030.lua deleted file mode 100644 index f35ea226ea..0000000000 --- a/pre-release/c101303030.lua +++ /dev/null @@ -1,81 +0,0 @@ ---ファースト・ペンギン ---First Penguin ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --If you control no face-up monsters, you can Special Summon this card (from your hand), and if you do, it is treated as a Tuner - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) - e1:SetCode(EFFECT_SPSUMMON_PROC) - e1:SetRange(LOCATION_HAND) - e1:SetCondition(s.selfspcon) - e1:SetOperation(s.selfspop) - c:RegisterEffect(e1) - --Add 1 WATER monster with the same Type as the revealed monster, but 1 Level lower, from your Deck to your hand, then you can change this card to face-down Defense Position, also you cannot Special Summon from the Extra Deck for the rest of this turn, except WATER monsters - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_POSITION) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,id) - e2:SetCost(Cost.AND(Cost.Discard(),Cost.Reveal(s.revealfilter,false,1,1,function(e,tp,g) local sc=g:GetFirst() e:SetLabel(sc:GetRace(),sc:GetLevel()-1) end,LOCATION_EXTRA))) - e2:SetTarget(s.thtg) - e2:SetOperation(s.thop) - c:RegisterEffect(e2) -end -function s.selfspcon(e,c) - if c==nil then return true end - local tp=e:GetHandlerPlayer() - return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and not Duel.IsExistingMatchingCard(Card.IsFaceup,tp,LOCATION_MZONE,0,1,nil) -end -function s.selfspop(e,tp,eg,ep,ev,re,r,rp,c) - --It is treated as a Tuner - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_ADD_TYPE) - e1:SetValue(TYPE_TUNER) - e1:SetReset(RESET_EVENT|(RESETS_STANDARD&~RESET_TOFIELD)) - c:RegisterEffect(e1) -end -function s.revealfilter(c,e,tp) - return c:IsAttribute(ATTRIBUTE_WATER) and c:IsSynchroMonster() and not c:IsLevel(1) and not c:IsPublic() - and Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil,c:GetRace(),c:GetLevel()-1) -end -function s.thfilter(c,race,lv) - return c:IsAttribute(ATTRIBUTE_WATER) and c:IsRace(race) and c:IsLevel(lv) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return true end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) - Duel.SetPossibleOperationInfo(0,CATEGORY_POSITION,e:GetHandler(),1,tp,0) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local race,lv=e:GetLabel() - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local sc=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil,race,lv):GetFirst() - if sc and Duel.SendtoHand(sc,nil,REASON_EFFECT)>0 and sc:IsLocation(LOCATION_HAND) then - Duel.ConfirmCards(1-tp,sc) - Duel.ShuffleHand(tp) - if c:IsRelateToEffect(e) and c:IsCanTurnSet() and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.BreakEffect() - Duel.ChangePosition(c,POS_FACEDOWN_DEFENSE) - end - end - --You cannot Special Summon from the Extra Deck for the rest of this turn, except WATER monsters - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,3)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsAttribute(ATTRIBUTE_WATER) end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) - --"Clock Lizard" check - aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalAttribute(ATTRIBUTE_WATER) end) -end \ No newline at end of file diff --git a/pre-release/c101303031.lua b/pre-release/c101303031.lua deleted file mode 100644 index 04ecd84df4..0000000000 --- a/pre-release/c101303031.lua +++ /dev/null @@ -1,92 +0,0 @@ ---デス・エンペラー・デーモン ---Doom Emperor Archfiend ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - Pendulum.AddProcedure(c) - c:AddMustBeRitualSummoned() - --Destroy both this card and 1 other face-up Spell/Trap on the field - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_DESTROY) - e1:SetProperty(EFFECT_FLAG_CARD_TARGET) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetRange(LOCATION_PZONE) - e1:SetCountLimit(1,id) - e1:SetTarget(s.destg) - e1:SetOperation(s.desop) - c:RegisterEffect(e1) - --Unaffected by other monsters' effects while in the Extra Monster Zone - local e2=Effect.CreateEffect(c) - e2:SetType(EFFECT_TYPE_SINGLE) - e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e2:SetCode(EFFECT_IMMUNE_EFFECT) - e2:SetRange(LOCATION_EMZONE) - e2:SetValue(function(e,te) return te:IsMonsterEffect() and te:GetOwner()~=e:GetOwner() end) - c:RegisterEffect(e2) - --Banish all monsters on the field, except those in the Extra Monster Zone - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_REMOVE) - e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e3:SetProperty(EFFECT_FLAG_DELAY) - e3:SetCode(EVENT_SPSUMMON_SUCCESS) - e3:SetCountLimit(1,{id,1}) - e3:SetCondition(function(e) local c=e:GetHandler() return c:IsRitualSummoned() and c:IsSummonLocation(LOCATION_EXTRA) end) - e3:SetTarget(s.rmtg) - e3:SetOperation(s.rmop) - c:RegisterEffect(e3) - --Special Summon 1 Fiend monster from your hand, Deck, GY, or banishment - local e4=Effect.CreateEffect(c) - e4:SetDescription(aux.Stringid(id,2)) - e4:SetCategory(CATEGORY_SPECIAL_SUMMON) - e4:SetType(EFFECT_TYPE_IGNITION) - e4:SetRange(LOCATION_EMZONE) - e4:SetCountLimit(1,{id,2}) - e4:SetTarget(s.sptg) - e4:SetOperation(s.spop) - c:RegisterEffect(e4) -end -s.listed_names={101303059} --"Throne of Archfiends" -function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - local c=e:GetHandler() - if chkc then return c:IsOnField() and c:IsSpellTrap() and c:IsFaceup() and chkc~=c end - if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(Card.IsSpellTrap),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,c) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local g=Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsSpellTrap),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,c) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,g+c,2,tp,0) -end -function s.desop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local tc=Duel.GetFirstTarget() - if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) then - Duel.Destroy(Group.FromCards(c,tc),REASON_EFFECT) - end -end -function s.rmtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,LOCATION_MMZONE,LOCATION_MMZONE,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,PLAYER_ALL,LOCATION_MMZONE) -end -function s.rmop(e,tp,eg,ep,ev,re,r,rp) - local g=Duel.GetFieldGroup(tp,LOCATION_MMZONE,LOCATION_MMZONE) - if #g>0 then - Duel.Remove(g,POS_FACEUP,REASON_EFFECT) - end -end -function s.spfilter(c,e,tp) - return c:IsRace(RACE_FIEND) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE|LOCATION_REMOVED,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE|LOCATION_REMOVED) -end -function s.spop(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,s.spfilter,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE|LOCATION_REMOVED,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c101303033.lua b/pre-release/c101303033.lua deleted file mode 100644 index 9e95286211..0000000000 --- a/pre-release/c101303033.lua +++ /dev/null @@ -1,76 +0,0 @@ ---DDD聖賢王アルフレッド ---D/D/D Sage King Alfred ---Scripted by The Razgriz -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Fusion Materials: 2 "D/D" monsters - Fusion.AddProcMixN(c,true,true,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_DD),2) - local params={ - fusfilter=aux.FilterBoolFunction(Card.IsSetCard,SET_DDD), - matfilter=Card.IsAbleToDeck, - extrafil=function(e,tp,mg) - return Duel.GetMatchingGroup(Fusion.IsMonsterFilter(Card.IsFaceup,Card.IsAbleToDeck),tp,LOCATION_REMOVED,0,nil) - end, - extraop=Fusion.ShuffleMaterial, - extratg=function(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return true end - Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,1,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_REMOVED) - end - } - --Fusion Summon 1 "D/D/D" Fusion Monster from your Extra Deck, by shuffling its materials from your hand, field, and/or banishment into the Deck - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TODECK+CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetRange(LOCATION_MZONE) - e1:SetCountLimit(1,id) - e1:SetTarget(Fusion.SummonEffTG(params)) - e1:SetOperation(Fusion.SummonEffOP(params)) - c:RegisterEffect(e1) - --Place "Dark Contract" Spell/Traps face-up on your field from your GY and/or banishment, up to the number of "D/D/D" monsters you control - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) - e2:SetCode(EVENT_REMOVE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.pltg) - e2:SetOperation(s.plop) - c:RegisterEffect(e2) -end -s.listed_series={SET_DD,SET_DDD,SET_DARK_CONTRACT} -s.material_setcode=SET_DD -function s.plfilter(c,tp) - return c:IsSetCard(SET_DARK_CONTRACT) and c:IsContinuousSpellTrap() and c:IsFaceup() and c:CheckUniqueOnField(tp) - and not c:IsForbidden() -end -function s.pltg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_GRAVE|LOCATION_REMOVED) and chkc:IsControler(tp) and s.plfilter(chkc,tp) end - local ct=Duel.GetMatchingGroupCount(aux.FaceupFilter(Card.IsSetCard,SET_DDD),tp,LOCATION_MZONE,0,nil) - local ft=Duel.GetLocationCount(tp,LOCATION_SZONE) - if chk==0 then return ct>0 and ft>0 and Duel.IsExistingTarget(s.plfilter,tp,LOCATION_GRAVE|LOCATION_REMOVED,0,1,nil,tp) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) - local g=Duel.SelectTarget(tp,s.plfilter,tp,LOCATION_GRAVE|LOCATION_REMOVED,0,1,math.min(ct,ft),nil,tp) - if g:IsExists(Card.IsLocation,1,nil,LOCATION_GRAVE) then - Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,nil,1,tp,0) - end -end -function s.plop(e,tp,eg,ep,ev,re,r,rp) - local tg=Duel.GetTargetCards(e) - if #tg==0 then return end - local gg=Group.CreateGroup() - local ft=Duel.GetLocationCount(tp,LOCATION_SZONE) - if ft<#tg then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) - local sg=tg:FilterSelect(tp,s.plfilter,ft,ft,nil,tp) - gg=tg-sg - tg=sg - end - for tc in tg:Iter() do - Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) - end - if #gg>0 then - Duel.SendtoGrave(gg,REASON_RULE|REASON_RETURN,PLAYER_NONE,tp) - end -end \ No newline at end of file diff --git a/pre-release/c101303034.lua b/pre-release/c101303034.lua deleted file mode 100644 index c4d0fee00c..0000000000 --- a/pre-release/c101303034.lua +++ /dev/null @@ -1,82 +0,0 @@ ---超電導戦騎プラズマ・マグナム ---Conduction Knight Plasma Magnum ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Fusion Materials: 2 EARTH Rock monsters - Fusion.AddProcMixN(c,true,true,s.matfilter,2) - --All face-up monsters on the field become EARTH - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetCode(EFFECT_CHANGE_ATTRIBUTE) - e1:SetRange(LOCATION_MZONE) - e1:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) - e1:SetValue(ATTRIBUTE_EARTH) - c:RegisterEffect(e1) - --Add 1 "Magnet" Normal, Quick-Play, or Field Spell from your Deck to your hand - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY) - e2:SetCode(EVENT_SPSUMMON_SUCCESS) - e2:SetCountLimit(1,id) - e2:SetCondition(function(e) return e:GetHandler():IsFusionSummoned() end) - e2:SetTarget(s.thtg) - e2:SetOperation(s.thop) - c:RegisterEffect(e2) - --Immediately after this effect resolves, Normal Summon 1 Level 4 or lower "Magnet Warrior" monster - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_SUMMON) - e3:SetType(EFFECT_TYPE_IGNITION) - e3:SetRange(LOCATION_MZONE) - e3:SetCountLimit(1,{id,1}) - e3:SetCost(s.nscost) - e3:SetTarget(s.nstg) - e3:SetOperation(s.nsop) - c:RegisterEffect(e3) -end -s.listed_series={SET_MAGNET,SET_MAGNA_WARRIOR,SET_MAGNET_WARRIOR} -function s.matfilter(c,fc,sumtype,tp) - return c:IsAttribute(ATTRIBUTE_EARTH,fc,sumtype,tp) and c:IsRace(RACE_ROCK,fc,sumtype,tp) -end -function s.thfilter(c) - return c:IsSetCard(SET_MAGNET) and (c:IsNormalSpell() or c:IsQuickPlaySpell() or c:IsFieldSpell()) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end -function s.nscostfilter(c) - return c:IsLevel(8) and c:IsSetCard(SET_MAGNA_WARRIOR) and c:IsAbleToGraveAsCost() -end -function s.nscost(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.nscostfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local g=Duel.SelectMatchingCard(tp,s.nscostfilter,tp,LOCATION_DECK,0,1,1,nil) - Duel.SendtoGrave(g,REASON_COST) -end -function s.nsfilter(c) - return c:IsLevelBelow(4) and c:IsSetCard(SET_MAGNET_WARRIOR) and c:IsSummonable(true,nil) -end -function s.nstg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.nsfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_MZONE) -end -function s.nsop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON) - local sc=Duel.SelectMatchingCard(tp,s.nsfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,1,nil):GetFirst() - if sc then - Duel.Summon(tp,sc,true,nil) - end -end \ No newline at end of file diff --git a/pre-release/c101303035.lua b/pre-release/c101303035.lua deleted file mode 100644 index 654c7eeb3d..0000000000 --- a/pre-release/c101303035.lua +++ /dev/null @@ -1,111 +0,0 @@ ---神芸なる知恵の乙女 ---Artmage Non Finito ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Fusion Materials: 2 "Artmage" monsters - Fusion.AddProcMixN(c,true,true,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_ARTMAGE),2) - c:AddMustBeFusionSummoned() - --You can only Fusion Summon or Special Summon by its alternate procedure "Artmage Nonfinite" once per turn - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) - e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e0:SetCode(EVENT_SPSUMMON_SUCCESS) - e0:SetCondition(s.regcon) - e0:SetOperation(s.regop) - c:RegisterEffect(e0) - --You can Special Summon this card by discarding 1 Spell/Trap and Tributing 1 Level 7 or higher "Artmage" monster in your hand or field - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) - e1:SetCode(EFFECT_SPSUMMON_PROC) - e1:SetRange(LOCATION_EXTRA) - e1:SetCondition(s.selfspcon) - e1:SetTarget(s.selfsptg) - e1:SetOperation(s.selfspop) - e1:SetValue(1) - c:RegisterEffect(e1) - --Set 1 "Artmage" Spell/Trap from your Deck - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY) - e2:SetCode(EVENT_SPSUMMON_SUCCESS) - e2:SetTarget(s.settg) - e2:SetOperation(s.setop) - c:RegisterEffect(e2) - --Fusion Summon 1 Fusion Monster by using monsters you control - local fusion_params={handler=c,matfilter=Fusion.OnFieldMat} - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,2)) - e3:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON) - e3:SetType(EFFECT_TYPE_QUICK_O) - e3:SetCode(EVENT_FREE_CHAIN) - e3:SetRange(LOCATION_MZONE) - e3:SetCountLimit(1) - e3:SetCondition(function(e,tp) return Duel.IsTurnPlayer(1-tp) end) - e3:SetTarget(Fusion.SummonEffTG(fusion_params)) - e3:SetOperation(Fusion.SummonEffOP(fusion_params)) - e3:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e3) -end -s.listed_series={SET_ARTMAGE} -s.listed_names={id} -function s.regcon(e) - local c=e:GetHandler() - return c:IsFusionSummoned() or c:IsSummonType(SUMMON_TYPE_SPECIAL+1) -end -function s.regop(e,tp,eg,ep,ev,re,r,rp) - --Prevent another Fusion Summon or Special Summon by its alternate procedure of "Artmage Nonfinite" that turn - 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(function(e,c,sump,sumtype) - return c:IsCode(id) and (sumtype&SUMMON_TYPE_FUSION==SUMMON_TYPE_FUSION or sumtype&SUMMON_TYPE_SPECIAL+1==SUMMON_TYPE_SPECIAL+1) - end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) -end -function s.selfspcostfilter(c,tp,fc) - return c:IsLevelAbove(7) and c:IsSetCard(SET_ARTMAGE,fc,SUMMON_TYPE_SPECIAL+1,tp) and Duel.GetLocationCountFromEx(tp,tp,c,fc)>0 -end -function s.selfspcon(e,c) - if not c then return true end - if c:IsFaceup() then return false end - local tp=c:GetControler() - return Duel.IsExistingMatchingCard(aux.AND(Card.IsSpellTrap,Card.IsDiscardable),tp,LOCATION_HAND,0,1,nil) - and Duel.CheckReleaseGroup(tp,s.selfspcostfilter,1,true,1,true,c,tp,nil,nil,nil,tp,c) -end -function s.selfsptg(e,tp,eg,ep,ev,re,r,rp,chk,c) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) - local dg=Duel.SelectMatchingCard(tp,aux.AND(Card.IsSpellTrap,Card.IsDiscardable),tp,LOCATION_HAND,0,1,1,true,nil) - if not dg then return false end - local rg=Duel.SelectReleaseGroup(tp,s.selfspcostfilter,1,1,true,true,true,c,tp,nil,false,nil,tp,c) - if not rg then return false end - e:SetLabelObject(dg+rg) - return true -end -function s.selfspop(e,tp,eg,ep,ev,re,r,rp,c) - local g=e:GetLabelObject() - if not g or #g~=2 then return end - local dg,rg=g:Split(Card.IsSpellTrap,nil) - Duel.SendtoGrave(dg,REASON_COST|REASON_MATERIAL|REASON_DISCARD) - Duel.Release(rg,REASON_COST|REASON_MATERIAL) -end -function s.setfilter(c) - return c:IsSetCard(SET_ARTMAGE) and c:IsSpellTrap() and c:IsSSetable() -end -function s.settg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.setfilter,tp,LOCATION_DECK,0,1,nil) end -end -function s.setop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) - local g=Duel.SelectMatchingCard(tp,s.setfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SSet(tp,g) - end -end \ No newline at end of file diff --git a/pre-release/c101303036.lua b/pre-release/c101303036.lua deleted file mode 100644 index 614782b6e1..0000000000 --- a/pre-release/c101303036.lua +++ /dev/null @@ -1,102 +0,0 @@ ---黄昏の堕天使ルシファー ---Lucifer, Darklord of the Evening Twilight ---Scripted by The Razgriz -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Fusion Materials: 2 Level 6 or higher DARK Fairy monsters - Fusion.AddProcMixN(c,true,true,s.matfilter,2) - --Your opponent cannot target this card with card effects - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e1:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET) - e1:SetRange(LOCATION_MZONE) - e1:SetValue(aux.tgoval) - c:RegisterEffect(e1) - --Set 1 "Darklord" Spell and 1 "Darklord" Trap from your Deck - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY) - e2:SetCode(EVENT_SPSUMMON_SUCCESS) - e2:SetCountLimit(1,id) - e2:SetCondition(function(e) return e:GetHandler():IsFusionSummoned() end) - e2:SetTarget(s.settg) - e2:SetOperation(s.setop) - c:RegisterEffect(e2) - --Apply the effect of 1 "Darklord" Spell/Trap in your GY, then shuffle it into the Deck - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_TODECK) - e3:SetType(EFFECT_TYPE_QUICK_O) - e3:SetProperty(EFFECT_FLAG_CARD_TARGET) - e3:SetCode(EVENT_FREE_CHAIN) - e3:SetRange(LOCATION_MZONE) - e3:SetCountLimit(1,{id,1}) - e3:SetCost(Cost.PayLP(1000)) - e3:SetTarget(s.copytg) - e3:SetOperation(s.copyop) - e3:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e3) -end -s.listed_series={SET_DARKLORD} -function s.matfilter(c,fc,sumtype,sump) - return c:IsLevelAbove(6) and c:IsAttribute(ATTRIBUTE_DARK,fc,sumtype,sump) and c:IsRace(RACE_FAIRY,fc,sumtype,sump) -end -function s.setfilter(c) - return c:IsSetCard(SET_DARKLORD) and c:IsSpellTrap() and c:IsSSetable() -end -function s.rescon(stzone_chk) - return function(sg,e,tp,mg) - return #sg==2 and (stzone_chk or sg:IsExists(Card.IsFieldSpell,1,nil)) and sg:IsExists(Card.IsSpell,1,nil) and sg:IsExists(Card.IsTrap,1,nil) - end -end -function s.settg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then - local stzone_chk=Duel.GetLocationCount(tp,LOCATION_SZONE)>=2 - local g=Duel.GetMatchingGroup(s.setfilter,tp,LOCATION_DECK,0,nil) - return #g>=2 and aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon(stzone_chk),0) - end -end -function s.setop(e,tp,eg,ep,ev,re,r,rp) - local stzone_chk=Duel.GetLocationCount(tp,LOCATION_SZONE)>=2 - local g=Duel.GetMatchingGroup(s.setfilter,tp,LOCATION_DECK,0,nil) - local sg=aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon(stzone_chk),1,tp,HINTMSG_SET) - if #sg==2 then - Duel.SSet(tp,sg) - end -end -function s.copyfilter(c) - return c:IsSetCard(SET_DARKLORD) and c:IsSpellTrap() and c:IsAbleToDeck() and c:CheckActivateEffect(false,true,false)~=nil -end -function s.copytg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.copyfilter(chkc) end - if chk==0 then return Duel.IsExistingTarget(s.copyfilter,tp,LOCATION_GRAVE,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) - local g=Duel.SelectTarget(tp,s.copyfilter,tp,LOCATION_GRAVE,0,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_TODECK,g,1,tp,0) -end -function s.copyop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if not tc:IsRelateToEffect(e) then return end - local te,ceg,cep,cev,cre,cr,crp=tc:CheckActivateEffect(false,true,true) - if not te then return end - local tg=te:GetTarget() - local op=te:GetOperation() - if tg then tg(te,tp,Group.CreateGroup(),PLAYER_NONE,0,e,REASON_EFFECT,PLAYER_NONE,1) end - Duel.BreakEffect() - tc:CreateEffectRelation(te) - Duel.BreakEffect() - local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS) - for etc in aux.Next(g) do - etc:CreateEffectRelation(te) - end - if op then op(te,tp,Group.CreateGroup(),PLAYER_NONE,0,e,REASON_EFFECT,PLAYER_NONE,1) end - tc:ReleaseEffectRelation(te) - for etc in aux.Next(g) do - etc:ReleaseEffectRelation(te) - end - Duel.BreakEffect() - Duel.SendtoDeck(te:GetHandler(),nil,SEQ_DECKSHUFFLE,REASON_EFFECT) -end \ No newline at end of file diff --git a/pre-release/c101303037.lua b/pre-release/c101303037.lua deleted file mode 100644 index 1ea215b012..0000000000 --- a/pre-release/c101303037.lua +++ /dev/null @@ -1,104 +0,0 @@ ---星辰鋏竜シャウラス ---Dracotail Shaurus ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Fusion Materials: 1 "Dragontail" monster + 1 monster in the hand - Fusion.AddProcMix(c,true,true,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_DRACOTAIL),aux.FilterBoolFunctionEx(Card.IsLocation,LOCATION_HAND)) - --Shuffle 2 "Dracotail" cards from your GY, and 1 face-up card on the field of the same type (Monster, Spell, or Trap) as 1 of them into the Deck - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TODECK) - e1:SetType(EFFECT_TYPE_IGNITION) - e1:SetProperty(EFFECT_FLAG_CARD_TARGET) - e1:SetRange(LOCATION_MZONE) - e1:SetCountLimit(1,id) - e1:SetTarget(s.tdtg) - e1:SetOperation(s.tdop) - c:RegisterEffect(e1) - --Special Summon this card from the GY, but banish it when it leaves the field - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_REMOVE) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY,EFFECT_FLAG2_CHECK_SIMULTANEOUS) - e2:SetCode(EVENT_CUSTOM+id) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - c:RegisterEffect(e2) - --Keep track of monsters being sent to the GY at the same time - local e3=Effect.CreateEffect(c) - e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) - e3:SetCode(EVENT_TO_GRAVE) - e3:SetRange(LOCATION_GRAVE) - e3:SetCondition(function() return not Duel.IsDamageStep() end) - e3:SetOperation(s.regop) - c:RegisterEffect(e3) - local e4=e3:Clone() - e4:SetCode(EVENT_CHAINING) - e4:SetOperation(function(e) e:GetHandler():ResetFlagEffect(id+100) end) - c:RegisterEffect(e4) - local e5=e4:Clone() - e5:SetCode(EVENT_CHAIN_SOLVED) - c:RegisterEffect(e5) - local e6=e4:Clone() - e6:SetCode(EVENT_BREAK_EFFECT) - c:RegisterEffect(e6) -end -s.listed_series={SET_DRACOTAIL} -function s.tdfilter(c,e) - return (c:IsSetCard(SET_DRACOTAIL) or c:IsOnField()) and c:IsFaceup() and c:IsAbleToDeck() and c:IsCanBeEffectTarget(e) -end -function s.rescon(sg,e,tp,mg) - local gy_sg,field_sg=sg:Split(Card.IsLocation,nil,LOCATION_GRAVE) - return #gy_sg==2 and #field_sg==1 and field_sg:GetFirst():IsType(gy_sg:GetBitwiseOr(Card.GetMainCardType)) -end -function s.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return false end - local g=Duel.GetMatchingGroup(s.tdfilter,tp,LOCATION_GRAVE|LOCATION_ONFIELD,LOCATION_ONFIELD,nil,e) - if chk==0 then return #g>=3 and aux.SelectUnselectGroup(g,e,tp,3,3,s.rescon,0) end - local tg=aux.SelectUnselectGroup(g,e,tp,3,3,s.rescon,1,tp,HINTMSG_TODECK) - Duel.SetTargetCard(tg) - Duel.SetOperationInfo(0,CATEGORY_TODECK,tg,3,tp,0) -end -function s.tdop(e,tp,eg,ep,ev,re,r,rp) - local tg=Duel.GetTargetCards(e) - if #tg==3 then - Duel.SendtoDeck(tg,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) - end -end -function s.regop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local ct=eg:FilterCount(Card.IsMonster,nil) - if ct==0 or eg:IsContains(c) then return end - if ct>=2 or c:HasFlagEffect(id+100) then - Duel.RaiseSingleEvent(c,EVENT_CUSTOM+id,re,r,rp,ep,ev) - end - local eff=Duel.GetChainInfo(0,CHAININFO_TRIGGERING_EFFECT) - if eff then - c:RegisterFlagEffect(id+100,RESET_EVENT|RESETS_STANDARD|RESET_CHAIN,0,1) - end -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 then - --Banish it when it leaves the field - local e1=Effect.CreateEffect(c) - e1:SetDescription(3300) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_LEAVE_FIELD_REDIRECT) - e1:SetValue(LOCATION_REMOVED) - e1:SetReset(RESET_EVENT|RESETS_REDIRECT) - c:RegisterEffect(e1,true) - end -end \ No newline at end of file diff --git a/pre-release/c101303038.lua b/pre-release/c101303038.lua deleted file mode 100644 index c6057f6b72..0000000000 --- a/pre-release/c101303038.lua +++ /dev/null @@ -1,86 +0,0 @@ ---ナイトウィング・プリースト ---Night Wing Priestess ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Synchro Summon procedure: 1 Tuner + 1+ non-Tuner monsters - Synchro.AddProcedure(c,nil,1,1,Synchro.NonTuner(nil),1,99) - --Set 1 "Assault Mode Activate" from your hand, Deck, or GY - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetCountLimit(1,id) - e1:SetTarget(s.settg) - e1:SetOperation(s.setop) - c:RegisterEffect(e1) - --Add to your hand, or Special Summon, 1 monster that mentions "Assault Mode Activate" from your Deck - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND+CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetCost(Cost.Discard()) - e2:SetTarget(s.thsptg) - e2:SetOperation(s.thspop) - c:RegisterEffect(e2) -end -s.listed_names={CARD_ASSAULT_MODE} -function s.setfilter(c) - return c:IsCode(CARD_ASSAULT_MODE) and c:IsSSetable() -end -function s.settg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.setfilter,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE,0,1,nil) end -end -function s.setop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) - local sc=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.setfilter),tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil):GetFirst() - if sc and Duel.SSet(tp,sc)>0 then - --It can be activated this turn - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_TRAP_ACT_IN_SET_TURN) - e1:SetReset(RESETS_STANDARD_PHASE_END) - sc:RegisterEffect(e1) - end -end -function s.thspfilter(c,e,tp,mzone_chk) - return c:ListsCode(CARD_ASSAULT_MODE) and c:IsMonster() and (c:IsAbleToHand() or (mzone_chk and c:IsCanBeSpecialSummoned(e,0,tp,false,false))) -end -function s.thsptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thspfilter,tp,LOCATION_DECK,0,1,nil,e,tp,Duel.GetLocationCount(tp,LOCATION_MZONE)>0) end - Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) - Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) -end -function s.thspop(e,tp,eg,ep,ev,re,r,rp) - local mzone_chk=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(id,3)) - local sc=Duel.SelectMatchingCard(tp,s.thspfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,mzone_chk):GetFirst() - aux.ToHandOrElse(sc,tp, - function() - return mzone_chk and sc:IsCanBeSpecialSummoned(e,0,tp,false,false) - end, - function() - Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP) - end, - aux.Stringid(id,4) - ) - local c=e:GetHandler() - --You cannot Special Summon from the Extra Deck for the rest of this turn, except Synchro Monsters - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,5)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsSynchroMonster() end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) - --"Clock Lizard" check - aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalType(TYPE_SYNCHRO) end) -end \ No newline at end of file diff --git a/pre-release/c101303039.lua b/pre-release/c101303039.lua deleted file mode 100644 index 8292183dbb..0000000000 --- a/pre-release/c101303039.lua +++ /dev/null @@ -1,75 +0,0 @@ ---調獄神ジュノーラ ---Junora the Power Patron of Tuning ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Synchro Summon procedure: 1 Tuner + 2 non-Tuner monsters (For this card's Synchro Summon, you can treat 1 monster in your center Main Monster Zone as a Tuner) - Synchro.AddProcedure(c,nil,1,1,Synchro.NonTuner(nil),2,2,s.extratunerfilter) - --Negate the effects of all face-up cards your opponent currently controls - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_DISABLE) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetCondition(function(e) return e:GetHandler():IsSynchroSummoned() end) - e1:SetTarget(s.distg) - e1:SetOperation(s.disop) - c:RegisterEffect(e1) - --Make all monsters your opponent currently controls in the same columns as your "Elvennotes" monsters unable to be used as material for a Fusion, Synchro, Xyz, or Link Summon until the end of this turn - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,id) - e2:SetTarget(s.efftg) - e2:SetOperation(s.effop) - e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) - c:RegisterEffect(e2) -end -s.listed_series={SET_ELVENNOTES} -function s.extratunerfilter(c,scard,sumtype,tp) - return c:IsSequence(2) and c:IsControler(tp) -end -function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,nil) end - local g=Duel.GetMatchingGroup(Card.IsNegatable,tp,0,LOCATION_ONFIELD,nil) - Duel.SetOperationInfo(0,CATEGORY_DISABLE,g,#g,tp,0) -end -function s.disop(e,tp,eg,ep,ev,re,r,rp) - local g=Duel.GetMatchingGroup(Card.IsNegatable,tp,0,LOCATION_ONFIELD,nil) - if #g==0 then return end - local c=e:GetHandler() - for tc in g:Iter() do - --Negate the effects of all face-up cards your opponent currently controls - tc:NegateEffects(c,nil,true) - end -end -function s.cannotmatfilter(c,tp) - return c:GetColumnGroup():IsExists(s.elvennotesfilter,1,nil,tp) -end -function s.elvennotesfilter(c,tp) - return c:IsSetCard(SET_ELVENNOTES) and c:IsMonster() and c:IsFaceup() and c:IsControler(tp) -end -function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.cannotmatfilter,tp,0,LOCATION_MZONE,1,nil,tp) end -end -function s.effop(e,tp,eg,ep,ev,re,r,rp,chk) - local g=Duel.GetMatchingGroup(s.cannotmatfilter,tp,0,LOCATION_MZONE,nil,tp) - if #g==0 then return end - local c=e:GetHandler() - for tc in g:Iter() do - Duel.HintSelection(tc) - --All monsters your opponent currently controls in the same columns as your "Elvennotes" monsters cannot be used as material for a Fusion, Synchro, Xyz, or Link Summon until the end of this turn - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_BE_MATERIAL) - e1:SetValue(aux.cannotmatfilter(SUMMON_TYPE_FUSION,SUMMON_TYPE_SYNCHRO,SUMMON_TYPE_XYZ,SUMMON_TYPE_LINK)) - e1:SetReset(RESETS_STANDARD_PHASE_END) - tc:RegisterEffect(e1) - end -end \ No newline at end of file diff --git a/pre-release/c101303040.lua b/pre-release/c101303040.lua deleted file mode 100644 index 960503aac9..0000000000 --- a/pre-release/c101303040.lua +++ /dev/null @@ -1,73 +0,0 @@ ---獄花の大燿聖ストリチア ---Elvennotes Seraphim Stlitzia ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Synchro Summon procedure: 1 Tuner + 1+ non-Tuner monsters - Synchro.AddProcedure(c,nil,1,1,Synchro.NonTuner(nil),1,99) - --This card's original ATK becomes 3000 while in the center Main Monster Zone - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e1:SetCode(EFFECT_SET_BASE_ATTACK) - e1:SetRange(LOCATION_MMZONE) - e1:SetCondition(function(e) return e:GetHandler():IsSequence(2) end) - e1:SetValue(3000) - c:RegisterEffect(e1) - --Special Summon 1 Level 6 or lower "Elvennotes" monster from your hand or GY, then you can decrease the Levels of all Level 4 or higher monsters currently on the field by 3 until the end of this turn - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_LVCHANGE) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,id) - e2:SetCondition(function() return Duel.IsMainPhase() end) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - e2:SetHintTiming(0,TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) - c:RegisterEffect(e2) -end -s.listed_series={SET_ELVENNOTES} -function s.spfilter(c,e,tp) - return c:IsLevelBelow(6) and c:IsSetCard(SET_ELVENNOTES) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_GRAVE,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_GRAVE) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_HAND|LOCATION_GRAVE,0,1,1,nil,e,tp) - if #g>0 and Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)>0 - and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsLevelAbove,4),tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) - and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then - local g=Duel.GetMatchingGroup(aux.FaceupFilter(Card.IsLevelAbove,4),tp,LOCATION_MZONE,LOCATION_MZONE,nil) - Duel.BreakEffect() - for tc in g:Iter() do - --Decrease the Levels of all Level 4 or higher monsters currently on the field by 3 until the end of this turn - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_UPDATE_LEVEL) - e1:SetValue(-3) - e1:SetReset(RESETS_STANDARD_PHASE_END) - tc:RegisterEffect(e1) - end - end - end - --You cannot Special Summon from the Extra Deck for the rest of this turn, except Synchro Monsters - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,2)) - e2:SetType(EFFECT_TYPE_FIELD) - e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e2:SetTargetRange(1,0) - e2:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsSynchroMonster() end) - e2:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e2,tp) -end \ No newline at end of file diff --git a/pre-release/c101303041.lua b/pre-release/c101303041.lua deleted file mode 100644 index 8c9367a18b..0000000000 --- a/pre-release/c101303041.lua +++ /dev/null @@ -1,86 +0,0 @@ ---黒き竜のエクレシア ---Ecclesia of the Black Dragon ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Synchro Summon procedure: 1 Tuner + 1+ non-Tuner monsters - Synchro.AddProcedure(c,nil,1,1,Synchro.NonTuner(nil),1,99) - --Banish this card (until the End Phase), and if you do, Special Summon 1 "Fallen of Albaz" or 1 Level 4 or lower monster that mentions it from your Deck or GY - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_REMOVE+CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_QUICK_O) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetRange(LOCATION_MZONE) - e1:SetCountLimit(1,{id,0}) - e1:SetCondition(function() return Duel.IsMainPhase() end) - e1:SetTarget(s.rmsptg) - e1:SetOperation(s.rmspop) - e1:SetHintTiming(0,TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) - c:RegisterEffect(e1) - --Shuffle both 1 Level 8 Fusion Monster in your GY or banishment and 1 card on the field, and this card into the Deck - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TODECK+CATEGORY_TOEXTRA) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.tdtg) - e2:SetOperation(s.tdop) - c:RegisterEffect(e2) -end -s.listed_names={CARD_ALBAZ} -function s.spfilter(c,e,tp) - return (c:IsCode(CARD_ALBAZ) or (c:IsLevelBelow(4) and c:ListsCode(CARD_ALBAZ))) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.rmsptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return c:IsAbleToRemove() and Duel.GetMZoneCount(tp,c)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_REMOVE,c,1,tp,0) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) -end -function s.rmspop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) and aux.RemoveUntil(c,nil,REASON_EFFECT,PHASE_END,id,e,tp,aux.DefaultFieldReturnOp) - and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end - end -end -function s.fustdfilter(c,e) - return c:IsLevel(8) and c:IsFusionMonster() and c:IsFaceup() and c:IsAbleToExtra() and c:IsCanBeEffectTarget(e) -end -function s.fieldtdfilter(c,e) - return c:IsAbleToDeck() and c:IsCanBeEffectTarget(e) -end -function s.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return false end - local c=e:GetHandler() - if chk==0 then return c:IsAbleToExtra() - and Duel.IsExistingMatchingCard(s.fustdfilter,tp,LOCATION_GRAVE|LOCATION_REMOVED,0,1,c,e) - and Duel.IsExistingMatchingCard(s.fieldtdfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil,e) end - local fusiong=Group.CreateGroup() - local fieldg=Group.CreateGroup() - repeat - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) - fusiong=Duel.SelectMatchingCard(tp,s.fustdfilter,tp,LOCATION_GRAVE|LOCATION_REMOVED,0,1,1,c,e) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) - fieldg=Duel.SelectMatchingCard(tp,s.fieldtdfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,true,nil,e) - until fieldg~=nil - local tg=fusiong:Merge(fieldg) - Duel.SetTargetCard(tg) - Duel.SetOperationInfo(0,CATEGORY_TODECK,tg+c,3,tp,0) -end -function s.tdop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local tg=Duel.GetTargetCards(e) - if c:IsRelateToEffect(e) and #tg==2 then - Duel.SendtoDeck(tg+c,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303042.lua b/pre-release/c101303042.lua deleted file mode 100644 index a19d2d3b10..0000000000 --- a/pre-release/c101303042.lua +++ /dev/null @@ -1,69 +0,0 @@ ---鎖縛竜ザレン ---Zaren the Chainbound Dragon ---Scripted by Hatter -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Synchro Summon procedure: 1 Tuner + 1+ Synchro Monsters - Synchro.AddProcedure(c,nil,1,1,aux.FilterBoolFunctionEx(Card.IsType,TYPE_SYNCHRO),1,99) - --Multiple Tuner check (Red Nova) - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_SINGLE) - e0:SetCode(EFFECT_MATERIAL_CHECK) - e0:SetValue(s.valcheck) - c:RegisterEffect(e0) - --If this card you control would be used as Synchro Material, you can treat it as a non-Tuner - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e1:SetCode(EFFECT_NONTUNER) - e1:SetRange(LOCATION_MZONE) - c:RegisterEffect(e1) - --Activate 1 of these effects - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_DISABLE+CATEGORY_DESTROY) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetCode(EVENT_CHAINING) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,id) - e2:SetCondition(function() return Duel.GetCurrentChain()>1 end) - e2:SetTarget(s.distg) - e2:SetOperation(s.disop) - c:RegisterEffect(e2) -end -function s.valcheck(e,c) - local g=c:GetMaterial() - if g:IsExists(Card.IsType,2,nil,TYPE_TUNER) then - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) - e1:SetCode(EFFECT_MULTIPLE_TUNERS) - e1:SetReset(RESET_EVENT|RESETS_STANDARD&~(RESET_TOFIELD)|RESET_PHASE|PHASE_END) - c:RegisterEffect(e1) - end -end -function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) - local b1=Duel.IsChainDisablable(ev) - local b2=Duel.IsChainDisablable(ev-1) - if chk==0 then return b1 or b2 end - local op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,1)}, - {b2,aux.Stringid(id,2)}) - local ch=ev-op+1 - e:SetLabel(ch) - local eff=Duel.GetChainInfo(ch,CHAININFO_TRIGGERING_EFFECT) - local rc=eff:GetHandler() - Duel.SetOperationInfo(0,CATEGORY_DISABLE,rc,1,tp,0) - if rc:IsDestructable() and rc:IsRelateToEffect(eff) then - Duel.SetOperationInfo(0,CATEGORY_DESTROY,rc,1,tp,0) - end -end -function s.disop(e,tp,eg,ep,ev,re,r,rp) - local ch=e:GetLabel() - local eff=Duel.GetChainInfo(ch,CHAININFO_TRIGGERING_EFFECT) - local rc=eff:GetHandler() - if Duel.NegateEffect(ch) and rc:IsRelateToEffect(eff) then - Duel.Destroy(rc,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303043.lua b/pre-release/c101303043.lua deleted file mode 100644 index 198bf01924..0000000000 --- a/pre-release/c101303043.lua +++ /dev/null @@ -1,71 +0,0 @@ ---K9-EX ”Ripper/M” ---K9-X "Ripper/Millennia" ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Xyz Summon procedure: 2 Level 9 monsters - Xyz.AddProcedure(c,nil,9,2) - --If this card attacks a Defense Position monster, inflict piercing battle damage to your opponent - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetCode(EFFECT_PIERCE) - c:RegisterEffect(e1) - --Shuffle up to 2 cards from your opponent's GY and/or banishment into the Deck - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_TODECK) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) - e2:SetCode(EVENT_SPSUMMON_SUCCESS) - e2:SetCountLimit(1,id) - e2:SetCondition(s.tdcon) - e2:SetTarget(s.tdtg) - e2:SetOperation(s.tdop) - c:RegisterEffect(e2) - --Negate a monster effect your opponent activates and destroy all cards on the field - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_DISABLE+CATEGORY_DESTROY) - e3:SetType(EFFECT_TYPE_QUICK_O) - e3:SetCode(EVENT_CHAINING) - e3:SetRange(LOCATION_MZONE) - e3:SetCountLimit(1,{id,1}) - e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return rp==1-tp and re:IsMonsterEffect() and Duel.IsChainDisablable(ev) end) - e3:SetCost(Cost.DetachFromSelf(2)) - e3:SetTarget(s.distg) - e3:SetOperation(s.disop) - c:RegisterEffect(e3) -end -s.listed_series={SET_K9} -function s.tdcon(e,tp,eg,ep,ev,re,r,rp) - return re and re:GetHandler():IsSetCard(SET_K9) and re:IsSpellTrapEffect() -end -function s.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_GRAVE|LOCATION_REMOVED) and chkc:IsControler(1-tp) and chkc:IsAbleToDeck() end - if chk==0 then return Duel.IsExistingTarget(Card.IsAbleToDeck,tp,0,LOCATION_GRAVE|LOCATION_REMOVED,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) - local g=Duel.SelectTarget(tp,Card.IsAbleToDeck,tp,0,LOCATION_GRAVE|LOCATION_REMOVED,1,2,nil) - Duel.SetOperationInfo(0,CATEGORY_TODECK,g,#g,tp,0) -end -function s.tdop(e,tp,eg,ep,ev,re,r,rp) - local tg=Duel.GetTargetCards(e) - if #tg>0 then - Duel.SendtoDeck(tg,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) - end -end -function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) - local g=Duel.GetFieldGroup(tp,LOCATION_ONFIELD,LOCATION_ONFIELD) - if chk==0 then return #g>0 end - Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,tp,0) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,#g,tp,0) -end -function s.disop(e,tp,eg,ep,ev,re,r,rp) - if Duel.NegateEffect(ev) then - local g=Duel.GetFieldGroup(tp,LOCATION_ONFIELD,LOCATION_ONFIELD) - if #g>0 then - Duel.BreakEffect() - Duel.Destroy(g,REASON_EFFECT) - end - end -end \ No newline at end of file diff --git a/pre-release/c101303044.lua b/pre-release/c101303044.lua deleted file mode 100644 index f6e565ab89..0000000000 --- a/pre-release/c101303044.lua +++ /dev/null @@ -1,82 +0,0 @@ ---エクソシスター・カルマエル ---Exosister Karmael ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Xyz Summon procedure: 2 Level 4 "Exosister" monsters - Xyz.AddProcedure(c,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_EXOSISTER),4,2) - --Apply a "during the End Phase of this turn, Set 1 "Exosister" Spell/Trap from your Deck, GY, or banishment" effect - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetCountLimit(1,id) - e1:SetCondition(function(e) return e:GetHandler():IsXyzSummoned() end) - e1:SetOperation(s.regop) - c:RegisterEffect(e1) - --Detach all materials from this card, and if you do, the activated effect becomes "Add 1 card from your opponent's GY to their hand" - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetCode(EVENT_CHAINING) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(s.chcon) - e2:SetTarget(s.chtg) - e2:SetOperation(s.chop) - c:RegisterEffect(e2) -end -s.listed_series={SET_EXOSISTER} -function s.regop(e,tp,eg,ep,ev,re,r,rp) - --During the End Phase of this turn, Set 1 "Exosister" Spell/Trap from your Deck, GY, or banishment - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) - e1:SetCode(EVENT_PHASE+PHASE_END) - e1:SetCountLimit(1) - e1:SetOperation(s.setop) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) -end -function s.setfilter(c) - return c:IsSetCard(SET_EXOSISTER) and c:IsSpellTrap() and c:IsSSetable() and (c:IsFaceup() or c:IsLocation(LOCATION_DECK)) -end -function s.setop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_CARD,0,id) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) - local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.setfilter),tp,LOCATION_DECK|LOCATION_GRAVE|LOCATION_REMOVED,0,1,1,nil) - if #g>0 then - Duel.SSet(tp,g) - end -end -function s.chcon(e,tp,eg,ep,ev,re,r,rp) - local rc=re:GetHandler() - return rp==1-tp and (re:IsMonsterEffect() or (rc:IsNormalSpellTrap() and re:IsHasType(EFFECT_TYPE_ACTIVATE))) -end -function s.chtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then - local c=e:GetHandler() - local mat_ct=c:GetOverlayCount() - return mat_ct>0 and c:CheckRemoveOverlayCard(tp,mat_ct,REASON_EFFECT) - and Duel.IsExistingMatchingCard(Card.IsAbleToHand,tp,LOCATION_GRAVE,0,1,nil) - end -end -function s.chop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local mg=c:GetOverlayGroup() - if c:IsRelateToEffect(e) and #mg>0 and Duel.SendtoGrave(mg,REASON_EFFECT)>0 then - local g=Group.CreateGroup() - Duel.ChangeTargetCard(ev,g) - Duel.ChangeChainOperation(ev,s.repop) - end -end -function s.repop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(Card.IsAbleToHand),tp,0,LOCATION_GRAVE,1,1,nil) - if #g>0 then - Duel.HintSelection(g) - Duel.SendtoHand(g,nil,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303045.lua b/pre-release/c101303045.lua deleted file mode 100644 index 74b44269ed..0000000000 --- a/pre-release/c101303045.lua +++ /dev/null @@ -1,77 +0,0 @@ ---ガンホー!スプリガンズ! ---Gung-ho! Springans! ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Xyz Summon procedure: 2+ Level 4 "Springans" monsters - Xyz.AddProcedure(c,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_SPRINGANS),4,2,nil,nil,Xyz.InfiniteMats) - --Special Summon 1 "Springans Captain Sargas" from your Deck or GY - local e1a=Effect.CreateEffect(c) - e1a:SetDescription(aux.Stringid(id,0)) - e1a:SetCategory(CATEGORY_SPECIAL_SUMMON) - e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1a:SetProperty(EFFECT_FLAG_DELAY) - e1a:SetCode(EVENT_TO_GRAVE) - e1a:SetCountLimit(1,id) - e1a:SetTarget(s.sptg) - e1a:SetOperation(s.spop) - c:RegisterEffect(e1a) - local e1b=e1a:Clone() - e1b:SetCode(EVENT_SPSUMMON_SUCCESS) - e1b:SetCondition(function(e) return e:GetHandler():IsXyzSummoned() end) - c:RegisterEffect(e1b) - --Add to your hand, or Special Summon, 1 "Springans" or "Therion" monster or "Fallen of Albaz" or monster that mentions it - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,id) - e2:SetCost(Cost.DetachFromSelf(2)) - e2:SetTarget(s.thsptg) - e2:SetOperation(s.thspop) - c:RegisterEffect(e2) -end -s.listed_names={CARD_ALBAZ,29601381} --"Springans Captain Sargas" -s.listed_series={SET_SPRINGANS,SET_THERION} -function s.spfilter(c,e,tp) - return c:IsCode(29601381) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) -end -function s.spop(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,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end -function s.thspfilter(c,e,tp,mmz_chk) - return (c:IsSetCard({SET_SPRINGANS,SET_THERION}) or (c:IsCode(CARD_ALBAZ) or c:ListsCode(CARD_ALBAZ))) and c:IsMonster() - and (c:IsAbleToHand() or (mmz_chk and c:IsCanBeSpecialSummoned(e,0,tp,false,false))) -end -function s.thsptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thspfilter,tp,LOCATION_DECK,0,1,nil,e,tp,Duel.GetLocationCount(tp,LOCATION_MZONE)>0) end - Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) - Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) -end -function s.thspop(e,tp,eg,ep,ev,re,r,rp) - local mmz_chk=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(id,2)) - local sc=Duel.SelectMatchingCard(tp,s.thspfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,mmz_chk):GetFirst() - if not sc then return end - aux.ToHandOrElse(sc,tp, - function() - return mmz_chk and sc:IsCanBeSpecialSummoned(e,0,tp,false,false) - end, - function() - return Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP) - end, - aux.Stringid(id,3) - ) -end \ No newline at end of file diff --git a/pre-release/c101303046.lua b/pre-release/c101303046.lua deleted file mode 100644 index 8867453c5c..0000000000 --- a/pre-release/c101303046.lua +++ /dev/null @@ -1,100 +0,0 @@ ---トポロジック・ブラスター・ドラゴン ---Topologic Blaster Dragon ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Link Summon procedure: 2+ Effect Monsters - Link.AddProcedure(c,aux.FilterBoolFunctionEx(Card.IsType,TYPE_EFFECT),2) - --You cannot Summon/Set monsters to any Extra Monster Zone this card points to - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_FIELD) - e0:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_CANNOT_DISABLE) - e0:SetCode(EFFECT_FORCE_MZONE) - e0:SetRange(LOCATION_MZONE) - e0:SetTargetRange(1,0) - e0:SetValue(function(e) return ~(e:GetHandler():GetLinkedZone()&ZONES_EMZ) end) - c:RegisterEffect(e0) - --Apply 1 of these effects - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TODECK+CATEGORY_REMOVE) - e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetRange(LOCATION_EMZONE) - e1:SetCondition(s.effcon) - e1:SetTarget(s.efftg) - e1:SetOperation(s.effop) - c:RegisterEffect(e1) -end -s.listed_name={id} -function s.effcon(e,tp,eg,ep,ev,re,r,rp) - if eg:IsContains(e:GetHandler()) then return false end - local linkg=Duel.GetMatchingGroup(Card.IsLinkMonster,tp,LOCATION_MZONE,LOCATION_MZONE,nil) - for lc in linkg:Iter() do - if aux.zptgroupcon(eg,nil,lc) then return true end - end - return false -end -function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - --Shuffle all other monsters on the field into the Deck - local b1=not Duel.HasFlagEffect(tp,id) - and Duel.IsExistingMatchingCard(Card.IsAbleToDeck,tp,LOCATION_MZONE,LOCATION_MZONE,1,c) - --Shuffle all Spells and Traps on the field into the Deck - local b2=not Duel.HasFlagEffect(tp,id+100) - and Duel.IsExistingMatchingCard(aux.AND(Card.IsSpellTrap,Card.IsAbleToDeck),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) - --Look at your opponent's Extra Deck and banish 1 card from it - local b3=not Duel.HasFlagEffect(tp,id+200) - and Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,0,LOCATION_EXTRA,1,nil) - if chk==0 then return (b1 or b2 or b3) end - if not Duel.HasFlagEffect(tp,id) then - local g=Duel.GetMatchingGroup(Card.IsAbleToDeck,tp,LOCATION_MZONE,LOCATION_MZONE,c) - Duel.SetPossibleOperationInfo(0,CATEGORY_TODECK,g,#g,tp,0) - end - if not Duel.HasFlagEffect(tp,id+100) then - local g=Duel.GetMatchingGroup(aux.AND(Card.IsSpellTrap,Card.IsAbleToDeck),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) - Duel.SetPossibleOperationInfo(0,CATEGORY_TODECK,g,#g,tp,0) - end - if not Duel.HasFlagEffect(tp,id+200) then - local g=Duel.GetMatchingGroup(Card.IsAbleToRemove,tp,0,LOCATION_EXTRA,nil,tp) - Duel.SetPossibleOperationInfo(0,CATEGORY_REMOVE,g,#g,tp,0) - end -end -function s.effop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local exc=c:IsRelateToEffect(e) and c or nil - local b1=not Duel.HasFlagEffect(tp,id) - and Duel.IsExistingMatchingCard(Card.IsAbleToDeck,tp,LOCATION_MZONE,LOCATION_MZONE,1,exc) - local b2=not Duel.HasFlagEffect(tp,id+100) - and Duel.IsExistingMatchingCard(aux.AND(Card.IsSpellTrap,Card.IsAbleToDeck),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) - local b3=not Duel.HasFlagEffect(tp,id+200) - and Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,0,LOCATION_EXTRA,1,nil) - if not (b1 or b2 or b3) then return end - local op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,1)}, - {b2,aux.Stringid(id,2)}, - {b3,aux.Stringid(id,3)}) - if op==1 then - --Shuffle all other monsters on the field into the Deck - Duel.RegisterFlagEffect(tp,id,RESET_PHASE|PHASE_END,0,1) - local g=Duel.GetMatchingGroup(Card.IsAbleToDeck,tp,LOCATION_MZONE,LOCATION_MZONE,exc) - Duel.SendtoDeck(g,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) - elseif op==2 then - --Shuffle all Spells and Traps on the field into the Deck - Duel.RegisterFlagEffect(tp,id+100,RESET_PHASE|PHASE_END,0,1) - local g=Duel.GetMatchingGroup(aux.AND(Card.IsSpellTrap,Card.IsAbleToDeck),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) - Duel.SendtoDeck(g,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) - elseif op==3 then - --Look at your opponent's Extra Deck and banish 1 card from it - Duel.RegisterFlagEffect(tp,id+200,RESET_PHASE|PHASE_END,0,1) - local g=Duel.GetFieldGroup(tp,0,LOCATION_EXTRA) - Duel.ConfirmCards(tp,g) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) - local sg=g:FilterSelect(tp,Card.IsAbleToRemove,1,1,nil) - if #sg>0 then - Duel.Remove(sg,POS_FACEUP,REASON_EFFECT) - end - Duel.ShuffleExtra(1-tp) - end -end \ No newline at end of file diff --git a/pre-release/c101303049.lua b/pre-release/c101303049.lua deleted file mode 100644 index 8a1842a31c..0000000000 --- a/pre-release/c101303049.lua +++ /dev/null @@ -1,113 +0,0 @@ ---絢嵐たる海霊ヴァルルーン ---Radiant Typhoon Varuroon, the Sea Spirit ---Scripted by Eerie Code -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Link Summon procedure: 2 "Radiant Typhoon" monsters - Link.AddProcedure(c,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_RADIANT_TYPHOON),2) - --Add 1 "Mystical Space Typhoon" from your Deck or GY to your hand - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetCountLimit(1,{id,0}) - e1:SetCondition(function(e) return e:GetHandler():IsLinkSummoned() end) - e1:SetTarget(s.thtg) - e1:SetOperation(s.thop) - c:RegisterEffect(e1) - --Place 2 face-up monsters on the field, including a "Radiant Typhoon" monster you control face-up in their owners' Spell & Trap Zones as Continuous Spells - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.monpltg) - e2:SetOperation(s.monplop) - c:RegisterEffect(e2) - --Place 1 "Radiant Typhoon" Continuous Trap from your Deck or GY face-up on your field - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,2)) - e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e3:SetProperty(EFFECT_FLAG_DELAY) - e3:SetCode(EVENT_CHAINING) - e3:SetRange(LOCATION_MZONE) - e3:SetCountLimit(1,{id,2}) - e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsSpellEffect() and re:IsActiveType(TYPE_QUICKPLAY) end) - e3:SetTarget(s.trappltg) - e3:SetOperation(s.trapplop) - c:RegisterEffect(e3) -end -s.listed_series={SET_RADIANT_TYPHOON} -s.listed_names={CARD_MYSTICAL_SPACE_TYPHOON} -function s.thfilter(c) - return c:IsCode(CARD_MYSTICAL_SPACE_TYPHOON) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.thfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end -function s.monplfilter(c,e) - return c:IsFaceup() and not c:IsForbidden() and c:IsCanBeEffectTarget(e) -end -function s.rescon(sg,e,tp) - local your_g,opp_g=sg:Split(Card.IsOwner,nil,tp) - return #sg==2 and #your_g>0 and your_g:IsExists(Card.IsSetCard,1,nil,SET_RADIANT_TYPHOON) - and Duel.GetLocationCount(tp,LOCATION_SZONE)>=#your_g - and Duel.GetLocationCount(1-tp,LOCATION_SZONE)>=#opp_g -end -function s.monpltg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return false end - local g=Duel.GetMatchingGroup(s.monplfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil,e) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 - and aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,0) end - local tg=aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,1,tp,HINTMSG_TOFIELD) - Duel.SetTargetCard(tg) -end -function s.monplop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local tg=Duel.GetTargetCards(e) - for tc in tg:Iter() do - if not tc:IsImmuneToEffect(e) then - local owner=tc:GetOwner() - if Duel.GetLocationCount(owner,LOCATION_SZONE)<=0 then - Duel.SendtoGrave(tc,REASON_RULE,nil,PLAYER_NONE) - elseif Duel.MoveToField(tc,tp,owner,LOCATION_SZONE,POS_FACEUP,tc:IsMonsterCard()) then - --Treated as a Continuous Spell - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_CHANGE_TYPE) - e1:SetValue(TYPE_SPELL|TYPE_CONTINUOUS) - e1:SetReset(RESET_EVENT|(RESETS_STANDARD&~RESET_TURN_SET)) - tc:RegisterEffect(e1) - end - end - end -end -function s.trapplfilter(c,tp) - return c:IsSetCard(SET_RADIANT_TYPHOON) and c:IsContinuousTrap() and not c:IsForbidden() and c:CheckUniqueOnField(tp) -end -function s.trappltg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 - and Duel.IsExistingMatchingCard(s.trapplfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil,tp) end -end -function s.trapplop(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) - local sc=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.trapplfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil,tp):GetFirst() - if sc then - Duel.MoveToField(sc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) - end -end \ No newline at end of file diff --git a/pre-release/c101303050.lua b/pre-release/c101303050.lua deleted file mode 100644 index 172a373b27..0000000000 --- a/pre-release/c101303050.lua +++ /dev/null @@ -1,92 +0,0 @@ ---空牙団の船匠 キール ---Keel, Shipwright Fur Hire ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Link Summon procedure: 2 monsters with different types - Link.AddProcedure(c,nil,2,nil,s.matfiltercheck) - --Set 1 Spell/Trap "Fur Hire" or 1 "Fandora, the Flying Furtress" from your Deck - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetCountLimit(1,id) - e1:SetCondition(function(e) return e:GetHandler():IsLinkSummoned() end) - e1:SetTarget(s.settg) - e1:SetOperation(s.setop) - c:RegisterEffect(e1) - --Banish this card from your GY, and if you do, Special Summon 1 monster "Fur Hire" from your hand - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_REMOVE+CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(function(e,tp) return Duel.IsTurnPlayer(1-tp) end) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e2) -end -s.listed_names={64400161} --"Fandora, the Flying Furtress" -s.listed_series={SET_FUR_HIRE} -function s.matfiltercheck(g,lc,sumtype,tp) - return g:CheckDifferentPropertyBinary(Card.GetRace,lc,sumtype,tp) -end -function s.setfilter(c) - return ((c:IsSetCard(SET_FUR_HIRE) and c:IsSpellTrap()) or c:IsCode(64400161)) and c:IsSSetable() -end -function s.settg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.setfilter,tp,LOCATION_DECK,0,1,nil) end -end -function s.setop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) - local g=Duel.SelectMatchingCard(tp,s.setfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SSet(tp,g) - end - --You cannot Special Summon for the rest of this turn, except monsters "Fur Hire" - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return not c:IsSetCard(SET_FUR_HIRE) end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) -end -function s.spfilter(c,e,tp) - return c:IsSetCard(SET_FUR_HIRE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return c:IsAbleToRemove() and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_REMOVE,c,1,tp,0) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT)>0 and c:IsLocation(LOCATION_REMOVED) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g1=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND,0,1,1,nil,e,tp) - if #g1>0 and Duel.SpecialSummon(g1,0,tp,tp,false,false,POS_FACEUP)>0 - and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND,0,1,nil,e,tp) then - local atkg=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,nil):GetMaxGroup(Card.GetBaseAttack) - if not atkg:IsExists(Card.IsControler,1,nil,1-tp) then return end - if Duel.SelectYesNo(tp,aux.Stringid(id,3)) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g2=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND,0,1,1,nil,e,tp) - if #g2>0 then - Duel.BreakEffect() - Duel.SpecialSummon(g2,0,tp,tp,false,false,POS_FACEUP) - end - end - end - end -end \ No newline at end of file diff --git a/pre-release/c101303051.lua b/pre-release/c101303051.lua deleted file mode 100644 index d2ef6f5506..0000000000 --- a/pre-release/c101303051.lua +++ /dev/null @@ -1,70 +0,0 @@ ---R-ACEアビトレイター ---Rescue-ACE Arbitrator ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Link Summon procedure: 2+ FIRE monsters - Link.AddProcedure(c,aux.FilterBoolFunctionEx(Card.IsAttribute,ATTRIBUTE_FIRE),2) - --You can only Special Summon "Rescue-ACE Arbitrator(s)" once per turn - c:SetSPSummonOnce(id) - --Add 1 "Rescue-ACE Hydrant" or "Rescue-ACE HQ" from your Deck or GY to your hand - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetCondition(function(e) return e:GetHandler():IsLinkSummoned() end) - e1:SetTarget(s.thtg) - e1:SetOperation(s.thop) - c:RegisterEffect(e1) - --Destroy 1 card your opponent controls - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_DESTROY) - e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) - e2:SetCode(EVENT_CHAINING) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(2,id) - e2:SetCondition(s.descon) - e2:SetTarget(s.destg) - e2:SetOperation(s.desop) - c:RegisterEffect(e2) -end -s.listed_names={id,CARD_R_ACE_HYDRANT,63899465} --"Rescue-ACE HQ" -s.listed_series={SET_RESCUE_ACE} -function s.thfilter(c) - return c:IsCode(CARD_R_ACE_HYDRANT,63899465) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.thfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end -function s.descon(e,tp,eg,ep,ev,re,r,rp) - local rc=re:GetHandler() - return rp==tp and re:IsSpellTrapEffect() and re:IsHasType(EFFECT_TYPE_ACTIVATE) and rc:IsSetCard(SET_RESCUE_ACE) - and (rc:IsQuickPlaySpell() or rc:IsNormalTrap()) -end -function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsOnField() and chkc:IsControler(1-tp) end - if chk==0 then return Duel.IsExistingTarget(nil,tp,0,LOCATION_ONFIELD,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local g=Duel.SelectTarget(tp,nil,tp,0,LOCATION_ONFIELD,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) -end -function s.desop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) then - Duel.Destroy(tc,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303053.lua b/pre-release/c101303053.lua deleted file mode 100644 index 40df14d555..0000000000 --- a/pre-release/c101303053.lua +++ /dev/null @@ -1,96 +0,0 @@ ---マグネット・ボンディング ---Magnet Bonding ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Activate 1 of these effects (but you can only use each effect of "Magnet Bonding" once per turn) - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCondition(function() return Duel.IsMainPhase() end) - e1:SetTarget(s.efftg) - e1:SetOperation(s.effop) - e1:SetHintTiming(0,TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) - c:RegisterEffect(e1) -end -s.listed_names={44839512} --"Conduction Warrior Linear Magnum ±" -s.listed_series={SET_MAGNET_WARRIOR,SET_MAGNA_WARRIOR} -function s.magnetthfilter(c) - return (c:IsCode(44839512) or (c:IsLevelBelow(4) and c:IsSetCard(SET_MAGNET_WARRIOR))) and c:IsAbleToHand() -end -function s.magnathfilter(c) - return c:IsLevel(8) and c:IsSetCard(SET_MAGNA_WARRIOR) and c:IsAbleToHand() -end -function s.fextrafilter(c) - return c:IsRace(RACE_ROCK) and c:IsFaceup() and c:IsAbleToDeck() -end -function s.fextra(e,tp,mg) - return Duel.GetMatchingGroup(s.fextrafilter,tp,LOCATION_GRAVE|LOCATION_REMOVED,0,nil) -end -function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) - --Add 1 "Conduction Warrior Linear Magnum ±" or 1 Level 4 or lower "Magnet Warrior" monster from your Deck to your hand - local b1=not Duel.HasFlagEffect(tp,id) - and Duel.IsExistingMatchingCard(s.magnetthfilter,tp,LOCATION_DECK,0,1,nil) - --Add 1 Level 8 "Magna Warrior" monster from your Deck to your hand - local b2=not Duel.HasFlagEffect(tp,id+100) - and Duel.IsExistingMatchingCard(s.magnathfilter,tp,LOCATION_DECK,0,1,nil) - --Fusion Summon 1 Rock Fusion Monster from your Extra Deck, by shuffling Rock monsters from your hand, field, GY, and/or banishment into the Deck - local fusion_params={ - fusfilter=function(c) return c:IsRace(RACE_ROCK) end, - matfilter=function(c) return c:IsRace(RACE_ROCK) and c:IsAbleToDeck() end, - extrafil=s.fextra, - extraop=Fusion.ShuffleMaterial - } - local b3=not Duel.HasFlagEffect(tp,id+200) - and Fusion.SummonEffTG(fusion_params)(e,tp,eg,ep,ev,re,r,rp,0) - if chk==0 then return b1 or b2 or b3 end - local op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,1)}, - {b2,aux.Stringid(id,2)}, - {b3,aux.Stringid(id,3)}) - e:SetLabel(op) - if op==1 then - e:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - Duel.RegisterFlagEffect(tp,id,RESET_PHASE|PHASE_END,0,1) - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) - elseif op==2 then - e:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - Duel.RegisterFlagEffect(tp,id+100,RESET_PHASE|PHASE_END,0,1) - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) - elseif op==3 then - e:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON+CATEGORY_TODECK) - Duel.RegisterFlagEffect(tp,id+200,RESET_PHASE|PHASE_END,0,1) - Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,1,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_GRAVE|LOCATION_REMOVED) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) - end -end -function s.effop(e,tp,eg,ep,ev,re,r,rp) - local op=e:GetLabel() - if op==1 then - --Add 1 "Conduction Warrior Linear Magnum ±" or 1 Level 4 or lower "Magnet Warrior" monster from your Deck to your hand - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.magnetthfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end - elseif op==2 then - --Add 1 Level 8 "Magna Warrior" monster from your Deck to your hand - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.magnathfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end - elseif op==3 then - --Fusion Summon 1 Rock Fusion Monster from your Extra Deck, by shuffling Rock monsters from your hand, field, GY, and/or banishment into the Deck - local fusion_params={ - fusfilter=function(c) return c:IsRace(RACE_ROCK) end, - matfilter=function(c) return c:IsRace(RACE_ROCK) and c:IsAbleToDeck() end, - extrafil=s.fextra, - extraop=Fusion.ShuffleMaterial - } - Fusion.SummonEffOP(fusion_params)(e,tp,eg,ep,ev,re,r,rp) - end -end \ No newline at end of file diff --git a/pre-release/c101303054.lua b/pre-release/c101303054.lua deleted file mode 100644 index 1fefef03cc..0000000000 --- a/pre-release/c101303054.lua +++ /dev/null @@ -1,81 +0,0 @@ ---決闘進化-バスター・ゾーン ---Duel Evolution - Assault Zone ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --When this card is activated: You can add 1 monster that mentions "Assault Mode Activate" from your Deck or GY to your hand - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) - e1:SetTarget(s.target) - e1:SetOperation(s.activate) - c:RegisterEffect(e1) - --"/Assault Mode" monsters cannot be destroyed by battle or your opponent's card effects during the turn they are Special Summoned - local e2a=Effect.CreateEffect(c) - e2a:SetType(EFFECT_TYPE_FIELD) - e2a:SetCode(EFFECT_INDESTRUCTABLE_BATTLE) - e2a:SetRange(LOCATION_FZONE) - e2a:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) - e2a:SetTarget(function(e,c) return c:IsSetCard(SET_ASSAULT_MODE) and c:IsStatus(STATUS_SPSUMMON_TURN) end) - e2a:SetValue(1) - c:RegisterEffect(e2a) - local e2b=e2a:Clone() - e2b:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) - e2b:SetValue(aux.indoval) - c:RegisterEffect(e2b) - --Apply an "once this turn, you can activate "Assault Mode Activate" by Tributing a Synchro Monster in the Extra Deck" effect - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetType(EFFECT_TYPE_IGNITION) - e3:SetRange(LOCATION_FZONE) - e3:SetCost(Cost.PayLP(2000)) - e3:SetCountLimit(1,{id,1}) - e3:SetOperation(s.effop) - c:RegisterEffect(e3) -end -s.listed_names={CARD_ASSAULT_MODE} -s.listed_series={SET_ASSAULT_MODE} -function s.thfilter(c) - return c:IsMonster() and c:ListsCode(CARD_ASSAULT_MODE) and c:IsAbleToHand() -end -function s.target(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return true end - Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) -end -function s.activate(e,tp,eg,ep,ev,re,r,rp) - local g=Duel.GetMatchingGroup(aux.NecroValleyFilter(s.thfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,nil) - if #g>0 and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local sg=g:Select(tp,1,1,nil) - Duel.SendtoHand(sg,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,sg) - end -end -function s.effop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - aux.RegisterClientHint(c,nil,tp,1,0,aux.Stringid(id,3)) - --Once this turn, you can activate "Assault Mode Activate" by Tributing a Synchro Monster in the Extra Deck - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE+EFFECT_FLAG_IGNORE_IMMUNE) - e1:SetCode(EFFECT_EXTRA_RELEASE_NONSUM) - e1:SetTargetRange(LOCATION_EXTRA,0) - e1:SetCondition(function(e) return not Duel.HasFlagEffect(e:GetHandlerPlayer(),id) end) - e1:SetValue(s.relval) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) - --Manually handling the OPT of the above effect - local e2=Effect.CreateEffect(c) - e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) - e2:SetCode(EVENT_RELEASE) - e2:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return s.relval(e,re,r) and eg:IsExists(Card.IsPreviousLocation,1,nil,LOCATION_EXTRA) end) - e2:SetOperation(function(e,tp) Duel.RegisterFlagEffect(tp,id,RESET_PHASE|PHASE_END,0,1) end) - e2:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e2,tp) -end -function s.relval(e,re,r,rp) - return re and re:IsActivated() and (r&REASON_COST)>0 and re:GetHandler():IsCode(CARD_ASSAULT_MODE) -end \ No newline at end of file diff --git a/pre-release/c101303055.lua b/pre-release/c101303055.lua deleted file mode 100644 index 1eb37a4b95..0000000000 --- a/pre-release/c101303055.lua +++ /dev/null @@ -1,73 +0,0 @@ ---終刻変転 ---DoomZ Changer ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Destroy 1 "DoomZ" card in your hand, Deck, or face-up field, except "DoomZ Changer" - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_DESTROY) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id) - e1:SetTarget(s.destg) - e1:SetOperation(s.desop) - c:RegisterEffect(e1) - --Add 1 "DoomZ" card from your GY to your hand, except "DoomZ Changer", then you can Special Summon 1 "DoomZ" monster from your hand - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY) - e2:SetCode(EVENT_DESTROYED) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return r&REASON_EFFECT>0 end) - e2:SetTarget(s.thsptg) - e2:SetOperation(s.thspop) - c:RegisterEffect(e2) -end -s.listed_names={id} -s.listed_series={SET_DOOMZ} -function s.desfilter(c) - return c:IsSetCard(SET_DOOMZ) and (c:IsFaceup() or not c:IsOnField()) and not c:IsCode(id) -end -function s.destg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.desfilter,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_ONFIELD,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_ONFIELD) -end -function s.desop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local sc=Duel.SelectMatchingCard(tp,s.desfilter,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_ONFIELD,0,1,1,nil):GetFirst() - if sc then - if sc:IsOnField() then Duel.HintSelection(sc) end - Duel.Destroy(sc,REASON_EFFECT) - end -end -function s.thfilter(c) - return c:IsSetCard(SET_DOOMZ) and c:IsAbleToHand() and not c:IsCode(id) -end -function s.thsptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_GRAVE,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_GRAVE) - Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND) -end -function s.spfilter(c,e,tp) - return c:IsSetCard(SET_DOOMZ) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.thspop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local sc=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_GRAVE,0,1,1,nil):GetFirst() - if not sc then return end - Duel.HintSelection(sc) - if Duel.SendtoHand(sc,nil,REASON_EFFECT)>0 and sc:IsLocation(LOCATION_HAND) - and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then - Duel.ShuffleHand(tp) - local g=Duel.GetMatchingGroup(s.spfilter,tp,LOCATION_HAND,0,nil,e,tp) - if #g>0 and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local sg=g:Select(tp,1,1,nil) - Duel.BreakEffect() - Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP) - end - end -end \ No newline at end of file diff --git a/pre-release/c101303056.lua b/pre-release/c101303056.lua deleted file mode 100644 index e1b67cdbeb..0000000000 --- a/pre-release/c101303056.lua +++ /dev/null @@ -1,70 +0,0 @@ ---エルフェンノーツ~廻郷のパラレリズム~ ---Elvennotes ~Homecoming Parallelism~ ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Activate - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_ACTIVATE) - e0:SetCode(EVENT_FREE_CHAIN) - c:RegisterEffect(e0) - --The monster in your center Main Monster Zone cannot be destroyed by card effects - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE) - e1:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) - e1:SetRange(LOCATION_SZONE) - e1:SetTargetRange(LOCATION_MZONE,0) - e1:SetTarget(function(e,c) return c:IsSequence(2) end) - e1:SetValue(1) - c:RegisterEffect(e1) - --Special Summon 1 "Elvennotes" monster with a different original Attribute from your Deck in Defense Position - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_SZONE) - e2:SetCountLimit(1,id) - e2:SetCost(s.spcost) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - c:RegisterEffect(e2) -end -s.listed_series={SET_ELVENNOTES} -function s.spcostfilter(c,e,tp) - return c:IsMonster() and c:IsAbleToGraveAsCost() and Duel.GetMZoneCount(tp,c)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp,c:GetOriginalAttribute()) -end -function s.spfilter(c,e,tp,attr) - return c:IsSetCard(SET_ELVENNOTES) and not c:IsOriginalAttribute(attr) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE) -end -function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.spcostfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,nil,e,tp) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local sc=Duel.SelectMatchingCard(tp,s.spcostfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,1,nil,e,tp):GetFirst() - e:SetLabel(sc:GetOriginalAttribute()) - Duel.SendtoGrave(sc,REASON_COST) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chk==0 then return true end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,e:GetLabel()) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP_DEFENSE) - end - end - --You cannot Special Summon from the Extra Deck for the rest of this turn, except Synchro Monsters - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetDescription(aux.Stringid(id,1)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsSynchroMonster() end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) -end \ No newline at end of file diff --git a/pre-release/c101303057.lua b/pre-release/c101303057.lua deleted file mode 100644 index 06df9d6e33..0000000000 --- a/pre-release/c101303057.lua +++ /dev/null @@ -1,53 +0,0 @@ ---エルフェンノーツ~再邂のテルチェット~ ---Elvennotes ~Reunion Tercet~ ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Activate - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_ACTIVATE) - e0:SetCode(EVENT_FREE_CHAIN) - c:RegisterEffect(e0) - --Your opponent cannot target the monster in your center Main Monster Zone with card effects - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE) - e1:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET) - e1:SetRange(LOCATION_SZONE) - e1:SetTargetRange(LOCATION_MZONE,0) - e1:SetTarget(function(e,c) return c:IsSequence(2) end) - e1:SetValue(aux.tgoval) - c:RegisterEffect(e1) - --● FIRE/EARTH: If your Synchro Monster attacks a Defense Position monster, inflict piercing battle damage to your opponent - local e2=Effect.CreateEffect(c) - e2:SetType(EFFECT_TYPE_FIELD) - e2:SetCode(EFFECT_PIERCE) - e2:SetRange(LOCATION_SZONE) - e2:SetTargetRange(LOCATION_MZONE,0) - e2:SetTarget(function(e,c) return c:IsSynchroMonster() end) - e2:SetCondition(s.effcon) - e2:SetLabel(ATTRIBUTE_FIRE|ATTRIBUTE_EARTH) - c:RegisterEffect(e2) - --● WATER/WIND: Other face-up Spells/Traps you control cannot be destroyed by your opponent's card effects - local e3=e2:Clone() - e3:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) - e3:SetTargetRange(LOCATION_ONFIELD,0) - e3:SetTarget(function(e,c) return c:IsSpellTrap() and c~=e:GetHandler() end) - e3:SetValue(aux.indoval) - e3:SetLabel(ATTRIBUTE_WATER|ATTRIBUTE_WIND) - c:RegisterEffect(e3) - --● LIGHT/DARK: You take no battle damage - local e4=e2:Clone() - e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET) - e4:SetCode(EFFECT_AVOID_BATTLE_DAMAGE) - e4:SetTargetRange(1,0) - e4:SetTarget(aux.TRUE) - e4:SetLabel(ATTRIBUTE_LIGHT|ATTRIBUTE_DARK) - c:RegisterEffect(e4) -end -function s.effconfilter(c,attr) - return c:IsSequence(2) and c:IsAttribute(attr) and c:IsFaceup() -end -function s.effcon(e) - return Duel.IsExistingMatchingCard(s.effconfilter,e:GetHandlerPlayer(),LOCATION_MMZONE,0,1,nil,e:GetLabel()) -end \ No newline at end of file diff --git a/pre-release/c101303058.lua b/pre-release/c101303058.lua deleted file mode 100644 index fb9b7eeba4..0000000000 --- a/pre-release/c101303058.lua +++ /dev/null @@ -1,72 +0,0 @@ ---開闢なる予幻視 ---Theorealize Liberation ---Scripted by The Razgriz -local s,id=GetID() -function s.initial_effect(c) - --Add to your hand, or Special Summon, 1 monster from your Deck with 300 ATK/200 DEF - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id) - e1:SetCondition(function(e,tp) return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsCode,CARD_MEDIUS_THE_PURE),tp,LOCATION_ONFIELD,0,1,nil) end) - e1:SetTarget(s.thsptg) - e1:SetOperation(s.thspop) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) - --Treat 1 face-up monster you control as a Tuner this turn - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,{id,1}) - e2:SetCost(Cost.SelfBanish) - e2:SetTarget(s.tunertg) - e2:SetOperation(s.tunerop) - c:RegisterEffect(e2) -end -s.listed_names={CARD_MEDIUS_THE_PURE} -function s.thspfilter(c,e,tp,sp_chk) - return c:IsAttack(300) and c:IsDefense(200) - and (c:IsAbleToHand() or (sp_chk and c:IsCanBeSpecialSummoned(e,0,tp,false,false))) -end -function s.thsptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then - local sp_chk=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - return Duel.IsExistingMatchingCard(s.thspfilter,tp,LOCATION_DECK,0,1,nil,e,tp,sp_chk) - end - Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) - Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) -end -function s.thspop(e,tp,eg,ep,ev,re,r,rp) - local sp_chk=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(id,2)) - local sc=Duel.SelectMatchingCard(tp,s.thspfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,sp_chk):GetFirst() - if not sc then return end - aux.ToHandOrElse(sc,tp, - function() return sp_chk and sc:IsCanBeSpecialSummoned(e,0,tp,false,false) end, - function() Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP) end, - aux.Stringid(id,3) - ) -end -function s.tunertg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and not chkc:IsType(TYPE_TUNER) and chkc:IsFaceup() end - if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(aux.NOT(Card.IsType),TYPE_TUNER),tp,LOCATION_MZONE,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) - Duel.SelectTarget(tp,aux.FaceupFilter(aux.NOT(Card.IsType),TYPE_TUNER),tp,LOCATION_MZONE,0,1,1,nil) -end -function s.tunerop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and tc:IsFaceup() then - --It is treated as a Tuner this turn - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_ADD_TYPE) - e1:SetValue(TYPE_TUNER) - e1:SetReset(RESETS_STANDARD_PHASE_END) - tc:RegisterEffect(e1) - end -end \ No newline at end of file diff --git a/pre-release/c101303059.lua b/pre-release/c101303059.lua deleted file mode 100644 index da75a04c5a..0000000000 --- a/pre-release/c101303059.lua +++ /dev/null @@ -1,37 +0,0 @@ ---スローン・オブ・デーモンズ ---Throne of Archfiends ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - Ritual.AddProcGreater({handler=c, - filter=s.ritualmonsterfilter, - location=LOCATION_HAND|LOCATION_GRAVE|LOCATION_EXTRA|LOCATION_REMOVED}) - --Add this card from your GY or banishment to your hand - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,1)) - e1:SetCategory(CATEGORY_TOHAND) - e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e1:SetCode(EVENT_PHASE+PHASE_STANDBY) - e1:SetRange(LOCATION_GRAVE|LOCATION_REMOVED) - e1:SetCountLimit(1,id) - e1:SetCondition(function(e,tp) return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsCode,101303031),tp,LOCATION_EXTRA,0,1,nil) end) - e1:SetTarget(s.thtg) - e1:SetOperation(s.thop) - c:RegisterEffect(e1) -end -s.listed_names={101303031} --"Doom Emperor Archfiend" -s.listed_series={SET_ARCHFIEND} -function s.ritualmonsterfilter(c) - return c:IsSetCard(SET_ARCHFIEND) and c:IsRitualMonster() and (c:IsFaceup() or c:IsLocation(LOCATION_HAND)) -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return c:IsAbleToHand() end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,c,1,tp,0) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if c:IsRelateToEffect(e) then - Duel.SendtoHand(c,nil,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303060.lua b/pre-release/c101303060.lua deleted file mode 100644 index 27956a0b26..0000000000 --- a/pre-release/c101303060.lua +++ /dev/null @@ -1,78 +0,0 @@ ---デーモンの盤上遊戯 ---Archfiend's Strategy Game ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Activate - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_ACTIVATE) - e0:SetCode(EVENT_FREE_CHAIN) - c:RegisterEffect(e0) - --Fiend monsters in the Extra Monster Zone gain 1000 ATK - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetCode(EFFECT_UPDATE_ATTACK) - e1:SetRange(LOCATION_FZONE) - e1:SetTargetRange(LOCATION_EMZONE,LOCATION_EMZONE) - e1:SetTarget(function(e,c) return c:IsRace(RACE_FIEND) end) - e1:SetValue(1000) - c:RegisterEffect(e1) - --Activate 1 of these effects - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_FZONE) - e2:SetCountLimit(1,id) - e2:SetTarget(s.efftg) - e2:SetOperation(s.effop) - c:RegisterEffect(e2) -end -s.listed_series={SET_ARCHFIEND} -function s.costfilter(c) - return (c:IsRace(RACE_FIEND) or c:IsSetCard(SET_ARCHFIEND)) and c:IsAbleToRemoveAsCost() -end -function s.thfilter(c) - return c:IsSetCard(SET_ARCHFIEND) and not c:IsFieldSpell() and c:IsAbleToHand() -end -function s.tedfilter(c) - return c:IsSetCard(SET_ARCHFIEND) and c:IsPendulumMonster() -end -function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) - local b1=Duel.IsExistingMatchingCard(s.costfilter,tp,LOCATION_HAND|LOCATION_GRAVE,0,1,nil) - and Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) - local b2=Duel.IsExistingMatchingCard(s.tedfilter,tp,LOCATION_DECK,0,1,nil) - if chk==0 then return b1 or b2 end - local op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,1)}, - {b2,aux.Stringid(id,2)}) - e:SetLabel(op) - if op==1 then - e:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) - local g=Duel.SelectMatchingCard(tp,s.costfilter,tp,LOCATION_HAND|LOCATION_GRAVE,0,1,1,nil) - Duel.Remove(g,POS_FACEUP,REASON_COST) - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) - elseif op==2 then - e:SetCategory(CATEGORY_TOEXTRA) - Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,nil,1,tp,LOCATION_DECK) - end -end -function s.effop(e,tp,eg,ep,ev,re,r,rp) - local op=e:GetLabel() - if op==1 then - --Add 1 "Archfiend" card from your Deck to your hand, except a Field Spell - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end - elseif op==2 then - --Add 1 "Archfiend" Pendulum Monster from your Deck to your Extra Deck face-up - Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(id,3)) - local g=Duel.SelectMatchingCard(tp,s.tedfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoExtraP(g,tp,REASON_EFFECT) - end - end -end \ No newline at end of file diff --git a/pre-release/c101303061.lua b/pre-release/c101303061.lua deleted file mode 100644 index d86590cfda..0000000000 --- a/pre-release/c101303061.lua +++ /dev/null @@ -1,85 +0,0 @@ ---飛竜戦艇-ファンドラ ---Fandora, the Fearsome Flying Furtress ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Activate - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_ACTIVATE) - e0:SetCode(EVENT_FREE_CHAIN) - c:RegisterEffect(e0) - --Monsters "Fur Hire" you control gain 300 ATK for each monster "Fur Hire" you control with different names - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetCode(EFFECT_UPDATE_ATTACK) - e1:SetRange(LOCATION_FZONE) - e1:SetTargetRange(LOCATION_MZONE,0) - e1:SetTarget(function(e,c) return c:IsSetCard(SET_FUR_HIRE) end) - e1:SetValue(function(e,c) return 300*Duel.GetMatchingGroup(aux.FaceupFilter(Card.IsSetCard,SET_FUR_HIRE),e:GetHandlerPlayer(),LOCATION_MZONE,0,nil):GetClassCount(Card.GetCode) end) - c:RegisterEffect(e1) - --Add 1 monster "Fur Hire" from your Deck to your hand, then discard 1 card - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_HANDES) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_FZONE) - e2:SetCountLimit(1,id) - e2:SetTarget(s.thtg) - e2:SetOperation(s.thop) - c:RegisterEffect(e2) - --Special Summon 1 monster "Fur Hire" from your Deck - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_SPECIAL_SUMMON) - e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e3:SetProperty(EFFECT_FLAG_DELAY) - e3:SetCode(EVENT_DESTROYED) - e3:SetRange(LOCATION_FZONE) - e3:SetCountLimit(1,{id,1}) - e3:SetCondition(s.spcon) - e3:SetTarget(s.sptg) - e3:SetOperation(s.spop) - c:RegisterEffect(e3) -end -s.listed_series={SET_FUR_HIRE} -function s.thfilter(c) - return c:IsSetCard(SET_FUR_HIRE) and c:IsMonster() and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) - Duel.SetOperationInfo(0,CATEGORY_HANDES,nil,1,tp,1) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 and Duel.SendtoHand(g,nil,REASON_EFFECT)>0 then - Duel.ConfirmCards(1-tp,g) - Duel.ShuffleHand(tp) - Duel.BreakEffect() - Duel.DiscardHand(tp,nil,1,1,REASON_EFFECT|REASON_DISCARD,nil) - end -end -function s.spconfilter(c,tp) - return c:IsPreviousSetCard(SET_FUR_HIRE) and c:IsReason(REASON_EFFECT) and c:IsPreviousPosition(POS_FACEUP) - and c:IsPreviousLocation(LOCATION_MZONE) and c:IsPreviousControler(tp) and c:IsReasonPlayer(1-tp) -end -function s.spcon(e,tp,eg,ep,ev,re,r,rp) - return eg:IsExists(s.spconfilter,1,nil,tp) -end -function s.spfilter(c,e,tp) - return c:IsSetCard(SET_FUR_HIRE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) -end -function s.spop(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,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c101303062.lua b/pre-release/c101303062.lua deleted file mode 100644 index aed4771688..0000000000 --- a/pre-release/c101303062.lua +++ /dev/null @@ -1,75 +0,0 @@ ---飆風の空牙団 ---Storm Fur Hire ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Special Summon 1 Level 4 or lower monster "Fur Hire" from your Deck, then if your opponent controls 2 or more monsters, you can Special Summon 1 monster “Fur Hire” from your Deck, also you cannot Special Summon for the rest of this turn, except monsters "Fur Hire" - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id) - e1:SetCondition(function(e,tp) return Duel.GetFieldGroupCount(tp,LOCATION_MZONE,0)==0 end) - e1:SetTarget(s.target) - e1:SetOperation(s.activate) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) - --If you would discard a card(s) to activate the effect of a monster "Fur Hire", you can banish this card from your GY instead of 1 of those cards - local e2=Effect.CreateEffect(c) - e2:SetType(EFFECT_TYPE_FIELD) - e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET) - e2:SetCode(EFFECT_FUR_HIRE_REPLACE) - e2:SetRange(LOCATION_GRAVE) - e2:SetTargetRange(1,0) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(function(e) return e:GetHandler():IsAbleToRemoveAsCost() end) - e2:SetValue(s.repval) - e2:SetOperation(function(base,e,tp,eg,ep,ev,re,r,rp) Duel.Hint(HINT_CARD,0,id) Duel.Remove(base:GetHandler(),POS_FACEUP,REASON_COST) end) - c:RegisterEffect(e2) -end -s.listed_series={SET_FUR_HIRE} -function s.spfilter(c,e,tp) - return c:IsSetCard(SET_FUR_HIRE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.lv4spfilter(c,e,tp) - return c:IsLevelBelow(4) and s.spfilter(c,e,tp) -end -function s.target(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.lv4spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) -end -function s.activate(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g1=Duel.SelectMatchingCard(tp,s.lv4spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) - if #g1>0 and Duel.SpecialSummon(g1,0,tp,tp,false,false,POS_FACEUP)>0 - and Duel.IsPlayerCanSpecialSummonCount(tp,2) - and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE)>=2 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) - and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g2=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) - if #g2>0 then - Duel.BreakEffect() - Duel.SpecialSummon(g2,0,tp,tp,false,false,POS_FACEUP) - end - end - end - --You cannot Special Summon for the rest of this turn, except monsters "Fur Hire" - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return not c:IsSetCard(SET_FUR_HIRE) end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) -end -function s.repval(base,e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - return c:IsSetCard(SET_FUR_HIRE) and c:IsFaceup() and c:IsControler(tp) and c:IsLocation(LOCATION_MZONE) -end \ No newline at end of file diff --git a/pre-release/c101303063.lua b/pre-release/c101303063.lua deleted file mode 100644 index e9c462fcbb..0000000000 --- a/pre-release/c101303063.lua +++ /dev/null @@ -1,48 +0,0 @@ ---佚楽の堕天使 ---Darklord Pleasure ---Scripted by The Razgriz -local s,id=GetID() -function s.initial_effect(c) - --Fusion Summon 1 DARK Fairy Fusion Monster from your Extra Deck, by banishing its materials from your hand, field, and/or GY, and if you do, it gains 1000 ATK - local e1=Fusion.CreateSummonEff({ - handler=c, - fusfilter=s.fusfilter, - matfilter=Card.IsAbleToRemove, - extrafil=s.fextra, - extraop=Fusion.BanishMaterial, - extratg=s.extratg, - stage2=s.stage2 - }) - e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) - c:RegisterEffect(e1) -end -s.listed_series={SET_DARKLORD} -function s.fusfilter(c) - return c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_FAIRY) -end -function s.fcheck(tp,sg,fc) - return fc:IsSetCard(SET_DARKLORD) or not sg:IsExists(Card.IsControler,1,nil,1-tp) -end -function s.fextrafilter(c,tp) - return c:IsMonster() and c:IsAbleToRemove() and (c:IsControler(tp) or (c:IsSetCard(SET_DARKLORD) and c:IsFaceup())) -end -function s.fextra(e,tp,mg) - if Duel.IsPlayerAffectedByEffect(tp,CARD_SPIRIT_ELIMINATION) then return nil,s.fcheck end - return Duel.GetMatchingGroup(s.fextrafilter,tp,LOCATION_GRAVE,LOCATION_MZONE,nil,tp),s.fcheck -end -function s.extratg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return true end - Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_GRAVE) -end -function s.stage2(e,fc,tp,sg,chk) - if chk==0 then - --It gains 1000 ATK - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_UPDATE_ATTACK) - e1:SetValue(1000) - e1:SetReset(RESET_EVENT|RESETS_STANDARD) - fc:RegisterEffect(e1) - end -end \ No newline at end of file diff --git a/pre-release/c101303064.lua b/pre-release/c101303064.lua deleted file mode 100644 index d0b8be7d1b..0000000000 --- a/pre-release/c101303064.lua +++ /dev/null @@ -1,100 +0,0 @@ ---ボスオンパレード ---Boss on Parade ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --When this card is activated: Add 1 "B.E.S." monster from your Deck to your hand - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) - e1:SetTarget(s.target) - e1:SetOperation(s.activate) - c:RegisterEffect(e1) - --Destroy 1 monster in your hand or field, and if you do, Special Summon 1 LIGHT Machine monster with 1200 ATK and 1000 or less DEF from your Deck to either field - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_DESTROY+CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetRange(LOCATION_SZONE) - e2:SetCountLimit(1) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - c:RegisterEffect(e2) - --Place 1 "Boss Rush" from your Deck or GY face-up on your field - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,2)) - e3:SetType(EFFECT_TYPE_IGNITION) - e3:SetRange(LOCATION_GRAVE) - e3:SetCost(Cost.SelfBanish) - e3:SetTarget(s.pltg) - e3:SetOperation(s.plop) - c:RegisterEffect(e3) -end -s.listed_names={66947414} --"Boss Rush" -s.listed_series={SET_BES} -function s.thfilter(c) - return c:IsSetCard(SET_BES) and c:IsMonster() and c:IsAbleToHand() -end -function s.target(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.activate(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end -function s.desfilter(c,e,tp) - return c:IsMonster() and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp,Duel.GetMZoneCount(tp,c)>0,Duel.GetLocationCount(1-tp,LOCATION_MZONE)>0) -end -function s.spfilter(c,e,tp,mmz_chk,opp_mmz_chk) - return c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsRace(RACE_MACHINE) and c:IsAttack(1200) and c:IsDefenseBelow(1000) - and ((mmz_chk and c:IsCanBeSpecialSummoned(e,0,tp,false,false)) - or (opp_mmz_chk and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,1-tp))) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.desfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,nil,e,tp) end - local g=Duel.GetMatchingGroup(s.desfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,nil,e,tp) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local dg=Duel.SelectMatchingCard(tp,s.desfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,1,nil,e,tp) - if #dg>0 and Duel.Destroy(dg,REASON_EFFECT)>0 then - local mmz_chk=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - local opp_mmz_chk=Duel.GetLocationCount(1-tp,LOCATION_MZONE)>0 - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local sc=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,mmz_chk,opp_mmz_chk):GetFirst() - if not sc then return end - local b1=mmz_chk and sc:IsCanBeSpecialSummoned(e,0,tp,false,false) - local b2=opp_mmz_chk and sc:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,1-tp) - if not (b1 or b2) then return end - local op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,3)}, - {b2,aux.Stringid(id,4)}) - local to_player=op==1 and tp or 1-tp - Duel.SpecialSummon(sc,0,tp,to_player,false,false,POS_FACEUP) - end -end -function s.plfilter(c,tp) - return c:IsCode(66947414) and not c:IsForbidden() and c:CheckUniqueOnField(tp) -end -function s.pltg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 - and Duel.IsExistingMatchingCard(s.plfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil,tp) end -end -function s.plop(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) - local sc=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.plfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil,tp):GetFirst() - if sc then - Duel.MoveToField(sc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) - end -end \ No newline at end of file diff --git a/pre-release/c101303065.lua b/pre-release/c101303065.lua deleted file mode 100644 index bc37e88825..0000000000 --- a/pre-release/c101303065.lua +++ /dev/null @@ -1,87 +0,0 @@ ---絢嵐たる軒昂 ---Radiant Typhoon Elation ---Scripted by Eerie Code -local s,id=GetID() -function s.initial_effect(c) - --Activate 1 of these effects - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetTarget(s.efftg) - e1:SetOperation(s.effop) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) - --Set this card - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY) - e2:SetCode(EVENT_DESTROYED) - e2:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return re and re:GetHandler():IsCode(CARD_MYSTICAL_SPACE_TYPHOON) end) - e2:SetTarget(s.settg) - e2:SetOperation(s.setop) - c:RegisterEffect(e2) -end -s.listed_names={CARD_MYSTICAL_SPACE_TYPHOON} -s.listed_series={SET_RADIANT_TYPHOON} -function s.spfilter(c,e,tp) - return c:IsLevelBelow(6) and c:IsSetCard(SET_RADIANT_TYPHOON) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.thfilter(c) - return c:IsCode(CARD_MYSTICAL_SPACE_TYPHOON) and c:IsAbleToHand() -end -function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) - local b1=not Duel.HasFlagEffect(tp,id) - and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) - local b2=not Duel.HasFlagEffect(tp,id+100) - and Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil) - if chk==0 then return b1 or b2 end - local op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,2)}, - {b2,aux.Stringid(id,3)}) - e:SetLabel(op) - if op==1 then - e:SetCategory(CATEGORY_SPECIAL_SUMMON) - Duel.RegisterFlagEffect(tp,id,RESET_PHASE|PHASE_END,0,1) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) - elseif op==2 then - e:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND) - Duel.RegisterFlagEffect(tp,id+100,RESET_PHASE|PHASE_END,0,1) - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) - end -end -function s.effop(e,tp,eg,ep,ev,re,r,rp) - local op=e:GetLabel() - if op==1 then - --Special Summon 1 Level 6 or lower "Radiant Typoon" monster from your GY - if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end - elseif op==2 then - --Add 1 "Mystical Space Typhoon" from your Deck or GY to your hand - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.thfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end - end -end -function s.settg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return c:IsSSetable() end - if c:IsLocation(LOCATION_GRAVE) then - Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,c,1,tp,0) - end -end -function s.setop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) then - Duel.SSet(tp,c) - end -end \ No newline at end of file diff --git a/pre-release/c101303066.lua b/pre-release/c101303066.lua deleted file mode 100644 index 29cf782c1f..0000000000 --- a/pre-release/c101303066.lua +++ /dev/null @@ -1,129 +0,0 @@ ---エクソシスター・バト・マーテル ---Exosister Bat Mater ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --When this card is activated: Add 2 "Exosister" monsters from your Deck to your hand, then discard 1 card - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_HANDES) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id) - e1:SetTarget(s.target) - e1:SetOperation(s.activate) - c:RegisterEffect(e1) - --Immediately after this effect resolves, Normal Summon 1 "Exosister" monster that is mentioned on that monster - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_SZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.nstg) - e2:SetOperation(s.nsop) - c:RegisterEffect(e2) - --Make your opponent banish 1 of them - local e3a=Effect.CreateEffect(c) - e3a:SetDescription(aux.Stringid(id,2)) - e3a:SetCategory(CATEGORY_REMOVE) - e3a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e3a:SetProperty(EFFECT_FLAG_DELAY) - e3a:SetCode(EVENT_CUSTOM+id) - e3a:SetRange(LOCATION_SZONE) - e3a:SetCountLimit(1,{id,2}) - e3a:SetTarget(s.rmtg) - e3a:SetOperation(s.rmop) - c:RegisterEffect(e3a) - local g=Group.CreateGroup() - e3a:SetLabelObject(g) - --Keep track of monsters sent to your opponent's GY - local e3b=Effect.CreateEffect(c) - e3b:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) - e3b:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e3b:SetCode(EVENT_TO_GRAVE) - e3b:SetRange(LOCATION_SZONE) - e3b:SetLabelObject(e3a) - e3b:SetOperation(s.regop) - c:RegisterEffect(e3b) -end -s.listed_series={SET_EXOSISTER} -function s.thfilter(c) - return c:IsSetCard(SET_EXOSISTER) and c:IsMonster() and c:IsAbleToHand() -end -function s.target(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,2,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK) - Duel.SetOperationInfo(0,CATEGORY_HANDES,nil,1,tp,1) -end -function s.activate(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,2,2,nil) - if #g==2 and Duel.SendtoHand(g,nil,REASON_EFFECT)>0 then - Duel.ConfirmCards(1-tp,g) - Duel.ShuffleHand(tp) - Duel.BreakEffect() - Duel.DiscardHand(tp,nil,1,1,REASON_EFFECT|REASON_DISCARD,nil) - end -end -function s.tgfilter(c,tp) - return c:IsFaceup() and Duel.IsExistingMatchingCard(s.nsfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,nil,c) -end -function s.nsfilter(c,tc) - return c:IsSetCard(SET_EXOSISTER) and c:IsSummonable(true,nil) and tc:ListsCode(c:GetCode()) -end -function s.nstg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and s.tgfilter(chkc,tp) end - if chk==0 then return Duel.IsExistingTarget(s.tgfilter,tp,LOCATION_MZONE,0,1,nil,tp) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) - local g=Duel.SelectTarget(tp,s.tgfilter,tp,LOCATION_MZONE,0,1,1,nil,tp) - Duel.SetOperationInfo(0,CATEGORY_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_MZONE) -end -function s.nsop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and tc:IsFaceup() then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON) - local sc=Duel.SelectMatchingCard(tp,s.nsfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,1,nil,tc):GetFirst() - if sc then - Duel.Summon(tp,sc,true,nil) - end - end -end -function s.regfilter(c,opp) - return c:IsMonster() and c:IsControler(opp) -end -function s.regop(e,tp,eg,ep,ev,re,r,rp) - local tg=eg:Filter(s.regfilter,nil,1-tp) - if #tg>0 then - for tc in tg:Iter() do - tc:RegisterFlagEffect(id,RESET_CHAIN,0,1) - end - local g=e:GetLabelObject():GetLabelObject() - if Duel.GetCurrentChain()==0 then g:Clear() end - g:Merge(tg) - g:Remove(function(c) return c:GetFlagEffect(id)==0 end,nil) - e:GetLabelObject():SetLabelObject(g) - Duel.RaiseSingleEvent(e:GetHandler(),EVENT_CUSTOM+id,e,0,tp,tp,0) - end -end -function s.rmfilter(c,opp) - return c:IsControler(opp) and c:IsLocation(LOCATION_GRAVE) and c:IsAbleToRemove(opp) -end -function s.rmtg(e,tp,eg,ep,ev,re,r,rp,chk) - local g=e:GetLabelObject():Filter(s.rmfilter,nil,1-tp) - if chk==0 then return #g>0 end - Duel.SetTargetCard(g) - Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,1,1-tp,0) -end -function s.rmop(e,tp,eg,ep,ev,re,r,rp) - local g=Duel.GetTargetCards(e) - if #g==0 then return end - local opp=1-tp - Duel.Hint(HINT_SELECTMSG,opp,HINTMSG_REMOVE) - g=g:FilterSelect(opp,Card.IsAbleToRemove,1,1,nil,opp) - if #g>0 then - Duel.HintSelection(g) - Duel.Remove(g,POS_FACEUP,REASON_EFFECT,PLAYER_NONE,opp) - end -end \ No newline at end of file diff --git a/pre-release/c101303067.lua b/pre-release/c101303067.lua deleted file mode 100644 index 34820d8b3e..0000000000 --- a/pre-release/c101303067.lua +++ /dev/null @@ -1,65 +0,0 @@ ---禁じられた聖冠 ---Forbidden Crown ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Apply these effects to 1 face-up monster on the field, until the end of this turn - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_DISABLE) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) - e1:SetTarget(s.target) - e1:SetOperation(s.activate) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) -end -function s.target(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(aux.FaceupFilter(aux.NOT(Card.HasFlagEffect),id),tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end - Duel.SetChainLimit(function(te) return not te:IsMonsterEffect() end) - Duel.SetOperationInfo(0,CATEGORY_DISABLE,nil,1,PLAYER_EITHER,LOCATION_MZONE) -end -function s.activate(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_APPLYTO) - local sc=Duel.SelectMatchingCard(tp,aux.FaceupFilter(aux.NOT(Card.HasFlagEffect),id),tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil):GetFirst() - if sc then - Duel.HintSelection(sc) - local c=e:GetHandler() - sc:RegisterFlagEffect(id,RESETS_STANDARD_PHASE_END,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(id,1)) - --Its effects are negated - sc:NegateEffects(c,RESETS_STANDARD_PHASE_END) - --It cannot attack - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_CANNOT_ATTACK) - e1:SetReset(RESETS_STANDARD_PHASE_END) - sc:RegisterEffect(e1) - --It cannot be destroyed by battle or card effects - local e2=e1:Clone() - e2:SetCode(EFFECT_INDESTRUCTABLE_BATTLE) - e2:SetValue(1) - sc:RegisterEffect(e2) - local e3=e2:Clone() - e3:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) - sc:RegisterEffect(e3) - --It is unaffected by other cards' activated effects, except its own - local e4=e1:Clone() - e4:SetCode(EFFECT_IMMUNE_EFFECT) - e4:SetValue(function(e,re) return re:IsActivated() and e:GetHandler()~=re:GetOwner() end) - sc:RegisterEffect(e4) - --It cannot be Tributed - local e5=e2:Clone() - e5:SetCode(EFFECT_UNRELEASABLE_SUM) - sc:RegisterEffect(e5) - local e6=e2:Clone() - e6:SetCode(EFFECT_UNRELEASABLE_NONSUM) - sc:RegisterEffect(e6) - --It cannot be used as material for a Fusion, Synchro, Xyz, or Link Summon - local e7=e1:Clone() - e7:SetCode(EFFECT_CANNOT_BE_MATERIAL) - e7:SetValue(aux.cannotmatfilter(SUMMON_TYPE_FUSION,SUMMON_TYPE_SYNCHRO,SUMMON_TYPE_XYZ,SUMMON_TYPE_LINK)) - sc:RegisterEffect(e7) - end -end \ No newline at end of file diff --git a/pre-release/c101303068.lua b/pre-release/c101303068.lua deleted file mode 100644 index fdfc2d82f1..0000000000 --- a/pre-release/c101303068.lua +++ /dev/null @@ -1,70 +0,0 @@ ---幻惑の操手 ---Nightmare Hand -local s,id=GetID() -function s.initial_effect(c) - --Send 1 Illusion monster from your Deck to the GY - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOGRAVE) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id) - e1:SetTarget(s.tgtg) - e1:SetOperation(s.tgop) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) - --Special Summon 1 monster from your opponent's GY to your field, but banish it during the End Phase of the next turn - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_REMOVE) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,id) - e2:SetCondition(s.spcon) - e2:SetCost(Cost.SelfBanish) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - c:RegisterEffect(e2) -end -function s.tgfilter(c) - return c:IsRace(RACE_ILLUSION) and c:IsAbleToGrave() -end -function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.tgfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) -end -function s.tgop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local g=Duel.SelectMatchingCard(tp,s.tgfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoGrave(g,REASON_EFFECT) - end -end -function s.spconfilter(c) - return c:IsLevelAbove(5) and c:IsRace(RACE_ILLUSION) and c:IsFaceup() -end -function s.spcon(e,tp,eg,ep,ev,re,r,rp) - return Duel.IsExistingMatchingCard(s.spconfilter,tp,LOCATION_MZONE,0,1,nil) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_GRAVE) and chkc:IsCanBeSpecialSummoned(e,0,tp,false,false) end - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingTarget(Card.IsCanBeSpecialSummoned,tp,0,LOCATION_GRAVE,1,nil,e,0,tp,false,false) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectTarget(tp,Card.IsCanBeSpecialSummoned,tp,0,LOCATION_GRAVE,1,1,nil,e,0,tp,false,false) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,0) - Duel.SetPossibleOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_MZONE) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)>0 then - local turn_summoned=Duel.GetTurnCount() - --Banish it during the End Phase of the next turn - aux.DelayedOperation(tc,PHASE_END,id,e,tp, - function(tc) Duel.Remove(tc,POS_FACEUP,REASON_EFFECT) end, - function() return Duel.GetTurnCount()==turn_summoned+1 end, - nil,2,aux.Stringid(id,2) - ) - end -end \ No newline at end of file diff --git a/pre-release/c101303069.lua b/pre-release/c101303069.lua deleted file mode 100644 index 4dab1ae512..0000000000 --- a/pre-release/c101303069.lua +++ /dev/null @@ -1,73 +0,0 @@ ---騒動 ---Riot ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Return 1 face-down Defense Position monster on the field to the hand, then the player who added it to their hand can Special Summon 1 monster from their hand in face-down Defense Position - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetProperty(EFFECT_FLAG_CARD_TARGET) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id) - e1:SetTarget(s.rthtg) - e1:SetOperation(s.rthop) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMING_BATTLE_START|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) - --Change 1 face-down Defense Position monster on the field to Attack Position - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_POSITION) - e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e2:SetCode(EVENT_ATTACK_ANNOUNCE) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(function(e,tp) return Duel.GetAttacker():IsControler(1-tp) end) - e2:SetCost(Cost.SelfBanish) - e2:SetTarget(s.postg) - e2:SetOperation(s.posop) - c:RegisterEffect(e2) -end -function s.rthfilter(c) - return c:IsPosition(POS_FACEDOWN_DEFENSE) and c:IsAbleToHand() -end -function s.rthtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingTarget(s.rthfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) - local tc=Duel.SelectTarget(tp,s.rthfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil):GetFirst() - Duel.SetOperationInfo(0,CATEGORY_TOHAND,tc,1,tp,0) - Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tc:GetOwner(),LOCATION_HAND) -end -function s.rthop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and Duel.SendtoHand(tc,nil,REASON_EFFECT)>0 and tc:IsLocation(LOCATION_HAND) then - local sp_player=tc:GetControler() - Duel.ShuffleHand(sp_player) - if Duel.GetLocationCount(sp_player,LOCATION_MZONE,sp_player)>0 - and Duel.IsExistingMatchingCard(Card.IsCanBeSpecialSummoned,sp_player,LOCATION_HAND,0,1,nil,e,0,sp_player,false,false,POS_FACEDOWN_DEFENSE) - and Duel.SelectYesNo(sp_player,aux.Stringid(id,2)) then - Duel.Hint(HINT_SELECTMSG,sp_player,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(sp_player,Card.IsCanBeSpecialSummoned,sp_player,LOCATION_HAND,0,1,1,nil,e,0,sp_player,false,false,POS_FACEDOWN_DEFENSE) - if #g>0 then - Duel.BreakEffect() - Duel.SpecialSummon(g,0,sp_player,sp_player,false,false,POS_FACEDOWN_DEFENSE) - end - end - end -end -function s.posfilter(c) - return c:IsPosition(POS_FACEDOWN_DEFENSE) and c:IsCanChangePosition() -end -function s.postg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.posfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_POSITION,nil,1,PLAYER_EITHER,LOCATION_MZONE) -end -function s.posop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_POSCHANGE) - local g=Duel.SelectMatchingCard(tp,s.posfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) - if #g>0 then - Duel.HintSelection(g) - Duel.ChangePosition(g,POS_FACEUP_ATTACK) - end -end \ No newline at end of file diff --git a/pre-release/c101303071.lua b/pre-release/c101303071.lua deleted file mode 100644 index a6e736d1e6..0000000000 --- a/pre-release/c101303071.lua +++ /dev/null @@ -1,70 +0,0 @@ ---エルフェンノーツ~託選のアリスティア~ ---Elvennotes ~Oracle Alicetea~ ---Scripted by Hatter -local s,id=GetID() -function s.initial_effect(c) - --Activate - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_ACTIVATE) - e0:SetCode(EVENT_FREE_CHAIN) - c:RegisterEffect(e0) - --Move 1 face-up monster you control to another of your Main Monster Zones - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_QUICK_O) - e1:SetProperty(EFFECT_FLAG_CARD_TARGET) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetRange(LOCATION_SZONE) - e1:SetCountLimit(1) - e1:SetCost(Cost.AND(Cost.HardOncePerChain(id),Cost.HintSelectedEffect)) - e1:SetTarget(s.mvtg) - e1:SetOperation(s.mvop) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) - --Negate the effect of an opponent's Spell/Trap card activation - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_DISABLE+CATEGORY_DESTROY) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetCode(EVENT_CHAINING) - e2:SetRange(LOCATION_SZONE) - e2:SetCountLimit(1,id) - e2:SetCondition(s.discon) - e2:SetCost(Cost.AND(Cost.HardOncePerChain(id),Cost.HintSelectedEffect)) - e2:SetTarget(s.distg) - e2:SetOperation(s.disop) - c:RegisterEffect(e2) -end -s.listed_series={SET_ELVENNOTES} -function s.mvtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsFaceup() end - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_MZONE,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) - Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_MZONE,0,1,1,nil) -end -function s.mvop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and tc:IsControler(tp) and not tc:IsImmuneToEffect(e) - and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOZONE) - local seq=math.log(Duel.SelectDisableField(tp,1,LOCATION_MZONE,0,0),2) - Duel.MoveSequence(tc,seq) - end -end -function s.discon(e,tp,eg,ep,ev,re,r,rp) - return rp==1-tp and re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsSpellTrapEffect() and Duel.IsChainDisablable(ev) - and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsSetCard,SET_ELVENNOTES),tp,LOCATION_MZONE,0,3,nil) -end -function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return true end - Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,tp,0) - Duel.SetPossibleOperationInfo(0,CATEGORY_DESTROY,eg,1,tp,0) -end -function s.disop(e,tp,eg,ep,ev,re,r,rp) - if Duel.NegateEffect(ev) and re:GetHandler():IsRelateToEffect(re) - and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsSynchroMonster),tp,LOCATION_MZONE,0,1,nil) - and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.BreakEffect() - Duel.Destroy(eg,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303072.lua b/pre-release/c101303072.lua deleted file mode 100644 index 5f4b8edf23..0000000000 --- a/pre-release/c101303072.lua +++ /dev/null @@ -1,73 +0,0 @@ ---エルフェンノーツ~狂奏のラプソディア~ ---Elvennotes ~Maddening Rhapsodia~ ---Scripted by Hatter -local s,id=GetID() -function s.initial_effect(c) - --Activate - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_ACTIVATE) - e0:SetCode(EVENT_FREE_CHAIN) - c:RegisterEffect(e0) - --While you have a monster in your center Main Monster Zone, your opponent's monsters cannot attack, except to attack that monster - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetCode(EFFECT_MUST_ATTACK_MONSTER) - e1:SetRange(LOCATION_SZONE) - e1:SetTargetRange(0,LOCATION_MZONE) - e1:SetCondition(function(e) return Duel.GetFieldCard(e:GetHandlerPlayer(),LOCATION_MZONE,2)~=nil end) - e1:SetValue(function(e,c) return c:IsSequence(2) end) - c:RegisterEffect(e1) - --Special Summon 1 "Elvennotes" monster from your GY - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DISABLE) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_SZONE) - e2:SetCountLimit(1,id) - e2:SetCost(s.spcost) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e2) -end -s.listed_series={SET_ELVENNOTES} -function s.spcostfilter(c,e,tp) - return c:IsMonster() and c:IsAbleToGraveAsCost() and Duel.GetMZoneCount(tp,c)>0 - and Duel.IsExistingTarget(s.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp,c:GetOriginalAttribute()) -end -function s.spfilter(c,e,tp,attr) - return c:IsSetCard(SET_ELVENNOTES) and not c:IsOriginalAttribute(attr) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.spcostfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,nil,e,tp) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local sc=Duel.SelectMatchingCard(tp,s.spcostfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,1,nil,e,tp):GetFirst() - e:SetLabel(sc:GetOriginalAttribute()) - Duel.SendtoGrave(sc,REASON_COST) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - local attr=e:GetLabel() - if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and s.spfilter(chkc,e,tp,attr) end - if chk==0 then return true end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectTarget(tp,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp,attr) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,0) - Duel.SetPossibleOperationInfo(0,CATEGORY_DISABLE,nil,1,1-tp,LOCATION_ONFIELD) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)>0 - and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsSynchroMonster),tp,LOCATION_MZONE,0,1,nil) - and Duel.IsExistingMatchingCard(Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,nil) - and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_NEGATE) - local sc=Duel.SelectMatchingCard(tp,Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,1,nil):GetFirst() - if sc then - Duel.HintSelection(sc) - Duel.BreakEffect() - sc:NegateEffects(e:GetHandler(),RESETS_STANDARD_PHASE_END,true) - end - end -end \ No newline at end of file diff --git a/pre-release/c101303073.lua b/pre-release/c101303073.lua deleted file mode 100644 index 3e5f7b26dd..0000000000 --- a/pre-release/c101303073.lua +++ /dev/null @@ -1,57 +0,0 @@ ---デーモンの諧謔 ---Archfiend's Jest ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Special Summon 1 Level 7 or lower "Archfiend" monster from your hand or Deck, or if you have a face-up "Archfiend" Ritual Monster in your Extra Deck, you can Special Summon 1 "Royal Archfiend", 1 "Duke Archfiend", and/or 1 "Highness Archfiend" from your hand and/or Deck instead - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) - e1:SetTarget(s.target) - e1:SetOperation(s.activate) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) -end -s.listed_series={SET_ARCHFIEND} -s.listed_names={101303014,101303015,101303016} --"Royal Archfiend", "Duke Archfiend", "Highness Archfiend" -function s.spfilter(c,e,tp,ex_chk) - return ((c:IsLevelBelow(7) and c:IsSetCard(SET_ARCHFIEND)) or (ex_chk and c:IsCode(101303014,101303015,101303016))) - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.archritfilter(c) - return c:IsSetCard(SET_ARCHFIEND) and c:IsRitualMonster() and c:IsFaceup() -end -function s.target(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then - local ex_chk=Duel.IsExistingMatchingCard(s.archritfilter,tp,LOCATION_EXTRA,0,1,nil) - return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,e,tp,ex_chk) - end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_DECK) -end -function s.rescon(ex_chk) - return function(sg,e,tp,mg) - return #sg==1 or (ex_chk and #sg<=3 and sg:FilterCount(Card.IsCode,nil,101303014,101303015,101303016)==#sg and sg:GetClassCount(Card.GetCode)==#sg) - end -end -function s.activate(e,tp,eg,ep,ev,re,r,rp) - local ft=Duel.GetLocationCount(tp,LOCATION_MZONE) - if ft<=0 then return end - local ex_chk=Duel.IsExistingMatchingCard(s.archritfilter,tp,LOCATION_EXTRA,0,1,nil) - local g=Duel.GetMatchingGroup(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,nil,e,tp,ex_chk) - if #g==0 then return end - if not ex_chk then - ft=1 - else - ft=math.min(ft,3) - if Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) then ft=1 end - end - local rescon=s.rescon(ex_chk) - local sg=aux.SelectUnselectGroup(g,e,tp,1,ft,rescon,1,tp,HINTMSG_SPSUMMON,rescon) - if #sg>0 then - Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c101303074.lua b/pre-release/c101303074.lua deleted file mode 100644 index 911f7fcb6a..0000000000 --- a/pre-release/c101303074.lua +++ /dev/null @@ -1,68 +0,0 @@ ---デーモンの気魄 ---Archfiend's Vigor ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Activate - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_ACTIVATE) - e0:SetCode(EVENT_FREE_CHAIN) - c:RegisterEffect(e0) - --Negate the effects of 1 face-up card your opponent controls until the end of this turn - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_DISABLE) - e1:SetType(EFFECT_TYPE_QUICK_O) - e1:SetProperty(EFFECT_FLAG_CARD_TARGET) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetRange(LOCATION_SZONE) - e1:SetCountLimit(1,id) - e1:SetCondition(function(e,tp) return Duel.IsExistingMatchingCard(function(c) return c:IsSetCard(SET_ARCHFIEND) and c:IsRitualMonster() and c:IsFaceup() end,tp,LOCATION_EMZONE,0,1,nil) end) - e1:SetTarget(s.distg) - e1:SetOperation(s.disop) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) - c:RegisterEffect(e1) - --Add 1 "Archfiend" card from your Deck to your hand, except "Archfiend's Vigor" - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY) - e2:SetCode(EVENT_REMOVE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(function(e) return e:GetHandler():IsPreviousLocation(LOCATION_HAND|LOCATION_ONFIELD) end) - e2:SetTarget(s.thtg) - e2:SetOperation(s.thop) - c:RegisterEffect(e2) -end -s.listed_names={id} -s.listed_series={SET_ARCHFIEND} -function s.distg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsOnField() and c:IsControler(1-tp) and chkc:IsNegatable() end - if chk==0 then return Duel.IsExistingTarget(Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_NEGATE) - local g=Duel.SelectTarget(tp,Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_DISABLE,g,1,tp,0) -end -function s.disop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and tc:IsFaceup() then - --Negate its effects until the end of this turn - tc:NegateEffects(e:GetHandler(),RESET_PHASE|PHASE_END,true) - end -end -function s.thfilter(c) - return c:IsSetCard(SET_ARCHFIEND) and not c:IsCode(id) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end \ No newline at end of file diff --git a/pre-release/c101303075.lua b/pre-release/c101303075.lua deleted file mode 100644 index 7d07f641ed..0000000000 --- a/pre-release/c101303075.lua +++ /dev/null @@ -1,80 +0,0 @@ ---空牙団の奥義 ---Secret Technique Fur Hire ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Destroy face-up cards on the field, up to the number of monsters "Fur Hire" you control with different names - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_DESTROY+CATEGORY_REMOVE) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetProperty(EFFECT_FLAG_CARD_TARGET) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id) - e1:SetTarget(s.target) - e1:SetOperation(s.activate) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) - --Add this card to your hand - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TOHAND) - e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY,EFFECT_FLAG2_CHECK_SIMULTANEOUS) - e2:SetCode(EVENT_SPSUMMON_SUCCESS) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,id) - e2:SetCondition(s.thcon) - e2:SetTarget(s.thtg) - e2:SetOperation(s.thop) - c:RegisterEffect(e2) -end -s.listed_series={SET_FUR_HIRE} -function s.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - local c=e:GetHandler() - if chkc then return chkc:IsOnField() and chkc:IsFaceup() and chkc~=c end - if chk==0 then return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsSetCard,SET_FUR_HIRE),tp,LOCATION_MZONE,0,1,nil) - and Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,c) end - local g=Duel.GetMatchingGroup(aux.FaceupFilter(Card.IsSetCard,SET_FUR_HIRE),tp,LOCATION_MZONE,0,nil) - local ct=g:GetClassCount(Card.GetCode) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local tg=Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,ct,c) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,tg,#tg,tp,0) - Duel.SetPossibleOperationInfo(0,CATEGORY_REMOVE,tg,#tg,tp,0) -end -function s.lv8filter(c) - return c:IsLevelAbove(8) and c:IsSetCard(SET_FUR_HIRE) and c:IsFaceup() -end -function s.link3filter(c) - return c:IsLinkAbove(3) and c:IsSetCard(SET_FUR_HIRE) and c:IsFaceup() -end -function s.activate(e,tp,eg,ep,ev,re,r,rp) - local tg=Duel.GetTargetCards(e) - if #tg>0 then - if Duel.IsExistingMatchingCard(s.lv8filter,tp,LOCATION_MZONE,0,1,nil) - and Duel.IsExistingMatchingCard(s.link3filter,tp,LOCATION_MZONE,0,1,nil) - and tg:IsExists(Card.IsAbleToRemove,1,nil) - and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.Remove(tg,POS_FACEUP,REASON_EFFECT) - else - Duel.Destroy(tg,REASON_EFFECT) - end - end -end -function s.thconfilter(c,tp) - return (s.lv8filter(c) or s.link3filter(c)) and c:IsControler(tp) -end -function s.thcon(e,tp,eg,ep,ev,re,r,rp) - return eg:IsExists(s.thconfilter,1,nil,tp) -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return c:IsAbleToHand() end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,c,1,tp,0) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) then - Duel.SendtoHand(c,nil,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303076.lua b/pre-release/c101303076.lua deleted file mode 100644 index b6ce5cfa7e..0000000000 --- a/pre-release/c101303076.lua +++ /dev/null @@ -1,99 +0,0 @@ ---アシスト★ヤミー! ---Assist★Yummy! ---scripted by Naim -local s,id=GetID() -function s.initial_effect(c) - --Activate - local e0=Effect.CreateEffect(c) - e0:SetType(EFFECT_TYPE_ACTIVATE) - e0:SetCode(EVENT_FREE_CHAIN) - e0:SetHintTiming(0,TIMING_MAIN_END|TIMING_BATTLE_START|TIMING_BATTLE_PHASE|TIMING_BATTLE_STEP_END|TIMING_BATTLE_END) - c:RegisterEffect(e0) - --Gain 100 LP, and if you do, your opponent pays 100 LP - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_RECOVER) - e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e1:SetCode(EVENT_PHASE+PHASE_STANDBY) - e1:SetRange(LOCATION_SZONE) - e1:SetCountLimit(1) - e1:SetTarget(s.lptg) - e1:SetOperation(s.lpop) - c:RegisterEffect(e1) - --Return 1 card from the field or GY to the hand - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_TOHAND) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_SZONE) - e2:SetCountLimit(1,id) - e2:SetCondition(function(e,tp) return Duel.IsMainPhase() or Duel.IsBattlePhase(1-tp) end) - e2:SetCost(s.retthcost) - e2:SetTarget(s.retthtg) - e2:SetOperation(s.retthop) - e2:SetHintTiming(0,TIMING_MAIN_END|TIMING_BATTLE_START|TIMING_BATTLE_PHASE|TIMING_BATTLE_STEP_END|TIMING_BATTLE_END) - c:RegisterEffect(e2) - --Send 1 "Yummy" card from your Deck to the GY - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,2)) - e3:SetCategory(CATEGORY_TOGRAVE) - e3:SetType(EFFECT_TYPE_QUICK_O) - e3:SetCode(EVENT_FREE_CHAIN) - e3:SetRange(LOCATION_GRAVE) - e3:SetCountLimit(1,id) - e3:SetCost(Cost.SelfBanish) - e3:SetTarget(s.tgtg) - e3:SetOperation(s.tgop) - e3:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e3) -end -s.listed_names={id} -s.listed_series={SET_YUMMY} -function s.lptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.CheckLPCost(1-tp,100) end - Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,100) -end -function s.lpop(e,tp,eg,ep,ev,re,r,rp) - if Duel.Recover(tp,100,REASON_EFFECT)>0 and Duel.CheckLPCost(1-tp,100) then - Duel.PayLPCost(1-tp,100) - end -end -function s.costfilter(c,exc) - return c:IsSetCard(SET_YUMMY) and c:IsFaceup() and c:IsAbleToGraveAsCost() - and Duel.IsExistingMatchingCard(Card.IsAbleToHand,0,LOCATION_ONFIELD|LOCATION_GRAVE,LOCATION_ONFIELD|LOCATION_GRAVE,1,c+c:GetEquipGroup()+exc) -end -function s.retthcost(e,tp,eg,ep,ev,re,r,rp,chk) - local c=e:GetHandler() - if chk==0 then return c:IsStatus(STATUS_EFFECT_ENABLED) and c:IsAbleToGraveAsCost() - and Duel.IsExistingMatchingCard(s.costfilter,tp,LOCATION_ONFIELD,0,1,c,c) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local g=Duel.SelectMatchingCard(tp,s.costfilter,tp,LOCATION_ONFIELD,0,1,1,c,c) - Duel.SendtoGrave(g+c,REASON_COST) -end -function s.retthtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToHand,tp,LOCATION_ONFIELD|LOCATION_GRAVE,LOCATION_ONFIELD|LOCATION_GRAVE,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_ONFIELD|LOCATION_GRAVE) -end -function s.retthop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) - local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(Card.IsAbleToHand),tp,LOCATION_ONFIELD|LOCATION_GRAVE,LOCATION_ONFIELD|LOCATION_GRAVE,1,1,nil) - if #g>0 then - Duel.HintSelection(g) - Duel.SendtoHand(g,nil,REASON_EFFECT) - end -end -function s.tgfilter(c) - return c:IsSetCard(SET_YUMMY) and c:IsAbleToGrave() and not c:IsCode(id) -end -function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.tgfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) -end -function s.tgop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) - local g=Duel.SelectMatchingCard(tp,s.tgfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoGrave(g,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303077.lua b/pre-release/c101303077.lua deleted file mode 100644 index bdeaa02ea5..0000000000 --- a/pre-release/c101303077.lua +++ /dev/null @@ -1,56 +0,0 @@ ---禁断儀式術 ---Forbidden Ritual Art ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Ritual Summon 1 Ritual Monster from your GY, by banishing monsters from your GY whose total Levels equal its Level, but destroy it during the End Phase - local e1=Ritual.AddProcEqual({ - handler=c, - location=LOCATION_GRAVE, - matfilter=function(c) return c:IsLocation(LOCATION_GRAVE) end, - extrafil=s.rextra, - extratg=s.extratg, - stage2=s.stage2 - }) - e1:SetCategory(e1:GetCategory()+CATEGORY_REMOVE) - e1:SetCountLimit(1,{id,0}) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) - --Apply an "once this turn, when you Ritual Summon with a card effect that requires use of monster Tributes, you can also banish Ritual Monsters from your GY as monsters used for the Ritual Summon" effect - local e2=Effect.CreateEffect(c) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,{id,1}) - e2:SetCost(Cost.SelfBanish) - e2:SetOperation(s.effop) - e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e2) -end -function s.rextra(e,tp,eg,ep,ev,re,r,rp,chk) - if not Duel.IsPlayerAffectedByEffect(tp,CARD_SPIRIT_ELIMINATION) then - return Duel.GetMatchingGroup(aux.AND(Card.HasLevel,Card.IsAbleToRemove),tp,LOCATION_GRAVE,0,nil) - end -end -function s.extratg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return true end - Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_GRAVE) -end -function s.stage2(mat,e,tp,eg,ep,ev,re,r,rp,rc) - --Destroy it during the End Phase - aux.DelayedOperation(rc,PHASE_END,id,e,tp,function(ag) Duel.Destroy(ag,REASON_EFFECT) end,nil,0,0,aux.Stringid(id,2)) -end -function s.effop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - aux.RegisterClientHint(c,0,tp,1,0,aux.Stringid(id,3)) - --Once this turn, when you Ritual Summon with a card effect that requires use of monster Tributes, you can also banish Ritual Monsters from your GY as monsters used for the Ritual Summon - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetCode(EFFECT_EXTRA_RITUAL_MATERIAL) - e1:SetCountLimit(1,id) - e1:SetTargetRange(LOCATION_GRAVE,0) - e1:SetCondition(function(e) return not Duel.HasFlagEffect(tp,id) end) - e1:SetTarget(function(e,c) return c:IsRitualMonster() and c:IsAbleToRemove() end) - e1:SetValue(1) - Duel.RegisterEffect(e1,tp) -end \ No newline at end of file diff --git a/pre-release/c101303078.lua b/pre-release/c101303078.lua deleted file mode 100644 index f82668016a..0000000000 --- a/pre-release/c101303078.lua +++ /dev/null @@ -1,89 +0,0 @@ ---武器庫整理 ---Arsenal Organization ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Send up to 2 Equip Spells with different names from your Deck to the GY - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOGRAVE) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCountLimit(1,id) - e1:SetTarget(s.tgtg) - e1:SetOperation(s.tgop) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) - --Equip 1 face-up monster you control with up to 2 Equip Spells with different names from your hand and/or GY that can equip to it, but any battle damage it inflicts to your opponent is halved while equipped with any of those Equip Spells - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_EQUIP) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,id) - e2:SetCost(Cost.SelfBanish) - e2:SetTarget(s.eqtg) - e2:SetOperation(s.eqop) - e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e2) -end -function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(aux.AND(Card.IsEquipSpell,Card.IsAbleToGrave),tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) -end -function s.tgop(e,tp,eg,ep,ev,re,r,rp) - local g=Duel.GetMatchingGroup(aux.AND(Card.IsEquipSpell,Card.IsAbleToGrave),tp,LOCATION_DECK,0,nil) - if #g==0 then return end - local sg=aux.SelectUnselectGroup(g,e,tp,1,2,aux.dncheck,1,tp,HINTMSG_TOGRAVE) - if #sg>0 then - Duel.SendtoGrave(sg,REASON_EFFECT) - end -end -function s.eqtargetfilter(c,tp) - return c:IsFaceup() and Duel.IsExistingMatchingCard(s.eqspellfilter,tp,LOCATION_HAND|LOCATION_GRAVE,0,1,nil,c) -end -function s.eqspellfilter(c,tc) - return c:IsEquipSpell() and c:CheckEquipTarget(tc) -end -function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and s.eqtargetfilter(chkc,tp) end - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 - and Duel.IsExistingTarget(s.eqtargetfilter,tp,LOCATION_MZONE,0,1,nil,tp) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) - Duel.SelectTarget(tp,s.eqtargetfilter,tp,LOCATION_MZONE,0,1,1,nil,tp) -end -function s.eqop(e,tp,eg,ep,ev,re,r,rp) - local ft=Duel.GetLocationCount(tp,LOCATION_SZONE) - if ft<=0 then return end - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and tc:IsFaceup() then - local g=Duel.GetMatchingGroup(aux.NecroValleyFilter(s.eqspellfilter),tp,LOCATION_HAND|LOCATION_GRAVE,0,nil,tc) - if #g==0 then return end - ft=math.min(2,ft) - local sg=aux.SelectUnselectGroup(g,e,tp,1,ft,aux.dncheck,1,tp,HINTMSG_EQUIP) - if #sg==0 then return end - local fid=e:GetFieldID() - local equip_success=false - for ec in sg:Iter() do - if Duel.Equip(tp,ec,tc,true,true) then - equip_success=true - ec:RegisterFlagEffect(id,RESET_EVENT|RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,fid,aux.Stringid(id,2)) - end - end - Duel.EquipComplete() - if equip_success then - --Any battle damage it inflicts to your opponent is halved while equipped with any of those Equip Spells - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetDescription(aux.Stringid(id,3)) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CHANGE_BATTLE_DAMAGE) - e1:SetCondition(function(e) return e:GetHandler():GetEquipGroup():IsExists(function(ec) return ec:GetFlagEffectLabel(id)==fid end,1,nil) end) - e1:SetValue(aux.ChangeBattleDamage(1,HALF_DAMAGE)) - e1:SetReset(RESET_EVENT|RESETS_STANDARD) - tc:RegisterEffect(e1) - end - end -end \ No newline at end of file diff --git a/pre-release/c101303079.lua b/pre-release/c101303079.lua deleted file mode 100644 index d4286f796f..0000000000 --- a/pre-release/c101303079.lua +++ /dev/null @@ -1,71 +0,0 @@ ---舌先減少 ---Tip of the Tongue Reduction ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Negate that opponent's effect that was activated by declaring exactly 1 card name, then you can add 1 card with that name from your Deck to your hand - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_DISABLE+CATEGORY_TOHAND+CATEGORY_SEARCH) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_CHAINING) - e1:SetCondition(s.discon) - e1:SetTarget(s.distg) - e1:SetOperation(s.disop) - c:RegisterEffect(e1) - --Make 1 face-up monster your opponent controls lose 500 ATK - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_ATKCHANGE) - e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) - e2:SetCode(EVENT_DESTROYED) - e2:SetCondition(s.atkcon) - e2:SetTarget(s.atktg) - e2:SetOperation(s.atkop) - c:RegisterEffect(e2) -end -function s.discon(e,tp,eg,ep,ev,re,r,rp) - local ex,cg,ct,cp,cv=Duel.GetOperationInfo(ev,CATEGORY_ANNOUNCE) - return rp==1-tp and ex and cv&(ANNOUNCE_CARD|ANNOUNCE_CARD_FILTER)>0 and Duel.IsChainDisablable(ev) -end -function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return true end - Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thfilter(c,code) - return c:IsCode(code) and c:IsAbleToHand() -end -function s.disop(e,tp,eg,ep,ev,re,r,rp) - if Duel.NegateEffect(ev) then - local declared_card=Duel.GetChainInfo(ev,CHAININFO_TARGET_PARAM) - if Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil,declared_card) - and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil,declared_card) - if #g>0 then - Duel.BreakEffect() - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end - end - end -end -function s.atkcon(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - return c:IsPreviousPosition(POS_FACEDOWN) and c:IsPreviousControler(tp) and c:IsPreviousLocation(LOCATION_ONFIELD) - and rp==1-tp and c:IsReason(REASON_EFFECT) -end -function s.atktg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsFaceup() end - if chk==0 then return Duel.IsExistingTarget(Card.IsFaceup,tp,0,LOCATION_MZONE,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATKDEF) - Duel.SelectTarget(tp,Card.IsFaceup,tp,0,LOCATION_MZONE,1,1,nil) -end -function s.atkop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and tc:IsFaceup() then - --It loses 500 ATK - tc:UpdateAttack(-500,nil,e:GetHandler()) - end -end \ No newline at end of file diff --git a/pre-release/c101303080.lua b/pre-release/c101303080.lua deleted file mode 100644 index 8892b3526a..0000000000 --- a/pre-release/c101303080.lua +++ /dev/null @@ -1,115 +0,0 @@ ---死地誤算守護 ---Shichigosan Shugo ---scripted by pyrQ -local s,id=GetID() -function s.initial_effect(c) - --Special Summon 1 Level/Rank 1 monster from either GY to your field, and if you do, equip this card to it - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_EQUIP) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCost(aux.RemainFieldCost) - e1:SetTarget(s.sptg) - e1:SetOperation(s.spop) - e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) - c:RegisterEffect(e1) - --Increase the equipped monster's Level/Rank by 1 - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_LVCHANGE) - e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F) - e2:SetCode(EVENT_PHASE+PHASE_END) - e2:SetRange(LOCATION_SZONE) - e2:SetCountLimit(1) - e2:SetCondition(function(e) return e:GetHandler():HasFlagEffect(id) end) - e2:SetOperation(s.lvrkop) - c:RegisterEffect(e2) - --● 3+: It gains ATK equal to its original ATK - local e3=Effect.CreateEffect(c) - e3:SetType(EFFECT_TYPE_EQUIP) - e3:SetCode(EFFECT_UPDATE_ATTACK) - e3:SetCondition(s.effcon(3)) - e3:SetValue(function(e,c) return c:GetBaseAttack() end) - c:RegisterEffect(e3) - --● 5+: It is unaffected by your opponent's activated effects - local e4=Effect.CreateEffect(c) - e4:SetType(EFFECT_TYPE_EQUIP) - e4:SetCode(EFFECT_IMMUNE_EFFECT) - e4:SetCondition(s.effcon(5)) - e4:SetValue(function(e,te) return te:GetOwnerPlayer()==1-e:GetHandlerPlayer() and te:IsActivated() end) - c:RegisterEffect(e4) - --Send all cards on the field to the GY - local e5=Effect.CreateEffect(c) - e5:SetDescription(aux.Stringid(id,2)) - e5:SetCategory(CATEGORY_TOGRAVE) - e5:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F) - e5:SetCode(EVENT_PHASE+PHASE_STANDBY) - e5:SetRange(LOCATION_SZONE) - e5:SetCountLimit(1) - e5:SetCondition(function(e,tp) return Duel.IsTurnPlayer(tp) and s.effcon(7)(e) end) - e5:SetTarget(s.tgtg) - e5:SetOperation(s.tgop) - c:RegisterEffect(e5) -end -function s.spfilter(c,e,tp) - return (c:IsLevel(1) or c:IsRank(1)) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,PLAYER_EITHER,LOCATION_GRAVE) - Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,tp,0) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return c:CancelToGrave(false) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local sc=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,nil,e,tp):GetFirst() - if sc and Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP)>0 and c:IsRelateToEffect(e) - and not c:IsStatus(STATUS_LEAVE_CONFIRMED) and Duel.Equip(tp,c,sc) then - c:RegisterFlagEffect(id,RESET_EVENT|RESETS_STANDARD,0,1) - --Equip limit - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_EQUIP_LIMIT) - e1:SetValue(function(e,c) return c==sc end) - e1:SetReset(RESET_EVENT|RESETS_STANDARD) - c:RegisterEffect(e1) - else - c:CancelToGrave(false) - end -end -function s.lvrkop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local ec=c:GetEquipTarget() - local eff_code=(ec:HasLevel() and EFFECT_UPDATE_LEVEL) - or (ec:HasRank() and EFFECT_UPDATE_RANK) - --Increase the equipped monster's Level/Rank by 1 - local e1=Effect.CreateEffect(c) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(eff_code) - e1:SetValue(1) - e1:SetReset(RESET_EVENT|RESETS_STANDARD) - ec:RegisterEffect(e1) -end -function s.effcon(level_rank) - return function(e) - local c=e:GetHandler() - local ec=c:GetEquipTarget() - return c:HasFlagEffect(id) and (ec:IsLevelAbove(level_rank) or ec:IsRankAbove(level_rank)) - end -end -function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) - local ct=Duel.GetFieldGroupCount(tp,LOCATION_ONFIELD,LOCATION_ONFIELD) - if chk==0 then return ct>0 end - Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,ct,PLAYER_ALL,LOCATION_ONFIELD) -end -function s.tgop(e,tp,eg,ep,ev,re,r,rp) - local g=Duel.GetFieldGroup(tp,LOCATION_ONFIELD,LOCATION_ONFIELD) - if #g>0 then - Duel.SendtoGrave(g,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303101.lua b/pre-release/c101303101.lua deleted file mode 100644 index 9f6501d181..0000000000 --- a/pre-release/c101303101.lua +++ /dev/null @@ -1,78 +0,0 @@ ---ヴァレット・ローダー ---Rokket Loader ---Scripted by Eerie Code -local s,id=GetID() -function s.initial_effect(c) - --Add 1 Level 7 DARK Dragon monster from your Deck to your hand - local e1a=Effect.CreateEffect(c) - e1a:SetDescription(aux.Stringid(id,0)) - e1a:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1a:SetProperty(EFFECT_FLAG_DELAY) - e1a:SetCode(EVENT_SUMMON_SUCCESS) - e1a:SetCountLimit(1,{id,0}) - e1a:SetTarget(s.thtg) - e1a:SetOperation(s.thop) - c:RegisterEffect(e1a) - local e1b=e1a:Clone() - e1b:SetCode(EVENT_SPSUMMON_SUCCESS) - c:RegisterEffect(e1b) - --Make 1 face-up monster on the field become DARK until the end of this turn - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,{id,1}) - e2:SetCost(Cost.SelfBanish) - e2:SetTarget(s.attrtg) - e2:SetOperation(s.attrop) - c:RegisterEffect(e2) -end -function s.thfilter(c) - return c:IsLevel(7) and c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_DRAGON) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end - local c=e:GetHandler() - --You cannot Special Summon from the Extra Deck for the rest of this turn, except DARK monsters - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e1:SetTargetRange(1,0) - e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsAttribute(ATTRIBUTE_DARK) end) - e1:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e1,tp) - --"Clock Lizard" check - aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalAttribute(ATTRIBUTE_DARK) end) -end -function s.attrtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsAttributeExcept(ATTRIBUTE_DARK) and chkc:IsFaceup() end - if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(Card.IsAttributeExcept,ATTRIBUTE_DARK),tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) - Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsAttributeExcept,ATTRIBUTE_DARK),tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) -end -function s.attrop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and tc:IsFaceup() then - --It becomes DARK until the end of this turn - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e1:SetCode(EFFECT_CHANGE_ATTRIBUTE) - e1:SetValue(ATTRIBUTE_DARK) - e1:SetReset(RESETS_STANDARD_PHASE_END) - tc:RegisterEffect(e1) - end -end \ No newline at end of file diff --git a/pre-release/c101303102.lua b/pre-release/c101303102.lua deleted file mode 100644 index 87b116a6ad..0000000000 --- a/pre-release/c101303102.lua +++ /dev/null @@ -1,74 +0,0 @@ ---ホロウヴァレット・ドラゴン ---Hollowrokket Dragon ---Scripted by ahtelel -local s,id=GetID() -function s.initial_effect(c) - --Destroy this card, then excavate up to 6 cards from the top of your opponent's Deck, and if you do, banish 1 excavated card, also place the rest on top of the Deck in the same order - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_DESTROY+CATEGORY_REMOVE) - e1:SetType(EFFECT_TYPE_QUICK_O) - e1:SetCode(EVENT_CHAINING) - e1:SetRange(LOCATION_MZONE) - e1:SetCountLimit(1,id) - e1:SetCondition(s.rmcon) - e1:SetTarget(s.rmtg) - e1:SetOperation(s.rmop) - c:RegisterEffect(e1) - --Special Summon 1 "Rokket" monster from your Deck, except "Hollowrokket Dragon" - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e2:SetCode(EVENT_PHASE+PHASE_END) - e2:SetRange(LOCATION_GRAVE) - e2:SetCountLimit(1,{id,1}) - e2:SetCondition(function(e) local c=e:GetHandler() return c:GetTurnID()==Duel.GetTurnCount() and c:IsReason(REASON_DESTROY) and c:IsReason(REASON_BATTLE|REASON_EFFECT) and c:IsPreviousLocation(LOCATION_ONFIELD) end) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - c:RegisterEffect(e2) -end -s.listed_names={id} -s.listed_series={SET_ROKKET} -function s.rmcon(e,tp,eg,ep,ev,re,r,rp) - if not (re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) and re:IsActiveType(TYPE_LINK)) then return false end - local tg=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS) - return tg and tg:IsContains(e:GetHandler()) -end -function s.rmtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetFieldGroupCount(tp,0,LOCATION_DECK)>5 and Duel.IsPlayerCanRemove(tp) end - Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,1-tp,LOCATION_DECK) -end -function s.rmop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - if c:IsRelateToEffect(e) and Duel.Destroy(c,REASON_EFFECT)>0 then - local ct=math.min(6,Duel.GetFieldGroupCount(tp,0,LOCATION_DECK)) - if ct==0 then return end - local ac=ct==1 and ct or Duel.AnnounceNumberRange(tp,1,ct) - Duel.BreakEffect() - Duel.ConfirmDecktop(1-tp,ac) - local g=Duel.GetDecktopGroup(1-tp,ac) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) - local sg=g:FilterSelect(tp,Card.IsAbleToRemove,1,1,nil) - if #sg>0 then - Duel.DisableShuffleCheck(true) - Duel.Remove(sg,POS_FACEUP,REASON_EFFECT) - end - end -end -function s.spfilter(c,e,tp) - return c:IsSetCard(SET_ROKKET) and not c:IsCode(id) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) -end -function s.spop(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,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c101303103.lua b/pre-release/c101303103.lua deleted file mode 100644 index a334ada03a..0000000000 --- a/pre-release/c101303103.lua +++ /dev/null @@ -1,77 +0,0 @@ ---ヴァレット・デトネイター ---Rokket Detonator ---Scripted by ahtelel -local s,id=GetID() -function s.initial_effect(c) - --If you control a DARK Dragon Link Monster, you can Special Summon this card (from your hand) - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_FIELD) - e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) - e1:SetCode(EFFECT_SPSUMMON_PROC) - e1:SetRange(LOCATION_HAND) - e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) - e1:SetCondition(s.selfspcon) - c:RegisterEffect(e1) - --Special Summon 1 DARK Dragon Monster Card from your Spell & Trap Zone - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_SPECIAL_SUMMON) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.sptg) - e2:SetOperation(s.spop) - c:RegisterEffect(e2) -end -function s.selfspconfilter(c) - return c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_DRAGON) and c:IsLinkMonster() and c:IsFaceup() -end -function s.selfspcon(e,c) - if c==nil then return true end - local tp=c:GetControler() - return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingMatchingCard(s.selfspconfilter,tp,LOCATION_MZONE,0,1,nil) -end -function s.spfilter(c,e,tp) - return c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_DRAGON) and c:IsMonsterCard() and c:IsFaceup() - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsLocation(LOCATION_STZONE) and chkc:IsControler(tp) and s.spfilter(chkc,e,tp) end - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 - and Duel.IsExistingTarget(s.spfilter,tp,LOCATION_STZONE,0,1,nil,e,tp) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectTarget(tp,s.spfilter,tp,LOCATION_STZONE,0,1,1,nil,e,tp) - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,0) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - local c=e:GetHandler() - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) and Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP) then - --It cannot attack - local e1=Effect.CreateEffect(c) - e1:SetDescription(3206) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_ATTACK) - e1:SetReset(RESET_EVENT|RESETS_STANDARD) - tc:RegisterEffect(e1,true) - --Its effects are negated - tc:NegateEffects(c) - end - Duel.SpecialSummonComplete() - --You cannot Special Summon from the Extra Deck for the rest of this turn, except DARK monsters - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,2)) - e2:SetType(EFFECT_TYPE_FIELD) - e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) - e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) - e2:SetTargetRange(1,0) - e2:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsAttribute(ATTRIBUTE_DARK) end) - e2:SetReset(RESET_PHASE|PHASE_END) - Duel.RegisterEffect(e2,tp) - --"Clock Lizard" check - aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalAttribute(ATTRIBUTE_DARK) end) -end \ No newline at end of file diff --git a/pre-release/c101303104.lua b/pre-release/c101303104.lua deleted file mode 100644 index e0ce041758..0000000000 --- a/pre-release/c101303104.lua +++ /dev/null @@ -1,113 +0,0 @@ ---ヴァレルロード・FF・ドラゴン ---Borreload Fatal Flare Dragon ---Scripted by Eerie Code -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Fusion Materials: 1 DARK Link Monster + 1 DARK monster - Fusion.AddProcMix(c,true,true,s.matfilter,aux.FilterBoolFunctionEx(Card.IsAttribute,ATTRIBUTE_DARK)) - --Add 1 "Rokket" monster from your Deck to your hand - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetCountLimit(1,{id,0}) - e1:SetCondition(function(e) return e:GetHandler():IsFusionSummoned() end) - e1:SetTarget(s.thtg) - e1:SetOperation(s.thop) - c:RegisterEffect(e1) - --Equip 1 DARK Link MOnster from your GY or banishment to 1 DARK monster you control as an Equip Spell that gives it 500 ATK - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_EQUIP) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.eqtg) - e2:SetOperation(s.eqop) - c:RegisterEffect(e2) - --Destroy 1 card on the field - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,2)) - e3:SetCategory(CATEGORY_DESTROY) - e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e3:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) - e3:SetCode(EVENT_BE_MATERIAL) - e3:SetCountLimit(1,{id,2}) - e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return e:GetHandler():IsLocation(LOCATION_GRAVE) and r==REASON_LINK end) - e3:SetTarget(s.destg) - e3:SetOperation(s.desop) - c:RegisterEffect(e3) -end -s.listed_series={SET_ROKKET} -function s.matfilter(c,sc,st,tp) - return c:IsAttribute(ATTRIBUTE_DARK,sc,st,tp) and c:IsType(TYPE_LINK,sc,st,tp) -end -function s.thfilter(c) - return c:IsSetCard(SET_ROKKET) and c:IsMonster() and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end -function s.eqfilter(c,tp) - return c:IsAttribute(ATTRIBUTE_DARK) and c:IsLinkMonster() and c:IsFaceup() and c:CheckUniqueOnField(tp) - and not c:IsForbidden() -end -function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsAttribute(ATTRIBUTE_DARK) and chkc:IsFaceup() end - if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 - and Duel.IsExistingTarget(aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_DARK),tp,LOCATION_MZONE,0,1,nil) - and Duel.IsExistingMatchingCard(s.eqfilter,tp,LOCATION_GRAVE|LOCATION_REMOVED,0,1,nil,tp) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) - Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_DARK),tp,LOCATION_MZONE,0,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_EQUIP,nil,1,tp,LOCATION_GRAVE|LOCATION_REMOVED) -end -function s.eqop(e,tp,eg,ep,ev,re,r,rp) - if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end - local tc=Duel.GetFirstTarget() - if tc:IsFacedown() or not tc:IsRelateToEffect(e) then return end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) - local ec=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.eqfilter),tp,LOCATION_GRAVE|LOCATION_REMOVED,0,1,1,nil,tp):GetFirst() - if ec and Duel.Equip(tp,ec,tc) then - --The equipped monster gains 500 ATK - local e1=Effect.CreateEffect(ec) - e1:SetType(EFFECT_TYPE_EQUIP) - e1:SetCode(EFFECT_UPDATE_ATTACK) - e1:SetValue(500) - e1:SetReset(RESET_EVENT|RESETS_STANDARD) - ec:RegisterEffect(e1) - --Equip limit - local e2=Effect.CreateEffect(ec) - e2:SetType(EFFECT_TYPE_SINGLE) - e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) - e2:SetCode(EFFECT_EQUIP_LIMIT) - e2:SetValue(function(e,c) return c==tc end) - e2:SetReset(RESET_EVENT|RESETS_STANDARD) - ec:RegisterEffect(e2) - end -end -function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsOnField() end - if chk==0 then return Duel.IsExistingTarget(nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local g=Duel.SelectTarget(tp,nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) -end -function s.desop(e,tp,eg,ep,ev,re,r,rp) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) then - Duel.Destroy(tc,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303105.lua b/pre-release/c101303105.lua deleted file mode 100644 index 61b9ab0997..0000000000 --- a/pre-release/c101303105.lua +++ /dev/null @@ -1,93 +0,0 @@ ---ヴァレルシュラウド・ドラゴン ---Borrelshroud Dragon ---Scripted by Eerie Code -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Link Summon procedure: 3+ Effect Monsters - Link.AddProcedure(c,aux.FilterBoolFunctionEx(Card.IsType,TYPE_EFFECT),3) - --Your opponent cannot Tribute this card on the field - local e1a=Effect.CreateEffect(c) - e1a:SetType(EFFECT_TYPE_SINGLE) - e1a:SetProperty(EFFECT_FLAG_SINGLE_RANGE) - e1a:SetCode(EFFECT_UNRELEASABLE_SUM) - e1a:SetRange(LOCATION_MZONE) - e1a:SetValue(function(e,c) return c and not c:IsControler(e:GetHandlerPlayer()) end) - c:RegisterEffect(e1a) - local e1b=Effect.CreateEffect(c) - e1b:SetType(EFFECT_TYPE_FIELD) - e1b:SetProperty(EFFECT_FLAG_PLAYER_TARGET) - e1b:SetCode(EFFECT_CANNOT_RELEASE) - e1b:SetRange(LOCATION_MZONE) - e1b:SetTargetRange(0,1) - e1b:SetTarget(function(e,c) return c==e:GetHandler() end) - e1b:SetValue(1) - c:RegisterEffect(e1b) - --Negate the effects of 1 face-up card your opponent controls, then destroy 1 "Rokket" monster you control - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,0)) - e2:SetCategory(CATEGORY_DISABLE+CATEGORY_DESTROY) - e2:SetType(EFFECT_TYPE_QUICK_O) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetCode(EVENT_FREE_CHAIN) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1) - e2:SetCondition(function(e) return Duel.IsMainPhase() end) - e2:SetTarget(s.distg) - e2:SetOperation(s.disop) - e2:SetHintTiming(0,TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) - c:RegisterEffect(e2) - --Special Summon 1 Link-4 or lower "Borrel" Link Monster from your Extra Deck - local e3=Effect.CreateEffect(c) - e3:SetDescription(aux.Stringid(id,1)) - e3:SetCategory(CATEGORY_SPECIAL_SUMMON) - e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) - e3:SetProperty(EFFECT_FLAG_NO_TURN_RESET) - e3:SetCode(EVENT_PHASE+PHASE_BATTLE_START) - e3:SetRange(LOCATION_MZONE) - e3:SetCountLimit(1) - e3:SetTarget(s.sptg) - e3:SetOperation(s.spop) - c:RegisterEffect(e3) -end -s.listed_series={SET_ROKKET,SET_BORREL} -function s.distg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsFaceup() and chkc:IsSetCard(SET_ROKKET) end - if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(Card.IsSetCard,SET_ROKKET),tp,LOCATION_MZONE,0,1,nil) - and Duel.IsExistingMatchingCard(Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local g=Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsSetCard,SET_ROKKET),tp,LOCATION_MZONE,0,1,1,nil) - Duel.SetChainLimit(function(e,ep,tp) return tp==ep end) - Duel.SetOperationInfo(0,CATEGORY_DISABLE,nil,1,1-tp,LOCATION_ONFIELD) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) -end -function s.disop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_NEGATE) - local sc=Duel.SelectMatchingCard(tp,Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,1,nil):GetFirst() - if not sc then return end - Duel.HintSelection(sc) - if sc:IsCanBeDisabledByEffect(e) then - --Negate its effects - sc:NegateEffects(e:GetHandler(),nil,true) - local tc=Duel.GetFirstTarget() - if tc:IsRelateToEffect(e) then - Duel.BreakEffect() - Duel.Destroy(tc,REASON_EFFECT) - end - end -end -function s.spfilter(c,e,tp) - return c:IsLinkBelow(4) and c:IsSetCard(SET_BORREL) and Duel.GetLocationCountFromEx(tp,tp,nil,c)>0 - and c:IsCanBeSpecialSummoned(e,0,tp,false,false) -end -function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_EXTRA,0,1,nil,e,tp) end - Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) -end -function s.spop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) - local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_EXTRA,0,1,1,nil,e,tp) - if #g>0 then - Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) - end -end \ No newline at end of file diff --git a/pre-release/c101303106.lua b/pre-release/c101303106.lua deleted file mode 100644 index 77a56dcdbb..0000000000 --- a/pre-release/c101303106.lua +++ /dev/null @@ -1,77 +0,0 @@ ---トゥリスヴァレル・ドラゴン ---Trisborrel Dragon ---Scripted by Eerie Code -local s,id=GetID() -function s.initial_effect(c) - c:EnableReviveLimit() - --Link Summon procedure: 2+ DARK Dragon monsters, including a "Rokket" monster - Link.AddProcedure(c,s.matfilter,2,nil,s.matcheck) - --Add 1 "Rapid Trigger", "Heavy Interlock", or "Double Trigger" from your Deck to your hand - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) - e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) - e1:SetProperty(EFFECT_FLAG_DELAY) - e1:SetCode(EVENT_SPSUMMON_SUCCESS) - e1:SetCountLimit(1,{id,0}) - e1:SetCondition(function(e) return e:GetHandler():IsLinkSummoned() end) - e1:SetTarget(s.thtg) - e1:SetOperation(s.thop) - c:RegisterEffect(e1) - --Destroy 1 face-up card you control, and if you do, add 1 DARK Dragon monster from your GY to your hand - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetCategory(CATEGORY_DESTROY+CATEGORY_TOHAND) - e2:SetType(EFFECT_TYPE_IGNITION) - e2:SetProperty(EFFECT_FLAG_CARD_TARGET) - e2:SetRange(LOCATION_MZONE) - e2:SetCountLimit(1,{id,1}) - e2:SetTarget(s.destg) - e2:SetOperation(s.desop) - c:RegisterEffect(e2) -end -s.listed_names={67526112,20071842,101303107} --"Rapid Trigger", "Heavy Interlock", "Double Trigger" -s.listed_series={SET_ROKKET} -function s.matfilter(c,sc,st,tp) - return c:IsAttribute(ATTRIBUTE_DARK,sc,st,tp) and c:IsRace(RACE_DRAGON,sc,st,tp) -end -function s.matcheck(g,lc,sumtype,tp) - return g:IsExists(Card.IsSetCard,1,nil,SET_ROKKET,lc,sumtype,tp) -end -function s.deckthfilter(c) - return c:IsCode(67526112,20071842,101303107) and c:IsAbleToHand() -end -function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return Duel.IsExistingMatchingCard(s.deckthfilter,tp,LOCATION_DECK,0,1,nil) end - Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) -end -function s.thop(e,tp,eg,ep,ev,re,r,rp) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local g=Duel.SelectMatchingCard(tp,s.deckthfilter,tp,LOCATION_DECK,0,1,1,nil) - if #g>0 then - Duel.SendtoHand(g,nil,REASON_EFFECT) - Duel.ConfirmCards(1-tp,g) - end -end -function s.gythfilter(c) - return c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_DRAGON) and c:IsAbleToHand() -end -function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) - if chkc then return false end - if chk==0 then return Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_ONFIELD,0,1,nil) - and Duel.IsExistingTarget(s.gythfilter,tp,LOCATION_GRAVE,0,1,nil) end - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) - local dg=Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_ONFIELD,0,1,1,nil) - Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) - local hg=Duel.SelectTarget(tp,s.gythfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) - Duel.SetOperationInfo(0,CATEGORY_DESTROY,dg,1,tp,0) - Duel.SetOperationInfo(0,CATEGORY_TOHAND,hg,1,tp,0) -end -function s.desop(e,tp,eg,ep,ev,re,r,rp) - local tg=Duel.GetTargetCards(e) - if #tg==0 then return end - local fc,gyc=tg:Split(Card.IsLocation,nil,LOCATION_ONFIELD) - if fc and Duel.Destroy(fc,REASON_EFFECT)>0 and gyc then - Duel.SendtoHand(gyc,nil,REASON_EFFECT) - end -end \ No newline at end of file diff --git a/pre-release/c101303107.lua b/pre-release/c101303107.lua deleted file mode 100644 index 9c63c53d33..0000000000 --- a/pre-release/c101303107.lua +++ /dev/null @@ -1,97 +0,0 @@ ---ダブル・トリガー ---Double Trigger ---Scripted by Eerie Code -local s,id=GetID() -function s.initial_effect(c) - local fusion_params={ - handler=c, - matfilter=aux.FALSE, - extrafil=s.fextra, - extraop=Fusion.BanishMaterial, - extratg=s.extratg - } - local ritual_params={ - handler=c, - lvtype=RITPROC_GREATER, - forcedselection=s.forcedselection, - matfilter=aux.FilterBoolFunction(Card.IsLocation,LOCATION_GRAVE), - extrafil=s.rextra, - extratg=s.extratg - } - --Activate 1 of these effects - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_FREE_CHAIN) - e1:SetCost(s.effcost(fusion_params,ritual_params)) - e1:SetTarget(s.efftg(fusion_params,ritual_params)) - e1:SetOperation(s.effop(fusion_params,ritual_params)) - c:RegisterEffect(e1) -end -s.listed_series={SET_ROKKET} -function s.matcheck(tp,sg,fc) - return sg:IsExists(Card.IsSetCard,1,nil,SET_ROKKET,fc,SUMMON_TYPE_FUSION,tp) -end -function s.fextra(e,tp,mg) - if not Duel.IsPlayerAffectedByEffect(tp,CARD_SPIRIT_ELIMINATION) then - return Duel.GetMatchingGroup(Fusion.IsMonsterFilter(Card.IsAbleToRemove),tp,LOCATION_GRAVE,0,nil),s.matcheck - end - return nil,s.matcheck -end -function s.extratg(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return true end - Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_GRAVE) -end -function s.rextra(e,tp,eg,ep,ev,re,r,rp,chk) - if not Duel.IsPlayerAffectedByEffect(tp,CARD_SPIRIT_ELIMINATION) then - return Duel.GetMatchingGroup(aux.AND(Card.HasLevel,Card.IsAbleToRemove),tp,LOCATION_GRAVE,0,nil) - end -end -function s.forcedselection(e,tp,sg,sc) - return sg:IsExists(Card.IsSetCard,1,nil,SET_ROKKET) -end -function s.effcost(fusion_params,ritual_params) - return function(e,tp,eg,ep,ev,re,r,rp,chk) - e:SetLabel(-100) - local b1=not Duel.HasFlagEffect(tp,id) - and Fusion.SummonEffTG(fusion_params)(e,tp,eg,ep,ev,re,r,rp,0) - local b2=not Duel.HasFlagEffect(tp,id+100) - and Ritual.Target(ritual_params)(e,tp,eg,ep,ev,re,r,rp,0) - if chk==0 then return b1 or b2 end - end -end -function s.efftg(fusion_params,ritual_params) - return function(e,tp,eg,ep,ev,re,r,rp,chk) - local cost_skip=e:GetLabel()~=-100 - local b1=(cost_skip or not Duel.HasFlagEffect(tp,id)) - and Fusion.SummonEffTG(fusion_params)(e,tp,eg,ep,ev,re,r,rp,0) - local b2=(cost_skip or not Duel.HasFlagEffect(tp,id+100)) - and Ritual.Target(ritual_params)(e,tp,eg,ep,ev,re,r,rp,0) - if chk==0 then e:SetLabel(0) return b1 or b2 end - local op=Duel.SelectEffect(tp, - {b1,aux.Stringid(id,1)}, - {b2,aux.Stringid(id,2)}) - e:SetLabel(op) - if op==1 then - e:SetCategory(CATEGORY_REMOVE+CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON) - if not cost_skip then Duel.RegisterFlagEffect(tp,id,RESET_PHASE|PHASE_END,0,1) end - Fusion.SummonEffTG(fusion_params)(e,tp,eg,ep,ev,re,r,rp,1) - elseif op==2 then - e:SetCategory(CATEGORY_REMOVE+CATEGORY_SPECIAL_SUMMON) - if not cost_skip then Duel.RegisterFlagEffect(tp,id+100,RESET_PHASE|PHASE_END,0,1) end - Ritual.Target(ritual_params)(e,tp,eg,ep,ev,re,r,rp,1) - end - end -end -function s.effop(fusion_params,ritual_params) - return function(e,tp,eg,ep,ev,re,r,rp) - local op=e:GetLabel() - if op==1 then - --Fusion Summon 1 Fusion Monster from your Extra Deck, by banishing its materials from your GY, including a "Rokket" monster - Fusion.SummonEffOP(fusion_params)(e,tp,eg,ep,ev,re,r,rp) - elseif op==2 then - --Ritual Summon 1 Ritual Monster from your hand, by banishing monsters from your GY whose total Levels equal or exceed that monster's Level, including a "Rokket" monster - Ritual.Operation(ritual_params)(e,tp,eg,ep,ev,re,r,rp) - end - end -end \ No newline at end of file diff --git a/pre-release/c101303108.lua b/pre-release/c101303108.lua deleted file mode 100644 index 1ce421066e..0000000000 --- a/pre-release/c101303108.lua +++ /dev/null @@ -1,59 +0,0 @@ ---ヴァレル・リブート ---Borrel Reboot ---Scripted by ahtelel -local s,id=GetID() -function s.initial_effect(c) - --Negate the activation of an opponent's Spell/Trap Card, and if you do, Set that card - local e1=Effect.CreateEffect(c) - e1:SetDescription(aux.Stringid(id,0)) - e1:SetCategory(CATEGORY_NEGATE) - e1:SetType(EFFECT_TYPE_ACTIVATE) - e1:SetCode(EVENT_CHAINING) - e1:SetCondition(s.condition) - e1:SetCost(s.cost) - e1:SetTarget(s.target) - e1:SetOperation(s.activate) - c:RegisterEffect(e1) - --You can activate this card from your hand by paying half your LP - local e2=Effect.CreateEffect(c) - e2:SetDescription(aux.Stringid(id,1)) - e2:SetType(EFFECT_TYPE_SINGLE) - e2:SetCode(EFFECT_TRAP_ACT_IN_HAND) - e2:SetValue(function(e,c) e:SetLabel(1) end) - c:RegisterEffect(e2) - e1:SetLabelObject(e2) -end -s.listed_series={SET_ROKKET,SET_BORREL} -function s.condition(e,tp,eg,ep,ev,re,r,rp) - return rp==1-tp and re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsSpellTrapEffect() and Duel.IsChainNegatable(ev) - and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsSetCard,{SET_ROKKET,SET_BORREL}),tp,LOCATION_MZONE,0,1,nil) -end -function s.cost(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then e:GetLabelObject():SetLabel(0) return true end - if e:GetLabelObject():GetLabel()>0 then - e:GetLabelObject():SetLabel(0) - Duel.PayLPCost(tp,Duel.GetLP(tp)//2) - end -end -function s.target(e,tp,eg,ep,ev,re,r,rp,chk) - if chk==0 then return true end - Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,tp,0) -end -function s.activate(e,tp,eg,ep,ev,re,r,rp) - local rc=re:GetHandler() - if Duel.NegateActivation(ev) and rc:IsRelateToEffect(re) and rc:IsSSetable(true) then - rc:CancelToGrave() - Duel.ChangePosition(rc,POS_FACEDOWN) - rc:SetStatus(STATUS_ACTIVATE_DISABLED,false) - rc:SetStatus(STATUS_SET_TURN,false) - Duel.RaiseEvent(rc,EVENT_SSET,e,REASON_EFFECT,tp,tp,0) - --It cannot be activated this turn - local e1=Effect.CreateEffect(e:GetHandler()) - e1:SetDescription(aux.Stringid(id,2)) - e1:SetType(EFFECT_TYPE_SINGLE) - e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT) - e1:SetCode(EFFECT_CANNOT_TRIGGER) - e1:SetReset(RESET_EVENT|RESETS_CANNOT_ACT|RESET_PHASE|PHASE_END) - rc:RegisterEffect(e1) - end -end \ No newline at end of file From 418ab3c211d8f1984443b17dc11c5d3a19726e5c Mon Sep 17 00:00:00 2001 From: pyrQ <30827955+pyrQ@users.noreply.github.com> Date: Thu, 30 Oct 2025 14:40:24 +0200 Subject: [PATCH 2/2] Add files via upload --- official/c10136446.lua | 102 +++++++++++++++++++++++++++++ official/c10426067.lua | 88 +++++++++++++++++++++++++ official/c11035075.lua | 115 +++++++++++++++++++++++++++++++++ official/c11248645.lua | 84 ++++++++++++++++++++++++ official/c11852093.lua | 76 ++++++++++++++++++++++ official/c12157563.lua | 56 ++++++++++++++++ official/c12197223.lua | 58 +++++++++++++++++ official/c12375297.lua | 95 +++++++++++++++++++++++++++ official/c12975671.lua | 81 +++++++++++++++++++++++ official/c13379114.lua | 68 +++++++++++++++++++ official/c13597785.lua | 78 ++++++++++++++++++++++ official/c19304410.lua | 65 +++++++++++++++++++ official/c23219323.lua | 70 ++++++++++++++++++++ official/c24092792.lua | 73 +++++++++++++++++++++ official/c24431911.lua | 115 +++++++++++++++++++++++++++++++++ official/c25224340.lua | 70 ++++++++++++++++++++ official/c25554552.lua | 78 ++++++++++++++++++++++ official/c25940932.lua | 87 +++++++++++++++++++++++++ official/c26162470.lua | 85 ++++++++++++++++++++++++ official/c2725599.lua | 70 ++++++++++++++++++++ official/c27285068.lua | 72 +++++++++++++++++++++ official/c30064423.lua | 100 ++++++++++++++++++++++++++++ official/c30271097.lua | 98 ++++++++++++++++++++++++++++ official/c31286915.lua | 71 ++++++++++++++++++++ official/c38007649.lua | 73 +++++++++++++++++++++ official/c38129297.lua | 97 ++++++++++++++++++++++++++++ official/c39341885.lua | 113 ++++++++++++++++++++++++++++++++ official/c3957130.lua | 77 ++++++++++++++++++++++ official/c4079728.lua | 77 ++++++++++++++++++++++ official/c41516133.lua | 81 +++++++++++++++++++++++ official/c42125140.lua | 104 ++++++++++++++++++++++++++++++ official/c42302563.lua | 73 +++++++++++++++++++++ official/c46708514.lua | 91 ++++++++++++++++++++++++++ official/c47247792.lua | 82 +++++++++++++++++++++++ official/c47425162.lua | 91 ++++++++++++++++++++++++++ official/c47647354.lua | 70 ++++++++++++++++++++ official/c48469380.lua | 92 ++++++++++++++++++++++++++ official/c4891376.lua | 69 ++++++++++++++++++++ official/c4909946.lua | 100 ++++++++++++++++++++++++++++ official/c49181828.lua | 77 ++++++++++++++++++++++ official/c49652661.lua | 89 +++++++++++++++++++++++++ official/c50590801.lua | 70 ++++++++++++++++++++ official/c50604072.lua | 81 +++++++++++++++++++++++ official/c5121528.lua | 93 ++++++++++++++++++++++++++ official/c51548207.lua | 74 +++++++++++++++++++++ official/c51612489.lua | 73 +++++++++++++++++++++ official/c51826619.lua | 67 +++++++++++++++++++ official/c52335937.lua | 129 +++++++++++++++++++++++++++++++++++++ official/c53557529.lua | 75 +++++++++++++++++++++ official/c58769832.lua | 85 ++++++++++++++++++++++++ official/c5914858.lua | 75 +++++++++++++++++++++ official/c59374259.lua | 80 +++++++++++++++++++++++ official/c59581480.lua | 72 +++++++++++++++++++++ official/c63679166.lua | 37 +++++++++++ official/c64491754.lua | 70 ++++++++++++++++++++ official/c65514302.lua | 96 +++++++++++++++++++++++++++ official/c66452432.lua | 93 ++++++++++++++++++++++++++ official/c66736884.lua | 92 ++++++++++++++++++++++++++ official/c73819701.lua | 82 +++++++++++++++++++++++ official/c74631897.lua | 111 +++++++++++++++++++++++++++++++ official/c76666602.lua | 77 ++++++++++++++++++++++ official/c77675029.lua | 82 +++++++++++++++++++++++ official/c78397661.lua | 86 +++++++++++++++++++++++++ official/c78910832.lua | 97 ++++++++++++++++++++++++++++ official/c79519259.lua | 86 +++++++++++++++++++++++++ official/c84031359.lua | 77 ++++++++++++++++++++++ official/c84464389.lua | 113 ++++++++++++++++++++++++++++++++ official/c85154941.lua | 86 +++++++++++++++++++++++++ official/c85586937.lua | 92 ++++++++++++++++++++++++++ official/c85640370.lua | 71 ++++++++++++++++++++ official/c85976588.lua | 76 ++++++++++++++++++++++ official/c86098176.lua | 72 +++++++++++++++++++++ official/c86762958.lua | 99 ++++++++++++++++++++++++++++ official/c87607094.lua | 59 +++++++++++++++++ official/c87814728.lua | 66 +++++++++++++++++++ official/c87985506.lua | 57 ++++++++++++++++ official/c90764871.lua | 78 ++++++++++++++++++++++ official/c90880453.lua | 53 +++++++++++++++ official/c91002901.lua | 81 +++++++++++++++++++++++ official/c98829635.lua | 65 +++++++++++++++++++ official/c98937206.lua | 77 ++++++++++++++++++++++ official/c99941223.lua | 48 ++++++++++++++ pre-release/c100295111.lua | 85 ++++++++++++++++++++++++ pre-release/c100447018.lua | 87 +++++++++++++++++++++++++ pre-release/c100447019.lua | 78 ++++++++++++++++++++++ pre-release/c100447020.lua | 79 +++++++++++++++++++++++ pre-release/c100447021.lua | 78 ++++++++++++++++++++++ pre-release/c100447064.lua | 81 +++++++++++++++++++++++ pre-release/c100447101.lua | 85 ++++++++++++++++++++++++ pre-release/c100447102.lua | 84 ++++++++++++++++++++++++ pre-release/c100447103.lua | 68 +++++++++++++++++++ pre-release/c100447104.lua | 89 +++++++++++++++++++++++++ pre-release/c100447106.lua | 90 ++++++++++++++++++++++++++ pre-release/c100447107.lua | 101 +++++++++++++++++++++++++++++ pre-release/c100447108.lua | 113 ++++++++++++++++++++++++++++++++ pre-release/c100447109.lua | 104 ++++++++++++++++++++++++++++++ pre-release/c100448001.lua | 93 ++++++++++++++++++++++++++ pre-release/c100448002.lua | 79 +++++++++++++++++++++++ 98 files changed, 8058 insertions(+) create mode 100644 official/c10136446.lua create mode 100644 official/c10426067.lua create mode 100644 official/c11035075.lua create mode 100644 official/c11248645.lua create mode 100644 official/c11852093.lua create mode 100644 official/c12157563.lua create mode 100644 official/c12197223.lua create mode 100644 official/c12375297.lua create mode 100644 official/c12975671.lua create mode 100644 official/c13379114.lua create mode 100644 official/c13597785.lua create mode 100644 official/c19304410.lua create mode 100644 official/c23219323.lua create mode 100644 official/c24092792.lua create mode 100644 official/c24431911.lua create mode 100644 official/c25224340.lua create mode 100644 official/c25554552.lua create mode 100644 official/c25940932.lua create mode 100644 official/c26162470.lua create mode 100644 official/c2725599.lua create mode 100644 official/c27285068.lua create mode 100644 official/c30064423.lua create mode 100644 official/c30271097.lua create mode 100644 official/c31286915.lua create mode 100644 official/c38007649.lua create mode 100644 official/c38129297.lua create mode 100644 official/c39341885.lua create mode 100644 official/c3957130.lua create mode 100644 official/c4079728.lua create mode 100644 official/c41516133.lua create mode 100644 official/c42125140.lua create mode 100644 official/c42302563.lua create mode 100644 official/c46708514.lua create mode 100644 official/c47247792.lua create mode 100644 official/c47425162.lua create mode 100644 official/c47647354.lua create mode 100644 official/c48469380.lua create mode 100644 official/c4891376.lua create mode 100644 official/c4909946.lua create mode 100644 official/c49181828.lua create mode 100644 official/c49652661.lua create mode 100644 official/c50590801.lua create mode 100644 official/c50604072.lua create mode 100644 official/c5121528.lua create mode 100644 official/c51548207.lua create mode 100644 official/c51612489.lua create mode 100644 official/c51826619.lua create mode 100644 official/c52335937.lua create mode 100644 official/c53557529.lua create mode 100644 official/c58769832.lua create mode 100644 official/c5914858.lua create mode 100644 official/c59374259.lua create mode 100644 official/c59581480.lua create mode 100644 official/c63679166.lua create mode 100644 official/c64491754.lua create mode 100644 official/c65514302.lua create mode 100644 official/c66452432.lua create mode 100644 official/c66736884.lua create mode 100644 official/c73819701.lua create mode 100644 official/c74631897.lua create mode 100644 official/c76666602.lua create mode 100644 official/c77675029.lua create mode 100644 official/c78397661.lua create mode 100644 official/c78910832.lua create mode 100644 official/c79519259.lua create mode 100644 official/c84031359.lua create mode 100644 official/c84464389.lua create mode 100644 official/c85154941.lua create mode 100644 official/c85586937.lua create mode 100644 official/c85640370.lua create mode 100644 official/c85976588.lua create mode 100644 official/c86098176.lua create mode 100644 official/c86762958.lua create mode 100644 official/c87607094.lua create mode 100644 official/c87814728.lua create mode 100644 official/c87985506.lua create mode 100644 official/c90764871.lua create mode 100644 official/c90880453.lua create mode 100644 official/c91002901.lua create mode 100644 official/c98829635.lua create mode 100644 official/c98937206.lua create mode 100644 official/c99941223.lua create mode 100644 pre-release/c100295111.lua create mode 100644 pre-release/c100447018.lua create mode 100644 pre-release/c100447019.lua create mode 100644 pre-release/c100447020.lua create mode 100644 pre-release/c100447021.lua create mode 100644 pre-release/c100447064.lua create mode 100644 pre-release/c100447101.lua create mode 100644 pre-release/c100447102.lua create mode 100644 pre-release/c100447103.lua create mode 100644 pre-release/c100447104.lua create mode 100644 pre-release/c100447106.lua create mode 100644 pre-release/c100447107.lua create mode 100644 pre-release/c100447108.lua create mode 100644 pre-release/c100447109.lua create mode 100644 pre-release/c100448001.lua create mode 100644 pre-release/c100448002.lua diff --git a/official/c10136446.lua b/official/c10136446.lua new file mode 100644 index 0000000000..a73288e72a --- /dev/null +++ b/official/c10136446.lua @@ -0,0 +1,102 @@ +--黄昏の堕天使ルシファー +--Darklord Eveningstar +--Scripted by The Razgriz +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Fusion Materials: 2 Level 6 or higher DARK Fairy monsters + Fusion.AddProcMixN(c,true,true,s.matfilter,2) + --Your opponent cannot target this card with card effects + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e1:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET) + e1:SetRange(LOCATION_MZONE) + e1:SetValue(aux.tgoval) + c:RegisterEffect(e1) + --Set 1 "Darklord" Spell and 1 "Darklord" Trap from your Deck + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY) + e2:SetCode(EVENT_SPSUMMON_SUCCESS) + e2:SetCountLimit(1,id) + e2:SetCondition(function(e) return e:GetHandler():IsFusionSummoned() end) + e2:SetTarget(s.settg) + e2:SetOperation(s.setop) + c:RegisterEffect(e2) + --Apply the effect of 1 "Darklord" Spell/Trap in your GY, then shuffle it into the Deck + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_TODECK) + e3:SetType(EFFECT_TYPE_QUICK_O) + e3:SetProperty(EFFECT_FLAG_CARD_TARGET) + e3:SetCode(EVENT_FREE_CHAIN) + e3:SetRange(LOCATION_MZONE) + e3:SetCountLimit(1,{id,1}) + e3:SetCost(Cost.PayLP(1000)) + e3:SetTarget(s.copytg) + e3:SetOperation(s.copyop) + e3:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e3) +end +s.listed_series={SET_DARKLORD} +function s.matfilter(c,fc,sumtype,sump) + return c:IsLevelAbove(6) and c:IsAttribute(ATTRIBUTE_DARK,fc,sumtype,sump) and c:IsRace(RACE_FAIRY,fc,sumtype,sump) +end +function s.setfilter(c) + return c:IsSetCard(SET_DARKLORD) and c:IsSpellTrap() and c:IsSSetable() +end +function s.rescon(stzone_chk) + return function(sg,e,tp,mg) + return #sg==2 and (stzone_chk or sg:IsExists(Card.IsFieldSpell,1,nil)) and sg:IsExists(Card.IsSpell,1,nil) and sg:IsExists(Card.IsTrap,1,nil) + end +end +function s.settg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then + local stzone_chk=Duel.GetLocationCount(tp,LOCATION_SZONE)>=2 + local g=Duel.GetMatchingGroup(s.setfilter,tp,LOCATION_DECK,0,nil) + return #g>=2 and aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon(stzone_chk),0) + end +end +function s.setop(e,tp,eg,ep,ev,re,r,rp) + local stzone_chk=Duel.GetLocationCount(tp,LOCATION_SZONE)>=2 + local g=Duel.GetMatchingGroup(s.setfilter,tp,LOCATION_DECK,0,nil) + local sg=aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon(stzone_chk),1,tp,HINTMSG_SET) + if #sg==2 then + Duel.SSet(tp,sg) + end +end +function s.copyfilter(c) + return c:IsSetCard(SET_DARKLORD) and c:IsSpellTrap() and c:IsAbleToDeck() and c:CheckActivateEffect(false,true,false)~=nil +end +function s.copytg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.copyfilter(chkc) end + if chk==0 then return Duel.IsExistingTarget(s.copyfilter,tp,LOCATION_GRAVE,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) + local g=Duel.SelectTarget(tp,s.copyfilter,tp,LOCATION_GRAVE,0,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_TODECK,g,1,tp,0) +end +function s.copyop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if not tc:IsRelateToEffect(e) then return end + local te,ceg,cep,cev,cre,cr,crp=tc:CheckActivateEffect(false,true,true) + if not te then return end + local tg=te:GetTarget() + local op=te:GetOperation() + if tg then tg(te,tp,Group.CreateGroup(),PLAYER_NONE,0,e,REASON_EFFECT,PLAYER_NONE,1) end + Duel.BreakEffect() + tc:CreateEffectRelation(te) + Duel.BreakEffect() + local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS) + for etc in aux.Next(g) do + etc:CreateEffectRelation(te) + end + if op then op(te,tp,Group.CreateGroup(),PLAYER_NONE,0,e,REASON_EFFECT,PLAYER_NONE,1) end + tc:ReleaseEffectRelation(te) + for etc in aux.Next(g) do + etc:ReleaseEffectRelation(te) + end + Duel.BreakEffect() + Duel.SendtoDeck(te:GetHandler(),nil,SEQ_DECKSHUFFLE,REASON_EFFECT) +end \ No newline at end of file diff --git a/official/c10426067.lua b/official/c10426067.lua new file mode 100644 index 0000000000..aee7e644d4 --- /dev/null +++ b/official/c10426067.lua @@ -0,0 +1,88 @@ +--堕天使ジェフティ +--Darklord Djehuty +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Special Summon 1 "Darklord" monster from your Deck in Defense Position + local e1a=Effect.CreateEffect(c) + e1a:SetDescription(aux.Stringid(id,0)) + e1a:SetCategory(CATEGORY_SPECIAL_SUMMON) + e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1a:SetProperty(EFFECT_FLAG_DELAY) + e1a:SetCode(EVENT_SUMMON_SUCCESS) + e1a:SetCountLimit(1,id) + e1a:SetTarget(s.sptg) + e1a:SetOperation(s.spop) + c:RegisterEffect(e1a) + local e1b=e1a:Clone() + e1b:SetCode(EVENT_SPSUMMON_SUCCESS) + c:RegisterEffect(e1b) + --Add 1 "Darklord" card or "Forbidden" Quick-Play Spell from your GY to your hand + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TOHAND) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(s.thcon) + e2:SetCost(Cost.SelfBanish) + e2:SetTarget(s.thtg) + e2:SetOperation(s.thop) + c:RegisterEffect(e2) +end +s.listed_names={id} +s.listed_series={SET_DARKLORD,SET_FORBIDDEN} +function s.spfilter(c,e,tp) + return c:IsSetCard(SET_DARKLORD) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE) and not c:IsCode(id) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP_DEFENSE) + end + end + local c=e:GetHandler() + --You cannot Special Summon for the rest of this turn, except Fairy monsters + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return not c:IsRace(RACE_FAIRY) end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) + --Clock Lizard check + aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalRace(RACE_FAIRY) end) +end +function s.thconfilter(c) + return c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_FAIRY) and c:IsFusionMonster() and c:IsFaceup() +end +function s.thcon(e,tp,eg,ep,ev,re,r,rp) + return Duel.IsExistingMatchingCard(s.thconfilter,tp,LOCATION_MZONE,0,1,nil) +end +function s.thfilter(c) + return (c:IsSetCard(SET_DARKLORD) or (c:IsSetCard(SET_FORBIDDEN) and c:IsQuickPlaySpell())) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.thfilter(chkc) end + local c=e:GetHandler() + if chk==0 then return Duel.IsExistingTarget(s.thfilter,tp,LOCATION_GRAVE,0,1,c) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectTarget(tp,s.thfilter,tp,LOCATION_GRAVE,0,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,tp,0) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) then + Duel.SendtoHand(tc,nil,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c11035075.lua b/official/c11035075.lua new file mode 100644 index 0000000000..8892b3526a --- /dev/null +++ b/official/c11035075.lua @@ -0,0 +1,115 @@ +--死地誤算守護 +--Shichigosan Shugo +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Special Summon 1 Level/Rank 1 monster from either GY to your field, and if you do, equip this card to it + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_EQUIP) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCost(aux.RemainFieldCost) + e1:SetTarget(s.sptg) + e1:SetOperation(s.spop) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) + --Increase the equipped monster's Level/Rank by 1 + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_LVCHANGE) + e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F) + e2:SetCode(EVENT_PHASE+PHASE_END) + e2:SetRange(LOCATION_SZONE) + e2:SetCountLimit(1) + e2:SetCondition(function(e) return e:GetHandler():HasFlagEffect(id) end) + e2:SetOperation(s.lvrkop) + c:RegisterEffect(e2) + --● 3+: It gains ATK equal to its original ATK + local e3=Effect.CreateEffect(c) + e3:SetType(EFFECT_TYPE_EQUIP) + e3:SetCode(EFFECT_UPDATE_ATTACK) + e3:SetCondition(s.effcon(3)) + e3:SetValue(function(e,c) return c:GetBaseAttack() end) + c:RegisterEffect(e3) + --● 5+: It is unaffected by your opponent's activated effects + local e4=Effect.CreateEffect(c) + e4:SetType(EFFECT_TYPE_EQUIP) + e4:SetCode(EFFECT_IMMUNE_EFFECT) + e4:SetCondition(s.effcon(5)) + e4:SetValue(function(e,te) return te:GetOwnerPlayer()==1-e:GetHandlerPlayer() and te:IsActivated() end) + c:RegisterEffect(e4) + --Send all cards on the field to the GY + local e5=Effect.CreateEffect(c) + e5:SetDescription(aux.Stringid(id,2)) + e5:SetCategory(CATEGORY_TOGRAVE) + e5:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F) + e5:SetCode(EVENT_PHASE+PHASE_STANDBY) + e5:SetRange(LOCATION_SZONE) + e5:SetCountLimit(1) + e5:SetCondition(function(e,tp) return Duel.IsTurnPlayer(tp) and s.effcon(7)(e) end) + e5:SetTarget(s.tgtg) + e5:SetOperation(s.tgop) + c:RegisterEffect(e5) +end +function s.spfilter(c,e,tp) + return (c:IsLevel(1) or c:IsRank(1)) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return e:IsHasType(EFFECT_TYPE_ACTIVATE) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,PLAYER_EITHER,LOCATION_GRAVE) + Duel.SetOperationInfo(0,CATEGORY_EQUIP,e:GetHandler(),1,tp,0) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return c:CancelToGrave(false) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local sc=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,nil,e,tp):GetFirst() + if sc and Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP)>0 and c:IsRelateToEffect(e) + and not c:IsStatus(STATUS_LEAVE_CONFIRMED) and Duel.Equip(tp,c,sc) then + c:RegisterFlagEffect(id,RESET_EVENT|RESETS_STANDARD,0,1) + --Equip limit + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_EQUIP_LIMIT) + e1:SetValue(function(e,c) return c==sc end) + e1:SetReset(RESET_EVENT|RESETS_STANDARD) + c:RegisterEffect(e1) + else + c:CancelToGrave(false) + end +end +function s.lvrkop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local ec=c:GetEquipTarget() + local eff_code=(ec:HasLevel() and EFFECT_UPDATE_LEVEL) + or (ec:HasRank() and EFFECT_UPDATE_RANK) + --Increase the equipped monster's Level/Rank by 1 + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(eff_code) + e1:SetValue(1) + e1:SetReset(RESET_EVENT|RESETS_STANDARD) + ec:RegisterEffect(e1) +end +function s.effcon(level_rank) + return function(e) + local c=e:GetHandler() + local ec=c:GetEquipTarget() + return c:HasFlagEffect(id) and (ec:IsLevelAbove(level_rank) or ec:IsRankAbove(level_rank)) + end +end +function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) + local ct=Duel.GetFieldGroupCount(tp,LOCATION_ONFIELD,LOCATION_ONFIELD) + if chk==0 then return ct>0 end + Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,ct,PLAYER_ALL,LOCATION_ONFIELD) +end +function s.tgop(e,tp,eg,ep,ev,re,r,rp) + local g=Duel.GetFieldGroup(tp,LOCATION_ONFIELD,LOCATION_ONFIELD) + if #g>0 then + Duel.SendtoGrave(g,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c11248645.lua b/official/c11248645.lua new file mode 100644 index 0000000000..3353e32e02 --- /dev/null +++ b/official/c11248645.lua @@ -0,0 +1,84 @@ +--ハイネス・デーモン +--Highness Archfiend +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Add 2 "Archfiend" cards from your Deck to your hand, except "Highess Archfiend", also you cannot Special Summon from the Extra Deck for the rest of this turn, except "Archfiend" monsters + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCode(EVENT_SUMMON_SUCCESS) + e1:SetCountLimit(1,id) + e1:SetCost(s.thcost) + e1:SetTarget(s.thtg) + e1:SetOperation(s.thop) + c:RegisterEffect(e1) + --Special Summon this card + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e2:SetCode(EVENT_BATTLE_DESTROYED) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(s.spcon) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + c:RegisterEffect(e2) +end +s.listed_names={id} +s.listed_series={SET_ARCHFIEND} +function s.thcostfilter(c,tp) + return c:IsSetCard(SET_ARCHFIEND) and c:IsAbleToRemoveAsCost() +end +function s.thcost(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thcostfilter,tp,LOCATION_GRAVE,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) + local g=Duel.SelectMatchingCard(tp,s.thcostfilter,tp,LOCATION_GRAVE,0,1,1,nil) + Duel.Remove(g,POS_FACEUP,REASON_COST) +end +function s.thfilter(c) + return c:IsSetCard(SET_ARCHFIEND) and not c:IsCode(id) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,2,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,2,2,nil) + if #g==2 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end + --For the rest of this turn, you cannot Special Summon from the Extra Deck, except "Archfiend" monsters + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsSetCard(SET_ARCHFIEND) end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) +end +function s.spconfilter(c,tp) + return c:IsPreviousControler(tp) and c:IsRitualMonster() +end +function s.spcon(e,tp,eg,ep,ev,re,r,rp) + return eg:IsExists(s.spconfilter,1,nil,tp) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) then + Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c11852093.lua b/official/c11852093.lua new file mode 100644 index 0000000000..9e95286211 --- /dev/null +++ b/official/c11852093.lua @@ -0,0 +1,76 @@ +--DDD聖賢王アルフレッド +--D/D/D Sage King Alfred +--Scripted by The Razgriz +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Fusion Materials: 2 "D/D" monsters + Fusion.AddProcMixN(c,true,true,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_DD),2) + local params={ + fusfilter=aux.FilterBoolFunction(Card.IsSetCard,SET_DDD), + matfilter=Card.IsAbleToDeck, + extrafil=function(e,tp,mg) + return Duel.GetMatchingGroup(Fusion.IsMonsterFilter(Card.IsFaceup,Card.IsAbleToDeck),tp,LOCATION_REMOVED,0,nil) + end, + extraop=Fusion.ShuffleMaterial, + extratg=function(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return true end + Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,1,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_REMOVED) + end + } + --Fusion Summon 1 "D/D/D" Fusion Monster from your Extra Deck, by shuffling its materials from your hand, field, and/or banishment into the Deck + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TODECK+CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetRange(LOCATION_MZONE) + e1:SetCountLimit(1,id) + e1:SetTarget(Fusion.SummonEffTG(params)) + e1:SetOperation(Fusion.SummonEffOP(params)) + c:RegisterEffect(e1) + --Place "Dark Contract" Spell/Traps face-up on your field from your GY and/or banishment, up to the number of "D/D/D" monsters you control + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) + e2:SetCode(EVENT_REMOVE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.pltg) + e2:SetOperation(s.plop) + c:RegisterEffect(e2) +end +s.listed_series={SET_DD,SET_DDD,SET_DARK_CONTRACT} +s.material_setcode=SET_DD +function s.plfilter(c,tp) + return c:IsSetCard(SET_DARK_CONTRACT) and c:IsContinuousSpellTrap() and c:IsFaceup() and c:CheckUniqueOnField(tp) + and not c:IsForbidden() +end +function s.pltg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_GRAVE|LOCATION_REMOVED) and chkc:IsControler(tp) and s.plfilter(chkc,tp) end + local ct=Duel.GetMatchingGroupCount(aux.FaceupFilter(Card.IsSetCard,SET_DDD),tp,LOCATION_MZONE,0,nil) + local ft=Duel.GetLocationCount(tp,LOCATION_SZONE) + if chk==0 then return ct>0 and ft>0 and Duel.IsExistingTarget(s.plfilter,tp,LOCATION_GRAVE|LOCATION_REMOVED,0,1,nil,tp) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) + local g=Duel.SelectTarget(tp,s.plfilter,tp,LOCATION_GRAVE|LOCATION_REMOVED,0,1,math.min(ct,ft),nil,tp) + if g:IsExists(Card.IsLocation,1,nil,LOCATION_GRAVE) then + Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,nil,1,tp,0) + end +end +function s.plop(e,tp,eg,ep,ev,re,r,rp) + local tg=Duel.GetTargetCards(e) + if #tg==0 then return end + local gg=Group.CreateGroup() + local ft=Duel.GetLocationCount(tp,LOCATION_SZONE) + if ft<#tg then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) + local sg=tg:FilterSelect(tp,s.plfilter,ft,ft,nil,tp) + gg=tg-sg + tg=sg + end + for tc in tg:Iter() do + Duel.MoveToField(tc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) + end + if #gg>0 then + Duel.SendtoGrave(gg,REASON_RULE|REASON_RETURN,PLAYER_NONE,tp) + end +end \ No newline at end of file diff --git a/official/c12157563.lua b/official/c12157563.lua new file mode 100644 index 0000000000..bdeaa02ea5 --- /dev/null +++ b/official/c12157563.lua @@ -0,0 +1,56 @@ +--禁断儀式術 +--Forbidden Ritual Art +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Ritual Summon 1 Ritual Monster from your GY, by banishing monsters from your GY whose total Levels equal its Level, but destroy it during the End Phase + local e1=Ritual.AddProcEqual({ + handler=c, + location=LOCATION_GRAVE, + matfilter=function(c) return c:IsLocation(LOCATION_GRAVE) end, + extrafil=s.rextra, + extratg=s.extratg, + stage2=s.stage2 + }) + e1:SetCategory(e1:GetCategory()+CATEGORY_REMOVE) + e1:SetCountLimit(1,{id,0}) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) + --Apply an "once this turn, when you Ritual Summon with a card effect that requires use of monster Tributes, you can also banish Ritual Monsters from your GY as monsters used for the Ritual Summon" effect + local e2=Effect.CreateEffect(c) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,{id,1}) + e2:SetCost(Cost.SelfBanish) + e2:SetOperation(s.effop) + e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e2) +end +function s.rextra(e,tp,eg,ep,ev,re,r,rp,chk) + if not Duel.IsPlayerAffectedByEffect(tp,CARD_SPIRIT_ELIMINATION) then + return Duel.GetMatchingGroup(aux.AND(Card.HasLevel,Card.IsAbleToRemove),tp,LOCATION_GRAVE,0,nil) + end +end +function s.extratg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return true end + Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_GRAVE) +end +function s.stage2(mat,e,tp,eg,ep,ev,re,r,rp,rc) + --Destroy it during the End Phase + aux.DelayedOperation(rc,PHASE_END,id,e,tp,function(ag) Duel.Destroy(ag,REASON_EFFECT) end,nil,0,0,aux.Stringid(id,2)) +end +function s.effop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + aux.RegisterClientHint(c,0,tp,1,0,aux.Stringid(id,3)) + --Once this turn, when you Ritual Summon with a card effect that requires use of monster Tributes, you can also banish Ritual Monsters from your GY as monsters used for the Ritual Summon + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetCode(EFFECT_EXTRA_RITUAL_MATERIAL) + e1:SetCountLimit(1,id) + e1:SetTargetRange(LOCATION_GRAVE,0) + e1:SetCondition(function(e) return not Duel.HasFlagEffect(tp,id) end) + e1:SetTarget(function(e,c) return c:IsRitualMonster() and c:IsAbleToRemove() end) + e1:SetValue(1) + Duel.RegisterEffect(e1,tp) +end \ No newline at end of file diff --git a/official/c12197223.lua b/official/c12197223.lua new file mode 100644 index 0000000000..34cc82a9be --- /dev/null +++ b/official/c12197223.lua @@ -0,0 +1,58 @@ +--天雷ノ双風神 シーナ +--Sheena the Twin Storm Deities of Divine Thunder +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Special Summon this card from your hand, then apply this effect based on that card effect's type + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOHAND) + e1:SetType(EFFECT_TYPE_QUICK_O) + e1:SetCode(EVENT_CHAINING) + e1:SetRange(LOCATION_HAND) + e1:SetCountLimit(1,id) + e1:SetCondition(s.spcon) + e1:SetTarget(s.sptg) + e1:SetOperation(s.spop) + c:RegisterEffect(e1) + --The first time this card would be destroyed by battle each turn, it is not destroyed + local e2=Effect.CreateEffect(c) + e2:SetType(EFFECT_TYPE_SINGLE) + e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e2:SetCode(EFFECT_INDESTRUCTABLE_COUNT) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1) + e2:SetValue(function(e,re,r,rp) return (r&REASON_BATTLE)>0 end) + c:RegisterEffect(e2) +end +s.listed_names={id} +function s.spcon(e,tp,eg,ep,ev,re,r,rp) + return rp==1-tp and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_WIND),tp,LOCATION_MZONE,0,1,nil) +end +function s.rthfilter(c) + return c:IsFaceup() and c:IsAbleToHand() and not c:IsCode(id) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) + and ((re:IsMonsterEffect() and Duel.IsExistingMatchingCard(s.rthfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil)) + or (re:IsSpellTrapEffect() and Duel.IsExistingMatchingCard(aux.AND(Card.IsSpellTrap,Card.IsAbleToHand),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil))) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,PLAYER_ALL,LOCATION_ONFIELD) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 then + local g=Group.CreateGroup() + if re:IsMonsterEffect() then + g=Duel.GetMatchingGroup(s.rthfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil) + elseif re:IsSpellTrapEffect(e) then + g=Duel.GetMatchingGroup(aux.AND(Card.IsSpellTrap,Card.IsAbleToHand),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) + end + if #g>0 then + Duel.BreakEffect() + Duel.SendtoHand(g,nil,REASON_EFFECT) + end + end +end \ No newline at end of file diff --git a/official/c12375297.lua b/official/c12375297.lua new file mode 100644 index 0000000000..5b3951b0b2 --- /dev/null +++ b/official/c12375297.lua @@ -0,0 +1,95 @@ +--燿ける聖詩の獄神精 +--Elvennotes Power Patron +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --You cannot Special Summon from the Extra Deck, except Synchro Monsters + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetRange(LOCATION_MZONE) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsSynchroMonster() end) + c:RegisterEffect(e1) + aux.addContinuousLizardCheck(c,LOCATION_MZONE,function(e,c) return not c:IsOriginalType(TYPE_SYNCHRO) end) + --Increase the Level of the monster in your center Main Monster Zone by 3 (until the end of this turn), then immediately after this effect resolves, you can Synchro Summon 1 "Elvennotes" monster or "Junora the Power Patron of Tuning" + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_LVCHANGE+CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,id) + e2:SetCondition(function() return Duel.IsMainPhase() end) + e2:SetTarget(s.lvtg) + e2:SetOperation(s.lvop) + e2:SetHintTiming(0,TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) + c:RegisterEffect(e2) + --Add 1 "Elvennotes" card from your Deck to your hand + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e3:SetProperty(EFFECT_FLAG_DELAY) + e3:SetCode(EVENT_BE_MATERIAL) + e3:SetCountLimit(1,{id,1}) + e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return e:GetHandler():IsLocation(LOCATION_GRAVE) and r==REASON_SYNCHRO end) + e3:SetTarget(s.thtg) + e3:SetOperation(s.thop) + c:RegisterEffect(e3) +end +s.listed_series={SET_ELVENNOTES} +s.listed_names={5914858} --"Junora the Power Patron of Tuning" +function s.lvfilter(c) + return c:IsSequence(2) and c:HasLevel() and c:IsFaceup() +end +function s.lvtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MMZONE) and s.lvfilter(chkc) end + if chk==0 then return Duel.IsExistingTarget(s.lvfilter,tp,LOCATION_MMZONE,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) + local g=Duel.SelectTarget(tp,s.lvfilter,tp,LOCATION_MMZONE,0,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_LVCHANGE,g,1,tp,3) + Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) +end +function s.synchrofilter(c) + return (c:IsSetCard(SET_ELVENNOTES) or c:IsCode(5914858)) and c:IsSynchroSummonable() +end +function s.lvop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and tc:IsFaceup() then + local prev_lv=tc:GetLevel() + --Increase its Level by 3 + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_UPDATE_LEVEL) + e1:SetValue(3) + e1:SetReset(RESETS_STANDARD_PHASE_END) + tc:RegisterEffect(e1) + Duel.AdjustInstantly(tc) + if not tc:IsLevel(prev_lv+3) then return end + local g=Duel.GetMatchingGroup(s.synchrofilter,tp,LOCATION_EXTRA,0,1,nil) + if #g>0 and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local sc=g:Select(tp,1,1,nil):GetFirst() + Duel.SynchroSummon(tp,sc) + end + end +end +function s.thfilter(c) + return c:IsSetCard(SET_ELVENNOTES) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end \ No newline at end of file diff --git a/official/c12975671.lua b/official/c12975671.lua new file mode 100644 index 0000000000..f35ea226ea --- /dev/null +++ b/official/c12975671.lua @@ -0,0 +1,81 @@ +--ファースト・ペンギン +--First Penguin +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --If you control no face-up monsters, you can Special Summon this card (from your hand), and if you do, it is treated as a Tuner + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) + e1:SetCode(EFFECT_SPSUMMON_PROC) + e1:SetRange(LOCATION_HAND) + e1:SetCondition(s.selfspcon) + e1:SetOperation(s.selfspop) + c:RegisterEffect(e1) + --Add 1 WATER monster with the same Type as the revealed monster, but 1 Level lower, from your Deck to your hand, then you can change this card to face-down Defense Position, also you cannot Special Summon from the Extra Deck for the rest of this turn, except WATER monsters + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_POSITION) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,id) + e2:SetCost(Cost.AND(Cost.Discard(),Cost.Reveal(s.revealfilter,false,1,1,function(e,tp,g) local sc=g:GetFirst() e:SetLabel(sc:GetRace(),sc:GetLevel()-1) end,LOCATION_EXTRA))) + e2:SetTarget(s.thtg) + e2:SetOperation(s.thop) + c:RegisterEffect(e2) +end +function s.selfspcon(e,c) + if c==nil then return true end + local tp=e:GetHandlerPlayer() + return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and not Duel.IsExistingMatchingCard(Card.IsFaceup,tp,LOCATION_MZONE,0,1,nil) +end +function s.selfspop(e,tp,eg,ep,ev,re,r,rp,c) + --It is treated as a Tuner + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_ADD_TYPE) + e1:SetValue(TYPE_TUNER) + e1:SetReset(RESET_EVENT|(RESETS_STANDARD&~RESET_TOFIELD)) + c:RegisterEffect(e1) +end +function s.revealfilter(c,e,tp) + return c:IsAttribute(ATTRIBUTE_WATER) and c:IsSynchroMonster() and not c:IsLevel(1) and not c:IsPublic() + and Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil,c:GetRace(),c:GetLevel()-1) +end +function s.thfilter(c,race,lv) + return c:IsAttribute(ATTRIBUTE_WATER) and c:IsRace(race) and c:IsLevel(lv) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return true end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) + Duel.SetPossibleOperationInfo(0,CATEGORY_POSITION,e:GetHandler(),1,tp,0) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local race,lv=e:GetLabel() + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local sc=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil,race,lv):GetFirst() + if sc and Duel.SendtoHand(sc,nil,REASON_EFFECT)>0 and sc:IsLocation(LOCATION_HAND) then + Duel.ConfirmCards(1-tp,sc) + Duel.ShuffleHand(tp) + if c:IsRelateToEffect(e) and c:IsCanTurnSet() and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.BreakEffect() + Duel.ChangePosition(c,POS_FACEDOWN_DEFENSE) + end + end + --You cannot Special Summon from the Extra Deck for the rest of this turn, except WATER monsters + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,3)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsAttribute(ATTRIBUTE_WATER) end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) + --"Clock Lizard" check + aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalAttribute(ATTRIBUTE_WATER) end) +end \ No newline at end of file diff --git a/official/c13379114.lua b/official/c13379114.lua new file mode 100644 index 0000000000..911f7fcb6a --- /dev/null +++ b/official/c13379114.lua @@ -0,0 +1,68 @@ +--デーモンの気魄 +--Archfiend's Vigor +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Activate + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_ACTIVATE) + e0:SetCode(EVENT_FREE_CHAIN) + c:RegisterEffect(e0) + --Negate the effects of 1 face-up card your opponent controls until the end of this turn + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_DISABLE) + e1:SetType(EFFECT_TYPE_QUICK_O) + e1:SetProperty(EFFECT_FLAG_CARD_TARGET) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetRange(LOCATION_SZONE) + e1:SetCountLimit(1,id) + e1:SetCondition(function(e,tp) return Duel.IsExistingMatchingCard(function(c) return c:IsSetCard(SET_ARCHFIEND) and c:IsRitualMonster() and c:IsFaceup() end,tp,LOCATION_EMZONE,0,1,nil) end) + e1:SetTarget(s.distg) + e1:SetOperation(s.disop) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) + c:RegisterEffect(e1) + --Add 1 "Archfiend" card from your Deck to your hand, except "Archfiend's Vigor" + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY) + e2:SetCode(EVENT_REMOVE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(function(e) return e:GetHandler():IsPreviousLocation(LOCATION_HAND|LOCATION_ONFIELD) end) + e2:SetTarget(s.thtg) + e2:SetOperation(s.thop) + c:RegisterEffect(e2) +end +s.listed_names={id} +s.listed_series={SET_ARCHFIEND} +function s.distg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsOnField() and c:IsControler(1-tp) and chkc:IsNegatable() end + if chk==0 then return Duel.IsExistingTarget(Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_NEGATE) + local g=Duel.SelectTarget(tp,Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_DISABLE,g,1,tp,0) +end +function s.disop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and tc:IsFaceup() then + --Negate its effects until the end of this turn + tc:NegateEffects(e:GetHandler(),RESET_PHASE|PHASE_END,true) + end +end +function s.thfilter(c) + return c:IsSetCard(SET_ARCHFIEND) and not c:IsCode(id) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end \ No newline at end of file diff --git a/official/c13597785.lua b/official/c13597785.lua new file mode 100644 index 0000000000..549487c656 --- /dev/null +++ b/official/c13597785.lua @@ -0,0 +1,78 @@ +--耀聖の花詩ルキナ +--Elvennotes Lucina +--Scripted by Hatter +local s,id=GetID() +function s.initial_effect(c) + --You can Special Summon this card (from your hand) to your center Main Monster Zone + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) + e1:SetCode(EFFECT_SPSUMMON_PROC) + e1:SetRange(LOCATION_HAND) + e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) + e1:SetValue(function() return 0,ZONE_CENTER_MMZ end) + c:RegisterEffect(e1) + --Add 1 "Elvennotes" monster from your Deck to your hand, except "Elvennotes Lucina" + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.thtg) + e2:SetOperation(s.thop) + c:RegisterEffect(e2) + --Switch the locations of this card in your Main Monster Zone and the monster in your center Main Monster Zone + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,2)) + e3:SetCategory(CATEGORY_TOHAND) + e3:SetType(EFFECT_TYPE_QUICK_O) + e3:SetCode(EVENT_FREE_CHAIN) + e3:SetRange(LOCATION_MMZONE) + e3:SetCountLimit(1,{id,2}) + e3:SetCondition(function(e,tp) return Duel.IsTurnPlayer(1-tp) end) + e3:SetTarget(s.swtg) + e3:SetOperation(s.swop) + e3:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e3) +end +s.listed_names={id} +s.listed_series={SET_ELVENNOTES} +function s.thfilter(c) + return c:IsSetCard(SET_ELVENNOTES) and c:IsMonster() and not c:IsCode(id) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end +function s.swtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return not e:GetHandler():IsSequence(2) and Duel.GetFieldCard(tp,LOCATION_MZONE,2) end + Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,1-tp,LOCATION_MZONE) +end +function s.rthfilter(c) + return c:IsLevelBelow(6) and c:IsFaceup() and c:IsAbleToHand() +end +function s.swop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local cc=Duel.GetFieldCard(tp,LOCATION_MZONE,2) + if c:IsRelateToEffect(e) and c:IsInMainMZone(tp) and cc and c~=cc and Duel.SwapSequence(c,cc) then + local g=Duel.GetMatchingGroup(s.rthfilter,tp,0,LOCATION_MZONE,nil) + if #g==0 or not Duel.SelectYesNo(tp,aux.Stringid(id,3)) then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) + local sg=g:Select(tp,1,1,nil) + if #sg>0 then + Duel.HintSelection(sg) + Duel.BreakEffect() + Duel.SendtoHand(sg,nil,REASON_EFFECT) + end + end +end \ No newline at end of file diff --git a/official/c19304410.lua b/official/c19304410.lua new file mode 100644 index 0000000000..f219071a16 --- /dev/null +++ b/official/c19304410.lua @@ -0,0 +1,65 @@ +--鉄獣の炎工 キット +--Tri-Brigade Springans Kitt +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Special Summon this card from your hand + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetRange(LOCATION_HAND) + e1:SetCountLimit(1,id) + e1:SetCondition(s.selfspcon) + e1:SetTarget(s.selfsptg) + e1:SetOperation(s.selfspop) + c:RegisterEffect(e1) + --Special Summon from your GY 1 "Tri-Brigade" or "Springans" monster or "Fallen of Albaz" or a monster that mentions it + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY) + e2:SetCode(EVENT_TO_GRAVE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.gysptg) + e2:SetOperation(s.gyspop) + c:RegisterEffect(e2) +end +s.listed_names={id,CARD_ALBAZ} +s.listed_series={SET_TRI_BRIGADE,SET_SPRINGANS} +function s.selfspconfilter(c) + return c:IsSetCard({SET_TRI_BRIGADE,SET_SPRINGANS}) and c:IsFaceup() and not c:IsCode(id) +end +function s.selfspcon(e,tp,eg,ep,ev,re,r,rp) + return Duel.IsExistingMatchingCard(s.selfspconfilter,tp,LOCATION_MZONE,0,1,nil) +end +function s.selfsptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) +end +function s.selfspop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) then + Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) + end +end +function s.gyspfilter(c,e,tp) + return (c:IsSetCard({SET_TRI_BRIGADE,SET_SPRINGANS}) or (c:IsCode(CARD_ALBAZ) or c:ListsCode(CARD_ALBAZ))) and not c:IsCode(id) + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.gysptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.gyspfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) +end +function s.gyspop(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,s.gyspfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c23219323.lua b/official/c23219323.lua new file mode 100644 index 0000000000..80114880d1 --- /dev/null +++ b/official/c23219323.lua @@ -0,0 +1,70 @@ +--ジャンク・ウォリアー/バスター +--Junk Warrior/Assault Mode +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + c:AddMustBeSpecialSummoned() + --Gains 1000 ATK for each "/Assault Mode" monster you control + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e1:SetCode(EFFECT_UPDATE_ATTACK) + e1:SetRange(LOCATION_MZONE) + e1:SetValue(function(e,c) return 1000*Duel.GetMatchingGroupCount(aux.FaceupFilter(Card.IsSetCard,SET_ASSAULT_MODE),c:GetControler(),LOCATION_MZONE,0,nil) end) + c:RegisterEffect(e1) + --If this card battles a monster, any battle damage it inflicts to your opponent is doubled + local e2=Effect.CreateEffect(c) + e2:SetType(EFFECT_TYPE_SINGLE) + e2:SetCode(EFFECT_CHANGE_BATTLE_DAMAGE) + e2:SetCondition(function(e) return e:GetHandler():GetBattleTarget() end) + e2:SetValue(aux.ChangeBattleDamage(1,DOUBLE_DAMAGE)) + c:RegisterEffect(e2) + --Unaffected by your opponent's activated monster effects + local e3=Effect.CreateEffect(c) + e3:SetType(EFFECT_TYPE_SINGLE) + e3:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e3:SetCode(EFFECT_IMMUNE_EFFECT) + e3:SetRange(LOCATION_MZONE) + e3:SetValue(function(e,te) return te:GetOwnerPlayer()~=e:GetHandlerPlayer() and te:IsActivated() and te:IsMonsterEffect() end) + c:RegisterEffect(e3) + --Return 1 "Junk Warrior" from your GY to the Extra Deck, then you can Special Summon it (this is treated as a Synchro Summon) + local e4=Effect.CreateEffect(c) + e4:SetDescription(aux.Stringid(id,0)) + e4:SetCategory(CATEGORY_TOEXTRA+CATEGORY_SPECIAL_SUMMON) + e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e4:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) + e4:SetCode(EVENT_DESTROYED) + e4:SetTarget(s.texsptg) + e4:SetOperation(s.texspop) + c:RegisterEffect(e4) +end +s.listed_names={CARD_ASSAULT_MODE,CARD_JUNK_WARRIOR} +s.listed_series={SET_ASSAULT_MODE} +s.assault_mode=CARD_JUNK_WARRIOR +function s.texfilter(c) + return c:IsCode(CARD_JUNK_WARRIOR) and c:IsAbleToExtra() +end +function s.texsptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.texfilter(chkc) end + if chk==0 then return Duel.IsExistingTarget(s.texfilter,tp,LOCATION_GRAVE,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) + local g=Duel.SelectTarget(tp,s.texfilter,tp,LOCATION_GRAVE,0,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,g,1,tp,0) + Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) +end +function s.texspop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,0,REASON_EFFECT)>0 and tc:IsLocation(LOCATION_EXTRA) then + local forcedg=aux.GetMustBeMaterialGroup(tp,Group.CreateGroup(),tp,tc,nil,REASON_SYNCHRO) + if #forcedg==0 and Duel.GetLocationCountFromEx(tp,tp,nil,tc)>0 + and tc:IsCanBeSpecialSummoned(e,SUMMON_TYPE_SYNCHRO,tp,false,false) + and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then + tc:SetMaterial(nil) + Duel.BreakEffect() + if Duel.SpecialSummon(tc,SUMMON_TYPE_SYNCHRO,tp,tp,false,false,POS_FACEUP)>0 then + tc:CompleteProcedure() + end + end + end +end \ No newline at end of file diff --git a/official/c24092792.lua b/official/c24092792.lua new file mode 100644 index 0000000000..5f4b8edf23 --- /dev/null +++ b/official/c24092792.lua @@ -0,0 +1,73 @@ +--エルフェンノーツ~狂奏のラプソディア~ +--Elvennotes ~Maddening Rhapsodia~ +--Scripted by Hatter +local s,id=GetID() +function s.initial_effect(c) + --Activate + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_ACTIVATE) + e0:SetCode(EVENT_FREE_CHAIN) + c:RegisterEffect(e0) + --While you have a monster in your center Main Monster Zone, your opponent's monsters cannot attack, except to attack that monster + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetCode(EFFECT_MUST_ATTACK_MONSTER) + e1:SetRange(LOCATION_SZONE) + e1:SetTargetRange(0,LOCATION_MZONE) + e1:SetCondition(function(e) return Duel.GetFieldCard(e:GetHandlerPlayer(),LOCATION_MZONE,2)~=nil end) + e1:SetValue(function(e,c) return c:IsSequence(2) end) + c:RegisterEffect(e1) + --Special Summon 1 "Elvennotes" monster from your GY + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DISABLE) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_SZONE) + e2:SetCountLimit(1,id) + e2:SetCost(s.spcost) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e2) +end +s.listed_series={SET_ELVENNOTES} +function s.spcostfilter(c,e,tp) + return c:IsMonster() and c:IsAbleToGraveAsCost() and Duel.GetMZoneCount(tp,c)>0 + and Duel.IsExistingTarget(s.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp,c:GetOriginalAttribute()) +end +function s.spfilter(c,e,tp,attr) + return c:IsSetCard(SET_ELVENNOTES) and not c:IsOriginalAttribute(attr) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.spcostfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,nil,e,tp) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local sc=Duel.SelectMatchingCard(tp,s.spcostfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,1,nil,e,tp):GetFirst() + e:SetLabel(sc:GetOriginalAttribute()) + Duel.SendtoGrave(sc,REASON_COST) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + local attr=e:GetLabel() + if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and s.spfilter(chkc,e,tp,attr) end + if chk==0 then return true end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectTarget(tp,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp,attr) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,0) + Duel.SetPossibleOperationInfo(0,CATEGORY_DISABLE,nil,1,1-tp,LOCATION_ONFIELD) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)>0 + and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsSynchroMonster),tp,LOCATION_MZONE,0,1,nil) + and Duel.IsExistingMatchingCard(Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,nil) + and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_NEGATE) + local sc=Duel.SelectMatchingCard(tp,Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,1,nil):GetFirst() + if sc then + Duel.HintSelection(sc) + Duel.BreakEffect() + sc:NegateEffects(e:GetHandler(),RESETS_STANDARD_PHASE_END,true) + end + end +end \ No newline at end of file diff --git a/official/c24431911.lua b/official/c24431911.lua new file mode 100644 index 0000000000..63348121b9 --- /dev/null +++ b/official/c24431911.lua @@ -0,0 +1,115 @@ +--磁石の戦士マグネット・テルスリオン +--Tellusrion the Magna Warrior +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + c:AddMustBeSpecialSummoned() + --Must be Special Summoned (from your GY) by banishing 1 "Magnet Warrior Σ+" and 1 "Magnet Warrior Σ-" from your hand, face-up Monster Zone, and/or GY + local e0=Effect.CreateEffect(c) + e0:SetDescription(aux.Stringid(id,0)) + e0:SetType(EFFECT_TYPE_FIELD) + e0:SetProperty(EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_CANNOT_DISABLE) + e0:SetCode(EFFECT_SPSUMMON_PROC) + e0:SetRange(LOCATION_GRAVE) + e0:SetCondition(s.selfspcon) + e0:SetTarget(s.selfsptg) + e0:SetOperation(s.selfspop) + c:RegisterEffect(e0) + --Destroy 1 monster your opponent controlst, or if you targeted an EARTH monster at activation, you can take control of it instead + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,1)) + e1:SetCategory(CATEGORY_DESTROY+CATEGORY_CONTROL) + e1:SetType(EFFECT_TYPE_QUICK_O) + e1:SetProperty(EFFECT_FLAG_CARD_TARGET) + e1:SetCode(EVENT_CHAINING) + e1:SetRange(LOCATION_MZONE) + e1:SetCountLimit(1) + e1:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return rp==1-tp end) + e1:SetTarget(s.destg) + e1:SetOperation(s.desop) + c:RegisterEffect(e1) + --Special Summon 2 of your banished "Magnet Warrior Σ" monsters + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_MZONE) + e2:SetCondition(function(e,tp) return Duel.IsTurnPlayer(1-tp) end) + e2:SetCost(Cost.SelfTribute) + e2:SetTarget(s.rmsptg) + e2:SetOperation(s.rmspop) + e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e2) +end +s.listed_names={51826619,87814728} --"Magnet Warrior Σ+", "Magnet Warrior Σ-" +s.listed_series={SET_MAGNET_WARRIOR_SIGMA} +function s.selfspcostfilter(c) + return c:IsCode(51826619,87814728) and (c:IsFaceup() or not c:IsOnField()) and c:IsAbleToRemoveAsCost() and aux.SpElimFilter(c,true,true) +end +function s.rescon(sg,e,tp,mg) + return Duel.GetMZoneCount(tp,sg)>0 and sg:IsExists(Card.IsCode,1,nil,51826619) and sg:IsExists(Card.IsCode,1,nil,87814728) +end +function s.selfspcon(e,c) + if c==nil then return true end + local tp=e:GetHandlerPlayer() + local g=Duel.GetMatchingGroup(s.selfspcostfilter,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_GRAVE,0,nil) + return #g>=2 and Duel.GetMZoneCount(tp,g)>0 and aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,0) +end +function s.selfsptg(e,tp,eg,ep,ev,re,r,rp,chk,c) + local g=Duel.GetMatchingGroup(s.selfspcostfilter,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_GRAVE,0,nil) + local sg=aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,1,tp,HINTMSG_REMOVE,nil,nil,true) + if #sg>0 then + e:SetLabelObject(sg) + return true + end + return false +end +function s.selfspop(e,tp,eg,ep,ev,re,r,rp,c) + local sg=e:GetLabelObject() + if sg then + Duel.Remove(sg,POS_FACEUP,REASON_COST) + end +end +function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_MZONE) end + if chk==0 then return Duel.IsExistingTarget(nil,tp,0,LOCATION_MZONE,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local tc=Duel.SelectTarget(tp,nil,tp,0,LOCATION_MZONE,1,1,nil):GetFirst() + if tc:IsAttribute(ATTRIBUTE_EARTH) and tc:IsFaceup() then + e:SetLabel(100) + Duel.SetPossibleOperationInfo(0,CATEGORY_DESTROY,tc,1,tp,0) + Duel.SetPossibleOperationInfo(0,CATEGORY_CONTROL,tc,1,tp,0) + else + e:SetLabel(0) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,tc,1,tp,0) + end +end +function s.desop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if not tc:IsRelateToEffect(e) then return end + local earth_chk=e:GetLabel()==100 + if earth_chk and tc:IsControlerCanBeChanged() and Duel.SelectYesNo(tp,aux.Stringid(id,3)) then + Duel.GetControl(tc,tp) + else + Duel.Destroy(tc,REASON_EFFECT) + end +end +function s.rmspfilter(c,e,tp) + return c:IsSetCard(SET_MAGNET_WARRIOR_SIGMA) and c:IsFaceup() and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.rmsptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetMZoneCount(tp,e:GetHandler())>=2 + and not Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) + and Duel.IsExistingMatchingCard(s.rmspfilter,tp,LOCATION_REMOVED,0,2,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,2,tp,LOCATION_REMOVED) +end +function s.rmspop(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetLocationCount(tp,LOCATION_MZONE)<2 or Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,s.rmspfilter,tp,LOCATION_REMOVED,0,2,2,nil,e,tp) + if #g==2 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c25224340.lua b/official/c25224340.lua new file mode 100644 index 0000000000..fdfc2d82f1 --- /dev/null +++ b/official/c25224340.lua @@ -0,0 +1,70 @@ +--幻惑の操手 +--Nightmare Hand +local s,id=GetID() +function s.initial_effect(c) + --Send 1 Illusion monster from your Deck to the GY + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOGRAVE) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id) + e1:SetTarget(s.tgtg) + e1:SetOperation(s.tgop) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) + --Special Summon 1 monster from your opponent's GY to your field, but banish it during the End Phase of the next turn + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_REMOVE) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,id) + e2:SetCondition(s.spcon) + e2:SetCost(Cost.SelfBanish) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + c:RegisterEffect(e2) +end +function s.tgfilter(c) + return c:IsRace(RACE_ILLUSION) and c:IsAbleToGrave() +end +function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.tgfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) +end +function s.tgop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local g=Duel.SelectMatchingCard(tp,s.tgfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoGrave(g,REASON_EFFECT) + end +end +function s.spconfilter(c) + return c:IsLevelAbove(5) and c:IsRace(RACE_ILLUSION) and c:IsFaceup() +end +function s.spcon(e,tp,eg,ep,ev,re,r,rp) + return Duel.IsExistingMatchingCard(s.spconfilter,tp,LOCATION_MZONE,0,1,nil) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_GRAVE) and chkc:IsCanBeSpecialSummoned(e,0,tp,false,false) end + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingTarget(Card.IsCanBeSpecialSummoned,tp,0,LOCATION_GRAVE,1,nil,e,0,tp,false,false) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectTarget(tp,Card.IsCanBeSpecialSummoned,tp,0,LOCATION_GRAVE,1,1,nil,e,0,tp,false,false) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,0) + Duel.SetPossibleOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_MZONE) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)>0 then + local turn_summoned=Duel.GetTurnCount() + --Banish it during the End Phase of the next turn + aux.DelayedOperation(tc,PHASE_END,id,e,tp, + function(tc) Duel.Remove(tc,POS_FACEUP,REASON_EFFECT) end, + function() return Duel.GetTurnCount()==turn_summoned+1 end, + nil,2,aux.Stringid(id,2) + ) + end +end \ No newline at end of file diff --git a/official/c25554552.lua b/official/c25554552.lua new file mode 100644 index 0000000000..9f6501d181 --- /dev/null +++ b/official/c25554552.lua @@ -0,0 +1,78 @@ +--ヴァレット・ローダー +--Rokket Loader +--Scripted by Eerie Code +local s,id=GetID() +function s.initial_effect(c) + --Add 1 Level 7 DARK Dragon monster from your Deck to your hand + local e1a=Effect.CreateEffect(c) + e1a:SetDescription(aux.Stringid(id,0)) + e1a:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1a:SetProperty(EFFECT_FLAG_DELAY) + e1a:SetCode(EVENT_SUMMON_SUCCESS) + e1a:SetCountLimit(1,{id,0}) + e1a:SetTarget(s.thtg) + e1a:SetOperation(s.thop) + c:RegisterEffect(e1a) + local e1b=e1a:Clone() + e1b:SetCode(EVENT_SPSUMMON_SUCCESS) + c:RegisterEffect(e1b) + --Make 1 face-up monster on the field become DARK until the end of this turn + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,{id,1}) + e2:SetCost(Cost.SelfBanish) + e2:SetTarget(s.attrtg) + e2:SetOperation(s.attrop) + c:RegisterEffect(e2) +end +function s.thfilter(c) + return c:IsLevel(7) and c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_DRAGON) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end + local c=e:GetHandler() + --You cannot Special Summon from the Extra Deck for the rest of this turn, except DARK monsters + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsAttribute(ATTRIBUTE_DARK) end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) + --"Clock Lizard" check + aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalAttribute(ATTRIBUTE_DARK) end) +end +function s.attrtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsAttributeExcept(ATTRIBUTE_DARK) and chkc:IsFaceup() end + if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(Card.IsAttributeExcept,ATTRIBUTE_DARK),tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) + Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsAttributeExcept,ATTRIBUTE_DARK),tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) +end +function s.attrop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and tc:IsFaceup() then + --It becomes DARK until the end of this turn + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_CHANGE_ATTRIBUTE) + e1:SetValue(ATTRIBUTE_DARK) + e1:SetReset(RESETS_STANDARD_PHASE_END) + tc:RegisterEffect(e1) + end +end \ No newline at end of file diff --git a/official/c25940932.lua b/official/c25940932.lua new file mode 100644 index 0000000000..4aeef6b1ff --- /dev/null +++ b/official/c25940932.lua @@ -0,0 +1,87 @@ +--絢嵐たる軒昂 +--Radiant Typhoon Elation +--Scripted by Eerie Code +local s,id=GetID() +function s.initial_effect(c) + --Activate 1 of these effects + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetTarget(s.efftg) + e1:SetOperation(s.effop) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) + --Set this card + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY) + e2:SetCode(EVENT_DESTROYED) + e2:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return re and re:GetHandler():IsCode(CARD_MYSTICAL_SPACE_TYPHOON) end) + e2:SetTarget(s.settg) + e2:SetOperation(s.setop) + c:RegisterEffect(e2) +end +s.listed_names={CARD_MYSTICAL_SPACE_TYPHOON} +s.listed_series={SET_RADIANT_TYPHOON} +function s.spfilter(c,e,tp) + return c:IsLevelBelow(6) and c:IsSetCard(SET_RADIANT_TYPHOON) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.thfilter(c) + return c:IsCode(CARD_MYSTICAL_SPACE_TYPHOON) and c:IsAbleToHand() +end +function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) + local b1=not Duel.HasFlagEffect(tp,id) + and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) + local b2=not Duel.HasFlagEffect(tp,id+1) + and Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil) + if chk==0 then return b1 or b2 end + local op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,2)}, + {b2,aux.Stringid(id,3)}) + e:SetLabel(op) + if op==1 then + e:SetCategory(CATEGORY_SPECIAL_SUMMON) + Duel.RegisterFlagEffect(tp,id,RESET_PHASE|PHASE_END,0,1) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) + elseif op==2 then + e:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND) + Duel.RegisterFlagEffect(tp,id+1,RESET_PHASE|PHASE_END,0,1) + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) + end +end +function s.effop(e,tp,eg,ep,ev,re,r,rp) + local op=e:GetLabel() + if op==1 then + --Special Summon 1 Level 6 or lower "Radiant Typoon" monster from your GY + if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end + elseif op==2 then + --Add 1 "Mystical Space Typhoon" from your Deck or GY to your hand + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.thfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end + end +end +function s.settg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return c:IsSSetable() end + if c:IsLocation(LOCATION_GRAVE) then + Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,c,1,tp,0) + end +end +function s.setop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) then + Duel.SSet(tp,c) + end +end \ No newline at end of file diff --git a/official/c26162470.lua b/official/c26162470.lua new file mode 100644 index 0000000000..d86590cfda --- /dev/null +++ b/official/c26162470.lua @@ -0,0 +1,85 @@ +--飛竜戦艇-ファンドラ +--Fandora, the Fearsome Flying Furtress +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Activate + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_ACTIVATE) + e0:SetCode(EVENT_FREE_CHAIN) + c:RegisterEffect(e0) + --Monsters "Fur Hire" you control gain 300 ATK for each monster "Fur Hire" you control with different names + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetCode(EFFECT_UPDATE_ATTACK) + e1:SetRange(LOCATION_FZONE) + e1:SetTargetRange(LOCATION_MZONE,0) + e1:SetTarget(function(e,c) return c:IsSetCard(SET_FUR_HIRE) end) + e1:SetValue(function(e,c) return 300*Duel.GetMatchingGroup(aux.FaceupFilter(Card.IsSetCard,SET_FUR_HIRE),e:GetHandlerPlayer(),LOCATION_MZONE,0,nil):GetClassCount(Card.GetCode) end) + c:RegisterEffect(e1) + --Add 1 monster "Fur Hire" from your Deck to your hand, then discard 1 card + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_HANDES) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_FZONE) + e2:SetCountLimit(1,id) + e2:SetTarget(s.thtg) + e2:SetOperation(s.thop) + c:RegisterEffect(e2) + --Special Summon 1 monster "Fur Hire" from your Deck + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_SPECIAL_SUMMON) + e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e3:SetProperty(EFFECT_FLAG_DELAY) + e3:SetCode(EVENT_DESTROYED) + e3:SetRange(LOCATION_FZONE) + e3:SetCountLimit(1,{id,1}) + e3:SetCondition(s.spcon) + e3:SetTarget(s.sptg) + e3:SetOperation(s.spop) + c:RegisterEffect(e3) +end +s.listed_series={SET_FUR_HIRE} +function s.thfilter(c) + return c:IsSetCard(SET_FUR_HIRE) and c:IsMonster() and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) + Duel.SetOperationInfo(0,CATEGORY_HANDES,nil,1,tp,1) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 and Duel.SendtoHand(g,nil,REASON_EFFECT)>0 then + Duel.ConfirmCards(1-tp,g) + Duel.ShuffleHand(tp) + Duel.BreakEffect() + Duel.DiscardHand(tp,nil,1,1,REASON_EFFECT|REASON_DISCARD,nil) + end +end +function s.spconfilter(c,tp) + return c:IsPreviousSetCard(SET_FUR_HIRE) and c:IsReason(REASON_EFFECT) and c:IsPreviousPosition(POS_FACEUP) + and c:IsPreviousLocation(LOCATION_MZONE) and c:IsPreviousControler(tp) and c:IsReasonPlayer(1-tp) +end +function s.spcon(e,tp,eg,ep,ev,re,r,rp) + return eg:IsExists(s.spconfilter,1,nil,tp) +end +function s.spfilter(c,e,tp) + return c:IsSetCard(SET_FUR_HIRE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) +end +function s.spop(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,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c2725599.lua b/official/c2725599.lua new file mode 100644 index 0000000000..d2ef6f5506 --- /dev/null +++ b/official/c2725599.lua @@ -0,0 +1,70 @@ +--R-ACEアビトレイター +--Rescue-ACE Arbitrator +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Link Summon procedure: 2+ FIRE monsters + Link.AddProcedure(c,aux.FilterBoolFunctionEx(Card.IsAttribute,ATTRIBUTE_FIRE),2) + --You can only Special Summon "Rescue-ACE Arbitrator(s)" once per turn + c:SetSPSummonOnce(id) + --Add 1 "Rescue-ACE Hydrant" or "Rescue-ACE HQ" from your Deck or GY to your hand + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetCondition(function(e) return e:GetHandler():IsLinkSummoned() end) + e1:SetTarget(s.thtg) + e1:SetOperation(s.thop) + c:RegisterEffect(e1) + --Destroy 1 card your opponent controls + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_DESTROY) + e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) + e2:SetCode(EVENT_CHAINING) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(2,id) + e2:SetCondition(s.descon) + e2:SetTarget(s.destg) + e2:SetOperation(s.desop) + c:RegisterEffect(e2) +end +s.listed_names={id,CARD_R_ACE_HYDRANT,63899465} --"Rescue-ACE HQ" +s.listed_series={SET_RESCUE_ACE} +function s.thfilter(c) + return c:IsCode(CARD_R_ACE_HYDRANT,63899465) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.thfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end +function s.descon(e,tp,eg,ep,ev,re,r,rp) + local rc=re:GetHandler() + return rp==tp and re:IsSpellTrapEffect() and re:IsHasType(EFFECT_TYPE_ACTIVATE) and rc:IsSetCard(SET_RESCUE_ACE) + and (rc:IsQuickPlaySpell() or rc:IsNormalTrap()) +end +function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsOnField() and chkc:IsControler(1-tp) end + if chk==0 then return Duel.IsExistingTarget(nil,tp,0,LOCATION_ONFIELD,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local g=Duel.SelectTarget(tp,nil,tp,0,LOCATION_ONFIELD,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) +end +function s.desop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) then + Duel.Destroy(tc,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c27285068.lua b/official/c27285068.lua new file mode 100644 index 0000000000..fb9b7eeba4 --- /dev/null +++ b/official/c27285068.lua @@ -0,0 +1,72 @@ +--開闢なる予幻視 +--Theorealize Liberation +--Scripted by The Razgriz +local s,id=GetID() +function s.initial_effect(c) + --Add to your hand, or Special Summon, 1 monster from your Deck with 300 ATK/200 DEF + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id) + e1:SetCondition(function(e,tp) return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsCode,CARD_MEDIUS_THE_PURE),tp,LOCATION_ONFIELD,0,1,nil) end) + e1:SetTarget(s.thsptg) + e1:SetOperation(s.thspop) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) + --Treat 1 face-up monster you control as a Tuner this turn + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,{id,1}) + e2:SetCost(Cost.SelfBanish) + e2:SetTarget(s.tunertg) + e2:SetOperation(s.tunerop) + c:RegisterEffect(e2) +end +s.listed_names={CARD_MEDIUS_THE_PURE} +function s.thspfilter(c,e,tp,sp_chk) + return c:IsAttack(300) and c:IsDefense(200) + and (c:IsAbleToHand() or (sp_chk and c:IsCanBeSpecialSummoned(e,0,tp,false,false))) +end +function s.thsptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then + local sp_chk=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + return Duel.IsExistingMatchingCard(s.thspfilter,tp,LOCATION_DECK,0,1,nil,e,tp,sp_chk) + end + Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) + Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) +end +function s.thspop(e,tp,eg,ep,ev,re,r,rp) + local sp_chk=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(id,2)) + local sc=Duel.SelectMatchingCard(tp,s.thspfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,sp_chk):GetFirst() + if not sc then return end + aux.ToHandOrElse(sc,tp, + function() return sp_chk and sc:IsCanBeSpecialSummoned(e,0,tp,false,false) end, + function() Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP) end, + aux.Stringid(id,3) + ) +end +function s.tunertg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and not chkc:IsType(TYPE_TUNER) and chkc:IsFaceup() end + if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(aux.NOT(Card.IsType),TYPE_TUNER),tp,LOCATION_MZONE,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) + Duel.SelectTarget(tp,aux.FaceupFilter(aux.NOT(Card.IsType),TYPE_TUNER),tp,LOCATION_MZONE,0,1,1,nil) +end +function s.tunerop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and tc:IsFaceup() then + --It is treated as a Tuner this turn + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_ADD_TYPE) + e1:SetValue(TYPE_TUNER) + e1:SetReset(RESETS_STANDARD_PHASE_END) + tc:RegisterEffect(e1) + end +end \ No newline at end of file diff --git a/official/c30064423.lua b/official/c30064423.lua new file mode 100644 index 0000000000..3458b5e2eb --- /dev/null +++ b/official/c30064423.lua @@ -0,0 +1,100 @@ +--トポロジック・ブラスター・ドラゴン +--Topologic Blaster Dragon +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Link Summon procedure: 2+ Effect Monsters + Link.AddProcedure(c,aux.FilterBoolFunctionEx(Card.IsType,TYPE_EFFECT),2) + --You cannot Summon/Set monsters to any Extra Monster Zone this card points to + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_FIELD) + e0:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_UNCOPYABLE+EFFECT_FLAG_CANNOT_DISABLE) + e0:SetCode(EFFECT_FORCE_MZONE) + e0:SetRange(LOCATION_MZONE) + e0:SetTargetRange(1,0) + e0:SetValue(function(e) return ~(e:GetHandler():GetLinkedZone()&ZONES_EMZ) end) + c:RegisterEffect(e0) + --Apply 1 of these effects + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TODECK+CATEGORY_REMOVE) + e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetRange(LOCATION_EMZONE) + e1:SetCondition(s.effcon) + e1:SetTarget(s.efftg) + e1:SetOperation(s.effop) + c:RegisterEffect(e1) +end +s.listed_name={id} +function s.effcon(e,tp,eg,ep,ev,re,r,rp) + if eg:IsContains(e:GetHandler()) then return false end + local linkg=Duel.GetMatchingGroup(Card.IsLinkMonster,tp,LOCATION_MZONE,LOCATION_MZONE,nil) + for lc in linkg:Iter() do + if aux.zptgroupcon(eg,nil,lc) then return true end + end + return false +end +function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + --Shuffle all other monsters on the field into the Deck + local b1=not Duel.HasFlagEffect(tp,id) + and Duel.IsExistingMatchingCard(Card.IsAbleToDeck,tp,LOCATION_MZONE,LOCATION_MZONE,1,c) + --Shuffle all Spells and Traps on the field into the Deck + local b2=not Duel.HasFlagEffect(tp,id+1) + and Duel.IsExistingMatchingCard(aux.AND(Card.IsSpellTrap,Card.IsAbleToDeck),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) + --Look at your opponent's Extra Deck and banish 1 card from it + local b3=not Duel.HasFlagEffect(tp,id+2) + and Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,0,LOCATION_EXTRA,1,nil) + if chk==0 then return (b1 or b2 or b3) end + if not Duel.HasFlagEffect(tp,id) then + local g=Duel.GetMatchingGroup(Card.IsAbleToDeck,tp,LOCATION_MZONE,LOCATION_MZONE,c) + Duel.SetPossibleOperationInfo(0,CATEGORY_TODECK,g,#g,tp,0) + end + if not Duel.HasFlagEffect(tp,id+1) then + local g=Duel.GetMatchingGroup(aux.AND(Card.IsSpellTrap,Card.IsAbleToDeck),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) + Duel.SetPossibleOperationInfo(0,CATEGORY_TODECK,g,#g,tp,0) + end + if not Duel.HasFlagEffect(tp,id+2) then + local g=Duel.GetMatchingGroup(Card.IsAbleToRemove,tp,0,LOCATION_EXTRA,nil,tp) + Duel.SetPossibleOperationInfo(0,CATEGORY_REMOVE,g,#g,tp,0) + end +end +function s.effop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local exc=c:IsRelateToEffect(e) and c or nil + local b1=not Duel.HasFlagEffect(tp,id) + and Duel.IsExistingMatchingCard(Card.IsAbleToDeck,tp,LOCATION_MZONE,LOCATION_MZONE,1,exc) + local b2=not Duel.HasFlagEffect(tp,id+1) + and Duel.IsExistingMatchingCard(aux.AND(Card.IsSpellTrap,Card.IsAbleToDeck),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) + local b3=not Duel.HasFlagEffect(tp,id+2) + and Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,0,LOCATION_EXTRA,1,nil) + if not (b1 or b2 or b3) then return end + local op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,1)}, + {b2,aux.Stringid(id,2)}, + {b3,aux.Stringid(id,3)}) + if op==1 then + --Shuffle all other monsters on the field into the Deck + Duel.RegisterFlagEffect(tp,id,RESET_PHASE|PHASE_END,0,1) + local g=Duel.GetMatchingGroup(Card.IsAbleToDeck,tp,LOCATION_MZONE,LOCATION_MZONE,exc) + Duel.SendtoDeck(g,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) + elseif op==2 then + --Shuffle all Spells and Traps on the field into the Deck + Duel.RegisterFlagEffect(tp,id+1,RESET_PHASE|PHASE_END,0,1) + local g=Duel.GetMatchingGroup(aux.AND(Card.IsSpellTrap,Card.IsAbleToDeck),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) + Duel.SendtoDeck(g,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) + elseif op==3 then + --Look at your opponent's Extra Deck and banish 1 card from it + Duel.RegisterFlagEffect(tp,id+2,RESET_PHASE|PHASE_END,0,1) + local g=Duel.GetFieldGroup(tp,0,LOCATION_EXTRA) + Duel.ConfirmCards(tp,g) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) + local sg=g:FilterSelect(tp,Card.IsAbleToRemove,1,1,nil) + if #sg>0 then + Duel.Remove(sg,POS_FACEUP,REASON_EFFECT) + end + Duel.ShuffleExtra(1-tp) + end +end \ No newline at end of file diff --git a/official/c30271097.lua b/official/c30271097.lua new file mode 100644 index 0000000000..f465eedc66 --- /dev/null +++ b/official/c30271097.lua @@ -0,0 +1,98 @@ +--The Fallen & The Virtuous +--The Fallen & The Virtuous +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Activate 1 of these effects + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetProperty(EFFECT_FLAG_CARD_TARGET) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) + e1:SetCost(s.effcost) + e1:SetTarget(s.efftg) + e1:SetOperation(s.effop) + e1:SetHintTiming(TIMING_END_PHASE,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) +end +s.listed_names={CARD_ALBAZ} +s.listed_series={SET_BRANDED,SET_DOGMATIKA,SET_ECCLESIA} +function s.descostfilter(c) + return c:ListsCode(CARD_ALBAZ) and c:IsAbleToGraveAsCost() +end +function s.spconfilter(c) + return c:IsSetCard(SET_ECCLESIA) and c:IsMonster() and c:IsFaceup() +end +function s.effcost(e,tp,eg,ep,ev,re,r,rp,chk) + --Send 1 monster that mentions "Fallen of Albaz" from your Extra Deck to the GY, then target 1 face-up card on the field; destroy it + local b1=Duel.IsExistingMatchingCard(s.descostfilter,tp,LOCATION_EXTRA,0,1,nil) + and Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) + --If you have an "Ecclesia" monster in your field or GY: Target 1 monster in either GY; Special Summon it to your field + local b2=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spconfilter,tp,LOCATION_MZONE|LOCATION_GRAVE,0,1,nil) + and Duel.IsExistingTarget(Card.IsCanBeSpecialSummoned,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil,e,0,tp,false,false) + if chk==0 then return b1 or b2 end + local op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,1)}, + {b2,aux.Stringid(id,2)}) + e:SetLabel(op) + if op==1 then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local g=Duel.SelectMatchingCard(tp,s.descostfilter,tp,LOCATION_EXTRA,0,1,1,nil) + Duel.SendtoGrave(g,REASON_COST) + end +end +function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + local c=e:GetHandler() + if chkc then + local op=Duel.GetChainInfo(0,CHAININFO_TARGET_PARAM) + if op==1 then + return chkc:IsOnField() and chkc:IsFaceup() and chkc~=c + elseif op==2 then + return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsCanBeSpecialSummoned(e,0,tp,false,false) + end + end + --Send 1 monster that mentions "Fallen of Albaz" from your Extra Deck to the GY, then target 1 face-up card on the field; destroy it + local b1=Duel.IsExistingMatchingCard(s.descostfilter,tp,LOCATION_EXTRA,0,1,nil) + and Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) + --If you have an "Ecclesia" monster in your field or GY: Target 1 monster in either GY; Special Summon it to your field + local b2=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spconfilter,tp,LOCATION_MZONE|LOCATION_GRAVE,0,1,nil) + and Duel.IsExistingTarget(Card.IsCanBeSpecialSummoned,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,nil,e,0,tp,false,false) + if chk==0 then return b1 or b2 end + local op=nil + local label=e:GetLabel() + if label~=0 then + op=label + else + op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,1)}, + {b2,aux.Stringid(id,2)}) + end + e:SetLabel(0) + Duel.SetTargetParam(op) + if op==1 then + e:SetCategory(CATEGORY_DESTROY) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local g=Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,c) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) + elseif op==2 then + e:SetCategory(CATEGORY_SPECIAL_SUMMON) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectTarget(tp,Card.IsCanBeSpecialSummoned,tp,LOCATION_GRAVE,LOCATION_GRAVE,1,1,nil,e,0,tp,false,false) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,0) + end +end +function s.effop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if not tc:IsRelateToEffect(e) then return end + local op=Duel.GetChainInfo(0,CHAININFO_TARGET_PARAM) + if op==1 then + --Send 1 monster that mentions "Fallen of Albaz" from your Extra Deck to the GY, then target 1 face-up card on the field; destroy it + Duel.Destroy(tc,REASON_EFFECT) + elseif op==2 then + --If you have an "Ecclesia" monster in your field or GY: Target 1 monster in either GY; Special Summon it to your field + Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c31286915.lua b/official/c31286915.lua new file mode 100644 index 0000000000..198bf01924 --- /dev/null +++ b/official/c31286915.lua @@ -0,0 +1,71 @@ +--K9-EX ”Ripper/M” +--K9-X "Ripper/Millennia" +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Xyz Summon procedure: 2 Level 9 monsters + Xyz.AddProcedure(c,nil,9,2) + --If this card attacks a Defense Position monster, inflict piercing battle damage to your opponent + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetCode(EFFECT_PIERCE) + c:RegisterEffect(e1) + --Shuffle up to 2 cards from your opponent's GY and/or banishment into the Deck + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_TODECK) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) + e2:SetCode(EVENT_SPSUMMON_SUCCESS) + e2:SetCountLimit(1,id) + e2:SetCondition(s.tdcon) + e2:SetTarget(s.tdtg) + e2:SetOperation(s.tdop) + c:RegisterEffect(e2) + --Negate a monster effect your opponent activates and destroy all cards on the field + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_DISABLE+CATEGORY_DESTROY) + e3:SetType(EFFECT_TYPE_QUICK_O) + e3:SetCode(EVENT_CHAINING) + e3:SetRange(LOCATION_MZONE) + e3:SetCountLimit(1,{id,1}) + e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return rp==1-tp and re:IsMonsterEffect() and Duel.IsChainDisablable(ev) end) + e3:SetCost(Cost.DetachFromSelf(2)) + e3:SetTarget(s.distg) + e3:SetOperation(s.disop) + c:RegisterEffect(e3) +end +s.listed_series={SET_K9} +function s.tdcon(e,tp,eg,ep,ev,re,r,rp) + return re and re:GetHandler():IsSetCard(SET_K9) and re:IsSpellTrapEffect() +end +function s.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_GRAVE|LOCATION_REMOVED) and chkc:IsControler(1-tp) and chkc:IsAbleToDeck() end + if chk==0 then return Duel.IsExistingTarget(Card.IsAbleToDeck,tp,0,LOCATION_GRAVE|LOCATION_REMOVED,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) + local g=Duel.SelectTarget(tp,Card.IsAbleToDeck,tp,0,LOCATION_GRAVE|LOCATION_REMOVED,1,2,nil) + Duel.SetOperationInfo(0,CATEGORY_TODECK,g,#g,tp,0) +end +function s.tdop(e,tp,eg,ep,ev,re,r,rp) + local tg=Duel.GetTargetCards(e) + if #tg>0 then + Duel.SendtoDeck(tg,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) + end +end +function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) + local g=Duel.GetFieldGroup(tp,LOCATION_ONFIELD,LOCATION_ONFIELD) + if chk==0 then return #g>0 end + Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,tp,0) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,#g,tp,0) +end +function s.disop(e,tp,eg,ep,ev,re,r,rp) + if Duel.NegateEffect(ev) then + local g=Duel.GetFieldGroup(tp,LOCATION_ONFIELD,LOCATION_ONFIELD) + if #g>0 then + Duel.BreakEffect() + Duel.Destroy(g,REASON_EFFECT) + end + end +end \ No newline at end of file diff --git a/official/c38007649.lua b/official/c38007649.lua new file mode 100644 index 0000000000..1eb37a4b95 --- /dev/null +++ b/official/c38007649.lua @@ -0,0 +1,73 @@ +--終刻変転 +--DoomZ Changer +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Destroy 1 "DoomZ" card in your hand, Deck, or face-up field, except "DoomZ Changer" + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_DESTROY) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id) + e1:SetTarget(s.destg) + e1:SetOperation(s.desop) + c:RegisterEffect(e1) + --Add 1 "DoomZ" card from your GY to your hand, except "DoomZ Changer", then you can Special Summon 1 "DoomZ" monster from your hand + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY) + e2:SetCode(EVENT_DESTROYED) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return r&REASON_EFFECT>0 end) + e2:SetTarget(s.thsptg) + e2:SetOperation(s.thspop) + c:RegisterEffect(e2) +end +s.listed_names={id} +s.listed_series={SET_DOOMZ} +function s.desfilter(c) + return c:IsSetCard(SET_DOOMZ) and (c:IsFaceup() or not c:IsOnField()) and not c:IsCode(id) +end +function s.destg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.desfilter,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_ONFIELD,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_ONFIELD) +end +function s.desop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local sc=Duel.SelectMatchingCard(tp,s.desfilter,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_ONFIELD,0,1,1,nil):GetFirst() + if sc then + if sc:IsOnField() then Duel.HintSelection(sc) end + Duel.Destroy(sc,REASON_EFFECT) + end +end +function s.thfilter(c) + return c:IsSetCard(SET_DOOMZ) and c:IsAbleToHand() and not c:IsCode(id) +end +function s.thsptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_GRAVE,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_GRAVE) + Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND) +end +function s.spfilter(c,e,tp) + return c:IsSetCard(SET_DOOMZ) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.thspop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local sc=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_GRAVE,0,1,1,nil):GetFirst() + if not sc then return end + Duel.HintSelection(sc) + if Duel.SendtoHand(sc,nil,REASON_EFFECT)>0 and sc:IsLocation(LOCATION_HAND) + and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then + Duel.ShuffleHand(tp) + local g=Duel.GetMatchingGroup(s.spfilter,tp,LOCATION_HAND,0,nil,e,tp) + if #g>0 and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local sg=g:Select(tp,1,1,nil) + Duel.BreakEffect() + Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP) + end + end +end \ No newline at end of file diff --git a/official/c38129297.lua b/official/c38129297.lua new file mode 100644 index 0000000000..37528efbf8 --- /dev/null +++ b/official/c38129297.lua @@ -0,0 +1,97 @@ +--ダブル・トリガー +--Double Trigger +--Scripted by Eerie Code +local s,id=GetID() +function s.initial_effect(c) + local fusion_params={ + handler=c, + matfilter=aux.FALSE, + extrafil=s.fextra, + extraop=Fusion.BanishMaterial, + extratg=s.extratg + } + local ritual_params={ + handler=c, + lvtype=RITPROC_GREATER, + forcedselection=s.forcedselection, + matfilter=aux.FilterBoolFunction(Card.IsLocation,LOCATION_GRAVE), + extrafil=s.rextra, + extratg=s.extratg + } + --Activate 1 of these effects + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCost(s.effcost(fusion_params,ritual_params)) + e1:SetTarget(s.efftg(fusion_params,ritual_params)) + e1:SetOperation(s.effop(fusion_params,ritual_params)) + c:RegisterEffect(e1) +end +s.listed_series={SET_ROKKET} +function s.matcheck(tp,sg,fc) + return sg:IsExists(Card.IsSetCard,1,nil,SET_ROKKET,fc,SUMMON_TYPE_FUSION,tp) +end +function s.fextra(e,tp,mg) + if not Duel.IsPlayerAffectedByEffect(tp,CARD_SPIRIT_ELIMINATION) then + return Duel.GetMatchingGroup(Fusion.IsMonsterFilter(Card.IsAbleToRemove),tp,LOCATION_GRAVE,0,nil),s.matcheck + end + return nil,s.matcheck +end +function s.extratg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return true end + Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_GRAVE) +end +function s.rextra(e,tp,eg,ep,ev,re,r,rp,chk) + if not Duel.IsPlayerAffectedByEffect(tp,CARD_SPIRIT_ELIMINATION) then + return Duel.GetMatchingGroup(aux.AND(Card.HasLevel,Card.IsAbleToRemove),tp,LOCATION_GRAVE,0,nil) + end +end +function s.forcedselection(e,tp,sg,sc) + return sg:IsExists(Card.IsSetCard,1,nil,SET_ROKKET) +end +function s.effcost(fusion_params,ritual_params) + return function(e,tp,eg,ep,ev,re,r,rp,chk) + e:SetLabel(-100) + local b1=not Duel.HasFlagEffect(tp,id) + and Fusion.SummonEffTG(fusion_params)(e,tp,eg,ep,ev,re,r,rp,0) + local b2=not Duel.HasFlagEffect(tp,id+1) + and Ritual.Target(ritual_params)(e,tp,eg,ep,ev,re,r,rp,0) + if chk==0 then return b1 or b2 end + end +end +function s.efftg(fusion_params,ritual_params) + return function(e,tp,eg,ep,ev,re,r,rp,chk) + local cost_skip=e:GetLabel()~=-100 + local b1=(cost_skip or not Duel.HasFlagEffect(tp,id)) + and Fusion.SummonEffTG(fusion_params)(e,tp,eg,ep,ev,re,r,rp,0) + local b2=(cost_skip or not Duel.HasFlagEffect(tp,id+1)) + and Ritual.Target(ritual_params)(e,tp,eg,ep,ev,re,r,rp,0) + if chk==0 then e:SetLabel(0) return b1 or b2 end + local op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,1)}, + {b2,aux.Stringid(id,2)}) + e:SetLabel(op) + if op==1 then + e:SetCategory(CATEGORY_REMOVE+CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON) + if not cost_skip then Duel.RegisterFlagEffect(tp,id,RESET_PHASE|PHASE_END,0,1) end + Fusion.SummonEffTG(fusion_params)(e,tp,eg,ep,ev,re,r,rp,1) + elseif op==2 then + e:SetCategory(CATEGORY_REMOVE+CATEGORY_SPECIAL_SUMMON) + if not cost_skip then Duel.RegisterFlagEffect(tp,id+1,RESET_PHASE|PHASE_END,0,1) end + Ritual.Target(ritual_params)(e,tp,eg,ep,ev,re,r,rp,1) + end + end +end +function s.effop(fusion_params,ritual_params) + return function(e,tp,eg,ep,ev,re,r,rp) + local op=e:GetLabel() + if op==1 then + --Fusion Summon 1 Fusion Monster from your Extra Deck, by banishing its materials from your GY, including a "Rokket" monster + Fusion.SummonEffOP(fusion_params)(e,tp,eg,ep,ev,re,r,rp) + elseif op==2 then + --Ritual Summon 1 Ritual Monster from your hand, by banishing monsters from your GY whose total Levels equal or exceed that monster's Level, including a "Rokket" monster + Ritual.Operation(ritual_params)(e,tp,eg,ep,ev,re,r,rp) + end + end +end \ No newline at end of file diff --git a/official/c39341885.lua b/official/c39341885.lua new file mode 100644 index 0000000000..8a1842a31c --- /dev/null +++ b/official/c39341885.lua @@ -0,0 +1,113 @@ +--絢嵐たる海霊ヴァルルーン +--Radiant Typhoon Varuroon, the Sea Spirit +--Scripted by Eerie Code +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Link Summon procedure: 2 "Radiant Typhoon" monsters + Link.AddProcedure(c,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_RADIANT_TYPHOON),2) + --Add 1 "Mystical Space Typhoon" from your Deck or GY to your hand + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetCountLimit(1,{id,0}) + e1:SetCondition(function(e) return e:GetHandler():IsLinkSummoned() end) + e1:SetTarget(s.thtg) + e1:SetOperation(s.thop) + c:RegisterEffect(e1) + --Place 2 face-up monsters on the field, including a "Radiant Typhoon" monster you control face-up in their owners' Spell & Trap Zones as Continuous Spells + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.monpltg) + e2:SetOperation(s.monplop) + c:RegisterEffect(e2) + --Place 1 "Radiant Typhoon" Continuous Trap from your Deck or GY face-up on your field + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,2)) + e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e3:SetProperty(EFFECT_FLAG_DELAY) + e3:SetCode(EVENT_CHAINING) + e3:SetRange(LOCATION_MZONE) + e3:SetCountLimit(1,{id,2}) + e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsSpellEffect() and re:IsActiveType(TYPE_QUICKPLAY) end) + e3:SetTarget(s.trappltg) + e3:SetOperation(s.trapplop) + c:RegisterEffect(e3) +end +s.listed_series={SET_RADIANT_TYPHOON} +s.listed_names={CARD_MYSTICAL_SPACE_TYPHOON} +function s.thfilter(c) + return c:IsCode(CARD_MYSTICAL_SPACE_TYPHOON) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.thfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end +function s.monplfilter(c,e) + return c:IsFaceup() and not c:IsForbidden() and c:IsCanBeEffectTarget(e) +end +function s.rescon(sg,e,tp) + local your_g,opp_g=sg:Split(Card.IsOwner,nil,tp) + return #sg==2 and #your_g>0 and your_g:IsExists(Card.IsSetCard,1,nil,SET_RADIANT_TYPHOON) + and Duel.GetLocationCount(tp,LOCATION_SZONE)>=#your_g + and Duel.GetLocationCount(1-tp,LOCATION_SZONE)>=#opp_g +end +function s.monpltg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return false end + local g=Duel.GetMatchingGroup(s.monplfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil,e) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 + and aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,0) end + local tg=aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,1,tp,HINTMSG_TOFIELD) + Duel.SetTargetCard(tg) +end +function s.monplop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local tg=Duel.GetTargetCards(e) + for tc in tg:Iter() do + if not tc:IsImmuneToEffect(e) then + local owner=tc:GetOwner() + if Duel.GetLocationCount(owner,LOCATION_SZONE)<=0 then + Duel.SendtoGrave(tc,REASON_RULE,nil,PLAYER_NONE) + elseif Duel.MoveToField(tc,tp,owner,LOCATION_SZONE,POS_FACEUP,tc:IsMonsterCard()) then + --Treated as a Continuous Spell + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_CHANGE_TYPE) + e1:SetValue(TYPE_SPELL|TYPE_CONTINUOUS) + e1:SetReset(RESET_EVENT|(RESETS_STANDARD&~RESET_TURN_SET)) + tc:RegisterEffect(e1) + end + end + end +end +function s.trapplfilter(c,tp) + return c:IsSetCard(SET_RADIANT_TYPHOON) and c:IsContinuousTrap() and not c:IsForbidden() and c:CheckUniqueOnField(tp) +end +function s.trappltg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 + and Duel.IsExistingMatchingCard(s.trapplfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil,tp) end +end +function s.trapplop(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) + local sc=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.trapplfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil,tp):GetFirst() + if sc then + Duel.MoveToField(sc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) + end +end \ No newline at end of file diff --git a/official/c3957130.lua b/official/c3957130.lua new file mode 100644 index 0000000000..283aada7e0 --- /dev/null +++ b/official/c3957130.lua @@ -0,0 +1,77 @@ +--トゥリスヴァレル・ドラゴン +--Trisborrel Dragon +--Scripted by Eerie Code +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Link Summon procedure: 2+ DARK Dragon monsters, including a "Rokket" monster + Link.AddProcedure(c,s.matfilter,2,nil,s.matcheck) + --Add 1 "Rapid Trigger", "Heavy Interlock", or "Double Trigger" from your Deck to your hand + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetCountLimit(1,{id,0}) + e1:SetCondition(function(e) return e:GetHandler():IsLinkSummoned() end) + e1:SetTarget(s.thtg) + e1:SetOperation(s.thop) + c:RegisterEffect(e1) + --Destroy 1 face-up card you control, and if you do, add 1 DARK Dragon monster from your GY to your hand + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_DESTROY+CATEGORY_TOHAND) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.destg) + e2:SetOperation(s.desop) + c:RegisterEffect(e2) +end +s.listed_names={67526112,20071842,38129297} --"Rapid Trigger", "Heavy Interlock", "Double Trigger" +s.listed_series={SET_ROKKET} +function s.matfilter(c,sc,st,tp) + return c:IsAttribute(ATTRIBUTE_DARK,sc,st,tp) and c:IsRace(RACE_DRAGON,sc,st,tp) +end +function s.matcheck(g,lc,sumtype,tp) + return g:IsExists(Card.IsSetCard,1,nil,SET_ROKKET,lc,sumtype,tp) +end +function s.deckthfilter(c) + return c:IsCode(67526112,20071842,38129297) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.deckthfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.deckthfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end +function s.gythfilter(c) + return c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_DRAGON) and c:IsAbleToHand() +end +function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return false end + if chk==0 then return Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_ONFIELD,0,1,nil) + and Duel.IsExistingTarget(s.gythfilter,tp,LOCATION_GRAVE,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local dg=Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_ONFIELD,0,1,1,nil) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local hg=Duel.SelectTarget(tp,s.gythfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,dg,1,tp,0) + Duel.SetOperationInfo(0,CATEGORY_TOHAND,hg,1,tp,0) +end +function s.desop(e,tp,eg,ep,ev,re,r,rp) + local tg=Duel.GetTargetCards(e) + if #tg==0 then return end + local fc,gyc=tg:Split(Card.IsLocation,nil,LOCATION_ONFIELD) + if fc and Duel.Destroy(fc,REASON_EFFECT)>0 and gyc then + Duel.SendtoHand(gyc,nil,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c4079728.lua b/official/c4079728.lua new file mode 100644 index 0000000000..74b44269ed --- /dev/null +++ b/official/c4079728.lua @@ -0,0 +1,77 @@ +--ガンホー!スプリガンズ! +--Gung-ho! Springans! +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Xyz Summon procedure: 2+ Level 4 "Springans" monsters + Xyz.AddProcedure(c,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_SPRINGANS),4,2,nil,nil,Xyz.InfiniteMats) + --Special Summon 1 "Springans Captain Sargas" from your Deck or GY + local e1a=Effect.CreateEffect(c) + e1a:SetDescription(aux.Stringid(id,0)) + e1a:SetCategory(CATEGORY_SPECIAL_SUMMON) + e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1a:SetProperty(EFFECT_FLAG_DELAY) + e1a:SetCode(EVENT_TO_GRAVE) + e1a:SetCountLimit(1,id) + e1a:SetTarget(s.sptg) + e1a:SetOperation(s.spop) + c:RegisterEffect(e1a) + local e1b=e1a:Clone() + e1b:SetCode(EVENT_SPSUMMON_SUCCESS) + e1b:SetCondition(function(e) return e:GetHandler():IsXyzSummoned() end) + c:RegisterEffect(e1b) + --Add to your hand, or Special Summon, 1 "Springans" or "Therion" monster or "Fallen of Albaz" or monster that mentions it + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,id) + e2:SetCost(Cost.DetachFromSelf(2)) + e2:SetTarget(s.thsptg) + e2:SetOperation(s.thspop) + c:RegisterEffect(e2) +end +s.listed_names={CARD_ALBAZ,29601381} --"Springans Captain Sargas" +s.listed_series={SET_SPRINGANS,SET_THERION} +function s.spfilter(c,e,tp) + return c:IsCode(29601381) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) +end +function s.spop(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,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end +function s.thspfilter(c,e,tp,mmz_chk) + return (c:IsSetCard({SET_SPRINGANS,SET_THERION}) or (c:IsCode(CARD_ALBAZ) or c:ListsCode(CARD_ALBAZ))) and c:IsMonster() + and (c:IsAbleToHand() or (mmz_chk and c:IsCanBeSpecialSummoned(e,0,tp,false,false))) +end +function s.thsptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thspfilter,tp,LOCATION_DECK,0,1,nil,e,tp,Duel.GetLocationCount(tp,LOCATION_MZONE)>0) end + Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) + Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) +end +function s.thspop(e,tp,eg,ep,ev,re,r,rp) + local mmz_chk=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(id,2)) + local sc=Duel.SelectMatchingCard(tp,s.thspfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,mmz_chk):GetFirst() + if not sc then return end + aux.ToHandOrElse(sc,tp, + function() + return mmz_chk and sc:IsCanBeSpecialSummoned(e,0,tp,false,false) + end, + function() + return Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP) + end, + aux.Stringid(id,3) + ) +end \ No newline at end of file diff --git a/official/c41516133.lua b/official/c41516133.lua new file mode 100644 index 0000000000..764beb5440 --- /dev/null +++ b/official/c41516133.lua @@ -0,0 +1,81 @@ +--超巨大戦艦 メタル・スレイブ +--Super B.E.S. Metal Slave +--scripted by Naim +local s,id=GetID() +local COUNTER_BES=0x1f +function s.initial_effect(c) + c:EnableCounterPermit(COUNTER_BES) + --Special Summon this card from your hand, then place counters on it equal to the number of cards sent to the GY to activate this effect + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_COUNTER) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetRange(LOCATION_HAND) + e1:SetCountLimit(1,id) + e1:SetCost(s.spcost) + e1:SetTarget(s.sptg) + e1:SetOperation(s.spop) + c:RegisterEffect(e1) + --Destroy 2 face-up cards on the field, including a "B.E.S." monster you control + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_DESTROY) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,0,EFFECT_COUNT_CODE_CHAIN) + e2:SetCost(Cost.RemoveCounterFromSelf(COUNTER_BES,1)) + e2:SetTarget(s.destg) + e2:SetOperation(s.desop) + e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e2) +end +s.listed_series={SET_BES} +function s.spcostfilter(c) + return c:IsLevelBelow(10) and c:IsSetCard(SET_BES) and c:IsAbleToGraveAsCost() +end +function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.IsExistingMatchingCard(s.spcostfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,c) end + local g=Duel.GetMatchingGroup(s.spcostfilter,tp,LOCATION_HAND|LOCATION_DECK,0,c) + local sg=aux.SelectUnselectGroup(g,e,tp,1,5,aux.dncheck,1,tp,HINTMSG_TOGRAVE) + e:SetLabel(Duel.SendtoGrave(sg,REASON_COST)) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) + and c:IsCanAddCounter(COUNTER_BES,1,false,LOCATION_MZONE) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) + Duel.SetOperationInfo(0,CATEGORY_COUNTER,nil,e:GetLabel(),tp,COUNTER_BES) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local count=e:GetLabel() + if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 + and c:IsCanAddCounter(COUNTER_BES,count) then + Duel.BreakEffect() + c:AddCounter(COUNTER_BES,count) + end +end +function s.besmonsterfilter(c,tp) + return c:IsSetCard(SET_BES) and c:IsLocation(LOCATION_MZONE) and c:IsControler(tp) +end +function s.rescon(sg,e,tp,mg) + return sg:IsExists(s.besmonsterfilter,1,nil,tp) +end +function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return false end + local g=Duel.GetMatchingGroup(aux.FaceupFilter(Card.IsCanBeEffectTarget,e),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) + if chk==0 then return #g>=2 and aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,0) end + local g=aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,1,tp,HINTMSG_DESTROY) + Duel.SetTargetCard(g) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,2,tp,0) +end +function s.desop(e,tp,eg,ep,ev,re,r,rp,chk) + local tg=Duel.GetTargetCards(e) + if #tg>0 then + Duel.Destroy(tg,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c42125140.lua b/official/c42125140.lua new file mode 100644 index 0000000000..e533fd1665 --- /dev/null +++ b/official/c42125140.lua @@ -0,0 +1,104 @@ +--星辰鋏竜シャウラス +--Dracotail Shaurus +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Fusion Materials: 1 "Dragontail" monster + 1 monster in the hand + Fusion.AddProcMix(c,true,true,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_DRACOTAIL),aux.FilterBoolFunctionEx(Card.IsLocation,LOCATION_HAND)) + --Shuffle 2 "Dracotail" cards from your GY, and 1 face-up card on the field of the same type (Monster, Spell, or Trap) as 1 of them into the Deck + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TODECK) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetProperty(EFFECT_FLAG_CARD_TARGET) + e1:SetRange(LOCATION_MZONE) + e1:SetCountLimit(1,id) + e1:SetTarget(s.tdtg) + e1:SetOperation(s.tdop) + c:RegisterEffect(e1) + --Special Summon this card from the GY, but banish it when it leaves the field + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_REMOVE) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY,EFFECT_FLAG2_CHECK_SIMULTANEOUS) + e2:SetCode(EVENT_CUSTOM+id) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + c:RegisterEffect(e2) + --Keep track of monsters being sent to the GY at the same time + local e3=Effect.CreateEffect(c) + e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) + e3:SetCode(EVENT_TO_GRAVE) + e3:SetRange(LOCATION_GRAVE) + e3:SetCondition(function() return not Duel.IsDamageStep() end) + e3:SetOperation(s.regop) + c:RegisterEffect(e3) + local e4=e3:Clone() + e4:SetCode(EVENT_CHAINING) + e4:SetOperation(function(e) e:GetHandler():ResetFlagEffect(id+1) end) + c:RegisterEffect(e4) + local e5=e4:Clone() + e5:SetCode(EVENT_CHAIN_SOLVED) + c:RegisterEffect(e5) + local e6=e4:Clone() + e6:SetCode(EVENT_BREAK_EFFECT) + c:RegisterEffect(e6) +end +s.listed_series={SET_DRACOTAIL} +function s.tdfilter(c,e) + return (c:IsSetCard(SET_DRACOTAIL) or c:IsOnField()) and c:IsFaceup() and c:IsAbleToDeck() and c:IsCanBeEffectTarget(e) +end +function s.rescon(sg,e,tp,mg) + local gy_sg,field_sg=sg:Split(Card.IsLocation,nil,LOCATION_GRAVE) + return #gy_sg==2 and #field_sg==1 and field_sg:GetFirst():IsType(gy_sg:GetBitwiseOr(Card.GetMainCardType)) +end +function s.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return false end + local g=Duel.GetMatchingGroup(s.tdfilter,tp,LOCATION_GRAVE|LOCATION_ONFIELD,LOCATION_ONFIELD,nil,e) + if chk==0 then return #g>=3 and aux.SelectUnselectGroup(g,e,tp,3,3,s.rescon,0) end + local tg=aux.SelectUnselectGroup(g,e,tp,3,3,s.rescon,1,tp,HINTMSG_TODECK) + Duel.SetTargetCard(tg) + Duel.SetOperationInfo(0,CATEGORY_TODECK,tg,3,tp,0) +end +function s.tdop(e,tp,eg,ep,ev,re,r,rp) + local tg=Duel.GetTargetCards(e) + if #tg==3 then + Duel.SendtoDeck(tg,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) + end +end +function s.regop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local ct=eg:FilterCount(Card.IsMonster,nil) + if ct==0 or eg:IsContains(c) then return end + if ct>=2 or c:HasFlagEffect(id+1) then + Duel.RaiseSingleEvent(c,EVENT_CUSTOM+id,re,r,rp,ep,ev) + end + local eff=Duel.GetChainInfo(0,CHAININFO_TRIGGERING_EFFECT) + if eff then + c:RegisterFlagEffect(id+1,RESET_EVENT|RESETS_STANDARD|RESET_CHAIN,0,1) + end +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 then + --Banish it when it leaves the field + local e1=Effect.CreateEffect(c) + e1:SetDescription(3300) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_LEAVE_FIELD_REDIRECT) + e1:SetValue(LOCATION_REMOVED) + e1:SetReset(RESET_EVENT|RESETS_REDIRECT) + c:RegisterEffect(e1,true) + end +end \ No newline at end of file diff --git a/official/c42302563.lua b/official/c42302563.lua new file mode 100644 index 0000000000..960503aac9 --- /dev/null +++ b/official/c42302563.lua @@ -0,0 +1,73 @@ +--獄花の大燿聖ストリチア +--Elvennotes Seraphim Stlitzia +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Synchro Summon procedure: 1 Tuner + 1+ non-Tuner monsters + Synchro.AddProcedure(c,nil,1,1,Synchro.NonTuner(nil),1,99) + --This card's original ATK becomes 3000 while in the center Main Monster Zone + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e1:SetCode(EFFECT_SET_BASE_ATTACK) + e1:SetRange(LOCATION_MMZONE) + e1:SetCondition(function(e) return e:GetHandler():IsSequence(2) end) + e1:SetValue(3000) + c:RegisterEffect(e1) + --Special Summon 1 Level 6 or lower "Elvennotes" monster from your hand or GY, then you can decrease the Levels of all Level 4 or higher monsters currently on the field by 3 until the end of this turn + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_LVCHANGE) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,id) + e2:SetCondition(function() return Duel.IsMainPhase() end) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + e2:SetHintTiming(0,TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) + c:RegisterEffect(e2) +end +s.listed_series={SET_ELVENNOTES} +function s.spfilter(c,e,tp) + return c:IsLevelBelow(6) and c:IsSetCard(SET_ELVENNOTES) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_GRAVE,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_GRAVE) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_HAND|LOCATION_GRAVE,0,1,1,nil,e,tp) + if #g>0 and Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)>0 + and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsLevelAbove,4),tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) + and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then + local g=Duel.GetMatchingGroup(aux.FaceupFilter(Card.IsLevelAbove,4),tp,LOCATION_MZONE,LOCATION_MZONE,nil) + Duel.BreakEffect() + for tc in g:Iter() do + --Decrease the Levels of all Level 4 or higher monsters currently on the field by 3 until the end of this turn + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_UPDATE_LEVEL) + e1:SetValue(-3) + e1:SetReset(RESETS_STANDARD_PHASE_END) + tc:RegisterEffect(e1) + end + end + end + --You cannot Special Summon from the Extra Deck for the rest of this turn, except Synchro Monsters + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,2)) + e2:SetType(EFFECT_TYPE_FIELD) + e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e2:SetTargetRange(1,0) + e2:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsSynchroMonster() end) + e2:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e2,tp) +end \ No newline at end of file diff --git a/official/c46708514.lua b/official/c46708514.lua new file mode 100644 index 0000000000..b57fbd2cc2 --- /dev/null +++ b/official/c46708514.lua @@ -0,0 +1,91 @@ +--蒼穹を睨めるダーク +--Dark Staring at the Blue Sky +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Special Summon this card + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY,EFFECT_FLAG2_CHECK_SIMULTANEOUS) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetRange(LOCATION_GRAVE) + e1:SetCountLimit(1,{id,0}) + e1:SetCondition(s.spcon) + e1:SetTarget(s.sptg) + e1:SetOperation(s.spop) + c:RegisterEffect(e1) + --Negate that monster effect that includes an effect that Special Summons a monster(s), and if you do, destroy that card + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_DISABLE+CATEGORY_DESTROY) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetCode(EVENT_CHAINING) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return re:IsMonsterEffect() and re:IsHasCategory(CATEGORY_SPECIAL_SUMMON) and Duel.IsChainDisablable(ev) end) + e2:SetCost(s.discost) + e2:SetTarget(s.distg) + e2:SetOperation(s.disop) + c:RegisterEffect(e2) + --Return 1 of your other banished monsters to the GY + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,2)) + e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e3:SetCode(EVENT_PHASE+PHASE_END) + e3:SetRange(LOCATION_REMOVED) + e3:SetCountLimit(1,{id,2}) + e3:SetCondition(function(e) return e:GetHandler():GetTurnID()==Duel.GetTurnCount() end) + e3:SetTarget(s.rtgtg) + e3:SetOperation(s.rtgop) + c:RegisterEffect(e3) +end +function s.spcon(e,tp,eg,ep,ev,re,r,rp) + return rp==1-tp and re and re:IsActivated() and re:IsMonsterEffect() + and eg:IsExists(Card.IsSummonLocation,1,nil,LOCATION_DECK|LOCATION_EXTRA) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) then + Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) + end +end +function s.discost(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemoveAsCost,tp,LOCATION_HAND|LOCATION_ONFIELD,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) + local g=Duel.SelectMatchingCard(tp,Card.IsAbleToRemoveAsCost,tp,LOCATION_HAND|LOCATION_ONFIELD,0,1,1,nil) + Duel.Remove(g,POS_FACEUP,REASON_COST) +end +function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return true end + local rc=re:GetHandler() + Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,tp,0) + if rc:IsDestructable() and rc:IsRelateToEffect(re) then + Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,tp,0) + end +end +function s.disop(e,tp,eg,ep,ev,re,r,rp) + if Duel.NegateEffect(ev) and re:GetHandler():IsRelateToEffect(re) then + Duel.Destroy(eg,REASON_EFFECT) + end +end +function s.rtgtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsMonster),tp,LOCATION_REMOVED,0,1,e:GetHandler()) end +end +function s.rtgop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local exc=c:IsRelateToEffect(e) and c or nil + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOGRAVE) + local g=Duel.SelectMatchingCard(tp,aux.FaceupFilter(Card.IsMonster),tp,LOCATION_REMOVED,0,1,1,exc) + if #g>0 then + Duel.HintSelection(g) + Duel.SendtoGrave(g,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c47247792.lua b/official/c47247792.lua new file mode 100644 index 0000000000..c4d0fee00c --- /dev/null +++ b/official/c47247792.lua @@ -0,0 +1,82 @@ +--超電導戦騎プラズマ・マグナム +--Conduction Knight Plasma Magnum +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Fusion Materials: 2 EARTH Rock monsters + Fusion.AddProcMixN(c,true,true,s.matfilter,2) + --All face-up monsters on the field become EARTH + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetCode(EFFECT_CHANGE_ATTRIBUTE) + e1:SetRange(LOCATION_MZONE) + e1:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) + e1:SetValue(ATTRIBUTE_EARTH) + c:RegisterEffect(e1) + --Add 1 "Magnet" Normal, Quick-Play, or Field Spell from your Deck to your hand + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY) + e2:SetCode(EVENT_SPSUMMON_SUCCESS) + e2:SetCountLimit(1,id) + e2:SetCondition(function(e) return e:GetHandler():IsFusionSummoned() end) + e2:SetTarget(s.thtg) + e2:SetOperation(s.thop) + c:RegisterEffect(e2) + --Immediately after this effect resolves, Normal Summon 1 Level 4 or lower "Magnet Warrior" monster + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_SUMMON) + e3:SetType(EFFECT_TYPE_IGNITION) + e3:SetRange(LOCATION_MZONE) + e3:SetCountLimit(1,{id,1}) + e3:SetCost(s.nscost) + e3:SetTarget(s.nstg) + e3:SetOperation(s.nsop) + c:RegisterEffect(e3) +end +s.listed_series={SET_MAGNET,SET_MAGNA_WARRIOR,SET_MAGNET_WARRIOR} +function s.matfilter(c,fc,sumtype,tp) + return c:IsAttribute(ATTRIBUTE_EARTH,fc,sumtype,tp) and c:IsRace(RACE_ROCK,fc,sumtype,tp) +end +function s.thfilter(c) + return c:IsSetCard(SET_MAGNET) and (c:IsNormalSpell() or c:IsQuickPlaySpell() or c:IsFieldSpell()) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end +function s.nscostfilter(c) + return c:IsLevel(8) and c:IsSetCard(SET_MAGNA_WARRIOR) and c:IsAbleToGraveAsCost() +end +function s.nscost(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.nscostfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local g=Duel.SelectMatchingCard(tp,s.nscostfilter,tp,LOCATION_DECK,0,1,1,nil) + Duel.SendtoGrave(g,REASON_COST) +end +function s.nsfilter(c) + return c:IsLevelBelow(4) and c:IsSetCard(SET_MAGNET_WARRIOR) and c:IsSummonable(true,nil) +end +function s.nstg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.nsfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_MZONE) +end +function s.nsop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON) + local sc=Duel.SelectMatchingCard(tp,s.nsfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,1,nil):GetFirst() + if sc then + Duel.Summon(tp,sc,true,nil) + end +end \ No newline at end of file diff --git a/official/c47425162.lua b/official/c47425162.lua new file mode 100644 index 0000000000..9f462eb426 --- /dev/null +++ b/official/c47425162.lua @@ -0,0 +1,91 @@ +--R-ACEクイック・アタッカー +--Rescue-ACE Quick Attacker +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Special Summon this card from your hand + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetRange(LOCATION_HAND) + e1:SetCountLimit(1,id) + e1:SetCost(s.spcost) + e1:SetTarget(s.sptg) + e1:SetOperation(s.spop) + c:RegisterEffect(e1) + --Add 1 "Rescue-ACE" monster from your Deck to your hand, then you can Special Summon it if only your opponent controls a monster + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetCost(Cost.SelfTribute) + e2:SetTarget(s.thtg) + e2:SetOperation(s.thop) + c:RegisterEffect(e2) +end +s.listed_series={SET_RESCUE_ACE} +function s.spcostfilter(c,tp) + return c:IsSetCard(SET_RESCUE_ACE) and c:IsAbleToDeckAsCost() and Duel.GetMZoneCount(tp,c)>0 + and (c:IsFaceup() or c:IsLocation(LOCATION_HAND)) +end +function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.IsExistingMatchingCard(s.spcostfilter,tp,LOCATION_HAND|LOCATION_ONFIELD,0,1,c,tp) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) + local sc=Duel.SelectMatchingCard(tp,s.spcostfilter,tp,LOCATION_HAND|LOCATION_ONFIELD,0,1,1,c,tp):GetFirst() + if sc:IsLocation(LOCATION_HAND) then + Duel.ConfirmCards(1-tp,sc) + else + Duel.HintSelection(sc) + end + Duel.SendtoDeck(sc,nil,SEQ_DECKSHUFFLE,REASON_COST) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) then + Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) + end +end +function s.thfilter(c) + return c:IsSetCard(SET_RESCUE_ACE) and c:IsMonster() and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) + Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local sc=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil):GetFirst() + if sc and Duel.SendtoHand(sc,nil,REASON_EFFECT)>0 and sc:IsLocation(LOCATION_HAND) then + Duel.ConfirmCards(1-tp,sc) + if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and sc:IsCanBeSpecialSummoned(e,0,tp,false,false) + and Duel.GetFieldGroupCount(tp,LOCATION_MZONE,0)==0 + and Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE)>0 + and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.BreakEffect() + Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP) + end + end + local c=e:GetHandler() + --You cannot Special Summon from the Extra Deck for the rest of this turn, except FIRE monsters + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,3)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsAttribute(ATTRIBUTE_FIRE) end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) + --"Clock Lizard" check + aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalAttribute(ATTRIBUTE_FIRE) end) +end \ No newline at end of file diff --git a/official/c47647354.lua b/official/c47647354.lua new file mode 100644 index 0000000000..974cfe741f --- /dev/null +++ b/official/c47647354.lua @@ -0,0 +1,70 @@ +--空牙団の疾風 レクス +--Rex, Gale Fur Hire +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Special Summon 1 "Fur Hire" from your hand, then Special Summon this card + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetRange(LOCATION_HAND) + e1:SetCountLimit(1,id) + e1:SetCost(Cost.SelfReveal) + e1:SetTarget(s.sptg) + e1:SetOperation(s.spop) + c:RegisterEffect(e1) + --Draw 1 card + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_DRAW) + e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY) + e2:SetCode(EVENT_TO_HAND) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,0,EFFECT_COUNT_CODE_CHAIN) + e2:SetCondition(s.drwcon) + e2:SetTarget(s.drwtg) + e2:SetOperation(s.drwop) + c:RegisterEffect(e2) +end +s.listed_names={id} +s.listed_series={SET_FUR_HIRE} +function s.spfilter(c,e,tp) + return c:IsSetCard(SET_FUR_HIRE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and not c:IsCode(id) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>=2 + and Duel.IsPlayerCanSpecialSummonCount(tp,2) + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND,0,1,nil,e,tp) + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,2,tp,LOCATION_HAND) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end + local c=e:GetHandler() + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND,0,1,1,nil,e,tp) + if #g>0 and Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)>0 and c:IsRelateToEffect(e) then + Duel.BreakEffect() + Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) + end +end +function s.drwconfilter(c,opp) + return c:IsPreviousLocation(LOCATION_DECK) and c:IsControler(opp) and c:IsReason(REASON_EFFECT) +end +function s.drwcon(e,tp,eg,ep,ev,re,r,rp) + return re and not re:GetHandler():IsSetCard(SET_FUR_HIRE) and eg:IsExists(s.drwconfilter,1,nil,1-tp) +end +function s.drwtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsSetCard,SET_FUR_HIRE),tp,LOCATION_MZONE,0,1,e:GetHandler()) + and Duel.IsPlayerCanDraw(tp,1) end + Duel.SetTargetPlayer(tp) + Duel.SetTargetParam(1) + Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1) +end +function s.drwop(e,tp,eg,ep,ev,re,r,rp) + local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM) + Duel.Draw(p,d,REASON_EFFECT) +end \ No newline at end of file diff --git a/official/c48469380.lua b/official/c48469380.lua new file mode 100644 index 0000000000..9f241c11e1 --- /dev/null +++ b/official/c48469380.lua @@ -0,0 +1,92 @@ +--デス・エンペラー・デーモン +--Doom Emperor Archfiend +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + Pendulum.AddProcedure(c) + c:AddMustBeRitualSummoned() + --Destroy both this card and 1 other face-up Spell/Trap on the field + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_DESTROY) + e1:SetProperty(EFFECT_FLAG_CARD_TARGET) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetRange(LOCATION_PZONE) + e1:SetCountLimit(1,id) + e1:SetTarget(s.destg) + e1:SetOperation(s.desop) + c:RegisterEffect(e1) + --Unaffected by other monsters' effects while in the Extra Monster Zone + local e2=Effect.CreateEffect(c) + e2:SetType(EFFECT_TYPE_SINGLE) + e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e2:SetCode(EFFECT_IMMUNE_EFFECT) + e2:SetRange(LOCATION_EMZONE) + e2:SetValue(function(e,te) return te:IsMonsterEffect() and te:GetOwner()~=e:GetOwner() end) + c:RegisterEffect(e2) + --Banish all monsters on the field, except those in the Extra Monster Zone + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_REMOVE) + e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e3:SetProperty(EFFECT_FLAG_DELAY) + e3:SetCode(EVENT_SPSUMMON_SUCCESS) + e3:SetCountLimit(1,{id,1}) + e3:SetCondition(function(e) local c=e:GetHandler() return c:IsRitualSummoned() and c:IsSummonLocation(LOCATION_EXTRA) end) + e3:SetTarget(s.rmtg) + e3:SetOperation(s.rmop) + c:RegisterEffect(e3) + --Special Summon 1 Fiend monster from your hand, Deck, GY, or banishment + local e4=Effect.CreateEffect(c) + e4:SetDescription(aux.Stringid(id,2)) + e4:SetCategory(CATEGORY_SPECIAL_SUMMON) + e4:SetType(EFFECT_TYPE_IGNITION) + e4:SetRange(LOCATION_EMZONE) + e4:SetCountLimit(1,{id,2}) + e4:SetTarget(s.sptg) + e4:SetOperation(s.spop) + c:RegisterEffect(e4) +end +s.listed_names={63679166} --"Throne of Archfiends" +function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + local c=e:GetHandler() + if chkc then return c:IsOnField() and c:IsSpellTrap() and c:IsFaceup() and chkc~=c end + if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(Card.IsSpellTrap),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,c) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local g=Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsSpellTrap),tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,c) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,g+c,2,tp,0) +end +function s.desop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local tc=Duel.GetFirstTarget() + if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) then + Duel.Destroy(Group.FromCards(c,tc),REASON_EFFECT) + end +end +function s.rmtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,LOCATION_MMZONE,LOCATION_MMZONE,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,PLAYER_ALL,LOCATION_MMZONE) +end +function s.rmop(e,tp,eg,ep,ev,re,r,rp) + local g=Duel.GetFieldGroup(tp,LOCATION_MMZONE,LOCATION_MMZONE) + if #g>0 then + Duel.Remove(g,POS_FACEUP,REASON_EFFECT) + end +end +function s.spfilter(c,e,tp) + return c:IsRace(RACE_FIEND) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE|LOCATION_REMOVED,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE|LOCATION_REMOVED) +end +function s.spop(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,s.spfilter,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE|LOCATION_REMOVED,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c4891376.lua b/official/c4891376.lua new file mode 100644 index 0000000000..a19d2d3b10 --- /dev/null +++ b/official/c4891376.lua @@ -0,0 +1,69 @@ +--鎖縛竜ザレン +--Zaren the Chainbound Dragon +--Scripted by Hatter +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Synchro Summon procedure: 1 Tuner + 1+ Synchro Monsters + Synchro.AddProcedure(c,nil,1,1,aux.FilterBoolFunctionEx(Card.IsType,TYPE_SYNCHRO),1,99) + --Multiple Tuner check (Red Nova) + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_SINGLE) + e0:SetCode(EFFECT_MATERIAL_CHECK) + e0:SetValue(s.valcheck) + c:RegisterEffect(e0) + --If this card you control would be used as Synchro Material, you can treat it as a non-Tuner + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e1:SetCode(EFFECT_NONTUNER) + e1:SetRange(LOCATION_MZONE) + c:RegisterEffect(e1) + --Activate 1 of these effects + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_DISABLE+CATEGORY_DESTROY) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetCode(EVENT_CHAINING) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,id) + e2:SetCondition(function() return Duel.GetCurrentChain()>1 end) + e2:SetTarget(s.distg) + e2:SetOperation(s.disop) + c:RegisterEffect(e2) +end +function s.valcheck(e,c) + local g=c:GetMaterial() + if g:IsExists(Card.IsType,2,nil,TYPE_TUNER) then + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) + e1:SetCode(EFFECT_MULTIPLE_TUNERS) + e1:SetReset(RESET_EVENT|RESETS_STANDARD&~(RESET_TOFIELD)|RESET_PHASE|PHASE_END) + c:RegisterEffect(e1) + end +end +function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) + local b1=Duel.IsChainDisablable(ev) + local b2=Duel.IsChainDisablable(ev-1) + if chk==0 then return b1 or b2 end + local op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,1)}, + {b2,aux.Stringid(id,2)}) + local ch=ev-op+1 + e:SetLabel(ch) + local eff=Duel.GetChainInfo(ch,CHAININFO_TRIGGERING_EFFECT) + local rc=eff:GetHandler() + Duel.SetOperationInfo(0,CATEGORY_DISABLE,rc,1,tp,0) + if rc:IsDestructable() and rc:IsRelateToEffect(eff) then + Duel.SetOperationInfo(0,CATEGORY_DESTROY,rc,1,tp,0) + end +end +function s.disop(e,tp,eg,ep,ev,re,r,rp) + local ch=e:GetLabel() + local eff=Duel.GetChainInfo(ch,CHAININFO_TRIGGERING_EFFECT) + local rc=eff:GetHandler() + if Duel.NegateEffect(ch) and rc:IsRelateToEffect(eff) then + Duel.Destroy(rc,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c4909946.lua b/official/c4909946.lua new file mode 100644 index 0000000000..d0b8be7d1b --- /dev/null +++ b/official/c4909946.lua @@ -0,0 +1,100 @@ +--ボスオンパレード +--Boss on Parade +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --When this card is activated: Add 1 "B.E.S." monster from your Deck to your hand + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) + e1:SetTarget(s.target) + e1:SetOperation(s.activate) + c:RegisterEffect(e1) + --Destroy 1 monster in your hand or field, and if you do, Special Summon 1 LIGHT Machine monster with 1200 ATK and 1000 or less DEF from your Deck to either field + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_DESTROY+CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_SZONE) + e2:SetCountLimit(1) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + c:RegisterEffect(e2) + --Place 1 "Boss Rush" from your Deck or GY face-up on your field + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,2)) + e3:SetType(EFFECT_TYPE_IGNITION) + e3:SetRange(LOCATION_GRAVE) + e3:SetCost(Cost.SelfBanish) + e3:SetTarget(s.pltg) + e3:SetOperation(s.plop) + c:RegisterEffect(e3) +end +s.listed_names={66947414} --"Boss Rush" +s.listed_series={SET_BES} +function s.thfilter(c) + return c:IsSetCard(SET_BES) and c:IsMonster() and c:IsAbleToHand() +end +function s.target(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.activate(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end +function s.desfilter(c,e,tp) + return c:IsMonster() and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp,Duel.GetMZoneCount(tp,c)>0,Duel.GetLocationCount(1-tp,LOCATION_MZONE)>0) +end +function s.spfilter(c,e,tp,mmz_chk,opp_mmz_chk) + return c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsRace(RACE_MACHINE) and c:IsAttack(1200) and c:IsDefenseBelow(1000) + and ((mmz_chk and c:IsCanBeSpecialSummoned(e,0,tp,false,false)) + or (opp_mmz_chk and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,1-tp))) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.desfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,nil,e,tp) end + local g=Duel.GetMatchingGroup(s.desfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,nil,e,tp) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local dg=Duel.SelectMatchingCard(tp,s.desfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,1,nil,e,tp) + if #dg>0 and Duel.Destroy(dg,REASON_EFFECT)>0 then + local mmz_chk=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + local opp_mmz_chk=Duel.GetLocationCount(1-tp,LOCATION_MZONE)>0 + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local sc=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,mmz_chk,opp_mmz_chk):GetFirst() + if not sc then return end + local b1=mmz_chk and sc:IsCanBeSpecialSummoned(e,0,tp,false,false) + local b2=opp_mmz_chk and sc:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP,1-tp) + if not (b1 or b2) then return end + local op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,3)}, + {b2,aux.Stringid(id,4)}) + local to_player=op==1 and tp or 1-tp + Duel.SpecialSummon(sc,0,tp,to_player,false,false,POS_FACEUP) + end +end +function s.plfilter(c,tp) + return c:IsCode(66947414) and not c:IsForbidden() and c:CheckUniqueOnField(tp) +end +function s.pltg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 + and Duel.IsExistingMatchingCard(s.plfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil,tp) end +end +function s.plop(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) + local sc=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.plfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil,tp):GetFirst() + if sc then + Duel.MoveToField(sc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) + end +end \ No newline at end of file diff --git a/official/c49181828.lua b/official/c49181828.lua new file mode 100644 index 0000000000..fe3adb0766 --- /dev/null +++ b/official/c49181828.lua @@ -0,0 +1,77 @@ +--スレット・アームド・ドラゴン +--Threat Armed Dragon +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Destroy 1 Dragon monster you control, and if you do, Special Summon this card + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_DESTROY+CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetProperty(EFFECT_FLAG_CARD_TARGET) + e1:SetRange(LOCATION_GRAVE) + e1:SetCountLimit(1,id) + e1:SetTarget(s.sptg) + e1:SetOperation(s.spop) + c:RegisterEffect(e1) + --Destroy 1 monster on the field with 2400 or less ATK, then if you destroyed a monster you control, you can Special Summon 1 Dragon monster from your hand or Deck whose original Level is 2 higher than the destroyed monster + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_DESTROY+CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetCost(Cost.Discard()) + e2:SetTarget(s.destg) + e2:SetOperation(s.desop) + c:RegisterEffect(e2) +end +function s.sptgdesfilter(c,tp) + return c:IsRace(RACE_DRAGON) and c:IsFaceup() and Duel.GetMZoneCount(tp,c)>0 +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and s.sptgdesfilter(chkc,tp) end + local c=e:GetHandler() + if chk==0 then return Duel.IsExistingTarget(s.sptgdesfilter,tp,LOCATION_MZONE,0,1,nil,tp) + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local g=Duel.SelectTarget(tp,s.sptgdesfilter,tp,LOCATION_MZONE,0,1,1,nil,tp) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and tc:IsMonster() and Duel.Destroy(tc,REASON_EFFECT)>0 + and c:IsRelateToEffect(e) then + Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) + end +end +function s.spfilter(c,e,tp,lv) + return c:IsRace(RACE_DRAGON) and c:IsOriginalLevel(lv) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsAttackBelow(2400) and chkc:IsFaceup() end + if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(Card.IsAttackBelow,2400),tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local g=Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsAttackBelow,2400),tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) + Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_DECK) +end +function s.desop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and tc:IsMonster() and Duel.Destroy(tc,REASON_EFFECT)>0 and tc:IsPreviousControler(tp) and tc:HasLevel() + and Duel.GetMZoneCount(tp)>0 then + local lv=tc:GetOriginalLevel()+2 + if Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,e,tp,lv) + and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,1,nil,e,tp,lv) + if #g>0 then + Duel.BreakEffect() + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end + end + end +end \ No newline at end of file diff --git a/official/c49652661.lua b/official/c49652661.lua new file mode 100644 index 0000000000..f82668016a --- /dev/null +++ b/official/c49652661.lua @@ -0,0 +1,89 @@ +--武器庫整理 +--Arsenal Organization +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Send up to 2 Equip Spells with different names from your Deck to the GY + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOGRAVE) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id) + e1:SetTarget(s.tgtg) + e1:SetOperation(s.tgop) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) + --Equip 1 face-up monster you control with up to 2 Equip Spells with different names from your hand and/or GY that can equip to it, but any battle damage it inflicts to your opponent is halved while equipped with any of those Equip Spells + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_EQUIP) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,id) + e2:SetCost(Cost.SelfBanish) + e2:SetTarget(s.eqtg) + e2:SetOperation(s.eqop) + e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e2) +end +function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(aux.AND(Card.IsEquipSpell,Card.IsAbleToGrave),tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) +end +function s.tgop(e,tp,eg,ep,ev,re,r,rp) + local g=Duel.GetMatchingGroup(aux.AND(Card.IsEquipSpell,Card.IsAbleToGrave),tp,LOCATION_DECK,0,nil) + if #g==0 then return end + local sg=aux.SelectUnselectGroup(g,e,tp,1,2,aux.dncheck,1,tp,HINTMSG_TOGRAVE) + if #sg>0 then + Duel.SendtoGrave(sg,REASON_EFFECT) + end +end +function s.eqtargetfilter(c,tp) + return c:IsFaceup() and Duel.IsExistingMatchingCard(s.eqspellfilter,tp,LOCATION_HAND|LOCATION_GRAVE,0,1,nil,c) +end +function s.eqspellfilter(c,tc) + return c:IsEquipSpell() and c:CheckEquipTarget(tc) +end +function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and s.eqtargetfilter(chkc,tp) end + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 + and Duel.IsExistingTarget(s.eqtargetfilter,tp,LOCATION_MZONE,0,1,nil,tp) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) + Duel.SelectTarget(tp,s.eqtargetfilter,tp,LOCATION_MZONE,0,1,1,nil,tp) +end +function s.eqop(e,tp,eg,ep,ev,re,r,rp) + local ft=Duel.GetLocationCount(tp,LOCATION_SZONE) + if ft<=0 then return end + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and tc:IsFaceup() then + local g=Duel.GetMatchingGroup(aux.NecroValleyFilter(s.eqspellfilter),tp,LOCATION_HAND|LOCATION_GRAVE,0,nil,tc) + if #g==0 then return end + ft=math.min(2,ft) + local sg=aux.SelectUnselectGroup(g,e,tp,1,ft,aux.dncheck,1,tp,HINTMSG_EQUIP) + if #sg==0 then return end + local fid=e:GetFieldID() + local equip_success=false + for ec in sg:Iter() do + if Duel.Equip(tp,ec,tc,true,true) then + equip_success=true + ec:RegisterFlagEffect(id,RESET_EVENT|RESETS_STANDARD,EFFECT_FLAG_CLIENT_HINT,1,fid,aux.Stringid(id,2)) + end + end + Duel.EquipComplete() + if equip_success then + --Any battle damage it inflicts to your opponent is halved while equipped with any of those Equip Spells + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetDescription(aux.Stringid(id,3)) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CHANGE_BATTLE_DAMAGE) + e1:SetCondition(function(e) return e:GetHandler():GetEquipGroup():IsExists(function(ec) return ec:GetFlagEffectLabel(id)==fid end,1,nil) end) + e1:SetValue(aux.ChangeBattleDamage(1,HALF_DAMAGE)) + e1:SetReset(RESET_EVENT|RESETS_STANDARD) + tc:RegisterEffect(e1) + end + end +end \ No newline at end of file diff --git a/official/c50590801.lua b/official/c50590801.lua new file mode 100644 index 0000000000..a6e736d1e6 --- /dev/null +++ b/official/c50590801.lua @@ -0,0 +1,70 @@ +--エルフェンノーツ~託選のアリスティア~ +--Elvennotes ~Oracle Alicetea~ +--Scripted by Hatter +local s,id=GetID() +function s.initial_effect(c) + --Activate + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_ACTIVATE) + e0:SetCode(EVENT_FREE_CHAIN) + c:RegisterEffect(e0) + --Move 1 face-up monster you control to another of your Main Monster Zones + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_QUICK_O) + e1:SetProperty(EFFECT_FLAG_CARD_TARGET) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetRange(LOCATION_SZONE) + e1:SetCountLimit(1) + e1:SetCost(Cost.AND(Cost.HardOncePerChain(id),Cost.HintSelectedEffect)) + e1:SetTarget(s.mvtg) + e1:SetOperation(s.mvop) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) + --Negate the effect of an opponent's Spell/Trap card activation + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_DISABLE+CATEGORY_DESTROY) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetCode(EVENT_CHAINING) + e2:SetRange(LOCATION_SZONE) + e2:SetCountLimit(1,id) + e2:SetCondition(s.discon) + e2:SetCost(Cost.AND(Cost.HardOncePerChain(id),Cost.HintSelectedEffect)) + e2:SetTarget(s.distg) + e2:SetOperation(s.disop) + c:RegisterEffect(e2) +end +s.listed_series={SET_ELVENNOTES} +function s.mvtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsFaceup() end + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_MZONE,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) + Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_MZONE,0,1,1,nil) +end +function s.mvop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and tc:IsControler(tp) and not tc:IsImmuneToEffect(e) + and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOZONE) + local seq=math.log(Duel.SelectDisableField(tp,1,LOCATION_MZONE,0,0),2) + Duel.MoveSequence(tc,seq) + end +end +function s.discon(e,tp,eg,ep,ev,re,r,rp) + return rp==1-tp and re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsSpellTrapEffect() and Duel.IsChainDisablable(ev) + and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsSetCard,SET_ELVENNOTES),tp,LOCATION_MZONE,0,3,nil) +end +function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return true end + Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,tp,0) + Duel.SetPossibleOperationInfo(0,CATEGORY_DESTROY,eg,1,tp,0) +end +function s.disop(e,tp,eg,ep,ev,re,r,rp) + if Duel.NegateEffect(ev) and re:GetHandler():IsRelateToEffect(re) + and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsSynchroMonster),tp,LOCATION_MZONE,0,1,nil) + and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.BreakEffect() + Duel.Destroy(eg,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c50604072.lua b/official/c50604072.lua new file mode 100644 index 0000000000..8a8df47e98 --- /dev/null +++ b/official/c50604072.lua @@ -0,0 +1,81 @@ +--クリムゾン・ブレーダー/バスタ +--Crimson Blader/Assault Mode +--scripted by Naim +local s,id=GetID() +local CARD_CRIMSON_BLADER=80321197 +function s.initial_effect(c) + c:EnableReviveLimit() + c:AddMustBeSpecialSummoned() + --Add 1 "Assault Mode Activate" or 1 card that mentions it from your Deck to your hand, and if you do, shuffle this card into the Deck + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_TODECK) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetRange(LOCATION_HAND) + e1:SetCountLimit(1,id) + e1:SetCost(Cost.SelfReveal) + e1:SetTarget(s.thtg) + e1:SetOperation(s.thop) + c:RegisterEffect(e1) + --Your opponent cannot activate the effects of Level 5 or higher monsters Special Summoned from the Extra Deck + local e2=Effect.CreateEffect(c) + e2:SetType(EFFECT_TYPE_FIELD) + e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET) + e2:SetCode(EFFECT_CANNOT_ACTIVATE) + e2:SetRange(LOCATION_MZONE) + e2:SetTargetRange(0,1) + e2:SetValue(s.cannotactval) + c:RegisterEffect(e2) + --Special Summon 1 "Crimson Blader" from your GY + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_SPECIAL_SUMMON) + e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e3:SetProperty(EFFECT_FLAG_DELAY) + e3:SetCode(EVENT_DESTROYED) + e3:SetTarget(s.sptg) + e3:SetOperation(s.spop) + c:RegisterEffect(e3) +end +s.listed_names={CARD_ASSAULT_MODE,CARD_CRIMSON_BLADER} +s.assault_mode=CARD_CRIMSON_BLADER +function s.thfilter(c) + return (c:IsCode(CARD_ASSAULT_MODE) or c:ListsCode(CARD_ASSAULT_MODE)) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return c:IsAbleToDeck() and Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) + Duel.SetOperationInfo(0,CATEGORY_TODECK,c,1,tp,0) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 and Duel.SendtoHand(g,nil,REASON_EFFECT)>0 then + Duel.ConfirmCards(1-tp,g) + if c:IsRelateToEffect(e) then + Duel.SendtoDeck(c,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) + end + end +end +function s.cannotactval(e,re,tp) + local rc=re:GetHandler() + return re:IsMonsterEffect() and rc:IsOnField() and rc:IsLevelAbove(5) and rc:IsSummonLocation(LOCATION_EXTRA) +end +function s.spfilter(c,e,tp) + return c:IsCode(CARD_CRIMSON_BLADER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) +end +function s.spop(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,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c5121528.lua b/official/c5121528.lua new file mode 100644 index 0000000000..1f12571eb8 --- /dev/null +++ b/official/c5121528.lua @@ -0,0 +1,93 @@ +--巨大戦艦 デリンジャー・コア +--B.E.S. Dellinger Core +--scripted by Naim +local s,id=GetID() +local COUNTER_BES=0x1f +function s.initial_effect(c) + c:EnableCounterPermit(COUNTER_BES) + --Special Summon this card from your hand, then place 3 counters on it + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_COUNTER) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetRange(LOCATION_HAND) + e1:SetCountLimit(1,id) + e1:SetCost(Cost.Reveal(function(c) return c:IsSetCard(SET_BES) and c:IsMonster() end,true)) + e1:SetTarget(s.sptg) + e1:SetOperation(s.spop) + c:RegisterEffect(e1) + --Activate 1 of these effects + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(function(e) return Duel.IsMainPhase() end) + e2:SetCost(Cost.RemoveCounterFromSelf(COUNTER_BES,1)) + e2:SetTarget(s.efftg) + e2:SetOperation(s.effop) + e2:SetHintTiming(0,TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) + c:RegisterEffect(e2) +end +s.listed_names={66947414} --"Boss Rush" +s.listed_series={SET_BES} +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) + and c:IsCanAddCounter(COUNTER_BES,3,false,LOCATION_MZONE) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) + Duel.SetOperationInfo(0,CATEGORY_COUNTER,nil,3,tp,COUNTER_BES) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 + and c:IsCanAddCounter(COUNTER_BES,3) then + Duel.BreakEffect() + c:AddCounter(COUNTER_BES,3) + end +end +function s.thfilter(c) + return (c:IsCode(66947414) or (c:IsSpellTrap() and c:ListsCode(66947414))) and c:IsAbleToHand() +end +function s.spfilter(c,e,tp) + return c:IsLevelBelow(9) and c:IsSetCard(SET_BES) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) + local b1=Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) + local b2=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) + if chk==0 then return b1 or b2 end + local op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,2)}, + {b2,aux.Stringid(id,3)}) + e:SetLabel(op) + if op==1 then + e:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND) + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) + elseif op==2 then + e:SetCategory(CATEGORY_SPECIAL_SUMMON) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) + end +end +function s.effop(e,tp,eg,ep,ev,re,r,rp) + local op=e:GetLabel() + if op==1 then + --Add 1 "Boss Rush" or 1 Spell/Trap that mentions it from your Deck to your hand + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end + elseif op==2 then + --Special Summon 1 Level 9 or lower "B.E.S." monster from your GY + if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end + end +end \ No newline at end of file diff --git a/official/c51548207.lua b/official/c51548207.lua new file mode 100644 index 0000000000..87b116a6ad --- /dev/null +++ b/official/c51548207.lua @@ -0,0 +1,74 @@ +--ホロウヴァレット・ドラゴン +--Hollowrokket Dragon +--Scripted by ahtelel +local s,id=GetID() +function s.initial_effect(c) + --Destroy this card, then excavate up to 6 cards from the top of your opponent's Deck, and if you do, banish 1 excavated card, also place the rest on top of the Deck in the same order + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_DESTROY+CATEGORY_REMOVE) + e1:SetType(EFFECT_TYPE_QUICK_O) + e1:SetCode(EVENT_CHAINING) + e1:SetRange(LOCATION_MZONE) + e1:SetCountLimit(1,id) + e1:SetCondition(s.rmcon) + e1:SetTarget(s.rmtg) + e1:SetOperation(s.rmop) + c:RegisterEffect(e1) + --Special Summon 1 "Rokket" monster from your Deck, except "Hollowrokket Dragon" + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e2:SetCode(EVENT_PHASE+PHASE_END) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(function(e) local c=e:GetHandler() return c:GetTurnID()==Duel.GetTurnCount() and c:IsReason(REASON_DESTROY) and c:IsReason(REASON_BATTLE|REASON_EFFECT) and c:IsPreviousLocation(LOCATION_ONFIELD) end) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + c:RegisterEffect(e2) +end +s.listed_names={id} +s.listed_series={SET_ROKKET} +function s.rmcon(e,tp,eg,ep,ev,re,r,rp) + if not (re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) and re:IsActiveType(TYPE_LINK)) then return false end + local tg=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS) + return tg and tg:IsContains(e:GetHandler()) +end +function s.rmtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetFieldGroupCount(tp,0,LOCATION_DECK)>5 and Duel.IsPlayerCanRemove(tp) end + Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,1-tp,LOCATION_DECK) +end +function s.rmop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) and Duel.Destroy(c,REASON_EFFECT)>0 then + local ct=math.min(6,Duel.GetFieldGroupCount(tp,0,LOCATION_DECK)) + if ct==0 then return end + local ac=ct==1 and ct or Duel.AnnounceNumberRange(tp,1,ct) + Duel.BreakEffect() + Duel.ConfirmDecktop(1-tp,ac) + local g=Duel.GetDecktopGroup(1-tp,ac) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) + local sg=g:FilterSelect(tp,Card.IsAbleToRemove,1,1,nil) + if #sg>0 then + Duel.DisableShuffleCheck(true) + Duel.Remove(sg,POS_FACEUP,REASON_EFFECT) + end + end +end +function s.spfilter(c,e,tp) + return c:IsSetCard(SET_ROKKET) and not c:IsCode(id) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) +end +function s.spop(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,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c51612489.lua b/official/c51612489.lua new file mode 100644 index 0000000000..4dab1ae512 --- /dev/null +++ b/official/c51612489.lua @@ -0,0 +1,73 @@ +--騒動 +--Riot +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Return 1 face-down Defense Position monster on the field to the hand, then the player who added it to their hand can Special Summon 1 monster from their hand in face-down Defense Position + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetProperty(EFFECT_FLAG_CARD_TARGET) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id) + e1:SetTarget(s.rthtg) + e1:SetOperation(s.rthop) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMING_BATTLE_START|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) + --Change 1 face-down Defense Position monster on the field to Attack Position + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_POSITION) + e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e2:SetCode(EVENT_ATTACK_ANNOUNCE) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(function(e,tp) return Duel.GetAttacker():IsControler(1-tp) end) + e2:SetCost(Cost.SelfBanish) + e2:SetTarget(s.postg) + e2:SetOperation(s.posop) + c:RegisterEffect(e2) +end +function s.rthfilter(c) + return c:IsPosition(POS_FACEDOWN_DEFENSE) and c:IsAbleToHand() +end +function s.rthtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingTarget(s.rthfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) + local tc=Duel.SelectTarget(tp,s.rthfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil):GetFirst() + Duel.SetOperationInfo(0,CATEGORY_TOHAND,tc,1,tp,0) + Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tc:GetOwner(),LOCATION_HAND) +end +function s.rthop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and Duel.SendtoHand(tc,nil,REASON_EFFECT)>0 and tc:IsLocation(LOCATION_HAND) then + local sp_player=tc:GetControler() + Duel.ShuffleHand(sp_player) + if Duel.GetLocationCount(sp_player,LOCATION_MZONE,sp_player)>0 + and Duel.IsExistingMatchingCard(Card.IsCanBeSpecialSummoned,sp_player,LOCATION_HAND,0,1,nil,e,0,sp_player,false,false,POS_FACEDOWN_DEFENSE) + and Duel.SelectYesNo(sp_player,aux.Stringid(id,2)) then + Duel.Hint(HINT_SELECTMSG,sp_player,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(sp_player,Card.IsCanBeSpecialSummoned,sp_player,LOCATION_HAND,0,1,1,nil,e,0,sp_player,false,false,POS_FACEDOWN_DEFENSE) + if #g>0 then + Duel.BreakEffect() + Duel.SpecialSummon(g,0,sp_player,sp_player,false,false,POS_FACEDOWN_DEFENSE) + end + end + end +end +function s.posfilter(c) + return c:IsPosition(POS_FACEDOWN_DEFENSE) and c:IsCanChangePosition() +end +function s.postg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.posfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_POSITION,nil,1,PLAYER_EITHER,LOCATION_MZONE) +end +function s.posop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_POSCHANGE) + local g=Duel.SelectMatchingCard(tp,s.posfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil) + if #g>0 then + Duel.HintSelection(g) + Duel.ChangePosition(g,POS_FACEUP_ATTACK) + end +end \ No newline at end of file diff --git a/official/c51826619.lua b/official/c51826619.lua new file mode 100644 index 0000000000..277d0fa805 --- /dev/null +++ b/official/c51826619.lua @@ -0,0 +1,67 @@ +--磁石の戦士Σ+ +--Magnet Warrior Σ+ +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --While you control an EARTH monster, your opponent's monsters that can attack must attack EARTH monsters + local e1a=Effect.CreateEffect(c) + e1a:SetType(EFFECT_TYPE_FIELD) + e1a:SetCode(EFFECT_MUST_ATTACK) + e1a:SetRange(LOCATION_MZONE) + e1a:SetTargetRange(0,LOCATION_MZONE) + e1a:SetCondition(function(e) return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_EARTH),e:GetHandlerPlayer(),LOCATION_MZONE,0,1,nil) end) + c:RegisterEffect(e1a) + local e1b=e1a:Clone() + e1b:SetCode(EFFECT_MUST_ATTACK_MONSTER) + e1b:SetValue(function(e,c) return c:IsAttribute(ATTRIBUTE_EARTH) end) + c:RegisterEffect(e1b) + --While your opponent controls an EARTH monster, you choose the attack targets for your opponent's attacks + local e2=Effect.CreateEffect(c) + e2:SetType(EFFECT_TYPE_FIELD) + e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET) + e2:SetCode(EFFECT_PATRICIAN_OF_DARKNESS) + e2:SetRange(LOCATION_MZONE) + e2:SetTargetRange(0,1) + e2:SetCondition(function(e) return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_EARTH),e:GetHandlerPlayer(),0,LOCATION_MZONE,1,nil) end) + c:RegisterEffect(e2) + --Add to your hand, or Special Summon, 1 Level 4 or lower "Magnet Warrior" monster in your GY, except "Magnet Warrior Σ+" + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,0)) + e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SPECIAL_SUMMON) + e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e3:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) + e3:SetCode(EVENT_TO_GRAVE) + e3:SetCountLimit(1,id) + e3:SetTarget(s.thsptg) + e3:SetOperation(s.thspop) + c:RegisterEffect(e3) +end +s.listed_series={SET_MAGNET_WARRIOR} +s.listed_names={id} +function s.thspfilter(c,e,tp,mmz_chk) + return c:IsLevelBelow(4) and c:IsSetCard(SET_MAGNET_WARRIOR) and not c:IsCode(id) + and (c:IsAbleToHand() or (mmz_chk and c:IsCanBeSpecialSummoned(e,0,tp,false,false))) +end +function s.thsptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + local mmz_chk=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and s.thspfilter(chkc,e,tp,mmz_chk) end + if chk==0 then return Duel.IsExistingTarget(s.thspfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp,mmz_chk) end + Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(id,1)) + local g=Duel.SelectTarget(tp,s.thspfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp,mmz_chk) + Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,g,1,tp,0) + Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,0) +end +function s.thspop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) then + aux.ToHandOrElse(tc,tp, + function() + return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and tc:IsCanBeSpecialSummoned(e,0,tp,false,false) + end, + function() + Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) + end, + aux.Stringid(id,2) + ) + end +end \ No newline at end of file diff --git a/official/c52335937.lua b/official/c52335937.lua new file mode 100644 index 0000000000..29cf782c1f --- /dev/null +++ b/official/c52335937.lua @@ -0,0 +1,129 @@ +--エクソシスター・バト・マーテル +--Exosister Bat Mater +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --When this card is activated: Add 2 "Exosister" monsters from your Deck to your hand, then discard 1 card + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_HANDES) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id) + e1:SetTarget(s.target) + e1:SetOperation(s.activate) + c:RegisterEffect(e1) + --Immediately after this effect resolves, Normal Summon 1 "Exosister" monster that is mentioned on that monster + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_SZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.nstg) + e2:SetOperation(s.nsop) + c:RegisterEffect(e2) + --Make your opponent banish 1 of them + local e3a=Effect.CreateEffect(c) + e3a:SetDescription(aux.Stringid(id,2)) + e3a:SetCategory(CATEGORY_REMOVE) + e3a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e3a:SetProperty(EFFECT_FLAG_DELAY) + e3a:SetCode(EVENT_CUSTOM+id) + e3a:SetRange(LOCATION_SZONE) + e3a:SetCountLimit(1,{id,2}) + e3a:SetTarget(s.rmtg) + e3a:SetOperation(s.rmop) + c:RegisterEffect(e3a) + local g=Group.CreateGroup() + e3a:SetLabelObject(g) + --Keep track of monsters sent to your opponent's GY + local e3b=Effect.CreateEffect(c) + e3b:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) + e3b:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e3b:SetCode(EVENT_TO_GRAVE) + e3b:SetRange(LOCATION_SZONE) + e3b:SetLabelObject(e3a) + e3b:SetOperation(s.regop) + c:RegisterEffect(e3b) +end +s.listed_series={SET_EXOSISTER} +function s.thfilter(c) + return c:IsSetCard(SET_EXOSISTER) and c:IsMonster() and c:IsAbleToHand() +end +function s.target(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,2,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,2,tp,LOCATION_DECK) + Duel.SetOperationInfo(0,CATEGORY_HANDES,nil,1,tp,1) +end +function s.activate(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,2,2,nil) + if #g==2 and Duel.SendtoHand(g,nil,REASON_EFFECT)>0 then + Duel.ConfirmCards(1-tp,g) + Duel.ShuffleHand(tp) + Duel.BreakEffect() + Duel.DiscardHand(tp,nil,1,1,REASON_EFFECT|REASON_DISCARD,nil) + end +end +function s.tgfilter(c,tp) + return c:IsFaceup() and Duel.IsExistingMatchingCard(s.nsfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,nil,c) +end +function s.nsfilter(c,tc) + return c:IsSetCard(SET_EXOSISTER) and c:IsSummonable(true,nil) and tc:ListsCode(c:GetCode()) +end +function s.nstg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and s.tgfilter(chkc,tp) end + if chk==0 then return Duel.IsExistingTarget(s.tgfilter,tp,LOCATION_MZONE,0,1,nil,tp) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) + local g=Duel.SelectTarget(tp,s.tgfilter,tp,LOCATION_MZONE,0,1,1,nil,tp) + Duel.SetOperationInfo(0,CATEGORY_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_MZONE) +end +function s.nsop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and tc:IsFaceup() then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON) + local sc=Duel.SelectMatchingCard(tp,s.nsfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,1,nil,tc):GetFirst() + if sc then + Duel.Summon(tp,sc,true,nil) + end + end +end +function s.regfilter(c,opp) + return c:IsMonster() and c:IsControler(opp) +end +function s.regop(e,tp,eg,ep,ev,re,r,rp) + local tg=eg:Filter(s.regfilter,nil,1-tp) + if #tg>0 then + for tc in tg:Iter() do + tc:RegisterFlagEffect(id,RESET_CHAIN,0,1) + end + local g=e:GetLabelObject():GetLabelObject() + if Duel.GetCurrentChain()==0 then g:Clear() end + g:Merge(tg) + g:Remove(function(c) return c:GetFlagEffect(id)==0 end,nil) + e:GetLabelObject():SetLabelObject(g) + Duel.RaiseSingleEvent(e:GetHandler(),EVENT_CUSTOM+id,e,0,tp,tp,0) + end +end +function s.rmfilter(c,opp) + return c:IsControler(opp) and c:IsLocation(LOCATION_GRAVE) and c:IsAbleToRemove(opp) +end +function s.rmtg(e,tp,eg,ep,ev,re,r,rp,chk) + local g=e:GetLabelObject():Filter(s.rmfilter,nil,1-tp) + if chk==0 then return #g>0 end + Duel.SetTargetCard(g) + Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,1,1-tp,0) +end +function s.rmop(e,tp,eg,ep,ev,re,r,rp) + local g=Duel.GetTargetCards(e) + if #g==0 then return end + local opp=1-tp + Duel.Hint(HINT_SELECTMSG,opp,HINTMSG_REMOVE) + g=g:FilterSelect(opp,Card.IsAbleToRemove,1,1,nil,opp) + if #g>0 then + Duel.HintSelection(g) + Duel.Remove(g,POS_FACEUP,REASON_EFFECT,PLAYER_NONE,opp) + end +end \ No newline at end of file diff --git a/official/c53557529.lua b/official/c53557529.lua new file mode 100644 index 0000000000..aed4771688 --- /dev/null +++ b/official/c53557529.lua @@ -0,0 +1,75 @@ +--飆風の空牙団 +--Storm Fur Hire +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Special Summon 1 Level 4 or lower monster "Fur Hire" from your Deck, then if your opponent controls 2 or more monsters, you can Special Summon 1 monster “Fur Hire” from your Deck, also you cannot Special Summon for the rest of this turn, except monsters "Fur Hire" + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id) + e1:SetCondition(function(e,tp) return Duel.GetFieldGroupCount(tp,LOCATION_MZONE,0)==0 end) + e1:SetTarget(s.target) + e1:SetOperation(s.activate) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) + --If you would discard a card(s) to activate the effect of a monster "Fur Hire", you can banish this card from your GY instead of 1 of those cards + local e2=Effect.CreateEffect(c) + e2:SetType(EFFECT_TYPE_FIELD) + e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET) + e2:SetCode(EFFECT_FUR_HIRE_REPLACE) + e2:SetRange(LOCATION_GRAVE) + e2:SetTargetRange(1,0) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(function(e) return e:GetHandler():IsAbleToRemoveAsCost() end) + e2:SetValue(s.repval) + e2:SetOperation(function(base,e,tp,eg,ep,ev,re,r,rp) Duel.Hint(HINT_CARD,0,id) Duel.Remove(base:GetHandler(),POS_FACEUP,REASON_COST) end) + c:RegisterEffect(e2) +end +s.listed_series={SET_FUR_HIRE} +function s.spfilter(c,e,tp) + return c:IsSetCard(SET_FUR_HIRE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.lv4spfilter(c,e,tp) + return c:IsLevelBelow(4) and s.spfilter(c,e,tp) +end +function s.target(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.lv4spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) +end +function s.activate(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g1=Duel.SelectMatchingCard(tp,s.lv4spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) + if #g1>0 and Duel.SpecialSummon(g1,0,tp,tp,false,false,POS_FACEUP)>0 + and Duel.IsPlayerCanSpecialSummonCount(tp,2) + and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE)>=2 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp) + and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g2=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) + if #g2>0 then + Duel.BreakEffect() + Duel.SpecialSummon(g2,0,tp,tp,false,false,POS_FACEUP) + end + end + end + --You cannot Special Summon for the rest of this turn, except monsters "Fur Hire" + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return not c:IsSetCard(SET_FUR_HIRE) end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) +end +function s.repval(base,e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + return c:IsSetCard(SET_FUR_HIRE) and c:IsFaceup() and c:IsControler(tp) and c:IsLocation(LOCATION_MZONE) +end \ No newline at end of file diff --git a/official/c58769832.lua b/official/c58769832.lua new file mode 100644 index 0000000000..77d40924a6 --- /dev/null +++ b/official/c58769832.lua @@ -0,0 +1,85 @@ +--ロワイヤル・デーモン +--Royal Archfiend +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Add 1 "Archfiend" card from your Deck to your hand + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetRange(LOCATION_HAND|LOCATION_MZONE) + e1:SetCountLimit(1,id) + e1:SetCost(Cost.SelfTribute) + e1:SetTarget(s.thtg) + e1:SetOperation(s.thop) + c:RegisterEffect(e1) + --Special Summon this card + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e2:SetCode(EVENT_BATTLE_DESTROYED) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(s.spcon) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + c:RegisterEffect(e2) +end +s.listed_names={id} +s.listed_series={SET_ARCHFIEND} +function s.thfilter(c) + return c:IsSetCard(SET_ARCHFIEND) and c:IsAbleToHand() and not c:IsCode(id) +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end + local c=e:GetHandler() + --For the rest of this turn, you cannot Special Summon from the Extra Deck, except "Archfiend" monsters + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsSetCard(SET_ARCHFIEND) end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) + aux.RegisterClientHint(c,nil,tp,1,0,aux.Stringid(id,3)) + --You can Normal Summon 1 Fiend monster during your Main Phase in addition to your Normal Summon/Set + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,4)) + e2:SetType(EFFECT_TYPE_FIELD) + e2:SetCode(EFFECT_EXTRA_SUMMON_COUNT) + e2:SetTargetRange(LOCATION_HAND|LOCATION_MZONE,0) + e2:SetTarget(aux.TargetBoolFunction(Card.IsRace,RACE_FIEND)) + e2:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e2,tp) +end +function s.spconfilter(c,tp) + return c:IsPreviousControler(tp) and c:IsRitualMonster() +end +function s.spcon(e,tp,eg,ep,ev,re,r,rp) + return eg:IsExists(s.spconfilter,1,nil,tp) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) then + Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c5914858.lua b/official/c5914858.lua new file mode 100644 index 0000000000..8292183dbb --- /dev/null +++ b/official/c5914858.lua @@ -0,0 +1,75 @@ +--調獄神ジュノーラ +--Junora the Power Patron of Tuning +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Synchro Summon procedure: 1 Tuner + 2 non-Tuner monsters (For this card's Synchro Summon, you can treat 1 monster in your center Main Monster Zone as a Tuner) + Synchro.AddProcedure(c,nil,1,1,Synchro.NonTuner(nil),2,2,s.extratunerfilter) + --Negate the effects of all face-up cards your opponent currently controls + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_DISABLE) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetCondition(function(e) return e:GetHandler():IsSynchroSummoned() end) + e1:SetTarget(s.distg) + e1:SetOperation(s.disop) + c:RegisterEffect(e1) + --Make all monsters your opponent currently controls in the same columns as your "Elvennotes" monsters unable to be used as material for a Fusion, Synchro, Xyz, or Link Summon until the end of this turn + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,id) + e2:SetTarget(s.efftg) + e2:SetOperation(s.effop) + e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) + c:RegisterEffect(e2) +end +s.listed_series={SET_ELVENNOTES} +function s.extratunerfilter(c,scard,sumtype,tp) + return c:IsSequence(2) and c:IsControler(tp) +end +function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,nil) end + local g=Duel.GetMatchingGroup(Card.IsNegatable,tp,0,LOCATION_ONFIELD,nil) + Duel.SetOperationInfo(0,CATEGORY_DISABLE,g,#g,tp,0) +end +function s.disop(e,tp,eg,ep,ev,re,r,rp) + local g=Duel.GetMatchingGroup(Card.IsNegatable,tp,0,LOCATION_ONFIELD,nil) + if #g==0 then return end + local c=e:GetHandler() + for tc in g:Iter() do + --Negate the effects of all face-up cards your opponent currently controls + tc:NegateEffects(c,nil,true) + end +end +function s.cannotmatfilter(c,tp) + return c:GetColumnGroup():IsExists(s.elvennotesfilter,1,nil,tp) +end +function s.elvennotesfilter(c,tp) + return c:IsSetCard(SET_ELVENNOTES) and c:IsMonster() and c:IsFaceup() and c:IsControler(tp) +end +function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.cannotmatfilter,tp,0,LOCATION_MZONE,1,nil,tp) end +end +function s.effop(e,tp,eg,ep,ev,re,r,rp,chk) + local g=Duel.GetMatchingGroup(s.cannotmatfilter,tp,0,LOCATION_MZONE,nil,tp) + if #g==0 then return end + local c=e:GetHandler() + for tc in g:Iter() do + Duel.HintSelection(tc) + --All monsters your opponent currently controls in the same columns as your "Elvennotes" monsters cannot be used as material for a Fusion, Synchro, Xyz, or Link Summon until the end of this turn + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_BE_MATERIAL) + e1:SetValue(aux.cannotmatfilter(SUMMON_TYPE_FUSION,SUMMON_TYPE_SYNCHRO,SUMMON_TYPE_XYZ,SUMMON_TYPE_LINK)) + e1:SetReset(RESETS_STANDARD_PHASE_END) + tc:RegisterEffect(e1) + end +end \ No newline at end of file diff --git a/official/c59374259.lua b/official/c59374259.lua new file mode 100644 index 0000000000..7d07f641ed --- /dev/null +++ b/official/c59374259.lua @@ -0,0 +1,80 @@ +--空牙団の奥義 +--Secret Technique Fur Hire +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Destroy face-up cards on the field, up to the number of monsters "Fur Hire" you control with different names + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_DESTROY+CATEGORY_REMOVE) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetProperty(EFFECT_FLAG_CARD_TARGET) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id) + e1:SetTarget(s.target) + e1:SetOperation(s.activate) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) + --Add this card to your hand + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TOHAND) + e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY,EFFECT_FLAG2_CHECK_SIMULTANEOUS) + e2:SetCode(EVENT_SPSUMMON_SUCCESS) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,id) + e2:SetCondition(s.thcon) + e2:SetTarget(s.thtg) + e2:SetOperation(s.thop) + c:RegisterEffect(e2) +end +s.listed_series={SET_FUR_HIRE} +function s.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + local c=e:GetHandler() + if chkc then return chkc:IsOnField() and chkc:IsFaceup() and chkc~=c end + if chk==0 then return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsSetCard,SET_FUR_HIRE),tp,LOCATION_MZONE,0,1,nil) + and Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,c) end + local g=Duel.GetMatchingGroup(aux.FaceupFilter(Card.IsSetCard,SET_FUR_HIRE),tp,LOCATION_MZONE,0,nil) + local ct=g:GetClassCount(Card.GetCode) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local tg=Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,ct,c) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,tg,#tg,tp,0) + Duel.SetPossibleOperationInfo(0,CATEGORY_REMOVE,tg,#tg,tp,0) +end +function s.lv8filter(c) + return c:IsLevelAbove(8) and c:IsSetCard(SET_FUR_HIRE) and c:IsFaceup() +end +function s.link3filter(c) + return c:IsLinkAbove(3) and c:IsSetCard(SET_FUR_HIRE) and c:IsFaceup() +end +function s.activate(e,tp,eg,ep,ev,re,r,rp) + local tg=Duel.GetTargetCards(e) + if #tg>0 then + if Duel.IsExistingMatchingCard(s.lv8filter,tp,LOCATION_MZONE,0,1,nil) + and Duel.IsExistingMatchingCard(s.link3filter,tp,LOCATION_MZONE,0,1,nil) + and tg:IsExists(Card.IsAbleToRemove,1,nil) + and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.Remove(tg,POS_FACEUP,REASON_EFFECT) + else + Duel.Destroy(tg,REASON_EFFECT) + end + end +end +function s.thconfilter(c,tp) + return (s.lv8filter(c) or s.link3filter(c)) and c:IsControler(tp) +end +function s.thcon(e,tp,eg,ep,ev,re,r,rp) + return eg:IsExists(s.thconfilter,1,nil,tp) +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return c:IsAbleToHand() end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,c,1,tp,0) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) then + Duel.SendtoHand(c,nil,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c59581480.lua b/official/c59581480.lua new file mode 100644 index 0000000000..3cacf49a32 --- /dev/null +++ b/official/c59581480.lua @@ -0,0 +1,72 @@ +--耀聖の波詩ディーナ +--Elvennotes Dyina +--Scripted by Hatter +local s,id=GetID() +function s.initial_effect(c) + --You can Special Summon this card (from your hand) to your center Main Monster Zone + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) + e1:SetCode(EFFECT_SPSUMMON_PROC) + e1:SetRange(LOCATION_HAND) + e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) + e1:SetValue(function() return 0,ZONE_CENTER_MMZ end) + c:RegisterEffect(e1) + --Place 1 "Elvennotes" Continuous Spell from your Deck face-up on your field + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.pltg) + e2:SetOperation(s.plop) + c:RegisterEffect(e2) + --Switch the locations of this card in your Main Monster Zone and the monster in your center Main Monster Zone + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,2)) + e3:SetCategory(CATEGORY_REMOVE) + e3:SetType(EFFECT_TYPE_QUICK_O) + e3:SetCode(EVENT_FREE_CHAIN) + e3:SetRange(LOCATION_MMZONE) + e3:SetCountLimit(1,{id,2}) + e3:SetCondition(function(e,tp) return Duel.IsTurnPlayer(1-tp) end) + e3:SetTarget(s.swtg) + e3:SetOperation(s.swop) + e3:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e3) +end +s.listed_series={SET_ELVENNOTES} +function s.plfilter(c,tp) + return c:IsSetCard(SET_ELVENNOTES) and c:IsContinuousSpell() and not c:IsForbidden() and c:CheckUniqueOnField(tp) +end +function s.pltg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 + and Duel.IsExistingMatchingCard(s.plfilter,tp,LOCATION_DECK,0,1,nil,tp) end +end +function s.plop(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) + local sc=Duel.SelectMatchingCard(tp,s.plfilter,tp,LOCATION_DECK,0,1,1,nil,tp):GetFirst() + if sc then + Duel.MoveToField(sc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) + end +end +function s.swtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return not e:GetHandler():IsSequence(2) and Duel.GetFieldCard(tp,LOCATION_MZONE,2) end + Duel.SetPossibleOperationInfo(0,CATEGORY_REMOVE,nil,1,1-tp,LOCATION_HAND) +end +function s.swop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local cc=Duel.GetFieldCard(tp,LOCATION_MZONE,2) + if c:IsRelateToEffect(e) and c:IsInMainMZone(tp) and cc and c~=cc and Duel.SwapSequence(c,cc) then + local g=Duel.GetMatchingGroup(Card.IsAbleToRemove,tp,0,LOCATION_HAND,nil) + if #g==0 or not Duel.SelectYesNo(tp,aux.Stringid(id,3)) then return end + local rg=g:RandomSelect(tp,1) + if #rg>0 then + Duel.BreakEffect() + --Banish 1 random card from your opponent's hand face-up until the End Phase + aux.RemoveUntil(rg,POS_FACEUP,REASON_EFFECT|REASON_TEMPORARY,PHASE_END,id,e,tp,function(ag,e,tp) Duel.SendtoHand(ag,nil,REASON_EFFECT) end) + end + end +end \ No newline at end of file diff --git a/official/c63679166.lua b/official/c63679166.lua new file mode 100644 index 0000000000..605329a22c --- /dev/null +++ b/official/c63679166.lua @@ -0,0 +1,37 @@ +--スローン・オブ・デーモンズ +--Throne of Archfiends +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + Ritual.AddProcGreater({handler=c, + filter=s.ritualmonsterfilter, + location=LOCATION_HAND|LOCATION_GRAVE|LOCATION_EXTRA|LOCATION_REMOVED}) + --Add this card from your GY or banishment to your hand + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,1)) + e1:SetCategory(CATEGORY_TOHAND) + e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e1:SetCode(EVENT_PHASE+PHASE_STANDBY) + e1:SetRange(LOCATION_GRAVE|LOCATION_REMOVED) + e1:SetCountLimit(1,id) + e1:SetCondition(function(e,tp) return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsCode,48469380),tp,LOCATION_EXTRA,0,1,nil) end) + e1:SetTarget(s.thtg) + e1:SetOperation(s.thop) + c:RegisterEffect(e1) +end +s.listed_names={48469380} --"Doom Emperor Archfiend" +s.listed_series={SET_ARCHFIEND} +function s.ritualmonsterfilter(c) + return c:IsSetCard(SET_ARCHFIEND) and c:IsRitualMonster() and (c:IsFaceup() or c:IsLocation(LOCATION_HAND)) +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return c:IsAbleToHand() end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,c,1,tp,0) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if c:IsRelateToEffect(e) then + Duel.SendtoHand(c,nil,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c64491754.lua b/official/c64491754.lua new file mode 100644 index 0000000000..e1b67cdbeb --- /dev/null +++ b/official/c64491754.lua @@ -0,0 +1,70 @@ +--エルフェンノーツ~廻郷のパラレリズム~ +--Elvennotes ~Homecoming Parallelism~ +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Activate + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_ACTIVATE) + e0:SetCode(EVENT_FREE_CHAIN) + c:RegisterEffect(e0) + --The monster in your center Main Monster Zone cannot be destroyed by card effects + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE) + e1:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) + e1:SetRange(LOCATION_SZONE) + e1:SetTargetRange(LOCATION_MZONE,0) + e1:SetTarget(function(e,c) return c:IsSequence(2) end) + e1:SetValue(1) + c:RegisterEffect(e1) + --Special Summon 1 "Elvennotes" monster with a different original Attribute from your Deck in Defense Position + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_SZONE) + e2:SetCountLimit(1,id) + e2:SetCost(s.spcost) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + c:RegisterEffect(e2) +end +s.listed_series={SET_ELVENNOTES} +function s.spcostfilter(c,e,tp) + return c:IsMonster() and c:IsAbleToGraveAsCost() and Duel.GetMZoneCount(tp,c)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,nil,e,tp,c:GetOriginalAttribute()) +end +function s.spfilter(c,e,tp,attr) + return c:IsSetCard(SET_ELVENNOTES) and not c:IsOriginalAttribute(attr) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE) +end +function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.spcostfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,nil,e,tp) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local sc=Duel.SelectMatchingCard(tp,s.spcostfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,1,nil,e,tp):GetFirst() + e:SetLabel(sc:GetOriginalAttribute()) + Duel.SendtoGrave(sc,REASON_COST) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chk==0 then return true end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,e:GetLabel()) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP_DEFENSE) + end + end + --You cannot Special Summon from the Extra Deck for the rest of this turn, except Synchro Monsters + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetDescription(aux.Stringid(id,1)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsSynchroMonster() end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) +end \ No newline at end of file diff --git a/official/c65514302.lua b/official/c65514302.lua new file mode 100644 index 0000000000..1bb7fc9277 --- /dev/null +++ b/official/c65514302.lua @@ -0,0 +1,96 @@ +--マグネット・ボンディング +--Magnet Bonding +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Activate 1 of these effects (but you can only use each effect of "Magnet Bonding" once per turn) + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCondition(function() return Duel.IsMainPhase() end) + e1:SetTarget(s.efftg) + e1:SetOperation(s.effop) + e1:SetHintTiming(0,TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) + c:RegisterEffect(e1) +end +s.listed_names={44839512} --"Conduction Warrior Linear Magnum ±" +s.listed_series={SET_MAGNET_WARRIOR,SET_MAGNA_WARRIOR} +function s.magnetthfilter(c) + return (c:IsCode(44839512) or (c:IsLevelBelow(4) and c:IsSetCard(SET_MAGNET_WARRIOR))) and c:IsAbleToHand() +end +function s.magnathfilter(c) + return c:IsLevel(8) and c:IsSetCard(SET_MAGNA_WARRIOR) and c:IsAbleToHand() +end +function s.fextrafilter(c) + return c:IsRace(RACE_ROCK) and c:IsFaceup() and c:IsAbleToDeck() +end +function s.fextra(e,tp,mg) + return Duel.GetMatchingGroup(s.fextrafilter,tp,LOCATION_GRAVE|LOCATION_REMOVED,0,nil) +end +function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) + --Add 1 "Conduction Warrior Linear Magnum ±" or 1 Level 4 or lower "Magnet Warrior" monster from your Deck to your hand + local b1=not Duel.HasFlagEffect(tp,id) + and Duel.IsExistingMatchingCard(s.magnetthfilter,tp,LOCATION_DECK,0,1,nil) + --Add 1 Level 8 "Magna Warrior" monster from your Deck to your hand + local b2=not Duel.HasFlagEffect(tp,id+1) + and Duel.IsExistingMatchingCard(s.magnathfilter,tp,LOCATION_DECK,0,1,nil) + --Fusion Summon 1 Rock Fusion Monster from your Extra Deck, by shuffling Rock monsters from your hand, field, GY, and/or banishment into the Deck + local fusion_params={ + fusfilter=function(c) return c:IsRace(RACE_ROCK) end, + matfilter=function(c) return c:IsRace(RACE_ROCK) and c:IsAbleToDeck() end, + extrafil=s.fextra, + extraop=Fusion.ShuffleMaterial + } + local b3=not Duel.HasFlagEffect(tp,id+2) + and Fusion.SummonEffTG(fusion_params)(e,tp,eg,ep,ev,re,r,rp,0) + if chk==0 then return b1 or b2 or b3 end + local op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,1)}, + {b2,aux.Stringid(id,2)}, + {b3,aux.Stringid(id,3)}) + e:SetLabel(op) + if op==1 then + e:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + Duel.RegisterFlagEffect(tp,id,RESET_PHASE|PHASE_END,0,1) + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) + elseif op==2 then + e:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + Duel.RegisterFlagEffect(tp,id+1,RESET_PHASE|PHASE_END,0,1) + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) + elseif op==3 then + e:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON+CATEGORY_TODECK) + Duel.RegisterFlagEffect(tp,id+2,RESET_PHASE|PHASE_END,0,1) + Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,1,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_GRAVE|LOCATION_REMOVED) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) + end +end +function s.effop(e,tp,eg,ep,ev,re,r,rp) + local op=e:GetLabel() + if op==1 then + --Add 1 "Conduction Warrior Linear Magnum ±" or 1 Level 4 or lower "Magnet Warrior" monster from your Deck to your hand + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.magnetthfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end + elseif op==2 then + --Add 1 Level 8 "Magna Warrior" monster from your Deck to your hand + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.magnathfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end + elseif op==3 then + --Fusion Summon 1 Rock Fusion Monster from your Extra Deck, by shuffling Rock monsters from your hand, field, GY, and/or banishment into the Deck + local fusion_params={ + fusfilter=function(c) return c:IsRace(RACE_ROCK) end, + matfilter=function(c) return c:IsRace(RACE_ROCK) and c:IsAbleToDeck() end, + extrafil=s.fextra, + extraop=Fusion.ShuffleMaterial + } + Fusion.SummonEffOP(fusion_params)(e,tp,eg,ep,ev,re,r,rp) + end +end \ No newline at end of file diff --git a/official/c66452432.lua b/official/c66452432.lua new file mode 100644 index 0000000000..61b9ab0997 --- /dev/null +++ b/official/c66452432.lua @@ -0,0 +1,93 @@ +--ヴァレルシュラウド・ドラゴン +--Borrelshroud Dragon +--Scripted by Eerie Code +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Link Summon procedure: 3+ Effect Monsters + Link.AddProcedure(c,aux.FilterBoolFunctionEx(Card.IsType,TYPE_EFFECT),3) + --Your opponent cannot Tribute this card on the field + local e1a=Effect.CreateEffect(c) + e1a:SetType(EFFECT_TYPE_SINGLE) + e1a:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e1a:SetCode(EFFECT_UNRELEASABLE_SUM) + e1a:SetRange(LOCATION_MZONE) + e1a:SetValue(function(e,c) return c and not c:IsControler(e:GetHandlerPlayer()) end) + c:RegisterEffect(e1a) + local e1b=Effect.CreateEffect(c) + e1b:SetType(EFFECT_TYPE_FIELD) + e1b:SetProperty(EFFECT_FLAG_PLAYER_TARGET) + e1b:SetCode(EFFECT_CANNOT_RELEASE) + e1b:SetRange(LOCATION_MZONE) + e1b:SetTargetRange(0,1) + e1b:SetTarget(function(e,c) return c==e:GetHandler() end) + e1b:SetValue(1) + c:RegisterEffect(e1b) + --Negate the effects of 1 face-up card your opponent controls, then destroy 1 "Rokket" monster you control + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_DISABLE+CATEGORY_DESTROY) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1) + e2:SetCondition(function(e) return Duel.IsMainPhase() end) + e2:SetTarget(s.distg) + e2:SetOperation(s.disop) + e2:SetHintTiming(0,TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) + c:RegisterEffect(e2) + --Special Summon 1 Link-4 or lower "Borrel" Link Monster from your Extra Deck + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_SPECIAL_SUMMON) + e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e3:SetProperty(EFFECT_FLAG_NO_TURN_RESET) + e3:SetCode(EVENT_PHASE+PHASE_BATTLE_START) + e3:SetRange(LOCATION_MZONE) + e3:SetCountLimit(1) + e3:SetTarget(s.sptg) + e3:SetOperation(s.spop) + c:RegisterEffect(e3) +end +s.listed_series={SET_ROKKET,SET_BORREL} +function s.distg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsFaceup() and chkc:IsSetCard(SET_ROKKET) end + if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(Card.IsSetCard,SET_ROKKET),tp,LOCATION_MZONE,0,1,nil) + and Duel.IsExistingMatchingCard(Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local g=Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsSetCard,SET_ROKKET),tp,LOCATION_MZONE,0,1,1,nil) + Duel.SetChainLimit(function(e,ep,tp) return tp==ep end) + Duel.SetOperationInfo(0,CATEGORY_DISABLE,nil,1,1-tp,LOCATION_ONFIELD) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) +end +function s.disop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_NEGATE) + local sc=Duel.SelectMatchingCard(tp,Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,1,nil):GetFirst() + if not sc then return end + Duel.HintSelection(sc) + if sc:IsCanBeDisabledByEffect(e) then + --Negate its effects + sc:NegateEffects(e:GetHandler(),nil,true) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) then + Duel.BreakEffect() + Duel.Destroy(tc,REASON_EFFECT) + end + end +end +function s.spfilter(c,e,tp) + return c:IsLinkBelow(4) and c:IsSetCard(SET_BORREL) and Duel.GetLocationCountFromEx(tp,tp,nil,c)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_EXTRA,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_EXTRA,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c66736884.lua b/official/c66736884.lua new file mode 100644 index 0000000000..172a373b27 --- /dev/null +++ b/official/c66736884.lua @@ -0,0 +1,92 @@ +--空牙団の船匠 キール +--Keel, Shipwright Fur Hire +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Link Summon procedure: 2 monsters with different types + Link.AddProcedure(c,nil,2,nil,s.matfiltercheck) + --Set 1 Spell/Trap "Fur Hire" or 1 "Fandora, the Flying Furtress" from your Deck + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetCountLimit(1,id) + e1:SetCondition(function(e) return e:GetHandler():IsLinkSummoned() end) + e1:SetTarget(s.settg) + e1:SetOperation(s.setop) + c:RegisterEffect(e1) + --Banish this card from your GY, and if you do, Special Summon 1 monster "Fur Hire" from your hand + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_REMOVE+CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(function(e,tp) return Duel.IsTurnPlayer(1-tp) end) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e2) +end +s.listed_names={64400161} --"Fandora, the Flying Furtress" +s.listed_series={SET_FUR_HIRE} +function s.matfiltercheck(g,lc,sumtype,tp) + return g:CheckDifferentPropertyBinary(Card.GetRace,lc,sumtype,tp) +end +function s.setfilter(c) + return ((c:IsSetCard(SET_FUR_HIRE) and c:IsSpellTrap()) or c:IsCode(64400161)) and c:IsSSetable() +end +function s.settg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.setfilter,tp,LOCATION_DECK,0,1,nil) end +end +function s.setop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) + local g=Duel.SelectMatchingCard(tp,s.setfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SSet(tp,g) + end + --You cannot Special Summon for the rest of this turn, except monsters "Fur Hire" + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return not c:IsSetCard(SET_FUR_HIRE) end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) +end +function s.spfilter(c,e,tp) + return c:IsSetCard(SET_FUR_HIRE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return c:IsAbleToRemove() and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_REMOVE,c,1,tp,0) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) and Duel.Remove(c,nil,REASON_EFFECT)>0 and c:IsLocation(LOCATION_REMOVED) and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g1=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND,0,1,1,nil,e,tp) + if #g1>0 and Duel.SpecialSummon(g1,0,tp,tp,false,false,POS_FACEUP)>0 + and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND,0,1,nil,e,tp) then + local atkg=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,LOCATION_MZONE,nil):GetMaxGroup(Card.GetBaseAttack) + if not atkg:IsExists(Card.IsControler,1,nil,1-tp) then return end + if Duel.SelectYesNo(tp,aux.Stringid(id,3)) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g2=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND,0,1,1,nil,e,tp) + if #g2>0 then + Duel.BreakEffect() + Duel.SpecialSummon(g2,0,tp,tp,false,false,POS_FACEUP) + end + end + end + end +end \ No newline at end of file diff --git a/official/c73819701.lua b/official/c73819701.lua new file mode 100644 index 0000000000..0e74ba76e5 --- /dev/null +++ b/official/c73819701.lua @@ -0,0 +1,82 @@ +--白き竜の落胤 +--Fallen of the White Dragon +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Special Summon this card, also you cannot Special Summon from the Extra Deck for the rest of this turn, except Level 8 Fusion or Synchro Monsters + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetRange(LOCATION_HAND) + e1:SetCountLimit(1,id) + e1:SetCost(s.selfspcost) + e1:SetTarget(s.selfsptg) + e1:SetOperation(s.selfspop) + c:RegisterEffect(e1) + --Special Summon 1 "Ecclesia" monster from your hand, Deck, or GY + local e2a=Effect.CreateEffect(c) + e2a:SetDescription(aux.Stringid(id,1)) + e2a:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2a:SetProperty(EFFECT_FLAG_DELAY) + e2a:SetCode(EVENT_SUMMON_SUCCESS) + e2a:SetCountLimit(1,{id,1}) + e2a:SetTarget(s.hdgysptg) + e2a:SetOperation(s.hdgyspop) + c:RegisterEffect(e2a) + local e2b=e2a:Clone() + e2b:SetCode(EVENT_SPSUMMON_SUCCESS) + c:RegisterEffect(e2b) +end +s.listed_names={CARD_ALBAZ} +s.listed_series={SET_ECCLESIA} +function s.selfspcostfilter(c) + return c:ListsCode(CARD_ALBAZ) and c:IsAbleToGraveAsCost() +end +function s.selfspcost(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.selfspcostfilter,tp,LOCATION_EXTRA,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local g=Duel.SelectMatchingCard(tp,s.selfspcostfilter,tp,LOCATION_EXTRA,0,1,1,nil) + Duel.SendtoGrave(g,REASON_COST) +end +function s.selfsptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) +end +function s.selfspop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) then + Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) + end + --You cannot Special Summon from the Extra Deck for the rest of this turn, except Level 8 Fusion or Synchro Monsters + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not (c:IsLevel(8) and c:IsType(TYPE_FUSION|TYPE_SYNCHRO)) end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) + --"Clock Lizard" check + aux.addTempLizardCheck(c,tp,function(e,c) return not (c:IsOriginalLevel(8) and c:IsType(TYPE_FUSION|TYPE_SYNCHRO)) end) +end +function s.hdgyspfilter(c,e,tp) + return c:IsSetCard(SET_ECCLESIA) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.hdgysptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.hdgyspfilter,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE) +end +function s.hdgyspop(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,aux.NecroValleyFilter(s.hdgyspfilter),tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c74631897.lua b/official/c74631897.lua new file mode 100644 index 0000000000..654c7eeb3d --- /dev/null +++ b/official/c74631897.lua @@ -0,0 +1,111 @@ +--神芸なる知恵の乙女 +--Artmage Non Finito +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Fusion Materials: 2 "Artmage" monsters + Fusion.AddProcMixN(c,true,true,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_ARTMAGE),2) + c:AddMustBeFusionSummoned() + --You can only Fusion Summon or Special Summon by its alternate procedure "Artmage Nonfinite" once per turn + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) + e0:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e0:SetCode(EVENT_SPSUMMON_SUCCESS) + e0:SetCondition(s.regcon) + e0:SetOperation(s.regop) + c:RegisterEffect(e0) + --You can Special Summon this card by discarding 1 Spell/Trap and Tributing 1 Level 7 or higher "Artmage" monster in your hand or field + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) + e1:SetCode(EFFECT_SPSUMMON_PROC) + e1:SetRange(LOCATION_EXTRA) + e1:SetCondition(s.selfspcon) + e1:SetTarget(s.selfsptg) + e1:SetOperation(s.selfspop) + e1:SetValue(1) + c:RegisterEffect(e1) + --Set 1 "Artmage" Spell/Trap from your Deck + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY) + e2:SetCode(EVENT_SPSUMMON_SUCCESS) + e2:SetTarget(s.settg) + e2:SetOperation(s.setop) + c:RegisterEffect(e2) + --Fusion Summon 1 Fusion Monster by using monsters you control + local fusion_params={handler=c,matfilter=Fusion.OnFieldMat} + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,2)) + e3:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON) + e3:SetType(EFFECT_TYPE_QUICK_O) + e3:SetCode(EVENT_FREE_CHAIN) + e3:SetRange(LOCATION_MZONE) + e3:SetCountLimit(1) + e3:SetCondition(function(e,tp) return Duel.IsTurnPlayer(1-tp) end) + e3:SetTarget(Fusion.SummonEffTG(fusion_params)) + e3:SetOperation(Fusion.SummonEffOP(fusion_params)) + e3:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e3) +end +s.listed_series={SET_ARTMAGE} +s.listed_names={id} +function s.regcon(e) + local c=e:GetHandler() + return c:IsFusionSummoned() or c:IsSummonType(SUMMON_TYPE_SPECIAL+1) +end +function s.regop(e,tp,eg,ep,ev,re,r,rp) + --Prevent another Fusion Summon or Special Summon by its alternate procedure of "Artmage Nonfinite" that turn + 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(function(e,c,sump,sumtype) + return c:IsCode(id) and (sumtype&SUMMON_TYPE_FUSION==SUMMON_TYPE_FUSION or sumtype&SUMMON_TYPE_SPECIAL+1==SUMMON_TYPE_SPECIAL+1) + end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) +end +function s.selfspcostfilter(c,tp,fc) + return c:IsLevelAbove(7) and c:IsSetCard(SET_ARTMAGE,fc,SUMMON_TYPE_SPECIAL+1,tp) and Duel.GetLocationCountFromEx(tp,tp,c,fc)>0 +end +function s.selfspcon(e,c) + if not c then return true end + if c:IsFaceup() then return false end + local tp=c:GetControler() + return Duel.IsExistingMatchingCard(aux.AND(Card.IsSpellTrap,Card.IsDiscardable),tp,LOCATION_HAND,0,1,nil) + and Duel.CheckReleaseGroup(tp,s.selfspcostfilter,1,true,1,true,c,tp,nil,nil,nil,tp,c) +end +function s.selfsptg(e,tp,eg,ep,ev,re,r,rp,chk,c) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DISCARD) + local dg=Duel.SelectMatchingCard(tp,aux.AND(Card.IsSpellTrap,Card.IsDiscardable),tp,LOCATION_HAND,0,1,1,true,nil) + if not dg then return false end + local rg=Duel.SelectReleaseGroup(tp,s.selfspcostfilter,1,1,true,true,true,c,tp,nil,false,nil,tp,c) + if not rg then return false end + e:SetLabelObject(dg+rg) + return true +end +function s.selfspop(e,tp,eg,ep,ev,re,r,rp,c) + local g=e:GetLabelObject() + if not g or #g~=2 then return end + local dg,rg=g:Split(Card.IsSpellTrap,nil) + Duel.SendtoGrave(dg,REASON_COST|REASON_MATERIAL|REASON_DISCARD) + Duel.Release(rg,REASON_COST|REASON_MATERIAL) +end +function s.setfilter(c) + return c:IsSetCard(SET_ARTMAGE) and c:IsSpellTrap() and c:IsSSetable() +end +function s.settg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.setfilter,tp,LOCATION_DECK,0,1,nil) end +end +function s.setop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) + local g=Duel.SelectMatchingCard(tp,s.setfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SSet(tp,g) + end +end \ No newline at end of file diff --git a/official/c76666602.lua b/official/c76666602.lua new file mode 100644 index 0000000000..c421869c19 --- /dev/null +++ b/official/c76666602.lua @@ -0,0 +1,77 @@ +--聖痕喰らいし竜 +--The Dragon that Devours the Dogma +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Fusion Materials: "Fallen of Albaz" + 1 LIGHT or DARK monster + 1 Effect Monster + Fusion.AddProcMix(c,true,true,CARD_ALBAZ,aux.FilterBoolFunctionEx(Card.IsAttribute,ATTRIBUTE_LIGHT|ATTRIBUTE_DARK),aux.FilterBoolFunctionEx(Card.IsType,TYPE_EFFECT)) + --While an "Ecclesia" monster is on the field or in either GY, this card gains 500 ATK, also it is unaffected by other cards' effects + local e1a=Effect.CreateEffect(c) + e1a:SetType(EFFECT_TYPE_SINGLE) + e1a:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e1a:SetCode(EFFECT_UPDATE_ATTACK) + e1a:SetRange(LOCATION_MZONE) + e1a:SetCondition(function() return Duel.IsExistingMatchingCard(s.atkimmconfilter,0,LOCATION_MZONE|LOCATION_GRAVE,LOCATION_MZONE|LOCATION_GRAVE,1,nil) end) + e1a:SetValue(500) + c:RegisterEffect(e1a) + local e1b=e1a:Clone() + e1b:SetCode(EFFECT_IMMUNE_EFFECT) + e1b:SetValue(function(e,te) return te:GetOwner()~=e:GetOwner() end) + c:RegisterEffect(e1b) + --Shuffle up to 2 cards from any GY(s) and/or banishment into the Deck + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_TODECK) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY) + e2:SetCode(EVENT_SPSUMMON_SUCCESS) + e2:SetCountLimit(1,id) + e2:SetTarget(s.tdtg) + e2:SetOperation(s.tdop) + c:RegisterEffect(e2) + --Add 1 "Dogmatika" or "Tri-Brigade" card from your Deck to your hand + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e3:SetCode(EVENT_PHASE+PHASE_END) + e3:SetRange(LOCATION_GRAVE) + e3:SetCountLimit(1,{id,1}) + e3:SetCondition(function(e) return e:GetHandler():GetTurnID()==Duel.GetTurnCount() end) + e3:SetTarget(s.thtg) + e3:SetOperation(s.thop) + c:RegisterEffect(e3) +end +s.listed_names={CARD_ALBAZ} +s.listed_series={SET_ECCLESIA,SET_DOGMATIKA,SET_TRI_BRIGADE} +function s.atkimmconfilter(c) + return c:IsFaceup() and c:IsSetCard(SET_ECCLESIA) and c:IsMonster() +end +function s.tdtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToDeck,tp,LOCATION_GRAVE|LOCATION_REMOVED,LOCATION_GRAVE|LOCATION_REMOVED,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TODECK,nil,1,PLAYER_EITHER,LOCATION_GRAVE|LOCATION_REMOVED) +end +function s.tdop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) + local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(Card.IsAbleToDeck),tp,LOCATION_GRAVE|LOCATION_REMOVED,LOCATION_GRAVE|LOCATION_REMOVED,1,2,nil) + if #g>0 then + Duel.HintSelection(g) + Duel.SendtoDeck(g,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) + end +end +function s.thfilter(c) + return c:IsSetCard({SET_DOGMATIKA,SET_TRI_BRIGADE}) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end diff --git a/official/c77675029.lua b/official/c77675029.lua new file mode 100644 index 0000000000..f6e565ab89 --- /dev/null +++ b/official/c77675029.lua @@ -0,0 +1,82 @@ +--エクソシスター・カルマエル +--Exosister Karmael +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Xyz Summon procedure: 2 Level 4 "Exosister" monsters + Xyz.AddProcedure(c,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_EXOSISTER),4,2) + --Apply a "during the End Phase of this turn, Set 1 "Exosister" Spell/Trap from your Deck, GY, or banishment" effect + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetCountLimit(1,id) + e1:SetCondition(function(e) return e:GetHandler():IsXyzSummoned() end) + e1:SetOperation(s.regop) + c:RegisterEffect(e1) + --Detach all materials from this card, and if you do, the activated effect becomes "Add 1 card from your opponent's GY to their hand" + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetCode(EVENT_CHAINING) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(s.chcon) + e2:SetTarget(s.chtg) + e2:SetOperation(s.chop) + c:RegisterEffect(e2) +end +s.listed_series={SET_EXOSISTER} +function s.regop(e,tp,eg,ep,ev,re,r,rp) + --During the End Phase of this turn, Set 1 "Exosister" Spell/Trap from your Deck, GY, or banishment + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) + e1:SetCode(EVENT_PHASE+PHASE_END) + e1:SetCountLimit(1) + e1:SetOperation(s.setop) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) +end +function s.setfilter(c) + return c:IsSetCard(SET_EXOSISTER) and c:IsSpellTrap() and c:IsSSetable() and (c:IsFaceup() or c:IsLocation(LOCATION_DECK)) +end +function s.setop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_CARD,0,id) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) + local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.setfilter),tp,LOCATION_DECK|LOCATION_GRAVE|LOCATION_REMOVED,0,1,1,nil) + if #g>0 then + Duel.SSet(tp,g) + end +end +function s.chcon(e,tp,eg,ep,ev,re,r,rp) + local rc=re:GetHandler() + return rp==1-tp and (re:IsMonsterEffect() or (rc:IsNormalSpellTrap() and re:IsHasType(EFFECT_TYPE_ACTIVATE))) +end +function s.chtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then + local c=e:GetHandler() + local mat_ct=c:GetOverlayCount() + return mat_ct>0 and c:CheckRemoveOverlayCard(tp,mat_ct,REASON_EFFECT) + and Duel.IsExistingMatchingCard(Card.IsAbleToHand,tp,LOCATION_GRAVE,0,1,nil) + end +end +function s.chop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local mg=c:GetOverlayGroup() + if c:IsRelateToEffect(e) and #mg>0 and Duel.SendtoGrave(mg,REASON_EFFECT)>0 then + local g=Group.CreateGroup() + Duel.ChangeTargetCard(ev,g) + Duel.ChangeChainOperation(ev,s.repop) + end +end +function s.repop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(Card.IsAbleToHand),tp,0,LOCATION_GRAVE,1,1,nil) + if #g>0 then + Duel.HintSelection(g) + Duel.SendtoHand(g,nil,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c78397661.lua b/official/c78397661.lua new file mode 100644 index 0000000000..8c9367a18b --- /dev/null +++ b/official/c78397661.lua @@ -0,0 +1,86 @@ +--黒き竜のエクレシア +--Ecclesia of the Black Dragon +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Synchro Summon procedure: 1 Tuner + 1+ non-Tuner monsters + Synchro.AddProcedure(c,nil,1,1,Synchro.NonTuner(nil),1,99) + --Banish this card (until the End Phase), and if you do, Special Summon 1 "Fallen of Albaz" or 1 Level 4 or lower monster that mentions it from your Deck or GY + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_REMOVE+CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_QUICK_O) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetRange(LOCATION_MZONE) + e1:SetCountLimit(1,{id,0}) + e1:SetCondition(function() return Duel.IsMainPhase() end) + e1:SetTarget(s.rmsptg) + e1:SetOperation(s.rmspop) + e1:SetHintTiming(0,TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) + c:RegisterEffect(e1) + --Shuffle both 1 Level 8 Fusion Monster in your GY or banishment and 1 card on the field, and this card into the Deck + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TODECK+CATEGORY_TOEXTRA) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_GRAVE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.tdtg) + e2:SetOperation(s.tdop) + c:RegisterEffect(e2) +end +s.listed_names={CARD_ALBAZ} +function s.spfilter(c,e,tp) + return (c:IsCode(CARD_ALBAZ) or (c:IsLevelBelow(4) and c:ListsCode(CARD_ALBAZ))) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.rmsptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return c:IsAbleToRemove() and Duel.GetMZoneCount(tp,c)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_REMOVE,c,1,tp,0) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) +end +function s.rmspop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) and aux.RemoveUntil(c,nil,REASON_EFFECT,PHASE_END,id,e,tp,aux.DefaultFieldReturnOp) + and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end + end +end +function s.fustdfilter(c,e) + return c:IsLevel(8) and c:IsFusionMonster() and c:IsFaceup() and c:IsAbleToExtra() and c:IsCanBeEffectTarget(e) +end +function s.fieldtdfilter(c,e) + return c:IsAbleToDeck() and c:IsCanBeEffectTarget(e) +end +function s.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return false end + local c=e:GetHandler() + if chk==0 then return c:IsAbleToExtra() + and Duel.IsExistingMatchingCard(s.fustdfilter,tp,LOCATION_GRAVE|LOCATION_REMOVED,0,1,c,e) + and Duel.IsExistingMatchingCard(s.fieldtdfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil,e) end + local fusiong=Group.CreateGroup() + local fieldg=Group.CreateGroup() + repeat + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) + fusiong=Duel.SelectMatchingCard(tp,s.fustdfilter,tp,LOCATION_GRAVE|LOCATION_REMOVED,0,1,1,c,e) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) + fieldg=Duel.SelectMatchingCard(tp,s.fieldtdfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,true,nil,e) + until fieldg~=nil + local tg=fusiong:Merge(fieldg) + Duel.SetTargetCard(tg) + Duel.SetOperationInfo(0,CATEGORY_TODECK,tg+c,3,tp,0) +end +function s.tdop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local tg=Duel.GetTargetCards(e) + if c:IsRelateToEffect(e) and #tg==2 then + Duel.SendtoDeck(tg+c,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c78910832.lua b/official/c78910832.lua new file mode 100644 index 0000000000..249e170c60 --- /dev/null +++ b/official/c78910832.lua @@ -0,0 +1,97 @@ +--ビック・バイパー Type-L +--Vic Viper Type-L +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Activate 1 of these effects + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e1:SetCode(EVENT_PHASE+PHASE_BATTLE_START) + e1:SetRange(LOCATION_MZONE) + e1:SetCountLimit(1,id) + e1:SetCondition(function(e,tp) return Duel.IsTurnPlayer(tp) end) + e1:SetTarget(s.efftg) + e1:SetOperation(s.effop) + c:RegisterEffect(e1) + --Special Summon 1 LIGHT Machine monster from your GY + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_ATKCHANGE) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) + e2:SetCode(EVENT_DESTROYED) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.gysptg) + e2:SetOperation(s.gyspop) + c:RegisterEffect(e2) +end +function s.handspfilter(c,e,tp) + return c:IsRace(RACE_MACHINE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.tgfilter(c) + return c:IsLevelBelow(4) and c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsRace(RACE_MACHINE) and c:IsAbleToGrave() +end +function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) + local b1=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.handspfilter,tp,LOCATION_HAND,0,1,nil,e,tp) + local b2=Duel.IsExistingMatchingCard(s.tgfilter,tp,LOCATION_DECK,0,1,nil) + if chk==0 then return b1 or b2 end + local op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,2)}, + {b2,aux.Stringid(id,3)}) + e:SetLabel(op) + if op==1 then + e:SetCategory(CATEGORY_SPECIAL_SUMMON) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND) + elseif op==2 then + e:SetCategory(CATEGORY_TOGRAVE) + Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) + end +end +function s.effop(e,tp,eg,ep,ev,re,r,rp) + local op=e:GetLabel() + if op==1 then + --Special Summon 1 Machine monster from your hand + if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,s.handspfilter,tp,LOCATION_HAND,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end + elseif op==2 then + --Send 1 Level 4 or lower LIGHT Machine monster from your Deck to the GY + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local g=Duel.SelectMatchingCard(tp,s.tgfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoGrave(g,REASON_EFFECT) + end + end +end +function s.gyspfilter(c,e,tp) + return c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsRace(RACE_MACHINE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.gysptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_GRAVE) and s.gyspfilter(chkc,e,tp) end + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingTarget(s.gyspfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local tc=Duel.SelectTarget(tp,s.gyspfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp):GetFirst() + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,tc,1,tp,0) + if tc:GetBaseAttack()<=1200 then + Duel.SetOperationInfo(0,CATEGORY_ATKCHANGE,tc,1,tp,1200) + end +end +function s.gyspop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)>0 and tc:GetBaseAttack()<=1200 then + --If its original ATK is 1200 or less, it gains 1200 ATK + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_UPDATE_ATTACK) + e1:SetValue(1200) + e1:SetReset(RESET_EVENT|RESETS_STANDARD) + tc:RegisterEffect(e1) + end +end \ No newline at end of file diff --git a/official/c79519259.lua b/official/c79519259.lua new file mode 100644 index 0000000000..c6057f6b72 --- /dev/null +++ b/official/c79519259.lua @@ -0,0 +1,86 @@ +--ナイトウィング・プリースト +--Night Wing Priestess +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Synchro Summon procedure: 1 Tuner + 1+ non-Tuner monsters + Synchro.AddProcedure(c,nil,1,1,Synchro.NonTuner(nil),1,99) + --Set 1 "Assault Mode Activate" from your hand, Deck, or GY + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetCountLimit(1,id) + e1:SetTarget(s.settg) + e1:SetOperation(s.setop) + c:RegisterEffect(e1) + --Add to your hand, or Special Summon, 1 monster that mentions "Assault Mode Activate" from your Deck + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SEARCH+CATEGORY_TOHAND+CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetCost(Cost.Discard()) + e2:SetTarget(s.thsptg) + e2:SetOperation(s.thspop) + c:RegisterEffect(e2) +end +s.listed_names={CARD_ASSAULT_MODE} +function s.setfilter(c) + return c:IsCode(CARD_ASSAULT_MODE) and c:IsSSetable() +end +function s.settg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.setfilter,tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE,0,1,nil) end +end +function s.setop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET) + local sc=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.setfilter),tp,LOCATION_HAND|LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil):GetFirst() + if sc and Duel.SSet(tp,sc)>0 then + --It can be activated this turn + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_TRAP_ACT_IN_SET_TURN) + e1:SetReset(RESETS_STANDARD_PHASE_END) + sc:RegisterEffect(e1) + end +end +function s.thspfilter(c,e,tp,mzone_chk) + return c:ListsCode(CARD_ASSAULT_MODE) and c:IsMonster() and (c:IsAbleToHand() or (mzone_chk and c:IsCanBeSpecialSummoned(e,0,tp,false,false))) +end +function s.thsptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thspfilter,tp,LOCATION_DECK,0,1,nil,e,tp,Duel.GetLocationCount(tp,LOCATION_MZONE)>0) end + Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) + Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) +end +function s.thspop(e,tp,eg,ep,ev,re,r,rp) + local mzone_chk=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(id,3)) + local sc=Duel.SelectMatchingCard(tp,s.thspfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,mzone_chk):GetFirst() + aux.ToHandOrElse(sc,tp, + function() + return mzone_chk and sc:IsCanBeSpecialSummoned(e,0,tp,false,false) + end, + function() + Duel.SpecialSummon(sc,0,tp,tp,false,false,POS_FACEUP) + end, + aux.Stringid(id,4) + ) + local c=e:GetHandler() + --You cannot Special Summon from the Extra Deck for the rest of this turn, except Synchro Monsters + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,5)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsSynchroMonster() end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) + --"Clock Lizard" check + aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalType(TYPE_SYNCHRO) end) +end \ No newline at end of file diff --git a/official/c84031359.lua b/official/c84031359.lua new file mode 100644 index 0000000000..3d5d4c5f3f --- /dev/null +++ b/official/c84031359.lua @@ -0,0 +1,77 @@ +--堕天使グルガルタ +--Darklord Gulgalta +--scripted by Naim +local s,id=GetID() +local TOKEN_DARKLORD=id+1 +function s.initial_effect(c) + --You can only Special Summon "Darklord Gulgalta(s)" once per turn + c:SetSPSummonOnce(id) + --Special Summon 2 "Darklord Tokens" + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetTarget(s.sptg) + e1:SetOperation(s.spop) + c:RegisterEffect(e1) + --Add 1 "Darklord" card or "Forbidden" Quick-Play Spell from your Deck to your hand + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY) + e2:SetCode(EVENT_TO_GRAVE) + e2:SetCountLimit(1,id) + e2:SetTarget(s.thtg) + e2:SetOperation(s.thop) + c:RegisterEffect(e2) +end +s.listed_names={id,TOKEN_DARKLORD} -- "Darklord Token" +s.listed_series={SET_DARKLORD,SET_FORBIDDEN} +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return not Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) + and Duel.GetLocationCount(tp,LOCATION_MZONE)>=2 + and Duel.IsPlayerCanSpecialSummonMonster(tp,TOKEN_DARKLORD,SET_DARKLORD,TYPES_TOKEN,0,0,6,RACE_FAIRY,ATTRIBUTE_DARK) end + Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,2,tp,0) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,2,tp,0) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + --You cannot Special Summon for the rest of this turn, except Fairy monsters + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return not c:IsRace(RACE_FAIRY) end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) + --Clock Lizard check + aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalRace(RACE_FAIRY) end) + --Special Summon 2 "Darklord Tokens" + if Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) or Duel.GetLocationCount(tp,LOCATION_MZONE)<2 + or not Duel.IsPlayerCanSpecialSummonMonster(tp,TOKEN_DARKLORD,SET_DARKLORD,TYPES_TOKEN,0,0,6,RACE_FAIRY,ATTRIBUTE_DARK) then return end + for i=1,2 do + local token=Duel.CreateToken(tp,TOKEN_DARKLORD) + Duel.SpecialSummonStep(token,0,tp,tp,false,false,POS_FACEUP) + end + Duel.SpecialSummonComplete() +end +function s.thfilter(c) + return (c:IsSetCard(SET_DARKLORD) or (c:IsSetCard(SET_FORBIDDEN) and c:IsQuickPlaySpell())) and c:IsAbleToHand() and not c:IsCode(id) +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end \ No newline at end of file diff --git a/official/c84464389.lua b/official/c84464389.lua new file mode 100644 index 0000000000..e0ce041758 --- /dev/null +++ b/official/c84464389.lua @@ -0,0 +1,113 @@ +--ヴァレルロード・FF・ドラゴン +--Borreload Fatal Flare Dragon +--Scripted by Eerie Code +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Fusion Materials: 1 DARK Link Monster + 1 DARK monster + Fusion.AddProcMix(c,true,true,s.matfilter,aux.FilterBoolFunctionEx(Card.IsAttribute,ATTRIBUTE_DARK)) + --Add 1 "Rokket" monster from your Deck to your hand + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetCountLimit(1,{id,0}) + e1:SetCondition(function(e) return e:GetHandler():IsFusionSummoned() end) + e1:SetTarget(s.thtg) + e1:SetOperation(s.thop) + c:RegisterEffect(e1) + --Equip 1 DARK Link MOnster from your GY or banishment to 1 DARK monster you control as an Equip Spell that gives it 500 ATK + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_EQUIP) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.eqtg) + e2:SetOperation(s.eqop) + c:RegisterEffect(e2) + --Destroy 1 card on the field + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,2)) + e3:SetCategory(CATEGORY_DESTROY) + e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e3:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) + e3:SetCode(EVENT_BE_MATERIAL) + e3:SetCountLimit(1,{id,2}) + e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return e:GetHandler():IsLocation(LOCATION_GRAVE) and r==REASON_LINK end) + e3:SetTarget(s.destg) + e3:SetOperation(s.desop) + c:RegisterEffect(e3) +end +s.listed_series={SET_ROKKET} +function s.matfilter(c,sc,st,tp) + return c:IsAttribute(ATTRIBUTE_DARK,sc,st,tp) and c:IsType(TYPE_LINK,sc,st,tp) +end +function s.thfilter(c) + return c:IsSetCard(SET_ROKKET) and c:IsMonster() and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end +function s.eqfilter(c,tp) + return c:IsAttribute(ATTRIBUTE_DARK) and c:IsLinkMonster() and c:IsFaceup() and c:CheckUniqueOnField(tp) + and not c:IsForbidden() +end +function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsAttribute(ATTRIBUTE_DARK) and chkc:IsFaceup() end + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 + and Duel.IsExistingTarget(aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_DARK),tp,LOCATION_MZONE,0,1,nil) + and Duel.IsExistingMatchingCard(s.eqfilter,tp,LOCATION_GRAVE|LOCATION_REMOVED,0,1,nil,tp) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) + Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_DARK),tp,LOCATION_MZONE,0,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_EQUIP,nil,1,tp,LOCATION_GRAVE|LOCATION_REMOVED) +end +function s.eqop(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end + local tc=Duel.GetFirstTarget() + if tc:IsFacedown() or not tc:IsRelateToEffect(e) then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) + local ec=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.eqfilter),tp,LOCATION_GRAVE|LOCATION_REMOVED,0,1,1,nil,tp):GetFirst() + if ec and Duel.Equip(tp,ec,tc) then + --The equipped monster gains 500 ATK + local e1=Effect.CreateEffect(ec) + e1:SetType(EFFECT_TYPE_EQUIP) + e1:SetCode(EFFECT_UPDATE_ATTACK) + e1:SetValue(500) + e1:SetReset(RESET_EVENT|RESETS_STANDARD) + ec:RegisterEffect(e1) + --Equip limit + local e2=Effect.CreateEffect(ec) + e2:SetType(EFFECT_TYPE_SINGLE) + e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e2:SetCode(EFFECT_EQUIP_LIMIT) + e2:SetValue(function(e,c) return c==tc end) + e2:SetReset(RESET_EVENT|RESETS_STANDARD) + ec:RegisterEffect(e2) + end +end +function s.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsOnField() end + if chk==0 then return Duel.IsExistingTarget(nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local g=Duel.SelectTarget(tp,nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) +end +function s.desop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) then + Duel.Destroy(tc,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c85154941.lua b/official/c85154941.lua new file mode 100644 index 0000000000..8eb1304acf --- /dev/null +++ b/official/c85154941.lua @@ -0,0 +1,86 @@ +--デューク・デーモン +--Duke Archfiend +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Gains ATK equal to its Level x 200 + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e1:SetCode(EFFECT_UPDATE_ATTACK) + e1:SetRange(LOCATION_MZONE) + e1:SetValue(function(e,c) return c:GetLevel()*200 end) + c:RegisterEffect(e1) + --Send 1 "Archfiend" monster from your Deck to the GY, and if you do, increase the targeted monster's Level by the sent monster's + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_TOGRAVE+CATEGORY_LVCHANGE) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,id) + e2:SetTarget(s.tgtg) + e2:SetOperation(s.tgop) + c:RegisterEffect(e2) + --Special Summon this card + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_SPECIAL_SUMMON) + e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e3:SetCode(EVENT_BATTLE_DESTROYED) + e3:SetRange(LOCATION_GRAVE) + e3:SetCountLimit(1,{id,1}) + e3:SetCondition(s.spcon) + e3:SetTarget(s.sptg) + e3:SetOperation(s.spop) + c:RegisterEffect(e3) +end +s.listed_names={id} +s.listed_series={SET_ARCHFIEND} +function s.tgfilter(c) + return c:IsSetCard(SET_ARCHFIEND) and c:IsMonster() and c:IsAbleToGrave() and not c:IsCode(id) +end +function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and chkc:IsFaceup() and chkc:HasLevel() end + if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(Card.HasLevel),tp,LOCATION_MZONE,0,1,nil) + and Duel.IsExistingMatchingCard(s.tgfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) + local g=Duel.SelectTarget(tp,aux.FaceupFilter(Card.HasLevel),tp,LOCATION_MZONE,0,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) + Duel.SetOperationInfo(0,CATEGORY_LVCHANGE,g,1,tp,1) +end +function s.tgop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local sc=Duel.SelectMatchingCard(tp,s.tgfilter,tp,LOCATION_DECK,0,1,1,nil):GetFirst() + if sc and Duel.SendtoGrave(sc,REASON_EFFECT)>0 and sc:IsLocation(LOCATION_GRAVE) then + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and tc:IsFaceup() then + --Increase the targeted monster's Level by the sent monster's + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_UPDATE_LEVEL) + e1:SetValue(sc:GetLevel()) + e1:SetReset(RESET_EVENT|RESETS_STANDARD) + tc:RegisterEffect(e1) + end + end +end +function s.spconfilter(c,tp) + return c:IsPreviousControler(tp) and c:IsRitualMonster() +end +function s.spcon(e,tp,eg,ep,ev,re,r,rp) + return eg:IsExists(s.spconfilter,1,nil,tp) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) then + Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c85586937.lua b/official/c85586937.lua new file mode 100644 index 0000000000..f8d37ce92e --- /dev/null +++ b/official/c85586937.lua @@ -0,0 +1,92 @@ +--WAKE CUP! アル +--WAKE CUP! Erl +--Scripted by The Razgriz +local s,id=GetID() +function s.initial_effect(c) + --FLIP: You can send face-up cards your opponent controls to the GY, up to the number of Flip monsters you control + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOGRAVE) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_FLIP+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCountLimit(1,id) + e1:SetTarget(s.tgtg) + e1:SetOperation(s.tgop) + c:RegisterEffect(e1) + --Discard 1 other Flip monster, and if you do, Special Summon this card in Attack Position or face-down Defense Position + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_HANDES+CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_HAND) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.selfsptg) + e2:SetOperation(s.selfspop) + c:RegisterEffect(e2) + --Special Summon 1 Flip monster from your GY in face-down Defense Position + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,2)) + e3:SetCategory(CATEGORY_SPECIAL_SUMMON) + e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e3:SetProperty(EFFECT_FLAG_CARD_TARGET) + e3:SetCode(EVENT_PHASE+PHASE_END) + e3:SetRange(LOCATION_MZONE) + e3:SetCountLimit(1,{id,2}) + e3:SetCondition(function(e,tp) return Duel.IsTurnPlayer(tp) end) + e3:SetTarget(s.gysptg) + e3:SetOperation(s.gyspop) + c:RegisterEffect(e3) +end +function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsType,TYPE_FLIP),tp,LOCATION_MZONE,0,1,nil) + and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsAbleToGrave),tp,0,LOCATION_ONFIELD,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,1-tp,LOCATION_ONFIELD) +end +function s.tgop(e,tp,eg,ep,ev,re,r,rp) + local ct=Duel.GetMatchingGroupCount(aux.FaceupFilter(Card.IsType,TYPE_FLIP),tp,LOCATION_MZONE,0,nil) + if ct==0 then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local g=Duel.SelectMatchingCard(tp,aux.FaceupFilter(Card.IsAbleToGrave),tp,0,LOCATION_ONFIELD,1,ct,nil) + if #g>0 then + Duel.HintSelection(g) + Duel.SendtoGrave(g,REASON_EFFECT) + end +end +function s.selfspdiscardfilter(c) + return c:IsType(TYPE_FLIP) and c:IsDiscardable(REASON_EFFECT) +end +function s.selfsptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.selfspdiscardfilter,tp,LOCATION_HAND,0,1,c) + and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_ATTACK|POS_FACEDOWN_DEFENSE) + end + Duel.SetOperationInfo(0,CATEGORY_HANDES,nil,0,tp,1) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) +end +function s.selfspop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local exc=c:IsRelateToEffect(e) and c or nil + if Duel.DiscardHand(tp,s.selfspdiscardfilter,1,1,REASON_DISCARD|REASON_EFFECT,exc)>0 and c:IsRelateToEffect(e) + and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP_ATTACK|POS_FACEDOWN_DEFENSE)>0 + and c:IsFacedown() then + Duel.ConfirmCards(1-tp,c) + end +end +function s.gyspfilter(c,e,tp) + return c:IsType(TYPE_FLIP) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEDOWN_DEFENSE) +end +function s.gysptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.gyspfilter(chkc,e,tp) end + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingTarget(s.gyspfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectTarget(tp,s.gyspfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,0) +end +function s.gyspop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEDOWN_DEFENSE)>0 then + Duel.ConfirmCards(1-tp,tc) + end +end \ No newline at end of file diff --git a/official/c85640370.lua b/official/c85640370.lua new file mode 100644 index 0000000000..d4286f796f --- /dev/null +++ b/official/c85640370.lua @@ -0,0 +1,71 @@ +--舌先減少 +--Tip of the Tongue Reduction +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Negate that opponent's effect that was activated by declaring exactly 1 card name, then you can add 1 card with that name from your Deck to your hand + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_DISABLE+CATEGORY_TOHAND+CATEGORY_SEARCH) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_CHAINING) + e1:SetCondition(s.discon) + e1:SetTarget(s.distg) + e1:SetOperation(s.disop) + c:RegisterEffect(e1) + --Make 1 face-up monster your opponent controls lose 500 ATK + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_ATKCHANGE) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) + e2:SetCode(EVENT_DESTROYED) + e2:SetCondition(s.atkcon) + e2:SetTarget(s.atktg) + e2:SetOperation(s.atkop) + c:RegisterEffect(e2) +end +function s.discon(e,tp,eg,ep,ev,re,r,rp) + local ex,cg,ct,cp,cv=Duel.GetOperationInfo(ev,CATEGORY_ANNOUNCE) + return rp==1-tp and ex and cv&(ANNOUNCE_CARD|ANNOUNCE_CARD_FILTER)>0 and Duel.IsChainDisablable(ev) +end +function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return true end + Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thfilter(c,code) + return c:IsCode(code) and c:IsAbleToHand() +end +function s.disop(e,tp,eg,ep,ev,re,r,rp) + if Duel.NegateEffect(ev) then + local declared_card=Duel.GetChainInfo(ev,CHAININFO_TARGET_PARAM) + if Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil,declared_card) + and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil,declared_card) + if #g>0 then + Duel.BreakEffect() + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end + end + end +end +function s.atkcon(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + return c:IsPreviousPosition(POS_FACEDOWN) and c:IsPreviousControler(tp) and c:IsPreviousLocation(LOCATION_ONFIELD) + and rp==1-tp and c:IsReason(REASON_EFFECT) +end +function s.atktg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsFaceup() end + if chk==0 then return Duel.IsExistingTarget(Card.IsFaceup,tp,0,LOCATION_MZONE,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATKDEF) + Duel.SelectTarget(tp,Card.IsFaceup,tp,0,LOCATION_MZONE,1,1,nil) +end +function s.atkop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and tc:IsFaceup() then + --It loses 500 ATK + tc:UpdateAttack(-500,nil,e:GetHandler()) + end +end \ No newline at end of file diff --git a/official/c85976588.lua b/official/c85976588.lua new file mode 100644 index 0000000000..8288f963b4 --- /dev/null +++ b/official/c85976588.lua @@ -0,0 +1,76 @@ +--耀聖の月詩フォルトナ +--Elvennotes Fortona +--Scripted by Hatter +local s,id=GetID() +function s.initial_effect(c) + --You can Special Summon this card (from your hand) to your center Main Monster Zone + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) + e1:SetCode(EFFECT_SPSUMMON_PROC) + e1:SetRange(LOCATION_HAND) + e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) + e1:SetValue(function() return 0,ZONE_CENTER_MMZ end) + c:RegisterEffect(e1) + --Place 1 "Elvennotes" Continuous Trap from your hand or Deck face-up on your field + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.pltg) + e2:SetOperation(s.plop) + c:RegisterEffect(e2) + --Switch the locations of this card in your Main Monster Zone and the monster in your center Main Monster Zone + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,2)) + e3:SetCategory(CATEGORY_TOHAND) + e3:SetType(EFFECT_TYPE_QUICK_O) + e3:SetCode(EVENT_FREE_CHAIN) + e3:SetRange(LOCATION_MMZONE) + e3:SetCountLimit(1,{id,2}) + e3:SetCondition(function(e,tp) return Duel.IsTurnPlayer(1-tp) end) + e3:SetTarget(s.swtg) + e3:SetOperation(s.swop) + e3:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e3) +end +s.listed_series={SET_ELVENNOTES} +function s.plfilter(c,tp) + return c:IsSetCard(SET_ELVENNOTES) and c:IsContinuousTrap() and not c:IsForbidden() and c:CheckUniqueOnField(tp) +end +function s.pltg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 + and Duel.IsExistingMatchingCard(s.plfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,tp) end +end +function s.plop(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOFIELD) + local sc=Duel.SelectMatchingCard(tp,s.plfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,1,nil,tp):GetFirst() + if sc then + Duel.MoveToField(sc,tp,tp,LOCATION_SZONE,POS_FACEUP,true) + end +end +function s.swtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return not e:GetHandler():IsSequence(2) and Duel.GetFieldCard(tp,LOCATION_MZONE,2) end + Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,PLAYER_EITHER,LOCATION_ONFIELD) +end +function s.rthfilter(c) + return c:IsSpellTrap() and c:IsFaceup() and c:IsAbleToHand() +end +function s.swop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local cc=Duel.GetFieldCard(tp,LOCATION_MZONE,2) + if c:IsRelateToEffect(e) and c:IsInMainMZone(tp) and cc and c~=cc and Duel.SwapSequence(c,cc) then + local g=Duel.GetMatchingGroup(s.rthfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil) + if #g==0 or not Duel.SelectYesNo(tp,aux.Stringid(id,3)) then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) + local sg=g:Select(tp,1,1,nil) + if #sg>0 then + Duel.HintSelection(sg) + Duel.BreakEffect() + Duel.SendtoHand(sg,nil,REASON_EFFECT) + end + end +end \ No newline at end of file diff --git a/official/c86098176.lua b/official/c86098176.lua new file mode 100644 index 0000000000..d45bdb357b --- /dev/null +++ b/official/c86098176.lua @@ -0,0 +1,72 @@ +--バスター・リッチー +--Assault Lich +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --If this card you control would be used as Synchro Material, you can treat it as a non-Tuner + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e1:SetCode(EFFECT_NONTUNER) + e1:SetRange(LOCATION_MZONE) + c:RegisterEffect(e1) + --Special Summon 1 monster that mentions "Assault Mode Activate" or 1 Level 4 or lower Zombie monster from your GY + local e2a=Effect.CreateEffect(c) + e2a:SetDescription(aux.Stringid(id,0)) + e2a:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2a:SetProperty(EFFECT_FLAG_DELAY) + e2a:SetCode(EVENT_SUMMON_SUCCESS) + e2a:SetCountLimit(1,id) + e2a:SetTarget(s.sptg) + e2a:SetOperation(s.spop) + c:RegisterEffect(e2a) + local e2b=e2a:Clone() + e2b:SetCode(EVENT_SPSUMMON_SUCCESS) + c:RegisterEffect(e2b) + --Add 1 "Assault Slash" or "Assault Counter" from your Deck to your hand + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e3:SetProperty(EFFECT_FLAG_DELAY) + e3:SetCode(EVENT_BE_MATERIAL) + e3:SetCountLimit(1,{id,1}) + e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return e:GetHandler():IsLocation(LOCATION_GRAVE) and r==REASON_SYNCHRO end) + e3:SetTarget(s.thtg) + e3:SetOperation(s.thop) + c:RegisterEffect(e3) +end +s.listed_names={CARD_ASSAULT_MODE,40012727,76407432} --"Assault Slash", "Assault Counter" +function s.spfilter(c,e,tp) + return (c:ListsCode(CARD_ASSAULT_MODE) or (c:IsLevelBelow(4) and c:IsRace(RACE_ZOMBIE))) + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_GRAVE,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) +end +function s.spop(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,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end +function s.thfilter(c,e,tp) + return c:IsCode(40012727,76407432) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end \ No newline at end of file diff --git a/official/c86762958.lua b/official/c86762958.lua new file mode 100644 index 0000000000..b6ce5cfa7e --- /dev/null +++ b/official/c86762958.lua @@ -0,0 +1,99 @@ +--アシスト★ヤミー! +--Assist★Yummy! +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Activate + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_ACTIVATE) + e0:SetCode(EVENT_FREE_CHAIN) + e0:SetHintTiming(0,TIMING_MAIN_END|TIMING_BATTLE_START|TIMING_BATTLE_PHASE|TIMING_BATTLE_STEP_END|TIMING_BATTLE_END) + c:RegisterEffect(e0) + --Gain 100 LP, and if you do, your opponent pays 100 LP + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_RECOVER) + e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e1:SetCode(EVENT_PHASE+PHASE_STANDBY) + e1:SetRange(LOCATION_SZONE) + e1:SetCountLimit(1) + e1:SetTarget(s.lptg) + e1:SetOperation(s.lpop) + c:RegisterEffect(e1) + --Return 1 card from the field or GY to the hand + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TOHAND) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_SZONE) + e2:SetCountLimit(1,id) + e2:SetCondition(function(e,tp) return Duel.IsMainPhase() or Duel.IsBattlePhase(1-tp) end) + e2:SetCost(s.retthcost) + e2:SetTarget(s.retthtg) + e2:SetOperation(s.retthop) + e2:SetHintTiming(0,TIMING_MAIN_END|TIMING_BATTLE_START|TIMING_BATTLE_PHASE|TIMING_BATTLE_STEP_END|TIMING_BATTLE_END) + c:RegisterEffect(e2) + --Send 1 "Yummy" card from your Deck to the GY + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,2)) + e3:SetCategory(CATEGORY_TOGRAVE) + e3:SetType(EFFECT_TYPE_QUICK_O) + e3:SetCode(EVENT_FREE_CHAIN) + e3:SetRange(LOCATION_GRAVE) + e3:SetCountLimit(1,id) + e3:SetCost(Cost.SelfBanish) + e3:SetTarget(s.tgtg) + e3:SetOperation(s.tgop) + e3:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e3) +end +s.listed_names={id} +s.listed_series={SET_YUMMY} +function s.lptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.CheckLPCost(1-tp,100) end + Duel.SetOperationInfo(0,CATEGORY_RECOVER,nil,0,tp,100) +end +function s.lpop(e,tp,eg,ep,ev,re,r,rp) + if Duel.Recover(tp,100,REASON_EFFECT)>0 and Duel.CheckLPCost(1-tp,100) then + Duel.PayLPCost(1-tp,100) + end +end +function s.costfilter(c,exc) + return c:IsSetCard(SET_YUMMY) and c:IsFaceup() and c:IsAbleToGraveAsCost() + and Duel.IsExistingMatchingCard(Card.IsAbleToHand,0,LOCATION_ONFIELD|LOCATION_GRAVE,LOCATION_ONFIELD|LOCATION_GRAVE,1,c+c:GetEquipGroup()+exc) +end +function s.retthcost(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return c:IsStatus(STATUS_EFFECT_ENABLED) and c:IsAbleToGraveAsCost() + and Duel.IsExistingMatchingCard(s.costfilter,tp,LOCATION_ONFIELD,0,1,c,c) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local g=Duel.SelectMatchingCard(tp,s.costfilter,tp,LOCATION_ONFIELD,0,1,1,c,c) + Duel.SendtoGrave(g+c,REASON_COST) +end +function s.retthtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToHand,tp,LOCATION_ONFIELD|LOCATION_GRAVE,LOCATION_ONFIELD|LOCATION_GRAVE,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_ONFIELD|LOCATION_GRAVE) +end +function s.retthop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) + local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(Card.IsAbleToHand),tp,LOCATION_ONFIELD|LOCATION_GRAVE,LOCATION_ONFIELD|LOCATION_GRAVE,1,1,nil) + if #g>0 then + Duel.HintSelection(g) + Duel.SendtoHand(g,nil,REASON_EFFECT) + end +end +function s.tgfilter(c) + return c:IsSetCard(SET_YUMMY) and c:IsAbleToGrave() and not c:IsCode(id) +end +function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.tgfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) +end +function s.tgop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local g=Duel.SelectMatchingCard(tp,s.tgfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoGrave(g,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c87607094.lua b/official/c87607094.lua new file mode 100644 index 0000000000..1ce421066e --- /dev/null +++ b/official/c87607094.lua @@ -0,0 +1,59 @@ +--ヴァレル・リブート +--Borrel Reboot +--Scripted by ahtelel +local s,id=GetID() +function s.initial_effect(c) + --Negate the activation of an opponent's Spell/Trap Card, and if you do, Set that card + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_NEGATE) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_CHAINING) + e1:SetCondition(s.condition) + e1:SetCost(s.cost) + e1:SetTarget(s.target) + e1:SetOperation(s.activate) + c:RegisterEffect(e1) + --You can activate this card from your hand by paying half your LP + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_SINGLE) + e2:SetCode(EFFECT_TRAP_ACT_IN_HAND) + e2:SetValue(function(e,c) e:SetLabel(1) end) + c:RegisterEffect(e2) + e1:SetLabelObject(e2) +end +s.listed_series={SET_ROKKET,SET_BORREL} +function s.condition(e,tp,eg,ep,ev,re,r,rp) + return rp==1-tp and re:IsHasType(EFFECT_TYPE_ACTIVATE) and re:IsSpellTrapEffect() and Duel.IsChainNegatable(ev) + and Duel.IsExistingMatchingCard(aux.FaceupFilter(Card.IsSetCard,{SET_ROKKET,SET_BORREL}),tp,LOCATION_MZONE,0,1,nil) +end +function s.cost(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then e:GetLabelObject():SetLabel(0) return true end + if e:GetLabelObject():GetLabel()>0 then + e:GetLabelObject():SetLabel(0) + Duel.PayLPCost(tp,Duel.GetLP(tp)//2) + end +end +function s.target(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return true end + Duel.SetOperationInfo(0,CATEGORY_NEGATE,eg,1,tp,0) +end +function s.activate(e,tp,eg,ep,ev,re,r,rp) + local rc=re:GetHandler() + if Duel.NegateActivation(ev) and rc:IsRelateToEffect(re) and rc:IsSSetable(true) then + rc:CancelToGrave() + Duel.ChangePosition(rc,POS_FACEDOWN) + rc:SetStatus(STATUS_ACTIVATE_DISABLED,false) + rc:SetStatus(STATUS_SET_TURN,false) + Duel.RaiseEvent(rc,EVENT_SSET,e,REASON_EFFECT,tp,tp,0) + --It cannot be activated this turn + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_TRIGGER) + e1:SetReset(RESET_EVENT|RESETS_CANNOT_ACT|RESET_PHASE|PHASE_END) + rc:RegisterEffect(e1) + end +end \ No newline at end of file diff --git a/official/c87814728.lua b/official/c87814728.lua new file mode 100644 index 0000000000..984786a681 --- /dev/null +++ b/official/c87814728.lua @@ -0,0 +1,66 @@ +--磁石の戦士Σ- +--Magnet Warrior Σ- +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Negate an attack involving 2 EARTH monsters + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e1:SetCode(EVENT_ATTACK_ANNOUNCE) + e1:SetRange(LOCATION_MZONE) + e1:SetCountLimit(1) + e1:SetCondition(s.atknegcon) + e1:SetOperation(function() Duel.NegateAttack() end) + c:RegisterEffect(e1) + --Fusion Summon 1 Fusion Monster from your Extra Deck, using Rock monsters from your hand or field, including this card in your hand + local fusion_params={ + handler=c, + matfilter=function(c) return c:IsRace(RACE_ROCK) end, + gc=Fusion.ForcedHandler + } + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_FUSION_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_HAND) + e2:SetCountLimit(1,id) + e2:SetCost(Cost.SelfReveal) + e2:SetTarget(Fusion.SummonEffTG(fusion_params)) + e2:SetOperation(Fusion.SummonEffOP(fusion_params)) + c:RegisterEffect(e2) + --Send 1 Level 8 "Magna Warrior" monster from your Deck to your GY + local e3a=Effect.CreateEffect(c) + e3a:SetDescription(aux.Stringid(id,2)) + e3a:SetCategory(CATEGORY_TOGRAVE) + e3a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e3a:SetProperty(EFFECT_FLAG_DELAY) + e3a:SetCode(EVENT_SUMMON_SUCCESS) + e3a:SetCountLimit(1,{id,1}) + e3a:SetTarget(s.tgtg) + e3a:SetOperation(s.tgop) + c:RegisterEffect(e3a) + local e3b=e3a:Clone() + e3b:SetCode(EVENT_SPSUMMON_SUCCESS) + c:RegisterEffect(e3b) +end +s.listed_series={SET_MAGNA_WARRIOR} +function s.atknegcon(e,tp,eg,ep,ev,re,r,rp) + local bc1=Duel.GetAttacker() + local bc2=Duel.GetAttackTarget() + return bc1:IsAttribute(ATTRIBUTE_EARTH) and bc2 and bc2:IsAttribute(ATTRIBUTE_EARTH) and bc2:IsFaceup() +end +function s.tgfilter(c) + return c:IsLevel(8) and c:IsSetCard(SET_MAGNA_WARRIOR) and c:IsAbleToGrave() +end +function s.tgtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.tgfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK) +end +function s.tgop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local g=Duel.SelectMatchingCard(tp,s.tgfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoGrave(g,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/official/c87985506.lua b/official/c87985506.lua new file mode 100644 index 0000000000..1cfe0dc4b8 --- /dev/null +++ b/official/c87985506.lua @@ -0,0 +1,57 @@ +--デーモンの諧謔 +--Archfiend's Jest +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Special Summon 1 Level 7 or lower "Archfiend" monster from your hand or Deck, or if you have a face-up "Archfiend" Ritual Monster in your Extra Deck, you can Special Summon 1 "Royal Archfiend", 1 "Duke Archfiend", and/or 1 "Highness Archfiend" from your hand and/or Deck instead + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) + e1:SetTarget(s.target) + e1:SetOperation(s.activate) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) +end +s.listed_series={SET_ARCHFIEND} +s.listed_names={58769832,85154941,11248645} --"Royal Archfiend", "Duke Archfiend", "Highness Archfiend" +function s.spfilter(c,e,tp,ex_chk) + return ((c:IsLevelBelow(7) and c:IsSetCard(SET_ARCHFIEND)) or (ex_chk and c:IsCode(58769832,85154941,11248645))) + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.archritfilter(c) + return c:IsSetCard(SET_ARCHFIEND) and c:IsRitualMonster() and c:IsFaceup() +end +function s.target(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then + local ex_chk=Duel.IsExistingMatchingCard(s.archritfilter,tp,LOCATION_EXTRA,0,1,nil) + return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,1,nil,e,tp,ex_chk) + end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_DECK) +end +function s.rescon(ex_chk) + return function(sg,e,tp,mg) + return #sg==1 or (ex_chk and #sg<=3 and sg:FilterCount(Card.IsCode,nil,58769832,85154941,11248645)==#sg and sg:GetClassCount(Card.GetCode)==#sg) + end +end +function s.activate(e,tp,eg,ep,ev,re,r,rp) + local ft=Duel.GetLocationCount(tp,LOCATION_MZONE) + if ft<=0 then return end + local ex_chk=Duel.IsExistingMatchingCard(s.archritfilter,tp,LOCATION_EXTRA,0,1,nil) + local g=Duel.GetMatchingGroup(s.spfilter,tp,LOCATION_HAND|LOCATION_DECK,0,nil,e,tp,ex_chk) + if #g==0 then return end + if not ex_chk then + ft=1 + else + ft=math.min(ft,3) + if Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) then ft=1 end + end + local rescon=s.rescon(ex_chk) + local sg=aux.SelectUnselectGroup(g,e,tp,1,ft,rescon,1,tp,HINTMSG_SPSUMMON,rescon) + if #sg>0 then + Duel.SpecialSummon(sg,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/official/c90764871.lua b/official/c90764871.lua new file mode 100644 index 0000000000..27956a0b26 --- /dev/null +++ b/official/c90764871.lua @@ -0,0 +1,78 @@ +--デーモンの盤上遊戯 +--Archfiend's Strategy Game +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Activate + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_ACTIVATE) + e0:SetCode(EVENT_FREE_CHAIN) + c:RegisterEffect(e0) + --Fiend monsters in the Extra Monster Zone gain 1000 ATK + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetCode(EFFECT_UPDATE_ATTACK) + e1:SetRange(LOCATION_FZONE) + e1:SetTargetRange(LOCATION_EMZONE,LOCATION_EMZONE) + e1:SetTarget(function(e,c) return c:IsRace(RACE_FIEND) end) + e1:SetValue(1000) + c:RegisterEffect(e1) + --Activate 1 of these effects + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_FZONE) + e2:SetCountLimit(1,id) + e2:SetTarget(s.efftg) + e2:SetOperation(s.effop) + c:RegisterEffect(e2) +end +s.listed_series={SET_ARCHFIEND} +function s.costfilter(c) + return (c:IsRace(RACE_FIEND) or c:IsSetCard(SET_ARCHFIEND)) and c:IsAbleToRemoveAsCost() +end +function s.thfilter(c) + return c:IsSetCard(SET_ARCHFIEND) and not c:IsFieldSpell() and c:IsAbleToHand() +end +function s.tedfilter(c) + return c:IsSetCard(SET_ARCHFIEND) and c:IsPendulumMonster() +end +function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) + local b1=Duel.IsExistingMatchingCard(s.costfilter,tp,LOCATION_HAND|LOCATION_GRAVE,0,1,nil) + and Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) + local b2=Duel.IsExistingMatchingCard(s.tedfilter,tp,LOCATION_DECK,0,1,nil) + if chk==0 then return b1 or b2 end + local op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,1)}, + {b2,aux.Stringid(id,2)}) + e:SetLabel(op) + if op==1 then + e:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) + local g=Duel.SelectMatchingCard(tp,s.costfilter,tp,LOCATION_HAND|LOCATION_GRAVE,0,1,1,nil) + Duel.Remove(g,POS_FACEUP,REASON_COST) + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) + elseif op==2 then + e:SetCategory(CATEGORY_TOEXTRA) + Duel.SetOperationInfo(0,CATEGORY_TOEXTRA,nil,1,tp,LOCATION_DECK) + end +end +function s.effop(e,tp,eg,ep,ev,re,r,rp) + local op=e:GetLabel() + if op==1 then + --Add 1 "Archfiend" card from your Deck to your hand, except a Field Spell + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end + elseif op==2 then + --Add 1 "Archfiend" Pendulum Monster from your Deck to your Extra Deck face-up + Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(id,3)) + local g=Duel.SelectMatchingCard(tp,s.tedfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoExtraP(g,tp,REASON_EFFECT) + end + end +end \ No newline at end of file diff --git a/official/c90880453.lua b/official/c90880453.lua new file mode 100644 index 0000000000..06df9d6e33 --- /dev/null +++ b/official/c90880453.lua @@ -0,0 +1,53 @@ +--エルフェンノーツ~再邂のテルチェット~ +--Elvennotes ~Reunion Tercet~ +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Activate + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_ACTIVATE) + e0:SetCode(EVENT_FREE_CHAIN) + c:RegisterEffect(e0) + --Your opponent cannot target the monster in your center Main Monster Zone with card effects + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE) + e1:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET) + e1:SetRange(LOCATION_SZONE) + e1:SetTargetRange(LOCATION_MZONE,0) + e1:SetTarget(function(e,c) return c:IsSequence(2) end) + e1:SetValue(aux.tgoval) + c:RegisterEffect(e1) + --● FIRE/EARTH: If your Synchro Monster attacks a Defense Position monster, inflict piercing battle damage to your opponent + local e2=Effect.CreateEffect(c) + e2:SetType(EFFECT_TYPE_FIELD) + e2:SetCode(EFFECT_PIERCE) + e2:SetRange(LOCATION_SZONE) + e2:SetTargetRange(LOCATION_MZONE,0) + e2:SetTarget(function(e,c) return c:IsSynchroMonster() end) + e2:SetCondition(s.effcon) + e2:SetLabel(ATTRIBUTE_FIRE|ATTRIBUTE_EARTH) + c:RegisterEffect(e2) + --● WATER/WIND: Other face-up Spells/Traps you control cannot be destroyed by your opponent's card effects + local e3=e2:Clone() + e3:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) + e3:SetTargetRange(LOCATION_ONFIELD,0) + e3:SetTarget(function(e,c) return c:IsSpellTrap() and c~=e:GetHandler() end) + e3:SetValue(aux.indoval) + e3:SetLabel(ATTRIBUTE_WATER|ATTRIBUTE_WIND) + c:RegisterEffect(e3) + --● LIGHT/DARK: You take no battle damage + local e4=e2:Clone() + e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET) + e4:SetCode(EFFECT_AVOID_BATTLE_DAMAGE) + e4:SetTargetRange(1,0) + e4:SetTarget(aux.TRUE) + e4:SetLabel(ATTRIBUTE_LIGHT|ATTRIBUTE_DARK) + c:RegisterEffect(e4) +end +function s.effconfilter(c,attr) + return c:IsSequence(2) and c:IsAttribute(attr) and c:IsFaceup() +end +function s.effcon(e) + return Duel.IsExistingMatchingCard(s.effconfilter,e:GetHandlerPlayer(),LOCATION_MMZONE,0,1,nil,e:GetLabel()) +end \ No newline at end of file diff --git a/official/c91002901.lua b/official/c91002901.lua new file mode 100644 index 0000000000..1fefef03cc --- /dev/null +++ b/official/c91002901.lua @@ -0,0 +1,81 @@ +--決闘進化-バスター・ゾーン +--Duel Evolution - Assault Zone +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --When this card is activated: You can add 1 monster that mentions "Assault Mode Activate" from your Deck or GY to your hand + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) + e1:SetTarget(s.target) + e1:SetOperation(s.activate) + c:RegisterEffect(e1) + --"/Assault Mode" monsters cannot be destroyed by battle or your opponent's card effects during the turn they are Special Summoned + local e2a=Effect.CreateEffect(c) + e2a:SetType(EFFECT_TYPE_FIELD) + e2a:SetCode(EFFECT_INDESTRUCTABLE_BATTLE) + e2a:SetRange(LOCATION_FZONE) + e2a:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) + e2a:SetTarget(function(e,c) return c:IsSetCard(SET_ASSAULT_MODE) and c:IsStatus(STATUS_SPSUMMON_TURN) end) + e2a:SetValue(1) + c:RegisterEffect(e2a) + local e2b=e2a:Clone() + e2b:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) + e2b:SetValue(aux.indoval) + c:RegisterEffect(e2b) + --Apply an "once this turn, you can activate "Assault Mode Activate" by Tributing a Synchro Monster in the Extra Deck" effect + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetType(EFFECT_TYPE_IGNITION) + e3:SetRange(LOCATION_FZONE) + e3:SetCost(Cost.PayLP(2000)) + e3:SetCountLimit(1,{id,1}) + e3:SetOperation(s.effop) + c:RegisterEffect(e3) +end +s.listed_names={CARD_ASSAULT_MODE} +s.listed_series={SET_ASSAULT_MODE} +function s.thfilter(c) + return c:IsMonster() and c:ListsCode(CARD_ASSAULT_MODE) and c:IsAbleToHand() +end +function s.target(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return true end + Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) +end +function s.activate(e,tp,eg,ep,ev,re,r,rp) + local g=Duel.GetMatchingGroup(aux.NecroValleyFilter(s.thfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,nil) + if #g>0 and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local sg=g:Select(tp,1,1,nil) + Duel.SendtoHand(sg,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,sg) + end +end +function s.effop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + aux.RegisterClientHint(c,nil,tp,1,0,aux.Stringid(id,3)) + --Once this turn, you can activate "Assault Mode Activate" by Tributing a Synchro Monster in the Extra Deck + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE+EFFECT_FLAG_IGNORE_IMMUNE) + e1:SetCode(EFFECT_EXTRA_RELEASE_NONSUM) + e1:SetTargetRange(LOCATION_EXTRA,0) + e1:SetCondition(function(e) return not Duel.HasFlagEffect(e:GetHandlerPlayer(),id) end) + e1:SetValue(s.relval) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) + --Manually handling the OPT of the above effect + local e2=Effect.CreateEffect(c) + e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) + e2:SetCode(EVENT_RELEASE) + e2:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return s.relval(e,re,r) and eg:IsExists(Card.IsPreviousLocation,1,nil,LOCATION_EXTRA) end) + e2:SetOperation(function(e,tp) Duel.RegisterFlagEffect(tp,id,RESET_PHASE|PHASE_END,0,1) end) + e2:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e2,tp) +end +function s.relval(e,re,r,rp) + return re and re:IsActivated() and (r&REASON_COST)>0 and re:GetHandler():IsCode(CARD_ASSAULT_MODE) +end \ No newline at end of file diff --git a/official/c98829635.lua b/official/c98829635.lua new file mode 100644 index 0000000000..34820d8b3e --- /dev/null +++ b/official/c98829635.lua @@ -0,0 +1,65 @@ +--禁じられた聖冠 +--Forbidden Crown +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + --Apply these effects to 1 face-up monster on the field, until the end of this turn + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_DISABLE) + e1:SetType(EFFECT_TYPE_ACTIVATE) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) + e1:SetTarget(s.target) + e1:SetOperation(s.activate) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) +end +function s.target(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(aux.FaceupFilter(aux.NOT(Card.HasFlagEffect),id),tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end + Duel.SetChainLimit(function(te) return not te:IsMonsterEffect() end) + Duel.SetOperationInfo(0,CATEGORY_DISABLE,nil,1,PLAYER_EITHER,LOCATION_MZONE) +end +function s.activate(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_APPLYTO) + local sc=Duel.SelectMatchingCard(tp,aux.FaceupFilter(aux.NOT(Card.HasFlagEffect),id),tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil):GetFirst() + if sc then + Duel.HintSelection(sc) + local c=e:GetHandler() + sc:RegisterFlagEffect(id,RESETS_STANDARD_PHASE_END,EFFECT_FLAG_CLIENT_HINT,1,0,aux.Stringid(id,1)) + --Its effects are negated + sc:NegateEffects(c,RESETS_STANDARD_PHASE_END) + --It cannot attack + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_CANNOT_ATTACK) + e1:SetReset(RESETS_STANDARD_PHASE_END) + sc:RegisterEffect(e1) + --It cannot be destroyed by battle or card effects + local e2=e1:Clone() + e2:SetCode(EFFECT_INDESTRUCTABLE_BATTLE) + e2:SetValue(1) + sc:RegisterEffect(e2) + local e3=e2:Clone() + e3:SetCode(EFFECT_INDESTRUCTABLE_EFFECT) + sc:RegisterEffect(e3) + --It is unaffected by other cards' activated effects, except its own + local e4=e1:Clone() + e4:SetCode(EFFECT_IMMUNE_EFFECT) + e4:SetValue(function(e,re) return re:IsActivated() and e:GetHandler()~=re:GetOwner() end) + sc:RegisterEffect(e4) + --It cannot be Tributed + local e5=e2:Clone() + e5:SetCode(EFFECT_UNRELEASABLE_SUM) + sc:RegisterEffect(e5) + local e6=e2:Clone() + e6:SetCode(EFFECT_UNRELEASABLE_NONSUM) + sc:RegisterEffect(e6) + --It cannot be used as material for a Fusion, Synchro, Xyz, or Link Summon + local e7=e1:Clone() + e7:SetCode(EFFECT_CANNOT_BE_MATERIAL) + e7:SetValue(aux.cannotmatfilter(SUMMON_TYPE_FUSION,SUMMON_TYPE_SYNCHRO,SUMMON_TYPE_XYZ,SUMMON_TYPE_LINK)) + sc:RegisterEffect(e7) + end +end \ No newline at end of file diff --git a/official/c98937206.lua b/official/c98937206.lua new file mode 100644 index 0000000000..a334ada03a --- /dev/null +++ b/official/c98937206.lua @@ -0,0 +1,77 @@ +--ヴァレット・デトネイター +--Rokket Detonator +--Scripted by ahtelel +local s,id=GetID() +function s.initial_effect(c) + --If you control a DARK Dragon Link Monster, you can Special Summon this card (from your hand) + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_UNCOPYABLE) + e1:SetCode(EFFECT_SPSUMMON_PROC) + e1:SetRange(LOCATION_HAND) + e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) + e1:SetCondition(s.selfspcon) + c:RegisterEffect(e1) + --Special Summon 1 DARK Dragon Monster Card from your Spell & Trap Zone + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + c:RegisterEffect(e2) +end +function s.selfspconfilter(c) + return c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_DRAGON) and c:IsLinkMonster() and c:IsFaceup() +end +function s.selfspcon(e,c) + if c==nil then return true end + local tp=c:GetControler() + return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.selfspconfilter,tp,LOCATION_MZONE,0,1,nil) +end +function s.spfilter(c,e,tp) + return c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_DRAGON) and c:IsMonsterCard() and c:IsFaceup() + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_STZONE) and chkc:IsControler(tp) and s.spfilter(chkc,e,tp) end + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingTarget(s.spfilter,tp,LOCATION_STZONE,0,1,nil,e,tp) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectTarget(tp,s.spfilter,tp,LOCATION_STZONE,0,1,1,nil,e,tp) + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,tp,0) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP) then + --It cannot attack + local e1=Effect.CreateEffect(c) + e1:SetDescription(3206) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_ATTACK) + e1:SetReset(RESET_EVENT|RESETS_STANDARD) + tc:RegisterEffect(e1,true) + --Its effects are negated + tc:NegateEffects(c) + end + Duel.SpecialSummonComplete() + --You cannot Special Summon from the Extra Deck for the rest of this turn, except DARK monsters + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,2)) + e2:SetType(EFFECT_TYPE_FIELD) + e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e2:SetTargetRange(1,0) + e2:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsAttribute(ATTRIBUTE_DARK) end) + e2:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e2,tp) + --"Clock Lizard" check + aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalAttribute(ATTRIBUTE_DARK) end) +end \ No newline at end of file diff --git a/official/c99941223.lua b/official/c99941223.lua new file mode 100644 index 0000000000..36bc1fcae5 --- /dev/null +++ b/official/c99941223.lua @@ -0,0 +1,48 @@ +--佚楽の堕天使 +--Darklord Dance +--Scripted by The Razgriz +local s,id=GetID() +function s.initial_effect(c) + --Fusion Summon 1 DARK Fairy Fusion Monster from your Extra Deck, by banishing its materials from your hand, field, and/or GY, and if you do, it gains 1000 ATK + local e1=Fusion.CreateSummonEff({ + handler=c, + fusfilter=s.fusfilter, + matfilter=Card.IsAbleToRemove, + extrafil=s.fextra, + extraop=Fusion.BanishMaterial, + extratg=s.extratg, + stage2=s.stage2 + }) + e1:SetCountLimit(1,id,EFFECT_COUNT_CODE_OATH) + c:RegisterEffect(e1) +end +s.listed_series={SET_DARKLORD} +function s.fusfilter(c) + return c:IsAttribute(ATTRIBUTE_DARK) and c:IsRace(RACE_FAIRY) +end +function s.fcheck(tp,sg,fc) + return fc:IsSetCard(SET_DARKLORD) or not sg:IsExists(Card.IsControler,1,nil,1-tp) +end +function s.fextrafilter(c,tp) + return c:IsMonster() and c:IsAbleToRemove() and (c:IsControler(tp) or (c:IsSetCard(SET_DARKLORD) and c:IsFaceup())) +end +function s.fextra(e,tp,mg) + if Duel.IsPlayerAffectedByEffect(tp,CARD_SPIRIT_ELIMINATION) then return nil,s.fcheck end + return Duel.GetMatchingGroup(s.fextrafilter,tp,LOCATION_GRAVE,LOCATION_MZONE,nil,tp),s.fcheck +end +function s.extratg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return true end + Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_GRAVE) +end +function s.stage2(e,fc,tp,sg,chk) + if chk==0 then + --It gains 1000 ATK + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_UPDATE_ATTACK) + e1:SetValue(1000) + e1:SetReset(RESET_EVENT|RESETS_STANDARD) + fc:RegisterEffect(e1) + end +end \ No newline at end of file diff --git a/pre-release/c100295111.lua b/pre-release/c100295111.lua new file mode 100644 index 0000000000..02734e55ef --- /dev/null +++ b/pre-release/c100295111.lua @@ -0,0 +1,85 @@ +--魔弾の悪魔 カスパール +--Magical Musket Mastermind Caspar +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Link Summon procedure: 2 monsters, including a LIGHT Fiend monster + Link.AddProcedure(c,nil,2,2,s.matcheck) + --Take 2 "Magical Musket" cards from your hand and/or Deck, including a monster, Special Summon 1 of those monsters, and Set the other card to your opponent's field + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetCountLimit(1,id) + e1:SetCondition(function(e) return e:GetHandler():IsLinkSummoned() end) + e1:SetTarget(s.spsettg) + e1:SetOperation(s.spsetop) + c:RegisterEffect(e1) + --During either player's turn, you can activate "Magical Musket" Spell/Trap Cards from your hand. + local e2a=Effect.CreateEffect(c) + e2a:SetType(EFFECT_TYPE_FIELD) + e2a:SetCode(EFFECT_QP_ACT_IN_NTPHAND) + e2a:SetRange(LOCATION_MZONE) + e2a:SetTargetRange(LOCATION_HAND,0) + e2a:SetTarget(aux.TargetBoolFunction(Card.IsSetCard,SET_MAGICAL_MUSKET)) + c:RegisterEffect(e2a) + local e2b=e2a:Clone() + e2b:SetCode(EFFECT_TRAP_ACT_IN_HAND) + c:RegisterEffect(e2b) +end +s.listed_series={SET_MAGICAL_MUSKET} +function s.matfilter(c,lc,sumtype,tp) + return c:IsAttribute(ATTRIBUTE_LIGHT,lc,sumtype,tp) and c:IsRace(RACE_FIEND,lc,sumtype,tp) +end +function s.matcheck(g,lc,sumtype,tp) + return g:IsExists(s.matfilter,1,nil,lc,sumtype,tp) +end +function s.rescon(sg,e,tp,mg) + return sg:IsExists(Card.IsMonster,1,nil) and sg:IsExists(s.spfilter,1,nil,e,tp,sg) +end +function s.spfilter(c,e,tp,sg) + return c:IsCanBeSpecialSummoned(e,0,tp,false,false) and sg:IsExists(s.setfilter,1,c,e,tp,1-tp) +end +function s.setfilter(c,e,tp,opp) + return (Duel.GetMZoneCount(opp)>0 and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEDOWN_DEFENSE,opp)) or c:IsSSetable(false,opp) +end +function s.spsettg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then + if Duel.GetMZoneCount(tp)<=0 then return false end + local g=Duel.GetMatchingGroup(Card.IsSetCard,tp,LOCATION_HAND|LOCATION_DECK,0,nil,SET_MAGICAL_MUSKET) + return aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,0) + end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_DECK) +end +function s.spsetop(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetMZoneCount(tp)<=0 then return end + local g=Duel.GetMatchingGroup(Card.IsSetCard,tp,LOCATION_HAND|LOCATION_DECK,0,nil,SET_MAGICAL_MUSKET) + if #g<2 then return end + local sg=aux.SelectUnselectGroup(g,e,tp,2,2,s.rescon,1,tp,aux.Stringid(id,1)) + if #sg~=2 then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local spg=sg:FilterSelect(tp,s.spfilter,1,1,nil,e,tp,sg) + if #spg>0 and Duel.SpecialSummon(spg,0,tp,tp,false,false,POS_FACEUP)>0 then + local opp=1-tp + local setc=(sg-spg):GetFirst() + local b1=Duel.GetMZoneCount(opp)>0 and setc:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEDOWN_DEFENSE,opp) + local b2=setc:IsSSetable(false,opp) + local op=nil + if b1 and b2 then + op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,2)}, + {b2,aux.Stringid(id,3)}) + else + op=b1 and 1 or 2 + end + if op==1 then + Duel.SpecialSummon(setc,0,tp,opp,false,false,POS_FACEDOWN_DEFENSE) + Duel.ConfirmCards(tp,setc) + elseif op==2 then + Duel.SSet(tp,setc,opp) + end + end +end \ No newline at end of file diff --git a/pre-release/c100447018.lua b/pre-release/c100447018.lua new file mode 100644 index 0000000000..b220ef59ec --- /dev/null +++ b/pre-release/c100447018.lua @@ -0,0 +1,87 @@ +--ドラグニティ-クイリヌス +--Dragunity Quirinus +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Your "Dragunity" monsters cannot be destroyed by battle while this card is equipped with an Equip Card + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetCode(EFFECT_INDESTRUCTABLE_BATTLE) + e1:SetRange(LOCATION_MZONE) + e1:SetTargetRange(LOCATION_MZONE,0) + e1:SetCondition(function(e) return e:GetHandler():HasEquipCard() end) + e1:SetTarget(function(e,c) return c:IsSetCard(SET_DRAGUNITY) end) + e1:SetValue(1) + c:RegisterEffect(e1) + --Add 1 "Dragunity" Spell/Trap from your Deck to your hand + local e2a=Effect.CreateEffect(c) + e2a:SetDescription(aux.Stringid(id,0)) + e2a:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e2a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2a:SetProperty(EFFECT_FLAG_DELAY) + e2a:SetCode(EVENT_SUMMON_SUCCESS) + e2a:SetCountLimit(1,id) + e2a:SetTarget(s.thtg) + e2a:SetOperation(s.thop) + c:RegisterEffect(e2a) + local e2b=e2a:Clone() + e2b:SetCode(EVENT_SPSUMMON_SUCCESS) + c:RegisterEffect(e2b) + --Return 1 "Dragunity" Monster Card you control to the hand/Extra Deck, then you can Special Summon 1 "Dragunity" monster from your hand + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_TOHAND+CATEGORY_TOEXTRA+CATEGORY_SPECIAL_SUMMON) + e3:SetType(EFFECT_TYPE_IGNITION) + e3:SetProperty(EFFECT_FLAG_CARD_TARGET) + e3:SetRange(LOCATION_MZONE) + e3:SetCountLimit(1,{id,1}) + e3:SetTarget(s.thsptg) + e3:SetOperation(s.thspop) + c:RegisterEffect(e3) +end +s.listed_series={SET_DRAGUNITY} +function s.thfilter(c) + return c:IsSetCard(SET_DRAGUNITY) and c:IsSpellTrap() and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end +function s.thorextfilter(c) + return c:IsSetCard(SET_DRAGUNITY) and c:IsMonsterCard() and c:IsFaceup() and (c:IsAbleToHand() or c:IsAbleToExtra()) +end +function s.thsptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + local c=e:GetHandler() + if chkc then return chkc:IsOnField() and chkc:IsControler(tp) and s.thorextfilter(chkc) and chkc~=c end + if chk==0 then return Duel.IsExistingTarget(s.thorextfilter,tp,LOCATION_ONFIELD,0,1,c) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND) + local g=Duel.SelectTarget(tp,s.thorextfilter,tp,LOCATION_ONFIELD,0,1,1,c) + Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,tp,0) + Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND) +end +function s.spfilter(c,e,tp) + return c:IsSetCard(SET_DRAGUNITY) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.thspop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) and Duel.SendtoHand(tc,nil,REASON_EFFECT)>0 and tc:IsLocation(LOCATION_HAND|LOCATION_EXTRA) then + if tc:IsLocation(LOCATION_HAND) then Duel.ShuffleHand(tp) end + if Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND,0,1,nil,e,tp) + and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON) + local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_HAND,0,1,1,nil,e,tp) + if #g>0 then + Duel.BreakEffect() + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end + end + end +end \ No newline at end of file diff --git a/pre-release/c100447019.lua b/pre-release/c100447019.lua new file mode 100644 index 0000000000..39602b3ee3 --- /dev/null +++ b/pre-release/c100447019.lua @@ -0,0 +1,78 @@ +--ドラグニティ-ファルシオン +--Dragunity Falchion +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Equip 1 Dragon "Dragunity" monster from your Deck or GY to 1 "Dragunity" monster you control as an Equip Spell + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_EQUIP) + e1:SetType(EFFECT_TYPE_IGNITION) + e1:SetProperty(EFFECT_FLAG_CARD_TARGET) + e1:SetRange(LOCATION_HAND|LOCATION_GRAVE) + e1:SetCountLimit(1,id) + e1:SetCost(Cost.SelfBanish) + e1:SetTarget(s.eqtg) + e1:SetOperation(s.eqop) + c:RegisterEffect(e1) + --Banish 1 face-up card your opponent controls + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_REMOVE) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_SZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(s.rmcon) + e2:SetCost(Cost.SelfToGrave) + e2:SetTarget(s.rmtg) + e2:SetOperation(s.rmop) + c:RegisterEffect(e2) +end +s.listed_series={SET_DRAGUNITY} +function s.eqfilter(c,tp) + return c:IsRace(RACE_DRAGON) and c:IsSetCard(SET_DRAGUNITY) and c:CheckUniqueOnField(tp) and not c:IsForbidden() +end +function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsSetCard(SET_DRAGUNITY) and chkc:IsFaceup() end + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 + and Duel.IsExistingTarget(aux.FaceupFilter(Card.IsSetCard,SET_DRAGUNITY),tp,LOCATION_MZONE,0,1,nil) + and Duel.IsExistingMatchingCard(s.eqfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,e:GetHandler(),tp) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) + Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsSetCard,SET_DRAGUNITY),tp,LOCATION_MZONE,0,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_EQUIP,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) +end +function s.eqop(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end + local tc=Duel.GetFirstTarget() + if tc:IsFacedown() or not tc:IsRelateToEffect(e) then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) + local ec=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.eqfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil,tp):GetFirst() + if ec and Duel.Equip(tp,ec,tc) then + --Equip limit + local e1=Effect.CreateEffect(ec) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_EQUIP_LIMIT) + e1:SetValue(function(e,c) return c==tc end) + e1:SetReset(RESET_EVENT|RESETS_STANDARD) + ec:RegisterEffect(e1) + end +end +function s.rmcon(e,tp,eg,ep,ev,re,r,rp) + local ec=e:GetHandler():GetEquipTarget() + return ec and ec:IsSetCard(SET_DRAGUNITY) +end +function s.rmtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsOnField() and chkc:IsControler(1-tp) and chkc:IsAbleToRemove() and chkc:IsFaceup() end + if chk==0 then return Duel.IsExistingTarget(aux.FaceupFilter(Card.IsAbleToRemove),tp,0,LOCATION_ONFIELD,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) + local g=Duel.SelectTarget(tp,aux.FaceupFilter(Card.IsAbleToRemove),tp,0,LOCATION_ONFIELD,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_REMOVE,g,1,tp,0) +end +function s.rmop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) then + Duel.Remove(tc,POS_FACEUP,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/pre-release/c100447020.lua b/pre-release/c100447020.lua new file mode 100644 index 0000000000..20fd810c77 --- /dev/null +++ b/pre-release/c100447020.lua @@ -0,0 +1,79 @@ +--ドラグニティナイト-アーレウス +--Dragunity Knight - Areus +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Synchro Summon procedure: 1 Tuner + 1+ non-Tuner Synchro Monsters + Synchro.AddProcedure(c,nil,1,1,Synchro.NonTunerEx(Card.IsType,TYPE_SYNCHRO),1,99) + --Negate the effects of face-up cards your opponent controls, up to the number of face-up Monster Cards in your Spell & Trap Zone, until the end of this turn + local e1a=Effect.CreateEffect(c) + e1a:SetDescription(aux.Stringid(id,0)) + e1a:SetCategory(CATEGORY_DISABLE) + e1a:SetType(EFFECT_TYPE_IGNITION) + e1a:SetProperty(EFFECT_FLAG_CARD_TARGET) + e1a:SetRange(LOCATION_MZONE) + e1a:SetCountLimit(1,id) + e1a:SetCondition(function(e) return not e:GetHandler():HasEquipCard() end) + e1a:SetTarget(s.distg) + e1a:SetOperation(s.disop) + c:RegisterEffect(e1a) + --This is a Quick Effect if this card is equipped with an Equip Card + local e1b=e1a:Clone() + e1b:SetType(EFFECT_TYPE_QUICK_O) + e1b:SetCode(EVENT_FREE_CHAIN) + e1b:SetCondition(function(e) return e:GetHandler():HasEquipCard() end) + e1b:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER) + c:RegisterEffect(e1b) + --Special Summon this card, then you can Special Summon 1 "Dragunity" Tuner from your GY + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_SZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(function(e) return e:GetHandler():GetEquipTarget() end) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + c:RegisterEffect(e2) +end +s.listed_series={SET_DRAGUNITY} +function s.distg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsOnField() and chkc:IsControler(1-tp) and chkc:IsNegatable() end + local ct=Duel.GetMatchingGroupCount(aux.FaceupFilter(Card.IsMonsterCard),tp,LOCATION_STZONE,0,nil) + if chk==0 then return ct>0 and Duel.IsExistingTarget(Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_NEGATE) + local g=Duel.SelectTarget(tp,Card.IsNegatable,tp,0,LOCATION_ONFIELD,1,ct,nil) + Duel.SetOperationInfo(0,CATEGORY_DISABLE,g,1,tp,0) +end +function s.disop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local tg=Duel.GetTargetCards(e) + for tc in tg:Iter() do + --Negate their effects until the end of this turn + tc:NegateEffects(c,RESETS_STANDARD_PHASE_END,true) + end +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) + Duel.SetPossibleOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_GRAVE) +end +function s.spfilter(c,e,tp) + return c:IsSetCard(SET_DRAGUNITY) and c:IsType(TYPE_TUNER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 + and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(aux.NecroValleyFilter(s.spfilter),tp,LOCATION_GRAVE,0,1,nil,e,tp) + and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_GRAVE,0,1,1,nil,e,tp) + if #g>0 then + Duel.BreakEffect() + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end + end +end \ No newline at end of file diff --git a/pre-release/c100447021.lua b/pre-release/c100447021.lua new file mode 100644 index 0000000000..eae2f39b0f --- /dev/null +++ b/pre-release/c100447021.lua @@ -0,0 +1,78 @@ +--ドラグニティロード-ゲオルギアス +--Dragunity Lord - Georgius +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Link Summon procedure: 2+ monsters, including a Tuner + Link.AddProcedure(c,nil,2,4,s.tunermatcheck) + --Your opponent cannot activate the effects of monsters in the GY while this card is equipped with a "Dragunity" card + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET) + e1:SetCode(EFFECT_CANNOT_ACTIVATE) + e1:SetRange(LOCATION_MZONE) + e1:SetTargetRange(0,1) + e1:SetCondition(function(e) return e:GetHandler():GetEquipGroup():IsExists(Card.IsSetCard,1,nil,SET_DRAGUNITY) end) + e1:SetValue(function(e,re,tp) return re:IsMonsterEffect() and re:GetHandler():IsLocation(LOCATION_GRAVE) end) + c:RegisterEffect(e1) + --Special Summon 1 Level 5 or higher "Dragunity" monster from your Extra Deck or GY + local e2a=Effect.CreateEffect(c) + e2a:SetDescription(aux.Stringid(id,0)) + e2a:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2a:SetProperty(EFFECT_FLAG_DELAY) + e2a:SetCode(EVENT_SPSUMMON_SUCCESS) + e2a:SetCountLimit(1,id) + e2a:SetCondition(function(e) return e:GetHandler():IsLinkSummoned() end) + e2a:SetTarget(s.sptg) + e2a:SetOperation(s.spop) + c:RegisterEffect(e2a) + local e2b=e2a:Clone() + e2b:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e2b:SetRange(LOCATION_MZONE) + e2b:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return not eg:IsContains(e:GetHandler()) and eg:IsExists(Card.IsSummonPlayer,1,nil,1-tp) end) + c:RegisterEffect(e2b) + --Negate an opponent's activated Spell/Trap Card or effect + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_DISABLE) + e3:SetType(EFFECT_TYPE_QUICK_O) + e3:SetCode(EVENT_CHAINING) + e3:SetRange(LOCATION_MZONE) + e3:SetCountLimit(1,{id,1}) + e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return ep==1-tp and re:IsSpellTrapEffect() and Duel.IsChainDisablable(ev) end) + e3:SetCost(s.discost) + e3:SetTarget(function(e,tp,eg,ep,ev,re,r,rp,chk) if chk==0 then return true end Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,tp,0) end) + e3:SetOperation(function(e,tp,eg,ep,ev,re,r,rp) Duel.NegateEffect(ev) end) + c:RegisterEffect(e3) + aux.DoubleSnareValidity(c,LOCATION_MZONE) +end +s.listed_series={SET_DRAGUNITY} +function s.tunermatcheck(g,lc,sumtype,tp) + return g:IsExists(Card.IsType,1,nil,TYPE_TUNER,lc,sumtype,tp) +end +function s.spfilter(c,e,tp,mmz_chk) + if not (c:IsLevelAbove(5) and c:IsSetCard(SET_DRAGUNITY) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)) then return false end + if c:IsLocation(LOCATION_EXTRA) then + return Duel.GetLocationCountFromEx(tp,tp,nil,c)>0 + else + return mmz_chk + end +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_EXTRA|LOCATION_GRAVE,0,1,nil,e,tp,Duel.GetLocationCount(tp,LOCATION_MZONE)>0) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA|LOCATION_GRAVE) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.spfilter),tp,LOCATION_EXTRA|LOCATION_GRAVE,0,1,1,nil,e,tp,Duel.GetLocationCount(tp,LOCATION_MZONE)>0) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end +function s.discost(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(aux.AND(Card.IsEquipCard,Card.IsAbleToGraveAsCost),tp,LOCATION_ONFIELD,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE) + local g=Duel.SelectMatchingCard(tp,aux.AND(Card.IsEquipCard,Card.IsAbleToGraveAsCost),tp,LOCATION_ONFIELD,0,1,1,nil) + Duel.SendtoGrave(g,REASON_COST) +end \ No newline at end of file diff --git a/pre-release/c100447064.lua b/pre-release/c100447064.lua new file mode 100644 index 0000000000..c0944ae733 --- /dev/null +++ b/pre-release/c100447064.lua @@ -0,0 +1,81 @@ +--影霊翼騎 ウェンディクルフ +--Reeshaddoll Wendicluhu +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + c:AddMustFirstBeFusionSummoned() + --Fusion Materials: 1 "Shaddoll" monster + 1 WIND monster + Fusion.AddProcMix(c,true,true,aux.FilterBoolFunctionEx(Card.IsSetCard,SET_SHADDOLL),s.matfilter) + --Change any number of face-down monsters on the field to face-up Defense Position + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_POSITION) + e1:SetType(EFFECT_TYPE_QUICK_O) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetRange(LOCATION_MZONE) + e1:SetCountLimit(1,id) + e1:SetTarget(s.postg) + e1:SetOperation(s.posop) + e1:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e1) + --Add 1 "Shaddoll" card from your GY to your hand + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TOHAND) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) + e2:SetCode(EVENT_TO_GRAVE) + e2:SetTarget(s.thtg) + e2:SetOperation(s.thop) + c:RegisterEffect(e2) +end +s.listed_series={SET_SHADDOLL} +s.material_setcode=SET_SHADDOLL +function s.matfilter(c,lc,sumtype,tp) + return c:IsAttribute(ATTRIBUTE_WIND,lc,sumtype,tp) or c:IsHasEffect(4904633) +end +function s.posfilter(c) + return c:IsPosition(POS_FACEDOWN_DEFENSE) and c:IsCanChangePosition() +end +function s.postg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.posfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_POSITION,nil,1,PLAYER_EITHER,LOCATION_MZONE) +end +function s.posop(e,tp,eg,ep,ev,re,r,rp,chk) + local facedown_ct=Duel.GetMatchingGroupCount(s.posfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil) + if facedown_ct==0 then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_POSCHANGE) + local g=Duel.SelectMatchingCard(tp,s.posfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,facedown_ct,nil) + if #g==0 then return end + Duel.HintSelection(g) + if Duel.ChangePosition(g,POS_FACEUP_DEFENSE)==0 then return end + local og=Duel.GetOperatedGroup() + local flip_count=og:FilterCount(Card.IsType,nil,TYPE_FLIP) + if flip_count>0 and Duel.IsExistingMatchingCard(Card.IsCanTurnSet,tp,LOCATION_MZONE,LOCATION_MZONE,1,og) + and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_POSCHANGE) + local pos_g=Duel.SelectMatchingCard(tp,Card.IsCanTurnSet,tp,LOCATION_MZONE,LOCATION_MZONE,1,flip_count,og) + if #pos_g>0 then + Duel.HintSelection(pos_g) + Duel.BreakEffect() + Duel.ChangePosition(pos_g,POS_FACEDOWN_DEFENSE) + end + end +end +function s.thfilter(c) + return c:IsSetCard(SET_SHADDOLL) and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.thfilter(chkc) end + if chk==0 then return Duel.IsExistingTarget(s.thfilter,tp,LOCATION_GRAVE,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectTarget(tp,s.thfilter,tp,LOCATION_GRAVE,0,1,1,nil) + Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,tp,0) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + local tc=Duel.GetFirstTarget() + if tc:IsRelateToEffect(e) then + Duel.SendtoHand(tc,nil,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/pre-release/c100447101.lua b/pre-release/c100447101.lua new file mode 100644 index 0000000000..11fcdc6d91 --- /dev/null +++ b/pre-release/c100447101.lua @@ -0,0 +1,85 @@ +--セイクリッド・カストル +--Constellar Castor +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + --Special Summon 1 "Constellar" monster from your Deck + local e1a=Effect.CreateEffect(c) + e1a:SetDescription(aux.Stringid(id,0)) + e1a:SetCategory(CATEGORY_SPECIAL_SUMMON) + e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1a:SetProperty(EFFECT_FLAG_DELAY) + e1a:SetCode(EVENT_SUMMON_SUCCESS) + e1a:SetCountLimit(1,id) + e1a:SetTarget(s.sptg) + e1a:SetOperation(s.spop) + c:RegisterEffect(e1a) + local e1b=e1a:Clone() + e1b:SetCode(EVENT_FLIP_SUMMON_SUCCESS) + c:RegisterEffect(e1b) + local e1c=e1a:Clone() + e1c:SetCode(EVENT_SPSUMMON_SUCCESS) + c:RegisterEffect(e1c) + --A "Constellar" Xyz Monster that has this card as material gains this effect: Negate a Spell or effect activated by the opponent, and if you do, destroy that card + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_DISABLE+CATEGORY_DESTROY) + e2:SetType(EFFECT_TYPE_XMATERIAL+EFFECT_TYPE_QUICK_O) + e2:SetCode(EVENT_CHAINING) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1) + e2:SetCondition(s.discon) + e2:SetTarget(s.distg) + e2:SetOperation(s.disop) + c:RegisterEffect(e2) +end +s.listed_series={SET_CONSTELLAR} +s.listed_names={id} +function s.spfilter(c,e,tp) + return c:IsSetCard(SET_CONSTELLAR) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and not c:IsCode(id) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + --Excluding itself for a proper interaction with "Tellarknight Constellar Caduceus" [58858807] + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,1,e:GetHandler(),e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + --You cannot Special Summon from the Extra Deck for the rest of this turn, except DARK monsters + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,2)) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) + e1:SetTargetRange(1,0) + e1:SetTarget(function(e,c) return c:IsLocation(LOCATION_EXTRA) and not c:IsAttribute(ATTRIBUTE_DARK|ATTRIBUTE_LIGHT) end) + e1:SetReset(RESET_PHASE|PHASE_END) + Duel.RegisterEffect(e1,tp) + --"Clock Lizard" check + aux.addTempLizardCheck(c,tp,function(e,c) return not c:IsOriginalAttribute(ATTRIBUTE_DARK|ATTRIBUTE_LIGHT) end) + --Special Summon 1 "Constellar" monster from your Deck + if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end +function s.discon(e,tp,eg,ep,ev,re,r,rp) + return e:GetHandler():IsSetCard(SET_CONSTELLAR) and rp==1-tp and re:IsSpellEffect() and Duel.IsChainDisablable(ev) +end +function s.distg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.CheckRemoveOverlayCard(tp,1,0,2,REASON_EFFECT) end + local rc=re:GetHandler() + Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,tp,0) + if rc:IsDestructable() and rc:IsRelateToEffect(re) then + Duel.SetOperationInfo(0,CATEGORY_DESTROY,eg,1,tp,0) + end +end +function s.disop(e,tp,eg,ep,ev,re,r,rp) + if Duel.RemoveOverlayCard(tp,1,0,2,2,REASON_EFFECT)==2 and Duel.NegateEffect(ev) + and re:GetHandler():IsRelateToEffect(re) then + Duel.Destroy(eg,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/pre-release/c100447102.lua b/pre-release/c100447102.lua new file mode 100644 index 0000000000..dfec98f201 --- /dev/null +++ b/pre-release/c100447102.lua @@ -0,0 +1,84 @@ +--星騎士 キュグニ +--Tellarknight Cygnian +--Scripted by ahtelel +local s,id=GetID() +function s.initial_effect(c) + --Add 1 "tellarknight" or "Constellar" monster from your Deck to your hand + local e1a=Effect.CreateEffect(c) + e1a:SetDescription(aux.Stringid(id,0)) + e1a:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1a:SetProperty(EFFECT_FLAG_DELAY) + e1a:SetCode(EVENT_SUMMON_SUCCESS) + e1a:SetCountLimit(1,id) + e1a:SetTarget(s.thtg) + e1a:SetOperation(s.thop) + c:RegisterEffect(e1a) + local e1b=e1a:Clone() + e1b:SetCode(EVENT_FLIP_SUMMON_SUCCESS) + c:RegisterEffect(e1b) + local e1c=e1a:Clone() + e1c:SetCode(EVENT_SPSUMMON_SUCCESS) + c:RegisterEffect(e1c) + --Increase this card and another LIGHT monster's Level by 1 + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_LVCHANGE) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1,{id,1}) + e2:SetTarget(s.lvtg) + e2:SetOperation(s.lvop) + c:RegisterEffect(e2) + --Can be treated as 2 Materials for the Xyz Summon of a "tellarknight" Xyz monster that requires 3 or more materials + local e3=Effect.CreateEffect(c) + e3:SetType(EFFECT_TYPE_SINGLE) + e3:SetCode(EFFECT_DOUBLE_XYZ_MATERIAL) + e3:SetCountLimit(1,{id,2}) + e3:SetValue(1) + e3:SetOperation(function(e,c) return c.minxyzct and c.minxyzct>=3 and c:IsSetCard(SET_TELLARKNIGHT) end) + c:RegisterEffect(e3) +end +s.listed_series={SET_TELLARKNIGHT,SET_CONSTELLAR} +function s.thfilter(c) + return c:IsSetCard({SET_TELLARKNIGHT,SET_CONSTELLAR}) and c:IsMonster() and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end +function s.lvfilter(c) + return c:IsAttribute(ATTRIBUTE_LIGHT) and c:HasLevel() and c:IsFaceup() +end +function s.lvtg(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 chkc~=c and s.lvfilter(chkc) end + if chk==0 then return Duel.IsExistingTarget(s.lvfilter,tp,LOCATION_MZONE,0,1,c) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) + Duel.SelectTarget(tp,s.lvfilter,tp,LOCATION_MZONE,0,1,1,c) +end +function s.lvop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local tc=Duel.GetFirstTarget() + if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and c:IsFaceup() and tc:IsFaceup() then + --Increase both their Level by 1 + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE) + e1:SetCode(EFFECT_UPDATE_LEVEL) + e1:SetValue(1) + e1:SetReset(RESET_EVENT|RESETS_STANDARD) + c:RegisterEffect(e1) + local e2=e1:Clone() + tc:RegisterEffect(e2) + end +end \ No newline at end of file diff --git a/pre-release/c100447103.lua b/pre-release/c100447103.lua new file mode 100644 index 0000000000..17783f1598 --- /dev/null +++ b/pre-release/c100447103.lua @@ -0,0 +1,68 @@ +--超神星輝士 セイクリッド・トレミスΩ7 +--Exstellarknight Constellar Ptolemy Ω7 +--Scripted by ahtelel +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Xyz Summon procedure: 3 Level 7 monsters OR 1 "tellarknight" or "Constellar" Xyz Monster you control + Xyz.AddProcedure(c,nil,7,3,s.ovfilter,aux.Stringid(id,0),3,s.xyzop) + --While you have 7 or more "tellarknight" monsters with different names in your GY and/or banishment, this card gains 2700 ATK/DEF, also it is unaffected by your opponent's activated effects + local e1a=Effect.CreateEffect(c) + e1a:SetType(EFFECT_TYPE_SINGLE) + e1a:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e1a:SetCode(EFFECT_UPDATE_ATTACK) + e1a:SetRange(LOCATION_MZONE) + e1a:SetCondition(s.atkdefimmcon) + e1a:SetValue(2700) + c:RegisterEffect(e1a) + local e1b=e1a:Clone() + e1b:SetCode(EFFECT_UPDATE_DEFENSE) + c:RegisterEffect(e1b) + local e1c=e1a:Clone() + e1c:SetCode(EFFECT_IMMUNE_EFFECT) + e1c:SetValue(function(e,te) return te:GetOwnerPlayer()~=e:GetHandlerPlayer() and te:IsActivated() end) + c:RegisterEffect(e1c) + --Shuffle opponent's monsters into the deck based on the number of materials you detach from this card + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_TODECK) + e2:SetType(EFFECT_TYPE_QUICK_O) + e2:SetProperty(EFFECT_FLAG_CARD_TARGET) + e2:SetCode(EVENT_FREE_CHAIN) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1) + e2:SetCost(Cost.DetachFromSelf(1,function(e,tp) return Duel.GetTargetCount(Card.IsAbleToDeck,tp,0,LOCATION_MZONE,nil) end,function(e,og) e:SetLabel(#og) end)) + e2:SetTarget(s.tdtg) + e2:SetOperation(s.tdop) + e2:SetHintTiming(0,TIMING_STANDBY_PHASE|TIMING_MAIN_END|TIMINGS_CHECK_MONSTER_E) + c:RegisterEffect(e2) +end +s.listed_series={SET_TELLARKNIGHT,SET_CONSTELLAR} +s.listed_names={id} +function s.ovfilter(c,tp,xyzc) + return c:IsSetCard({SET_TELLARKNIGHT,SET_CONSTELLAR},xyzc,SUMMON_TYPE_XYZ,tp) and c:IsType(TYPE_XYZ,xyzc,SUMMON_TYPE_XYZ,tp) and c:IsFaceup() +end +function s.xyzop(e,tp,chk) + if chk==0 then return Duel.IsMainPhase2(tp) and not Duel.HasFlagEffect(tp,id) end + return Duel.RegisterFlagEffect(tp,id,RESET_PHASE|PHASE_END,EFFECT_FLAG_OATH,1) +end +function s.atkdefimmfilter(c) + return c:IsSetCard(SET_TELLARKNIGHT) and c:IsMonster() and c:IsFaceup() +end +function s.atkdefimmcon(e,c) + return Duel.GetMatchingGroup(s.atkdefimmfilter,e:GetHandlerPlayer(),LOCATION_GRAVE|LOCATION_REMOVED,0,nil):GetClassCount(Card.GetCode)>=7 +end +function s.tdtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and chkc:IsAbleToDeck() end + if chk==0 then return Duel.IsExistingTarget(Card.IsAbleToDeck,tp,0,LOCATION_MZONE,1,nil) end + local ct=e:GetLabel() + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) + local g=Duel.SelectTarget(tp,Card.IsAbleToDeck,tp,0,LOCATION_MZONE,ct,ct,nil) + Duel.SetOperationInfo(0,CATEGORY_TODECK,g,#g,tp,0) +end +function s.tdop(e,tp,eg,ep,ev,re,r,rp) + local tg=Duel.GetTargetCards(e) + if #tg>0 then + Duel.SendtoDeck(tg,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) + end +end \ No newline at end of file diff --git a/pre-release/c100447104.lua b/pre-release/c100447104.lua new file mode 100644 index 0000000000..2bbe0f4f10 --- /dev/null +++ b/pre-release/c100447104.lua @@ -0,0 +1,89 @@ +--星騎士 セイクリッド・デルタテロス +--Tellarknight Constellar Delteros +--scripted by Naim +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Xyz Summon procedure: 3+ Level 4 monsters + Xyz.AddProcedure(c,nil,4,3,nil,nil,Xyz.InfiniteMats) + --Your opponent cannot target Rank 5 or higher "tellarknight" or "Constellar" Xyz Monsters you control with card effects + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_FIELD) + e1:SetProperty(EFFECT_FLAG_IGNORE_IMMUNE) + e1:SetCode(EFFECT_CANNOT_BE_EFFECT_TARGET) + e1:SetRange(LOCATION_MZONE) + e1:SetTargetRange(LOCATION_MZONE,0) + e1:SetTarget(s.tellarkR5filter) + e1:SetValue(aux.tgoval) + c:RegisterEffect(e1) + --Add 1 "tellarknight" or "Constellar" monster from your Deck to your hand, then immediately after this effect resolves, you can Normal Summon 1 LIGHT monster + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_MZONE) + e2:SetCountLimit(1) + e2:SetCost(Cost.DetachFromSelf(1)) + e2:SetTarget(s.thtg) + e2:SetOperation(s.thop) + c:RegisterEffect(e2) + --Special Summon 1 "tellarknight" or "Constellar" monster from your hand or banishment + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_SPECIAL_SUMMON) + e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e3:SetProperty(EFFECT_FLAG_DELAY) + e3:SetCode(EVENT_TO_GRAVE) + e3:SetCondition(function(e) return not e:GetHandler():IsPreviousLocation(LOCATION_ONFIELD) end) + e3:SetTarget(s.sptg) + e3:SetOperation(s.spop) + c:RegisterEffect(e3) +end +s.listed_series={SET_TELLARKNIGHT,SET_CONSTELLAR} +function s.tellarkR5filter(e,c) + return c:IsSetCard({SET_TELLARKNIGHT,SET_CONSTELLAR}) and c:IsRankAbove(5) and c:IsFaceup() +end +function s.thfilter(c) + return c:IsSetCard({SET_TELLARKNIGHT,SET_CONSTELLAR}) and c:IsMonster() and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) + Duel.SetPossibleOperationInfo(0,CATEGORY_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_MZONE) +end +function s.nsfilter(c) + return c:IsAttribute(ATTRIBUTE_LIGHT) and c:IsSummonable(true,nil) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 and Duel.SendtoHand(g,nil,REASON_EFFECT)>0 then + Duel.ConfirmCards(1-tp,g) + Duel.ShuffleHand(tp) + if Duel.IsExistingMatchingCard(s.nsfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SUMMON) + local sc=Duel.SelectMatchingCard(tp,s.nsfilter,tp,LOCATION_HAND|LOCATION_MZONE,0,1,1,nil):GetFirst() + if sc then + Duel.BreakEffect() + Duel.Summon(tp,sc,true,nil) + end + end + end +end +function s.spfilter(c,e,tp) + return c:IsSetCard({SET_TELLARKNIGHT,SET_CONSTELLAR}) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) + and (c:IsFaceup() or c:IsLocation(LOCATION_HAND)) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_HAND|LOCATION_REMOVED,0,1,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND|LOCATION_REMOVED) +end +function s.spop(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,s.spfilter,tp,LOCATION_HAND|LOCATION_REMOVED,0,1,1,nil,e,tp) + if #g>0 then + Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP) + end +end \ No newline at end of file diff --git a/pre-release/c100447106.lua b/pre-release/c100447106.lua new file mode 100644 index 0000000000..b5277b550f --- /dev/null +++ b/pre-release/c100447106.lua @@ -0,0 +1,90 @@ +--X-セイバー ペリナ +--X-Saber Perina +--Scripted by the Razgriz +local s,id=GetID() +function s.initial_effect(c) + --Special Summon 2 "X-Saber" monsters from your Deck, except "X-Saber Perina", but destroy them during the End Phase + local e1a=Effect.CreateEffect(c) + e1a:SetDescription(aux.Stringid(id,0)) + e1a:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DESTROY) + e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1a:SetProperty(EFFECT_FLAG_DELAY) + e1a:SetCode(EVENT_SUMMON_SUCCESS) + e1a:SetCountLimit(1,id) + e1a:SetCost(Cost.SelfToGrave) + e1a:SetTarget(s.sptg) + e1a:SetOperation(s.spop) + c:RegisterEffect(e1a) + local e1b=e1a:Clone() + e1b:SetCode(EVENT_SPSUMMON_SUCCESS) + c:RegisterEffect(e1b) + --Apply an effect to the "X-Saber" Synchro Monster that used this card as material + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_DELAY) + e2:SetCode(EVENT_BE_MATERIAL) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(s.effcon) + e2:SetTarget(s.efftg) + e2:SetOperation(s.effop) + c:RegisterEffect(e2) +end +s.listed_series={SET_X_SABER} +s.listed_names={id} +function s.spfilter(c,e,tp) + return c:IsSetCard(SET_X_SABER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false) and not c:IsCode(id) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return not Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) + and Duel.GetMZoneCount(tp,e:GetHandler())>=2 + and Duel.IsExistingMatchingCard(s.spfilter,tp,LOCATION_DECK,0,2,nil,e,tp) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,2,tp,LOCATION_DECK) + Duel.SetPossibleOperationInfo(0,CATEGORY_DESTROY,nil,2,tp,LOCATION_MZONE) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + if Duel.IsPlayerAffectedByEffect(tp,CARD_BLUEEYES_SPIRIT) or Duel.GetLocationCount(tp,LOCATION_MZONE)<2 then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_DECK,0,2,2,nil,e,tp) + if #g==2 and Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)==2 then + --Destroy them during the End Phase + aux.DelayedOperation(g,PHASE_END,id,e,tp,function(ag) Duel.Destroy(ag,REASON_EFFECT) end,nil,0,0,aux.Stringid(id,2)) + end +end +function s.effcon(e,tp,eg,ep,ev,re,r,rp) + if not (r==REASON_SYNCHRO and (Duel.IsAbleToEnterBP() or (Duel.IsBattlePhase() and not Duel.IsEndStep()))) then return false end + local c=e:GetHandler() + local sync=c:GetReasonCard() + if not (c:IsLocation(LOCATION_GRAVE) and sync:IsSetCard(SET_X_SABER)) then return false end + e:SetLabelObject(sync) + sync:RegisterFlagEffect(id,RESET_EVENT|(RESETS_STANDARD&~RESET_TURN_SET),0,1) + return true +end +function s.efftg(e,tp,eg,ep,ev,re,r,rp,chk) + local sync=e:GetLabelObject() + if chk==0 then + return sync:HasFlagEffect(id) and not (sync:IsHasEffect(EFFECT_EXTRA_ATTACK) and sync:IsHasEffect(EFFECT_DIRECT_ATTACK)) + end + sync:CreateEffectRelation(e) +end +function s.effop(e,tp,eg,ep,ev,re,r,rp) + local sync=e:GetLabelObject() + if not sync:IsRelateToEffect(e) then return end + local b1=not sync:IsHasEffect(EFFECT_EXTRA_ATTACK) + local b2=not sync:IsHasEffect(EFFECT_DIRECT_ATTACK) + if not (b1 or b2) then return end + local op=Duel.SelectEffect(tp, + {b1,aux.Stringid(id,3)}, + {b2,aux.Stringid(id,4)}) + local desc=op==1 and 3201 or 3205 + local eff_code=op==1 and EFFECT_EXTRA_ATTACK or EFFECT_DIRECT_ATTACK + --It can make a second attack during each Battle Phase OR it can attack directly + local e1=Effect.CreateEffect(e:GetHandler()) + e1:SetDescription(desc) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CLIENT_HINT) + e1:SetCode(eff_code) + e1:SetValue(1) + e1:SetReset(RESET_EVENT|RESETS_STANDARD) + sync:RegisterEffect(e1) +end \ No newline at end of file diff --git a/pre-release/c100447107.lua b/pre-release/c100447107.lua new file mode 100644 index 0000000000..591e2bd607 --- /dev/null +++ b/pre-release/c100447107.lua @@ -0,0 +1,101 @@ +--X-セイバー ブルノ +--X-Saber Bruno +--Scripted by the Razgriz +local s,id=GetID() +function s.initial_effect(c) + --Synchro Summon using only EARTH monsters, including this card + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_SPECIAL_SUMMON) + e1:SetType(EFFECT_TYPE_QUICK_O) + e1:SetCode(EVENT_FREE_CHAIN) + e1:SetRange(LOCATION_MZONE) + e1:SetCountLimit(1) + e1:SetCondition(function(e,tp) return Duel.IsMainPhase(1-tp) or Duel.IsBattlePhase(1-tp) end) + e1:SetTarget(s.synchtg) + e1:SetOperation(s.synchop) + e1:SetHintTiming(0,TIMING_MAIN_END|TIMING_BATTLE_END|TIMINGS_CHECK_MONSTER) + c:RegisterEffect(e1) + --Banish 1 other EARTH monster to Special Summon this card + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_HAND) + e2:SetCountLimit(1,id) + e2:SetCost(s.spcost) + e2:SetTarget(s.sptg) + e2:SetOperation(s.spop) + c:RegisterEffect(e2) + --Add 1 "Saber" Spell/Trap Card from your Deck to your hand + local e3a=Effect.CreateEffect(c) + e3a:SetDescription(aux.Stringid(id,2)) + e3a:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e3a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e3a:SetProperty(EFFECT_FLAG_DELAY) + e3a:SetCode(EVENT_SUMMON_SUCCESS) + e3a:SetCountLimit(1,{id,1}) + e3a:SetTarget(s.thtg) + e3a:SetOperation(s.thop) + c:RegisterEffect(e3a) + local e3b=e3a:Clone() + e3b:SetCode(EVENT_SPSUMMON_SUCCESS) + c:RegisterEffect(e3b) +end +s.listed_series={SET_X_SABER,SET_SABER} +s.listed_names={id} +function s.synchtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then + local c=e:GetHandler() + local mg=Duel.GetMatchingGroup(aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_EARTH),tp,LOCATION_MZONE,0,nil) + return c:IsAttribute(ATTRIBUTE_EARTH) and Duel.IsExistingMatchingCard(Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,1,nil,c,mg) + end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) +end +function s.synchop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if not (c:IsRelateToEffect(e) and c:IsControler(tp) and c:IsFaceup() and c:IsAttribute(ATTRIBUTE_EARTH)) then return end + local mg=Duel.GetMatchingGroup(aux.FaceupFilter(Card.IsAttribute,ATTRIBUTE_EARTH),tp,LOCATION_MZONE,0,nil) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) + local sc=Duel.SelectMatchingCard(tp,Card.IsSynchroSummonable,tp,LOCATION_EXTRA,0,1,1,nil,c,mg):GetFirst() + if sc then + Duel.SynchroSummon(tp,sc,c,mg) + end +end +function s.spcostfilter(c,tp) + return c:IsAttribute(ATTRIBUTE_EARTH) and c:IsAbleToRemoveAsCost() and (c:IsLocation(LOCATION_HAND) or c:IsFaceup()) + and Duel.GetMZoneCount(tp,c)>0 +end +function s.spcost(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.IsExistingMatchingCard(s.spcostfilter,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_GRAVE,0,1,c,tp) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) + local g=Duel.SelectMatchingCard(tp,s.spcostfilter,tp,LOCATION_HAND|LOCATION_MZONE|LOCATION_GRAVE,0,1,1,c,tp) + Duel.Remove(g,POS_FACEUP,REASON_COST) +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) then + Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) + end +end +function s.thfilter(c) + return c:IsSetCard(SET_SABER) and c:IsSpellTrap() and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK|LOCATION_GRAVE,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK|LOCATION_GRAVE) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.thfilter),tp,LOCATION_DECK|LOCATION_GRAVE,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end \ No newline at end of file diff --git a/pre-release/c100447108.lua b/pre-release/c100447108.lua new file mode 100644 index 0000000000..930bef545f --- /dev/null +++ b/pre-release/c100447108.lua @@ -0,0 +1,113 @@ +--総剣司令 ソウザ +--Commander Souza, Swordmaster +--Scripted by the Razgriz +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Synchro Summon procedure: 1 Tuner + 1+ EARTH monsters + Synchro.AddProcedure(c,nil,1,1,aux.FilterBoolFunctionEx(Card.IsAttribute,ATTRIBUTE_EARTH),1,99) + --Multiple Tuner check + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_SINGLE) + e0:SetCode(EFFECT_MATERIAL_CHECK) + e0:SetValue(s.valcheck) + c:RegisterEffect(e0) + --Gains 200 ATK for each banished monster + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e1:SetCode(EFFECT_UPDATE_ATTACK) + e1:SetRange(LOCATION_MZONE) + e1:SetValue(function(e,c) return 200*Duel.GetMatchingGroupCount(aux.FaceupFilter(Card.IsMonster),0,LOCATION_REMOVED,LOCATION_REMOVED,nil) end) + c:RegisterEffect(e1) + --Draw 1 card + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_DRAW) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET) + e2:SetCode(EVENT_BATTLE_DESTROYING) + e2:SetCondition(aux.bdocon) + e2:SetTarget(s.drtg) + e2:SetOperation(s.drop) + c:RegisterEffect(e2) + --Destroy 1 card your opponent controls + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_DESTROY) + e3:SetType(EFFECT_TYPE_QUICK_O) + e3:SetCode(EVENT_CHAINING) + e3:SetRange(LOCATION_MZONE) + e3:SetCountLimit(1) + e3:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return ep==1-tp end) + e3:SetCost(s.descost) + e3:SetTarget(s.destg) + e3:SetOperation(s.desop) + c:RegisterEffect(e3) + --If this card would be destroyed by battle or card effect, you can banish 1 "Saber" card from your GY instead + local e4=Effect.CreateEffect(c) + e4:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) + e4:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e4:SetCode(EFFECT_DESTROY_REPLACE) + e4:SetRange(LOCATION_MZONE) + e4:SetTarget(s.desreptg) + c:RegisterEffect(e4) +end +s.listed_series={SET_X_SABER,SET_SABER} +s.listed_names={id} +function s.valcheck(e,c) + local g=c:GetMaterial() + if g:IsExists(Card.IsType,2,nil,TYPE_TUNER) then + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) + e1:SetCode(EFFECT_MULTIPLE_TUNERS) + e1:SetReset(RESET_EVENT|RESETS_STANDARD&~(RESET_TOFIELD)|RESET_PHASE|PHASE_END) + c:RegisterEffect(e1) + end +end +function s.drtg(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) + Duel.SetOperationInfo(0,CATEGORY_DRAW,nil,0,tp,1) +end +function s.drop(e,tp,eg,ep,ev,re,r,rp) + local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM) + Duel.Draw(p,d,REASON_EFFECT) +end +function s.descostfilter(c,tp) + return c:IsSetCard(SET_X_SABER) and Duel.IsExistingMatchingCard(nil,tp,0,LOCATION_ONFIELD,1,c) +end +function s.descost(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.CheckReleaseGroupCost(tp,s.descostfilter,1,false,nil,nil,tp) end + local g=Duel.SelectReleaseGroupCost(tp,s.descostfilter,1,1,false,nil,nil,tp) + Duel.Release(g,REASON_COST) +end +function s.destg(e,tp,eg,ep,ev,re,r,rp,chk) + local g=Duel.GetFieldGroup(tp,0,LOCATION_ONFIELD) + if chk==0 then return #g>0 end + Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,tp,0) +end +function s.desop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) + local g=Duel.SelectMatchingCard(tp,nil,tp,0,LOCATION_ONFIELD,1,1,nil) + if #g>0 then + Duel.HintSelection(g) + Duel.Destroy(g,REASON_EFFECT) + end +end +function s.desrepfilter(c) + return c:IsSetCard(SET_SABER) and c:IsAbleToRemove() and aux.SpElimFilter(c,true) +end +function s.desreptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return not c:IsReason(REASON_REPLACE) + and Duel.IsExistingMatchingCard(s.desrepfilter,tp,LOCATION_MZONE|LOCATION_GRAVE,0,1,c) end + if Duel.SelectEffectYesNo(tp,c) then + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESREPLACE) + local g=Duel.SelectMatchingCard(tp,s.desrepfilter,tp,LOCATION_MZONE|LOCATION_GRAVE,0,1,1,c) + return Duel.Remove(g,POS_FACEUP,REASON_EFFECT)>0 + end + return false +end \ No newline at end of file diff --git a/pre-release/c100447109.lua b/pre-release/c100447109.lua new file mode 100644 index 0000000000..c5c1980f37 --- /dev/null +++ b/pre-release/c100447109.lua @@ -0,0 +1,104 @@ +--X-セイバー ガトムズ +--X-Saber Gottoms +--scripted by pyrQ +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Synchro Summon procedure: 1 Tuner + 1+ EARTH monsters + Synchro.AddProcedure(c,nil,1,1,aux.FilterBoolFunctionEx(Card.IsAttribute,ATTRIBUTE_EARTH),1,99) + --Multiple Tuner check + local e0=Effect.CreateEffect(c) + e0:SetType(EFFECT_TYPE_SINGLE) + e0:SetCode(EFFECT_MATERIAL_CHECK) + e0:SetValue(s.valcheck) + c:RegisterEffect(e0) + --Add 1 "Saber" or "Gottoms" Spell/Trap from your Deck to your hand + local e1=Effect.CreateEffect(c) + e1:SetDescription(aux.Stringid(id,0)) + e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH) + e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1:SetProperty(EFFECT_FLAG_DELAY) + e1:SetCode(EVENT_SPSUMMON_SUCCESS) + e1:SetCountLimit(1,id) + e1:SetCondition(function(e) return e:GetHandler():IsSynchroSummoned() end) + e1:SetTarget(s.thtg) + e1:SetOperation(s.thop) + c:RegisterEffect(e1) + --Discard 1 random card from your opponent's hand + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,1)) + e2:SetCategory(CATEGORY_HANDES) + e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e2:SetCode(EVENT_BATTLE_DAMAGE) + e2:SetCountLimit(1,{id,1}) + e2:SetCondition(function(e,tp,eg,ep,ev,re,r,rp) return ep==1-tp end) + e2:SetTarget(s.discardtg) + e2:SetOperation(s.discardop) + c:RegisterEffect(e2) + --Special Summon this card, then change the attack target to it + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,2)) + e3:SetCategory(CATEGORY_SPECIAL_SUMMON) + e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e3:SetCode(EVENT_ATTACK_ANNOUNCE) + e3:SetRange(LOCATION_GRAVE) + e3:SetCountLimit(1,{id,2}) + e3:SetCondition(function(e,tp) local bc=Duel.GetAttackTarget() return bc and bc:IsSetCard(SET_X_SABER) and bc:IsControler(tp) and bc:IsFaceup() end) + e3:SetTarget(s.sptg) + e3:SetOperation(s.spop) + c:RegisterEffect(e3) +end +s.listed_series={SET_SABER,SET_GOTTOMS,SET_X_SABER} +function s.valcheck(e,c) + local g=c:GetMaterial() + if g:IsExists(Card.IsType,2,nil,TYPE_TUNER) then + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) + e1:SetCode(EFFECT_MULTIPLE_TUNERS) + e1:SetReset(RESET_EVENT|RESETS_STANDARD&~(RESET_TOFIELD)|RESET_PHASE|PHASE_END) + c:RegisterEffect(e1) + end +end +function s.thfilter(c) + return c:IsSetCard({SET_SABER,SET_GOTTOMS}) and c:IsSpellTrap() and c:IsAbleToHand() +end +function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.thfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK) +end +function s.thop(e,tp,eg,ep,ev,re,r,rp) + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) + local g=Duel.SelectMatchingCard(tp,s.thfilter,tp,LOCATION_DECK,0,1,1,nil) + if #g>0 then + Duel.SendtoHand(g,nil,REASON_EFFECT) + Duel.ConfirmCards(1-tp,g) + end +end +function s.discardtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetFieldGroupCount(tp,0,LOCATION_HAND)>0 end + Duel.SetOperationInfo(0,CATEGORY_HANDES,nil,0,1-tp,1) +end +function s.discardop(e,tp,eg,ep,ev,re,r,rp) + local g=Duel.GetFieldGroup(tp,0,LOCATION_HAND) + if #g>0 then + local sg=g:RandomSelect(1-tp,1) + Duel.SendtoGrave(sg,REASON_EFFECT|REASON_DISCARD) + end +end +function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) + local c=e:GetHandler() + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0 + and c:IsCanBeSpecialSummoned(e,0,tp,false,false) end + Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,c,1,tp,0) +end +function s.spop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + if c:IsRelateToEffect(e) and Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)>0 then + local ac=Duel.GetAttacker() + if ac:CanAttack() and not ac:IsImmuneToEffect(e) then + Duel.BreakEffect() + Duel.ChangeAttackTarget(c) + end + end +end \ No newline at end of file diff --git a/pre-release/c100448001.lua b/pre-release/c100448001.lua new file mode 100644 index 0000000000..8cd12d7eb3 --- /dev/null +++ b/pre-release/c100448001.lua @@ -0,0 +1,93 @@ +--破滅と終焉の支配者 +--End of the World Ruler +--Scripted by The Razgriz +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --This card's name becomes "Demise, King of Armageddon" while in the hand or field + local e1=Effect.CreateEffect(c) + e1:SetType(EFFECT_TYPE_SINGLE) + e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e1:SetCode(EFFECT_CHANGE_CODE) + e1:SetRange(LOCATION_HAND|LOCATION_MZONE) + e1:SetValue(72426662) + c:RegisterEffect(e1) + --Apply the effect of a Ritual Spell that Ritual Summons + local e2=Effect.CreateEffect(c) + e2:SetDescription(aux.Stringid(id,0)) + e2:SetCategory(CATEGORY_SPECIAL_SUMMON) + e2:SetType(EFFECT_TYPE_IGNITION) + e2:SetRange(LOCATION_HAND) + e2:SetCountLimit(1,id) + e2:SetCost(Cost.AND(Cost.SelfReveal,Cost.PayLP(2000),s.applycost)) + e2:SetTarget(s.applytg) + e2:SetOperation(s.applyop) + c:RegisterEffect(e2) + --Destroy as many other cards on the field as possible, then this card gains 2900 ATK + local e3=Effect.CreateEffect(c) + e3:SetDescription(aux.Stringid(id,1)) + e3:SetCategory(CATEGORY_DESTROY+CATEGORY_ATKCHANGE) + e3:SetType(EFFECT_TYPE_IGNITION) + e3:SetRange(LOCATION_MZONE) + e3:SetCountLimit(1,{id,1}) + e3:SetCost(Cost.PayLP(2000)) + e3:SetTarget(s.destg) + e3:SetOperation(s.desop) + c:RegisterEffect(e3) +end +s.listed_series={SET_END_OF_THE_WORLD} +s.listed_names={72426662} --"Demise, King of Armageddon" +function s.applyfilter(c) + return c:IsRitualSpell() and c:IsAbleToRemoveAsCost() and c:CheckActivateEffect(true,true,false)~=nil +end +function s.applycost(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.IsExistingMatchingCard(s.applyfilter,tp,LOCATION_DECK,0,1,nil) end +end +function s.applytg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) + if chkc then + local te=e:GetLabelObject() + return tg and tg(e,tp,eg,ep,ev,re,r,rp,0,chkc) + end + if chk==0 then return Duel.IsExistingMatchingCard(s.applyfilter,tp,LOCATION_DECK,0,1,nil) end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE) + local g=Duel.SelectMatchingCard(tp,s.applyfilter,tp,LOCATION_DECK,0,1,1,nil) + Duel.Remove(g,POS_FACEUP,REASON_COST) + local te=g:GetFirst():CheckActivateEffect(true,true,false) + e:SetLabel(te:GetLabel()) + e:SetLabelObject(te:GetLabelObject()) + local tg=te:GetTarget() + e:SetProperty(te:GetProperty()) + if tg then + tg(e,tp,eg,ep,ev,re,r,rp,1) + end + te:SetLabel(e:GetLabel()) + te:SetLabelObject(e:GetLabelObject()) + e:SetLabelObject(te) + Duel.ClearOperationInfo(0) +end +function s.applyop(e,tp,eg,ep,ev,re,r,rp) + local te=e:GetLabelObject() + if te then + e:SetLabel(te:GetLabel()) + e:SetLabelObject(te:GetLabelObject()) + local op=te:GetOperation() + if op then op(e,tp,eg,ep,ev,re,r,rp) end + te:SetLabel(e:GetLabel()) + te:SetLabelObject(e:GetLabelObject()) + end +end +function s.destg(e,tp,eg,ep,ev,re,r,rp,chk) + local g=Duel.GetMatchingGroup(nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,e:GetHandler()) + if chk==0 then return #g>0 end + Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,#g,tp,0) +end +function s.desop(e,tp,eg,ep,ev,re,r,rp) + local c=e:GetHandler() + local exc=c:IsRelateToEffect(e) and c or nil + local g=Duel.GetMatchingGroup(nil,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,exc) + if #g>0 and Duel.Destroy(g,REASON_EFFECT)>0 and c:IsRelateToEffect(e) and c:IsFaceup() then + Duel.BreakEffect() + --This card gains 2900 ATK + c:UpdateAttack(2900) + end +end \ No newline at end of file diff --git a/pre-release/c100448002.lua b/pre-release/c100448002.lua new file mode 100644 index 0000000000..66c84ec3e3 --- /dev/null +++ b/pre-release/c100448002.lua @@ -0,0 +1,79 @@ +--ナイトメア・アイズ・サクリファイス +--Nightmare-Eyes Restrict +--Scripted by The Razgriz +local s,id=GetID() +function s.initial_effect(c) + c:EnableReviveLimit() + --Fusion Materials: 2 monsters with different Types (Fiend, Illusion, or Spellcaster) + Fusion.AddProcMixN(c,true,true,s.matfilter,2) + --Equip 1 monster your opponent controls to this card as an Equip Spell + local e1a=Effect.CreateEffect(c) + e1a:SetDescription(aux.Stringid(id,0)) + e1a:SetCategory(CATEGORY_EQUIP) + e1a:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) + e1a:SetProperty(EFFECT_FLAG_DELAY) + e1a:SetCode(EVENT_SPSUMMON_SUCCESS) + e1a:SetCountLimit(1,id) + e1a:SetTarget(s.eqtg) + e1a:SetOperation(s.eqop) + c:RegisterEffect(e1a) + local e1b=e1a:Clone() + e1b:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) + e1b:SetCode(EVENT_PHASE+PHASE_BATTLE) + e1b:SetRange(LOCATION_MZONE) + e1b:SetCondition(function(e) return e:GetHandler():GetBattledGroupCount()>0 end) + c:RegisterEffect(e1b) + aux.AddEREquipLimit(c,nil,s.eqval,s.equipop,e1a) + aux.AddEREquipLimit(c,nil,s.eqval,s.equipop,e1b) + --Gains ATK equal to the combined ATK of those equipped monsters + local e2=Effect.CreateEffect(c) + e2:SetType(EFFECT_TYPE_SINGLE) + e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE) + e2:SetCode(EFFECT_UPDATE_ATTACK) + e2:SetRange(LOCATION_MZONE) + e2:SetCondition(function(e) return e:GetHandler():GetEquipGroup():IsExists(aux.FaceupFilter(Card.HasFlagEffect,id),1,nil) end) + e2:SetValue(function(e,c) return c:GetEquipGroup():Match(function(c) return c:HasFlagEffect(id) and c:IsFaceup() and c:GetTextAttack()>0 end,nil):GetSum(Card.GetTextAttack) end) + c:RegisterEffect(e2) + --If this card battles a monster, neither can be destroyed by that battle + local e3=Effect.CreateEffect(c) + e3:SetType(EFFECT_TYPE_FIELD) + e3:SetCode(EFFECT_INDESTRUCTABLE_BATTLE) + e3:SetRange(LOCATION_MZONE) + e3:SetTargetRange(LOCATION_MZONE,LOCATION_MZONE) + e3:SetTarget(function(e,c) local handler=e:GetHandler() return c==handler or c==handler:GetBattleTarget() end) + e3:SetValue(1) + c:RegisterEffect(e3) + --Your opponent's monsters cannot attack monsters, except this one + local e4=Effect.CreateEffect(c) + e4:SetType(EFFECT_TYPE_FIELD) + e4:SetCode(EFFECT_CANNOT_SELECT_BATTLE_TARGET) + e4:SetRange(LOCATION_MZONE) + e4:SetTargetRange(0,LOCATION_MZONE) + e4:SetValue(function(e,c) return c~=e:GetHandler() end) + c:RegisterEffect(e4) +end +function s.matfilter(c,fc,sumtype,sp,sub,mg,sg) + return c:IsRace(RACE_FIEND|RACE_ILLUSION|RACE_SPELLCASTER,fc,sumtype,sp) and (not sg or sg:FilterCount(aux.TRUE,c)==0 or not sg:IsExists(Card.IsRace,1,c,c:GetRace(),fc,sumtype,sp)) +end +function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk) + if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0 + and Duel.IsExistingMatchingCard(Card.IsAbleToChangeControler,tp,0,LOCATION_MZONE,1,nil) end + Duel.SetOperationInfo(0,CATEGORY_EQUIP,nil,1,1-tp,LOCATION_MZONE) +end +function s.eqop(e,tp,eg,ep,ev,re,r,rp) + if Duel.GetLocationCount(tp,LOCATION_SZONE)<=0 then return end + local c=e:GetHandler() + if not (c:IsRelateToEffect(e) and c:IsFaceup()) then return end + Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP) + local sc=Duel.SelectMatchingCard(tp,Card.IsAbleToChangeControler,tp,0,LOCATION_MZONE,1,1,nil):GetFirst() + if sc then + Duel.HintSelection(sc) + s.equipop(c,e,tp,sc) + end +end +function s.eqval(ec,c,tp) + return ec:IsControler(1-tp) +end +function s.equipop(c,e,tp,tc) + c:EquipByEffectAndLimitRegister(e,tp,tc,id) +end \ No newline at end of file