Commit 2c182816 authored by 聖園ミカ's avatar 聖園ミカ 🐟

byd

parent 321a0c74
......@@ -10,7 +10,6 @@ local e5=Effect.CreateEffect(c)
e5:SetCountLimit(1,id+EFFECT_COUNT_CODE_OATH)
e5:SetCost(s.cost)
e5:SetProperty(EFFECT_FLAG_CARD_TARGET)
e5:SetCondition(s.thcon)
e5:SetTarget(s.thtg)
e5:SetOperation(s.thop)
c:RegisterEffect(e5)
......
......@@ -7,28 +7,29 @@ local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_ACTIVATE)
e5:SetCode(EVENT_FREE_CHAIN)
e5:SetProperty(EFFECT_FLAG_CARD_TARGET)
e5:SetCondition(s.thcon)
e5:SetTarget(s.thtg)
e5:SetOperation(s.thop)
c:RegisterEffect(e5)
end
function s.thtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(1-tp) and chkc:IsAbleToHand() end
if chk==0 then return Duel.IsExistingTarget(Card.IsAbleToHand,tp,0,LOCATION_GRAVE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g=Duel.SelectTarget(tp,Card.IsAbleToHand,tp,LOCATION_GRAVE,0,1,1,nil)
local g=Duel.SelectTarget(tp,Card.IsAbleToHand,tp,0,LOCATION_GRAVE,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
if e:IsHasType(EFFECT_TYPE_ACTIVATE) then
Duel.SetChainLimit(aux.FALSE)
end
end
function s.thop(e,tp,eg,ep,ev,re,r,rp)
local g2=Duel.GetFieldGroup(tp,0,LOCATION_HAND)
local g1=Duel.GetFieldGroup(tp,0,LOCATION_HAND)
local tc=Duel.GetFirstTarget()
if g1:GetCount()>0 then
Duel.ConfirmCards(tp,g1)
local g=g1:Select(tp,1,1,nil)
if Duel.SendtoGrave(g,REASON_EFFECT)
and tc:IsRelateToEffect(e) then
Duel.SendtoHand(tc,1-tp,REASON_EFFECT)
end
end
end
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment