@@ -4,80 +4,63 @@ local s,id=GetID()
44function s .initial_effect (c )
55 c :EnableReviveLimit ()
66 c :EnableCounterPermit (COUNTER_SPELL )
7- -- Cannot special summon
7+ c :AddMustBeSpecialSummoned ()
8+ -- Place 2 Spell Counters on it
89 local e1 = Effect .CreateEffect (c )
9- e1 :SetProperty (EFFECT_FLAG_CANNOT_DISABLE + EFFECT_FLAG_UNCOPYABLE )
10- e1 :SetType (EFFECT_TYPE_SINGLE )
11- e1 :SetCode (EFFECT_SPSUMMON_CONDITION )
12- e1 :SetValue (aux .FALSE )
10+ e1 :SetDescription (aux .Stringid (id ,0 ))
11+ e1 :SetCategory (CATEGORY_COUNTER )
12+ e1 :SetType (EFFECT_TYPE_SINGLE + EFFECT_TYPE_TRIGGER_F )
13+ e1 :SetCode (EVENT_SPSUMMON_SUCCESS )
14+ e1 :SetTarget (function (e ,tp ,eg ,ep ,ev ,re ,r ,rp ,chk ) if chk == 0 then return true end Duel .SetOperationInfo (0 ,CATEGORY_COUNTER ,e :GetHandler (),2 ,tp ,COUNTER_SPELL ) end )
15+ e1 :SetOperation (s .counterop )
1316 c :RegisterEffect (e1 )
14- -- counter
17+ -- Gains 1000 ATK for each Spell Counter on it
1518 local e2 = Effect .CreateEffect (c )
16- e2 :SetDescription (aux .Stringid (id ,0 ))
17- e2 :SetCategory (CATEGORY_COUNTER )
18- e2 :SetType (EFFECT_TYPE_SINGLE + EFFECT_TYPE_TRIGGER_F )
19- e2 :SetCode (EVENT_SPSUMMON_SUCCESS )
20- e2 :SetTarget (s .addct )
21- e2 :SetOperation (s .addc )
19+ e2 :SetType (EFFECT_TYPE_SINGLE )
20+ e2 :SetCode (EFFECT_UPDATE_ATTACK )
21+ e2 :SetValue (function (e ,c ) return c :GetCounter (COUNTER_SPELL )* 1000 end )
2222 c :RegisterEffect (e2 )
23- -- increase ATK
23+ -- Destroy all cards your opponent controls
2424 local e3 = Effect .CreateEffect (c )
25- e3 :SetType (EFFECT_TYPE_SINGLE )
26- e3 :SetCode (EFFECT_UPDATE_ATTACK )
27- e3 :SetValue (s .attackup )
25+ e3 :SetDescription (aux .Stringid (id ,1 ))
26+ e3 :SetCategory (CATEGORY_DESTROY )
27+ e3 :SetType (EFFECT_TYPE_IGNITION )
28+ e3 :SetRange (LOCATION_MZONE )
29+ e3 :SetCost (Cost .RemoveCounterFromSelf (COUNTER_SPELL ,2 ))
30+ e3 :SetTarget (s .destg )
31+ e3 :SetOperation (s .desop )
2832 c :RegisterEffect (e3 )
29- -- destroy
33+ -- Special Summon 1 "Arcanite Magician" from your GY
3034 local e4 = Effect .CreateEffect (c )
31- e4 :SetDescription (aux .Stringid (id ,1 ))
32- e4 :SetCategory (CATEGORY_DESTROY )
33- e4 :SetType (EFFECT_TYPE_IGNITION )
34- e4 :SetRange (LOCATION_MZONE )
35- e4 :SetCost (s .descost )
36- e4 :SetTarget (s .destg )
37- e4 :SetOperation (s .desop )
35+ e4 :SetDescription (aux .Stringid (id ,2 ))
36+ e4 :SetCategory (CATEGORY_SPECIAL_SUMMON )
37+ e4 :SetType (EFFECT_TYPE_SINGLE + EFFECT_TYPE_TRIGGER_O )
38+ e4 :SetProperty (EFFECT_FLAG_CARD_TARGET )
39+ e4 :SetCode (EVENT_DESTROYED )
40+ e4 :SetCondition (function (e ) return e :GetHandler ():IsPreviousLocation (LOCATION_ONFIELD ) end )
41+ e4 :SetTarget (s .sptg )
42+ e4 :SetOperation (s .spop )
3843 c :RegisterEffect (e4 )
39- -- Special summon
40- local e5 = Effect .CreateEffect (c )
41- e5 :SetDescription (aux .Stringid (id ,2 ))
42- e5 :SetType (EFFECT_TYPE_TRIGGER_O + EFFECT_TYPE_SINGLE )
43- e5 :SetCategory (CATEGORY_SPECIAL_SUMMON )
44- e5 :SetProperty (EFFECT_FLAG_CARD_TARGET )
45- e5 :SetCode (EVENT_DESTROYED )
46- e5 :SetCondition (s .spcon )
47- e5 :SetTarget (s .sptg )
48- e5 :SetOperation (s .spop )
49- c :RegisterEffect (e5 )
5044end
5145s .counter_place_list = {COUNTER_SPELL }
52- s .listed_names = {CARD_ASSAULT_MODE ,31924889 }
46+ s .listed_names = {CARD_ASSAULT_MODE ,31924889 } -- "Arcanite Magician"
5347s .assault_mode = 31924889
54- function s .addct (e ,tp ,eg ,ep ,ev ,re ,r ,rp ,chk )
55- if chk == 0 then return true end
56- Duel .SetOperationInfo (0 ,CATEGORY_COUNTER ,nil ,2 ,0 ,COUNTER_SPELL )
57- end
58- function s .addc (e ,tp ,eg ,ep ,ev ,re ,r ,rp )
59- if e :GetHandler ():IsRelateToEffect (e ) then
60- e :GetHandler ():AddCounter (COUNTER_SPELL ,2 )
48+ function s .counterop (e ,tp ,eg ,ep ,ev ,re ,r ,rp )
49+ local c = e :GetHandler ()
50+ if c :IsRelateToEffect (e ) then
51+ c :AddCounter (COUNTER_SPELL ,2 )
6152 end
6253end
63- function s .attackup (e ,c )
64- return c :GetCounter (COUNTER_SPELL )* 1000
65- end
66- function s .descost (e ,tp ,eg ,ep ,ev ,re ,r ,rp ,chk )
67- if chk == 0 then return e :GetHandler ():IsCanRemoveCounter (tp ,COUNTER_SPELL ,2 ,REASON_COST ) end
68- e :GetHandler ():RemoveCounter (tp ,COUNTER_SPELL ,2 ,REASON_COST )
69- end
7054function s .destg (e ,tp ,eg ,ep ,ev ,re ,r ,rp ,chk )
71- if chk == 0 then return Duel .IsExistingMatchingCard ( aux . TRUE , tp ,0 ,LOCATION_ONFIELD , 1 , nil ) end
72- local g = Duel . GetMatchingGroup ( aux . TRUE , tp , 0 , LOCATION_ONFIELD , nil )
73- Duel .SetOperationInfo (0 ,CATEGORY_DESTROY ,g ,# g ,0 ,0 )
55+ local g = Duel .GetFieldGroup ( tp ,0 ,LOCATION_ONFIELD )
56+ if chk == 0 then return # g > 0 end
57+ Duel .SetOperationInfo (0 ,CATEGORY_DESTROY ,g ,# g ,tp ,0 )
7458end
7559function s .desop (e ,tp ,eg ,ep ,ev ,re ,r ,rp )
76- local g = Duel .GetMatchingGroup (aux .TRUE ,tp ,0 ,LOCATION_ONFIELD ,nil )
77- Duel .Destroy (g ,REASON_EFFECT )
78- end
79- function s .spcon (e ,tp ,eg ,ep ,ev ,re ,r ,rp )
80- return e :GetHandler ():IsPreviousLocation (LOCATION_ONFIELD )
60+ local g = Duel .GetFieldGroup (tp ,0 ,LOCATION_ONFIELD )
61+ if # g > 0 then
62+ Duel .Destroy (g ,REASON_EFFECT )
63+ end
8164end
8265function s .spfilter (c ,e ,tp )
8366 return c :IsCode (31924889 ) and c :IsCanBeSpecialSummoned (e ,0 ,tp ,false ,false )
@@ -88,11 +71,11 @@ function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
8871 and Duel .IsExistingTarget (s .spfilter ,tp ,LOCATION_GRAVE ,0 ,1 ,nil ,e ,tp ) end
8972 Duel .Hint (HINT_SELECTMSG ,tp ,HINTMSG_SPSUMMON )
9073 local g = Duel .SelectTarget (tp ,s .spfilter ,tp ,LOCATION_GRAVE ,0 ,1 ,1 ,nil ,e ,tp )
91- Duel .SetOperationInfo (0 ,CATEGORY_SPECIAL_SUMMON ,g ,1 ,0 ,0 )
74+ Duel .SetOperationInfo (0 ,CATEGORY_SPECIAL_SUMMON ,g ,1 ,tp ,0 )
9275end
9376function s .spop (e ,tp ,eg ,ep ,ev ,re ,r ,rp )
9477 local tc = Duel .GetFirstTarget ()
95- if tc and tc :IsRelateToEffect (e ) then
78+ if tc :IsRelateToEffect (e ) then
9679 Duel .SpecialSummon (tc ,0 ,tp ,tp ,false ,false ,POS_FACEUP )
9780 end
9881end
0 commit comments