Skip to content

Commit 94edc95

Browse files
committed
added Magma Dragon
1 parent d7851ad commit 94edc95

2 files changed

Lines changed: 44 additions & 1 deletion

File tree

proc_rush.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ local LEGEND_LIST={160001000,160205001,160418001,160002000,160421015,160404001,1
1111
160320038,160018036,160212004,160212003,160402044,160212075,160212001,160402045,160019063,160019064,160019065,
1212
160213078,160213082,160402047,160213084,160020059,160213076,160020001,160020040,160020000,160214052,160323029,
1313
160214020,160021065,160021027,160402052,160215086,160324001,160402055,160324022,160023000,160217058,160024000,
14-
160024029,160402062}
14+
160024029,160402062,160402064}
1515
-- Returns if a card is a Legend. Can be updated if a GetOT function is added to the core
1616
function Card.IsLegend(c)
1717
return c:IsHasEffect(EFFECT_IS_LEGEND) or c:IsOriginalCode(table.unpack(LEGEND_LIST))

rush/c160402064.lua

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
--マグマ・ドラゴン
2+
--Magma Dragon
3+
--scripted by YoshiDuels
4+
local s,id=GetID()
5+
function s.initial_effect(c)
6+
--Special Summon 1 monster from the hand
7+
local e1=Effect.CreateEffect(c)
8+
e1:SetDescription(aux.Stringid(id,0))
9+
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
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+
end
18+
function s.condition(e,tp,eg,ep,ev,re,r,rp)
19+
local c=e:GetHandler()
20+
return c:IsSummonPhaseMain() and c:IsStatus(STATUS_SUMMON_TURN+STATUS_SPSUMMON_TURN)
21+
end
22+
function s.spfilter(c,e,tp)
23+
return c:IsRace(RACE_WYRM) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE)
24+
end
25+
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
26+
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
27+
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,0,tp,LOCATION_GRAVE)
28+
end
29+
function s.operation(e,tp,eg,ep,ev,re,r,rp)
30+
--Effect
31+
if Duel.GetLocationCount(tp,LOCATION_MZONE)<1 then return end
32+
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
33+
local g=Duel.SelectMatchingCard(tp,s.spfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
34+
Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP_DEFENSE)
35+
--Cannot activate its effects
36+
local e1=Effect.CreateEffect(e:GetHandler())
37+
e1:SetDescription(3302)
38+
e1:SetProperty(EFFECT_FLAG_CLIENT_HINT)
39+
e1:SetType(EFFECT_TYPE_SINGLE)
40+
e1:SetCode(EFFECT_CANNOT_TRIGGER)
41+
e1:SetReset(RESETS_STANDARD_PHASE_END)
42+
g:GetFirst():RegisterEffect(e1)
43+
end

0 commit comments

Comments
 (0)