Commit 07f05e84 authored by Tachibana's avatar Tachibana

ybb

parent 8a43c03b
Pipeline #10200 passed with stages
in 33 minutes and 52 seconds
No preview for this file type
......@@ -33,7 +33,7 @@ end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_DECK,0,1,nil) end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK)
if Duel.GetMatchingGroupCount(cm.checkfilter,tp,LOCATION_MZONE,0,nil) then
if Duel.GetMatchingGroupCount(cm.checkfilter,tp,LOCATION_MZONE,0,nil)>0 then
e:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_DRAW)
end
end
......@@ -44,7 +44,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
if Duel.IsPlayerCanDraw(tp,1)
and Duel.GetMatchingGroupCount(cm.checkfilter,tp,LOCATION_MZONE,0,nil)
and Duel.GetMatchingGroupCount(cm.checkfilter,tp,LOCATION_MZONE,0,nil)>0
and Duel.SelectYesNo(tp,aux.Stringid(m,0)) then
Duel.BreakEffect()
Duel.ShuffleDeck(tp)
......
......@@ -145,9 +145,7 @@ function cm.operation(e,tp,eg,ep,ev,re,r,rp)
end
--Effect 3
function cm.chainop(e,tp,eg,ep,ev,re,r,rp)
if ep==1-tp then
Duel.SetChainLimit(aux.FALSE)
end
Duel.SetChainLimit(function(e,ep,tp) return ep~=e:GetHandlerPlayer() end)
end
--Effect 4
function cm.namecon(e,tp,eg,ep,ev,re,r,rp)
......
......@@ -54,7 +54,7 @@ function cm.conf2(c,tp)
return bit.band(c:GetType(),0x82)==0x82 and c:IsControler(tp)
end
function cm.con2(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(cm.conf2,1,nil,tp)
return eg:IsExists(cm.conf2,1,nil,tp) and not e:GetHandler():IsStatus(STATUS_CHAINING)
end
function cm.tgf2(c)
return bit.band(c:GetType(),0x82)==0x82 and c:IsAbleToHand()
......
......@@ -24,10 +24,13 @@ c:EnableReviveLimit()
c:RegisterEffect(e1)
--activate
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e3:SetCode(EVENT_TO_GRAVE)
e3:SetOperation(cm.regop)
e3:SetDescription(aux.Stringid(m,2))
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_PHASE+PHASE_END)
e3:SetRange(LOCATION_GRAVE)
e3:SetCost(cm.thcost)
e3:SetTarget(cm.acttg)
e3:SetOperation(cm.actop)
c:RegisterEffect(e3)
end
function cm.matfilter(c)
......@@ -44,7 +47,7 @@ end
function cm.desreptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return eg:IsExists(cm.repfilter,1,nil,tp)
and Duel.IsExistingMatchingCard(cm.desfilter,tp,LOCATION_GRAVE,0,3,nil,e,tp) end
if Duel.SelectYesNo(tp,aux.Stringid(m,0)) then
if Duel.SelectYesNo(tp,aux.Stringid(m,1)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(tp,cm.desfilter,tp,LOCATION_GRAVE,0,3,3,nil,e,tp)
g:KeepAlive()
......@@ -58,27 +61,12 @@ function cm.desrepval(e,c)
end
function cm.desrepop(e,tp,eg,ep,ev,re,r,rp)
local tg=e:GetLabelObject()
Duel.SendtoDeck(tg,nil,SEQ_DECKSHUFFLE,REASON_EFFECT)
end
function cm.regop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
if c:IsPreviousLocation(LOCATION_ONFIELD) then
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_TOHAND)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_PHASE+PHASE_END)
e1:SetRange(LOCATION_GRAVE)
--e1:SetCountLimit(1,m)
e1:SetCost(cm.thcost)
e1:SetTarget(cm.acttg)
e1:SetOperation(cm.actop)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1)
end
Duel.SendtoDeck(tg,nil,2,REASON_EFFECT+REASON_REPLACE)
end
function cm.thcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToExtraAsCost() end
Duel.SendtoDeck(e:GetHandler(),nil,SEQ_DECKSHUFFLE,REASON_EFFECT)
Duel.SendtoDeck(e:GetHandler(),nil,2,REASON_COST)
end
function cm.actfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsAbleToHand()
......@@ -94,4 +82,4 @@ function cm.actop(e,tp,eg,ep,ev,re,r,rp)
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
end
end
\ No newline at end of file
......@@ -29,6 +29,9 @@ function cm.initial_effect(c)
e3:SetCondition(cm.indcon)
e3:SetValue(aux.ChangeBattleDamage(1,HALF_DAMAGE))
c:RegisterEffect(e3)
local e4=e3:Clone()
e4:SetValue(aux.ChangeBattleDamage(0,HALF_DAMAGE))
c:RegisterEffect(e4)
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(m,0))
e3:SetType(EFFECT_TYPE_QUICK_O)
......
......@@ -26,7 +26,7 @@ function cm.initial_effect(c)
c:RegisterEffect(e1)
end
function cm.filter(c)
return c:IsFaceup() and c:IsSetCard(0xb71) and c:IsType(TYPE_MONSTER) and c:IsAbleToGraveAsCost()
return c:IsFaceup() and c:IsSetCard(0x3b71) and c:IsType(TYPE_MONSTER) and c:IsAbleToGraveAsCost()
end
function cm.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.filter,tp,LOCATION_ONFIELD,0,1,nil) end
......@@ -57,7 +57,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
end
function cm.filter1(c)
return c:IsFaceup() and c:IsSetCard(0xb71) and c:IsType(TYPE_MONSTER) and c:IsAbleToDeckAsCost()
return c:IsFaceup() and c:IsSetCard(0x3b71) and c:IsType(TYPE_MONSTER) and c:IsAbleToDeckAsCost()
end
function cm.cost1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(cm.filter1,tp,LOCATION_ONFIELD,0,1,nil) end
......
......@@ -12,7 +12,7 @@ function cm.initial_effect(c)
e0:SetType(EFFECT_TYPE_FIELD)
e0:SetCode(EFFECT_SPSUMMON_PROC)
e0:SetRange(LOCATION_EXTRA)
e2:SetCountLimit(1,m+EFFECT_COUNT_CODE_DUEL)
e0:SetCountLimit(1,m+EFFECT_COUNT_CODE_DUEL)
e0:SetCondition(function(e,c,og,min,max)
if c==nil then return true end
local tp=c:GetControler()
......
......@@ -6,7 +6,7 @@ function c9330010.initial_effect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCountLimit(1,9330009+EFFECT_COUNT_CODE_OATH)
e1:SetCountLimit(1,9330010+EFFECT_COUNT_CODE_OATH)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
e1:SetTarget(c9330010.target)
e1:SetOperation(c9330010.activate)
......
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