Added Universe Destruction
This commit is contained in:
BIN
UniverseDeck.cdb
BIN
UniverseDeck.cdb
Binary file not shown.
BIN
card pics/Universe Destruction/561586067.jpg
Normal file
BIN
card pics/Universe Destruction/561586067.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 27 KiB |
BIN
card pics/Universe Destruction/Universe Destruction.jpg
Normal file
BIN
card pics/Universe Destruction/Universe Destruction.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 390 KiB |
BIN
card pics/Universe Destruction/Universe Destruction.png
Normal file
BIN
card pics/Universe Destruction/Universe Destruction.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 552 KiB |
1
jsons/Universe Destruction.json
Normal file
1
jsons/Universe Destruction.json
Normal file
File diff suppressed because one or more lines are too long
@@ -3,7 +3,7 @@ local s,id=GetID()
|
|||||||
function s.initial_effect(c)
|
function s.initial_effect(c)
|
||||||
--pendulum summon
|
--pendulum summon
|
||||||
Pendulum.AddProcedure(c)
|
Pendulum.AddProcedure(c)
|
||||||
--atk change, pendulum effect
|
--pendulum effect
|
||||||
local e1=Effect.CreateEffect(c)
|
local e1=Effect.CreateEffect(c)
|
||||||
e1:SetType(EFFECT_TYPE_FIELD)
|
e1:SetType(EFFECT_TYPE_FIELD)
|
||||||
e1:SetCode(EFFECT_UPDATE_ATTACK)
|
e1:SetCode(EFFECT_UPDATE_ATTACK)
|
||||||
|
|||||||
49
lua/c561586067.lua
Normal file
49
lua/c561586067.lua
Normal file
@@ -0,0 +1,49 @@
|
|||||||
|
--Universe Arrival
|
||||||
|
local s,id=GetID()
|
||||||
|
function s.initial_effect(c)
|
||||||
|
--Activate
|
||||||
|
local e1=Effect.CreateEffect(c)
|
||||||
|
e1:SetCategory(CATEGORY_TOGRAVE)
|
||||||
|
e1:SetType(EFFECT_TYPE_ACTIVATE)
|
||||||
|
e1:SetCode(EVENT_FREE_CHAIN)
|
||||||
|
e1:SetCost(s.cost)
|
||||||
|
e1:SetTarget(s.thtg)
|
||||||
|
e1:SetOperation(s.activate)
|
||||||
|
e1:SetOperation(s.thop)
|
||||||
|
c:RegisterEffect(e1)
|
||||||
|
|
||||||
|
end
|
||||||
|
--Discard function
|
||||||
|
function s.costfilter(c)
|
||||||
|
return c:IsAbleToGrave() and c:IsSetCard(0x25e) and c:IsType(TYPE_MONSTER)
|
||||||
|
end
|
||||||
|
function s.cost(e,tp,eg,ep,ev,re,r,rp,chk)
|
||||||
|
if chk==0 then return Duel.IsExistingMatchingCard(s.costfilter,tp,LOCATION_DECK,0,1,nil) end
|
||||||
|
Duel.SetOperationInfo(0,CATEGORY_TOGRAVE,nil,1,tp,LOCATION_DECK)
|
||||||
|
end
|
||||||
|
function s.activate(e,tp,eg,ep,ev,re,r,rp)
|
||||||
|
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
|
||||||
|
local g=Duel.SelectMatchingCard(tp,s.costfilter,tp,LOCATION_DECK,0,1,1,nil)
|
||||||
|
if #g>0 then
|
||||||
|
Duel.SendtoGrave(g,REASON_EFFECT)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
--Destroy function
|
||||||
|
function s.tgfilter(c)
|
||||||
|
return c:IsFaceup()
|
||||||
|
end
|
||||||
|
function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
|
||||||
|
if chkc then return chkc:IsControler(1-tp) and s.tgfilter(chkc) end
|
||||||
|
if chk==0 then return Duel.IsExistingTarget(s.tgfilter,tp,0,LOCATION_MZONE,1,nil) end
|
||||||
|
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
|
||||||
|
local g=Duel.SelectTarget(tp,s.tgfilter,tp,0,LOCATION_MZONE,1,1,nil)
|
||||||
|
Duel.SetTargetPlayer(1-tp)
|
||||||
|
end
|
||||||
|
function s.thop(e,tp,eg,ep,ev,re,r,rp)
|
||||||
|
local tc=Duel.GetFirstTarget()
|
||||||
|
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
|
||||||
|
if tc and tc:IsRelateToEffect(e) then
|
||||||
|
Duel.Destroy(tc, REASON_DESTROY)
|
||||||
|
end
|
||||||
|
end
|
||||||
Reference in New Issue
Block a user