1+ -- バルーン・バティーア
2+ -- Balloon Bahtia
3+ -- Scripted by YoshiDuels
4+ local s ,id = GetID ()
5+ function s .initial_effect (c )
6+ -- Send the top 2 cards of your Deck to the GY
7+ local e1 = Effect .CreateEffect (c )
8+ e1 :SetDescription (aux .Stringid (id ,0 ))
9+ e1 :SetCategory (CATEGORY_DECKDES + CATEGORY_DAMAGE )
10+ e1 :SetType (EFFECT_TYPE_IGNITION )
11+ e1 :SetRange (LOCATION_MZONE )
12+ e1 :SetCountLimit (1 )
13+ e1 :SetCondition (s .condition )
14+ e1 :SetTarget (s .target )
15+ e1 :SetOperation (s .operation )
16+ c :RegisterEffect (e1 )
17+ -- Register when a player Special Summons a monster
18+ aux .GlobalCheck (s ,function ()
19+ local ge1 = Effect .CreateEffect (c )
20+ ge1 :SetType (EFFECT_TYPE_FIELD + EFFECT_TYPE_CONTINUOUS )
21+ ge1 :SetCode (EVENT_SPSUMMON_SUCCESS )
22+ ge1 :SetOperation (s .checkop )
23+ Duel .RegisterEffect (ge1 ,0 )
24+ end )
25+ end
26+ function s .checkop (e ,tp ,eg ,ep ,ev ,re ,r ,rp )
27+ for tc in eg :Iter () do
28+ Duel .RegisterFlagEffect (tc :GetSummonPlayer (),id ,RESET_PHASE |PHASE_END ,0 ,1 )
29+ end
30+ end
31+ function s .condition (e ,tp ,eg ,ep ,ev ,re ,r ,rp )
32+ return not Duel .HasFlagEffect (tp ,id )
33+ end
34+ function s .target (e ,tp ,eg ,ep ,ev ,re ,r ,rp ,chk )
35+ if chk == 0 then return Duel .IsPlayerCanDiscardDeck (tp ,2 ) end
36+ Duel .SetOperationInfo (0 ,CATEGORY_DECKDES ,nil ,0 ,tp ,2 )
37+ end
38+ function s .cfilter (c ,e ,tp )
39+ return c :IsLocation (LOCATION_GRAVE ) and c :IsMonster () and c :IsLevelBelow (6 ) and c :IsCanBeSpecialSummoned (e ,0 ,tp ,false ,false )
40+ end
41+ function s .operation (e ,tp ,eg ,ep ,ev ,re ,r ,rp )
42+ -- Effect
43+ if Duel .DiscardDeck (tp ,2 ,REASON_EFFECT )~= 2 then return end
44+ local g = Duel .GetOperatedGroup ()
45+ if g :FilterCount (aux .NecroValleyFilter (s .cfilter ),nil ,e ,tp )> 0 and Duel .GetLocationCount (tp ,LOCATION_MZONE )> 0 and Duel .SelectYesNo (tp ,aux .Stringid (id ,1 )) then
46+ Duel .Hint (HINT_SELECTMSG ,tp ,HINTMSG_SPSUMMON )
47+ local sg = g :FilterSelect (tp ,aux .NecroValleyFilter (s .cfilter ),1 ,1 ,nil ,e ,tp )
48+ if # sg > 0 then
49+ Duel .BreakEffect ()
50+ Duel .SpecialSummon (sg ,0 ,tp ,tp ,false ,false ,POS_FACEUP )
51+ end
52+ end
53+ end
0 commit comments