33-- scripted by Rundas
44local s ,id = GetID ()
55function s .initial_effect (c )
6- -- Tribute + search + deck stack + potentially Normal Summon
6+ -- Add 1 "Witch of the Black Rose" from your Deck to your hand, and if you do, take 1 Level 3 or lower Plant monster from your Deck and place it on top of your Deck, then immediately after this effect resolves, you can Normal Summon 1 "Witch of the Black Rose" from your hand
77 local e1 = Effect .CreateEffect (c )
88 e1 :SetDescription (aux .Stringid (id ,0 ))
9- e1 :SetCategory (CATEGORY_TOHAND + CATEGORY_SEARCH )
9+ e1 :SetCategory (CATEGORY_TOHAND + CATEGORY_SEARCH + CATEGORY_SUMMON )
1010 e1 :SetType (EFFECT_TYPE_IGNITION )
1111 e1 :SetRange (LOCATION_MZONE )
1212 e1 :SetCountLimit (1 ,id )
1313 e1 :SetCost (Cost .SelfTribute )
1414 e1 :SetTarget (s .thtg )
1515 e1 :SetOperation (s .thop )
1616 c :RegisterEffect (e1 )
17- -- To Extra Deck
17+ -- Return 1 of your "Black Rose Dragon" or "Ruddy Rose Dragon" that is banished or in your GY to the Extra Deck
1818 local e2 = Effect .CreateEffect (c )
1919 e2 :SetDescription (aux .Stringid (id ,1 ))
20- e2 :SetCategory (CATEGORY_TODECK )
20+ e2 :SetCategory (CATEGORY_TOEXTRA )
2121 e2 :SetType (EFFECT_TYPE_IGNITION )
2222 e2 :SetRange (LOCATION_GRAVE )
2323 e2 :SetCountLimit (1 ,{id ,1 })
2424 e2 :SetCost (Cost .SelfBanish )
25- e2 :SetTarget (s .tedtg )
26- e2 :SetOperation (s .tedop )
25+ e2 :SetTarget (s .textg )
26+ e2 :SetOperation (s .texop )
2727 c :RegisterEffect (e2 )
2828end
29- s .listed_names = {id ,17720747 ,CARD_BLACK_ROSE_DRAGON ,40139997 }
30- -- Tribute + search + deck stack + potentially Normal Summon
31- function s .thfilter (c )
32- return c :IsAbleToHand () and c :IsCode (17720747 )
29+ s .listed_names = {17720747 ,CARD_BLACK_ROSE_DRAGON ,40139997 } -- "Witch of the Black Rose", "Ruddy Rose Dragon"
30+ function s .thfilter (c ,tp )
31+ return c :IsCode (17720747 ) and c :IsAbleToHand () and Duel .IsExistingMatchingCard (s .topdeckfilter ,tp ,LOCATION_DECK ,0 ,1 ,c )
3332end
34- function s .filter (c )
35- return c :IsRace (RACE_PLANT ) and c :IsLevelBelow (3 )
36- end
37- function s .sfilter (c )
38- return c :IsCode (17720747 ) and c :IsSummonable (true ,nil )
33+ function s .topdeckfilter (c )
34+ return c :IsLevelBelow (3 ) and c :IsRace (RACE_PLANT )
3935end
4036function s .thtg (e ,tp ,eg ,ep ,ev ,re ,r ,rp ,chk )
41- if chk == 0 then return Duel .IsExistingMatchingCard (s .thfilter ,tp ,LOCATION_DECK ,0 ,1 ,nil ) end
37+ if chk == 0 then return Duel .IsExistingMatchingCard (s .thfilter ,tp ,LOCATION_DECK ,0 ,1 ,nil , tp ) end
4238 Duel .SetOperationInfo (0 ,CATEGORY_TOHAND ,nil ,1 ,tp ,LOCATION_DECK )
39+ Duel .SetPossibleOperationInfo (0 ,CATEGORY_SUMMON ,nil ,1 ,tp ,LOCATION_HAND )
40+ end
41+ function s .sumfilter (c )
42+ return c :IsCode (17720747 ) and c :IsSummonable (true ,nil )
4343end
4444function s .thop (e ,tp ,eg ,ep ,ev ,re ,r ,rp )
4545 Duel .Hint (HINT_SELECTMSG ,tp ,HINTMSG_ATOHAND )
46- local g = Duel .SelectMatchingCard (tp ,s .thfilter ,tp ,LOCATION_DECK ,0 ,1 ,1 ,nil )
47- if # g > 0 then
48- if Duel .SendtoHand (g ,nil ,REASON_EFFECT )> 0 and Duel .IsExistingMatchingCard (s .filter ,tp ,LOCATION_DECK ,0 ,1 ,nil ) then
49- Duel .ConfirmCards (1 - tp ,g )
50- local tc = Duel .SelectMatchingCard (tp ,s .filter ,tp ,LOCATION_DECK ,0 ,1 ,1 ,nil ):GetFirst ()
51- if tc then
52- Duel .ShuffleDeck (tp )
53- Duel .MoveSequence (tc ,0 )
54- Duel .ConfirmDecktop (tp ,1 )
46+ local sc = Duel .SelectMatchingCard (tp ,s .thfilter ,tp ,LOCATION_DECK ,0 ,1 ,1 ,nil ,tp ):GetFirst ()
47+ if sc and Duel .SendtoHand (sc ,nil ,REASON_EFFECT )> 0 and sc :IsLocation (LOCATION_HAND ) then
48+ Duel .ConfirmCards (1 - tp ,sc )
49+ Duel .ShuffleHand (tp )
50+ Duel .Hint (HINT_SELECTMSG ,tp ,aux .Stringid (id ,2 ))
51+ local topc = Duel .SelectMatchingCard (tp ,s .topdeckfilter ,tp ,LOCATION_DECK ,0 ,1 ,1 ,nil ):GetFirst ()
52+ if topc then
53+ Duel .ShuffleDeck (tp )
54+ Duel .MoveSequence (topc ,0 )
55+ Duel .ConfirmDecktop (tp ,1 )
56+ if Duel .IsExistingMatchingCard (s .sumfilter ,tp ,LOCATION_HAND ,0 ,1 ,nil )
57+ and Duel .SelectYesNo (tp ,aux .Stringid (id ,3 )) then
58+ Duel .Hint (HINT_SELECTMSG ,tp ,HINTMSG_SUMMON )
59+ local sumc = Duel .SelectMatchingCard (tp ,s .sumfilter ,tp ,LOCATION_HAND ,0 ,1 ,1 ,nil ):GetFirst ()
60+ if sumc then
61+ Duel .Summon (tp ,sumc ,true ,nil )
62+ end
5563 end
56- else Duel .ConfirmCards (1 - tp ,g )
57- end
58- end
59- local g2 = Duel .GetMatchingGroup (s .sfilter ,tp ,LOCATION_HAND ,0 ,nil )
60- if # g2 > 0 and Duel .SelectYesNo (tp ,aux .Stringid (id ,2 )) then
61- Duel .Hint (HINT_SELECTMSG ,tp ,HINTMSG_SUMMON )
62- local tc = Duel .SelectMatchingCard (tp ,s .sfilter ,tp ,LOCATION_HAND ,0 ,1 ,1 ,nil ):GetFirst ()
63- if tc then
64- Duel .Summon (tp ,tc ,true ,nil )
6564 end
6665 end
6766end
68- -- To Extra Deck
69- function s .tedfilter (c ,tp )
70- return (c :IsCode (CARD_BLACK_ROSE_DRAGON ) or c :IsCode (40139997 )) and c :IsAbleToExtra ()
71- and (c :IsFaceup () or c :IsLocation (LOCATION_GRAVE ))
67+ function s .texfilter (c )
68+ return c :IsCode (CARD_BLACK_ROSE_DRAGON ,40139997 ) and c :IsFaceup () and c :IsAbleToExtra ()
7269end
73- function s .tedtg (e ,tp ,eg ,ep ,ev ,re ,r ,rp ,chk )
74- if chk == 0 then return Duel .IsExistingMatchingCard (s .tedfilter ,tp ,LOCATION_GRAVE |LOCATION_REMOVED ,0 ,1 ,nil , tp ) end
75- Duel .SetOperationInfo (0 ,CATEGORY_TODECK ,nil ,1 ,tp ,LOCATION_GRAVE |LOCATION_REMOVED )
70+ function s .textg (e ,tp ,eg ,ep ,ev ,re ,r ,rp ,chk )
71+ if chk == 0 then return Duel .IsExistingMatchingCard (s .texfilter ,tp ,LOCATION_GRAVE |LOCATION_REMOVED ,0 ,1 ,e : GetHandler () ) end
72+ Duel .SetOperationInfo (0 ,CATEGORY_TOEXTRA ,nil ,1 ,tp ,LOCATION_GRAVE |LOCATION_REMOVED )
7673end
77- function s .tedop (e ,tp ,eg ,ep ,ev ,re ,r ,rp )
78- local tc = Duel .SelectMatchingCard (tp ,aux .NecroValleyFilter (s .tedfilter ),tp ,LOCATION_GRAVE |LOCATION_REMOVED ,0 ,1 ,1 ,nil ,tp ):GetFirst ()
79- if tc then
80- Duel .SendtoDeck (tc ,tp ,SEQ_DECKSHUFFLE ,REASON_EFFECT )
74+ function s .texop (e ,tp ,eg ,ep ,ev ,re ,r ,rp )
75+ Duel .Hint (HINT_SELECTMSG ,tp ,HINTMSG_TODECK )
76+ local g = Duel .SelectMatchingCard (tp ,aux .NecroValleyFilter (s .texfilter ),tp ,LOCATION_GRAVE |LOCATION_REMOVED ,0 ,1 ,1 ,nil )
77+ if # g > 0 then
78+ Duel .HintSelection (g )
79+ Duel .SendtoDeck (g ,nil ,SEQ_DECKSHUFFLE ,REASON_EFFECT )
8180 end
82- end
81+ end
0 commit comments