Skip to content

Commit d559d4f

Browse files
committed
added new rush cards
1 parent f1567b0 commit d559d4f

File tree

2 files changed

+102
-0
lines changed

2 files changed

+102
-0
lines changed

rush/c160020025.lua

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
--スペア・ガジェット
2+
--Spare Gadget
3+
--scripted by YoshiDuels
4+
local s,id=GetID()
5+
function s.initial_effect(c)
6+
--Gain ATK
7+
local e1=Effect.CreateEffect(c)
8+
e1:SetDescription(aux.Stringid(id,1))
9+
e1:SetCategory(CATEGORY_ATKCHANGE|CATEGORY_TOHAND)
10+
e1:SetType(EFFECT_TYPE_IGNITION)
11+
e1:SetRange(LOCATION_MZONE)
12+
e1:SetCountLimit(1)
13+
e1:SetCost(s.cost)
14+
e1:SetTarget(s.target)
15+
e1:SetOperation(s.operation)
16+
c:RegisterEffect(e1)
17+
end
18+
s.listed_names={41172955,86445415,13839120}
19+
function s.cost(e,tp,eg,ep,ev,re,r,rp,chk)
20+
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToGraveAsCost,tp,LOCATION_HAND,0,1,nil) end
21+
end
22+
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
23+
if chk==0 then return true end
24+
Duel.SetOperationInfo(0,CATEGORY_ATKCHANGE,e:GetHandler(),1,tp,800)
25+
Duel.SetPossibleOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_GRAVE)
26+
end
27+
function s.thfilter(c)
28+
return c:IsCode(41172955,86445415,13839120) and c:IsAbleToHand()
29+
end
30+
function s.operation(e,tp,eg,ep,ev,re,r,rp)
31+
--Requirement
32+
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
33+
local g=Duel.SelectMatchingCard(tp,Card.IsAbleToGraveAsCost,tp,LOCATION_HAND,0,1,1,nil)
34+
if Duel.SendtoGrave(g,REASON_COST)<1 then return end
35+
--Effect
36+
local c=e:GetHandler()
37+
local e1=Effect.CreateEffect(c)
38+
e1:SetType(EFFECT_TYPE_SINGLE)
39+
e1:SetCode(EFFECT_UPDATE_ATTACK)
40+
e1:SetValue(800)
41+
e1:SetReset(RESET_EVENT|RESETS_STANDARD_DISABLE|RESET_PHASE|PHASE_END,2)
42+
c:RegisterEffect(e1)
43+
if Duel.IsExistingMatchingCard(aux.NecroValleyFilter(s.thfilter),tp,LOCATION_GRAVE,0,1,nil) and Duel.SelectYesNo(tp,aux.Stringid(id,1)) then
44+
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
45+
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.thfilter),tp,LOCATION_GRAVE,0,1,1,nil)
46+
if #g>0 then
47+
Duel.BreakEffect()
48+
Duel.SendtoHand(g,nil,REASON_EFFECT)
49+
Duel.ConfirmCards(1-tp,g)
50+
end
51+
end
52+
end

rush/c160020049.lua

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
--磁石の騎士β
2+
--Beta the Magnet Cavalry
3+
--scripted by YoshiDuels
4+
local s,id=GetID()
5+
function s.initial_effect(c)
6+
--Fusion Procedure
7+
c:EnableReviveLimit()
8+
Fusion.AddProcMixN(c,true,true,39256679,1,s.matfilter,1)
9+
--1 monster gains 300 ATK and gains piercing
10+
local e1=Effect.CreateEffect(c)
11+
e1:SetDescription(aux.Stringid(id,0))
12+
e1:SetType(CATEGORY_ATKCHANGE)
13+
e1:SetType(EFFECT_TYPE_IGNITION)
14+
e1:SetRange(LOCATION_MZONE)
15+
e1:SetCountLimit(1)
16+
e1:SetCost(s.cost)
17+
e1:SetTarget(s.target)
18+
e1:SetOperation(s.operation)
19+
c:RegisterEffect(e1)
20+
end
21+
s.named_material={39256679}
22+
function s.matfilter(c,scard,sumtype,tp)
23+
return c:IsRace(RACE_ROCK,scard,sumtype,tp) and c:IsLevelBelow(4)
24+
end
25+
function s.cost(e,tp,eg,ep,ev,re,r,rp,chk)
26+
if chk==0 then return Duel.IsPlayerCanDiscardDeckAsCost(tp,2) end
27+
end
28+
function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
29+
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsFaceup,tp,LOCATION_MZONE,0,1,nil) end
30+
end
31+
function s.operation(e,tp,eg,ep,ev,re,r,rp)
32+
local c=e:GetHandler()
33+
--Requirement
34+
if Duel.DiscardDeck(tp,2,REASON_COST)<0 then return end
35+
--Effect
36+
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATKDEF)
37+
local g=Duel.SelectMatchingCard(tp,Card.IsFaceup,tp,LOCATION_MZONE,0,1,1,nil)
38+
if #g>0 then
39+
Duel.HintSelection(g)
40+
local tc=g:GetFirst()
41+
--Gains 300 ATK
42+
local e1=Effect.CreateEffect(c)
43+
e1:SetType(EFFECT_TYPE_SINGLE)
44+
e1:SetCode(EFFECT_UPDATE_ATTACK)
45+
e1:SetValue(300)
46+
e1:SetReset(RESETS_STANDARD_PHASE_END)
47+
tc:RegisterEffect(e1)
48+
tc:AddPiercing(RESETS_STANDARD_PHASE_END,c)
49+
end
50+
end

0 commit comments

Comments
 (0)