Skip to content

Commit 0306d18

Browse files
committed
added Command Knight
1 parent 828b8e4 commit 0306d18

2 files changed

Lines changed: 31 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,160402064,160219001}
14+
160024029,160402062,160402064,160219001,160402065}
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/c160402065.lua

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
--コマンド・ナイト
2+
--Command Knight
3+
--scripted by YoshiDuels
4+
local s,id=GetID()
5+
function s.initial_effect(c)
6+
--cannot be battle target
7+
local e1=Effect.CreateEffect(c)
8+
e1:SetType(EFFECT_TYPE_SINGLE)
9+
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
10+
e1:SetRange(LOCATION_MZONE)
11+
e1:SetCode(EFFECT_CANNOT_BE_BATTLE_TARGET)
12+
e1:SetCondition(s.ccon)
13+
e1:SetValue(aux.imval1)
14+
c:RegisterEffect(e1)
15+
--atk
16+
local e2=Effect.CreateEffect(c)
17+
e2:SetType(EFFECT_TYPE_FIELD)
18+
e2:SetRange(LOCATION_MZONE)
19+
e2:SetTargetRange(LOCATION_MZONE,0)
20+
e2:SetCode(EFFECT_UPDATE_ATTACK)
21+
e2:SetTarget(aux.TargetBoolFunction(Card.IsRace,RACE_WARRIOR))
22+
e2:SetValue(400)
23+
c:RegisterEffect(e2)
24+
end
25+
function s.filter(c)
26+
return c:IsFaceup() and c:IsRace(RACE_WARRIOR)
27+
end
28+
function s.ccon(e)
29+
return Duel.IsExistingMatchingCard(s.filter,e:GetHandlerPlayer(),LOCATION_MZONE,0,1,e:GetHandler())
30+
end

0 commit comments

Comments
 (0)