44local s ,id = GetID ()
55function s .initial_effect (c )
66 -- Activate
7+ local e0 = Effect .CreateEffect (c )
8+ e0 :SetType (EFFECT_TYPE_ACTIVATE )
9+ e0 :SetCode (EVENT_FREE_CHAIN )
10+ c :RegisterEffect (e0 )
11+ -- Reveal 1 LIGHT Fairy monster in your hand, and if you do, add 1 Level 7 LIGHT Dragon monster from your Deck to your hand, then place that revealed monster on the bottom of your Deck
712 local e1 = Effect .CreateEffect (c )
8- e1 :SetType (EFFECT_TYPE_ACTIVATE )
9- e1 :SetCode (EVENT_FREE_CHAIN )
13+ e1 :SetDescription (aux .Stringid (id ,0 ))
14+ e1 :SetCategory (CATEGORY_TOHAND + CATEGORY_SEARCH + CATEGORY_TODECK )
15+ e1 :SetType (EFFECT_TYPE_IGNITION )
16+ e1 :SetRange (LOCATION_SZONE )
17+ e1 :SetCountLimit (1 ,id )
18+ e1 :SetTarget (s .thtg )
19+ e1 :SetOperation (s .thop )
1020 c :RegisterEffect (e1 )
11- -- Reveal 1 LIGHT fairy monster, add 1 level 7 LIGHT dragon monster from deck
21+ -- Special Summon 1 Level 7 LIGHT Dragon monster from your hand
1222 local e2 = Effect .CreateEffect (c )
13- e2 :SetDescription (aux .Stringid (id ,0 ))
14- e2 :SetCategory (CATEGORY_TOHAND + CATEGORY_SEARCH + CATEGORY_TODECK )
15- e2 :SetType (EFFECT_TYPE_IGNITION )
23+ e2 :SetDescription (aux .Stringid (id ,1 ))
24+ e2 :SetCategory (CATEGORY_SPECIAL_SUMMON )
25+ e2 :SetType (EFFECT_TYPE_FIELD + EFFECT_TYPE_TRIGGER_O )
26+ e2 :SetProperty (EFFECT_FLAG_DELAY )
27+ e2 :SetCode (EVENT_CHAINING )
1628 e2 :SetRange (LOCATION_SZONE )
1729 e2 :SetCountLimit (1 ,id )
18- e2 :SetTarget (s .thtg )
19- e2 :SetOperation (s .thop )
30+ e2 :SetCondition (function (e ,tp ,eg ,ep ) return ep == 1 - tp end )
31+ e2 :SetTarget (s .sptg )
32+ e2 :SetOperation (s .spop )
2033 c :RegisterEffect (e2 )
21- -- Special Summon 1 Level 7 LIGHT Dragon monster from your hand
22- local e3 = Effect .CreateEffect (c )
23- e3 :SetDescription (aux .Stringid (id ,1 ))
24- e3 :SetType (EFFECT_TYPE_FIELD + EFFECT_TYPE_TRIGGER_O )
25- e3 :SetCategory (CATEGORY_SPECIAL_SUMMON )
26- e3 :SetProperty (EFFECT_FLAG_DELAY )
27- e3 :SetCode (EVENT_CHAINING )
28- e3 :SetRange (LOCATION_SZONE )
29- e3 :SetCountLimit (1 ,id )
30- e3 :SetCondition (function (_ ,tp ,_ ,ep )return ep == 1 - tp end )
31- e3 :SetTarget (s .sptg )
32- e3 :SetOperation (s .spop )
33- c :RegisterEffect (e3 )
34- end
35- function s .cfilter (c )
36- return c :IsRace (RACE_FAIRY ) and c :IsAttribute (ATTRIBUTE_LIGHT ) and not c :IsPublic () and c :IsAbleToDeck ()
3734end
38- function s .ldlv7filter (c )
39- return c :IsAttribute (ATTRIBUTE_LIGHT ) and c :IsRace (RACE_DRAGON ) and c : IsLevel ( 7 )
35+ function s .revealfilter (c )
36+ return c :IsAttribute (ATTRIBUTE_LIGHT ) and c :IsRace (RACE_FAIRY ) and not c : IsPublic () and c : IsAbleToDeck ( )
4037end
4138function s .thfilter (c )
42- return s . ldlv7filter ( c ) and c :IsAbleToHand ()
39+ return c : IsLevel ( 7 ) and c : IsAttribute ( ATTRIBUTE_LIGHT ) and c : IsRace ( RACE_DRAGON ) and c :IsAbleToHand ()
4340end
4441function s .thtg (e ,tp ,eg ,ep ,ev ,re ,r ,rp ,chk )
45- local g = Duel .GetMatchingGroup (s .thfilter ,tp ,LOCATION_DECK ,0 ,nil )
46- if chk == 0 then return Duel .IsExistingMatchingCard (s .cfilter ,tp ,LOCATION_HAND ,0 ,1 ,nil )
42+ if chk == 0 then return Duel .IsExistingMatchingCard (s .revealfilter ,tp ,LOCATION_HAND ,0 ,1 ,nil )
4743 and Duel .IsExistingMatchingCard (s .thfilter ,tp ,LOCATION_DECK ,0 ,1 ,nil ) end
4844 Duel .SetOperationInfo (0 ,CATEGORY_TOHAND ,nil ,1 ,tp ,LOCATION_DECK )
4945 Duel .SetOperationInfo (0 ,CATEGORY_TODECK ,nil ,1 ,tp ,LOCATION_HAND )
5046end
5147function s .thop (e ,tp ,eg ,ep ,ev ,re ,r ,rp )
5248 Duel .Hint (HINT_SELECTMSG ,tp ,HINTMSG_CONFIRM )
53- local rc = Duel .SelectMatchingCard (tp ,s .cfilter ,tp ,LOCATION_HAND ,0 ,1 ,1 ,nil )
54- if # rc > 0 then
55- Duel .ConfirmCards (1 - tp ,rc )
56- Duel .Hint (HINT_SELECTMSG ,tp ,HINTMSG_ATOHAND )
57- local sg = Duel .SelectMatchingCard (tp ,s .thfilter ,tp ,LOCATION_DECK ,0 ,1 ,1 ,nil )
58- if # sg > 0 and Duel .SendtoHand (sg ,nil ,REASON_EFFECT )~= 0 then
59- Duel .ConfirmCards (1 - tp ,sg )
60- Duel .ShuffleDeck (tp )
61- Duel .BreakEffect ()
62- Duel .SendtoDeck (rc ,tp ,SEQ_DECKBOTTOM ,REASON_EFFECT )
63- end
64- end
49+ local rg = Duel .SelectMatchingCard (tp ,s .revealfilter ,tp ,LOCATION_HAND ,0 ,1 ,1 ,nil )
50+ if # rg == 0 then return end
51+ Duel .ConfirmCards (1 - tp ,rg )
52+ Duel .Hint (HINT_SELECTMSG ,tp ,HINTMSG_ATOHAND )
53+ local sg = Duel .SelectMatchingCard (tp ,s .thfilter ,tp ,LOCATION_DECK ,0 ,1 ,1 ,nil )
54+ if # sg == 0 or Duel .SendtoHand (sg ,nil ,REASON_EFFECT )== 0 then return Duel .ShuffleHand (tp ) end
55+ Duel .ConfirmCards (1 - tp ,sg )
56+ Duel .ShuffleDeck (tp )
57+ Duel .BreakEffect ()
58+ Duel .SendtoDeck (rg ,nil ,SEQ_DECKBOTTOM ,REASON_EFFECT )
6559end
6660function s .spfilter (c ,e ,tp )
67- return s . ldlv7filter ( c ) and c :IsCanBeSpecialSummoned (e ,0 ,tp ,false ,false )
61+ return c : IsLevel ( 7 ) and c : IsAttribute ( ATTRIBUTE_LIGHT ) and c : IsRace ( RACE_DRAGON ) and c :IsCanBeSpecialSummoned (e ,0 ,tp ,false ,false )
6862end
6963function s .sptg (e ,tp ,eg ,ep ,ev ,re ,r ,rp ,chk )
7064 if chk == 0 then return Duel .GetLocationCount (tp ,LOCATION_MZONE )> 0
@@ -78,4 +72,4 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
7872 if # g > 0 then
7973 Duel .SpecialSummon (g ,0 ,tp ,tp ,false ,false ,POS_FACEUP )
8074 end
81- end
75+ end
0 commit comments