Commit 7486d2f7 authored by POLYMER's avatar POLYMER

fix

parent 482f06f9
No preview for this file type
...@@ -177,8 +177,13 @@ end ...@@ -177,8 +177,13 @@ end
function c28318027.rcop(e,tp,eg,ep,ev,re,r,rp) function c28318027.rcop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if not c:IsRelateToEffect(e) or c:IsFacedown() then return end if not c:IsRelateToEffect(e) or c:IsFacedown() then return end
local tc=Duel.SelectMatchingCard(tp,c28318027.rcfilter,tp,LOCATION_MZONE,0,1,1,nil,c:GetRank()):GetFirst() local g=Duel.GetMatchingGroup(c28318027.rcfilter,tp,LOCATION_MZONE,0,nil,c:GetRank())
if not tc then return end if #g==0 then return end
local tc=g:GetFirst()
if #g>1 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
tc=g:Select(tp,1,1,nil):GetFirst()
end
Duel.HintSelection(Group.FromCards(tc)) Duel.HintSelection(Group.FromCards(tc))
if Duel.SelectOption(tp,aux.Stringid(28318027,3),aux.Stringid(28318027,4))==0 then if Duel.SelectOption(tp,aux.Stringid(28318027,3),aux.Stringid(28318027,4))==0 then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
......
...@@ -18,8 +18,7 @@ function c28322413.initial_effect(c) ...@@ -18,8 +18,7 @@ function c28322413.initial_effect(c)
e1:SetCategory(CATEGORY_TODECK) e1:SetCategory(CATEGORY_TODECK)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET) e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET)
e1:SetRange(LOCATION_MZONE)
e1:SetCondition(c28322413.tdcon) e1:SetCondition(c28322413.tdcon)
e1:SetCost(c28322413.tdcost) e1:SetCost(c28322413.tdcost)
e1:SetTarget(c28322413.tdtg) e1:SetTarget(c28322413.tdtg)
...@@ -90,8 +89,9 @@ function c28322413.Operation(f,gf,minct,maxct) ...@@ -90,8 +89,9 @@ function c28322413.Operation(f,gf,minct,maxct)
end end
c:SetMaterial(mg) c:SetMaterial(mg)
c:RegisterFlagEffect(28322413,RESET_EVENT+RESETS_STANDARD-RESET_TOFIELD,0,1,mg:GetFirst():GetLevel()) c:RegisterFlagEffect(28322413,RESET_EVENT+RESETS_STANDARD-RESET_TOFIELD,0,1,mg:GetFirst():GetLevel())
local check=mg:GetClassCount(Card.GetLevel)==1
Duel.Overlay(c,mg) Duel.Overlay(c,mg)
if mg:GetClassCount(Card.GetLevel)==1 then if check then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
......
...@@ -90,8 +90,9 @@ function c28366684.Operation(f,gf,minct,maxct) ...@@ -90,8 +90,9 @@ function c28366684.Operation(f,gf,minct,maxct)
end end
c:SetMaterial(mg) c:SetMaterial(mg)
c:RegisterFlagEffect(28366684,RESET_EVENT+RESETS_STANDARD-RESET_TOFIELD,0,1,mg:GetFirst():GetLevel()) c:RegisterFlagEffect(28366684,RESET_EVENT+RESETS_STANDARD-RESET_TOFIELD,0,1,mg:GetFirst():GetLevel())
local check=mg:GetClassCount(Card.GetLevel)==1
Duel.Overlay(c,mg) Duel.Overlay(c,mg)
if mg:GetClassCount(Card.GetLevel)==1 then if check then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
......
...@@ -83,6 +83,7 @@ end ...@@ -83,6 +83,7 @@ end
function s.tgop(e,tp,eg,ep,ev,re,r,rp) function s.tgop(e,tp,eg,ep,ev,re,r,rp)
local p=e:GetLabel() local p=e:GetLabel()
local te=e:GetLabelObject() local te=e:GetLabelObject()
Duel.ConfirmDecktop(tp,1)
Duel.DiscardDeck(tp,1,REASON_EFFECT) Duel.DiscardDeck(tp,1,REASON_EFFECT)
local tc=Duel.GetOperatedGroup():GetFirst() local tc=Duel.GetOperatedGroup():GetFirst()
if tc then if tc then
......
...@@ -7,7 +7,7 @@ function cm.initial_effect(c) ...@@ -7,7 +7,7 @@ function cm.initial_effect(c)
e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_DRAW) e1:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH+CATEGORY_DRAW)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCondition(cm.condition) e1:SetCondition(cm.con)
e1:SetTarget(cm.target) e1:SetTarget(cm.target)
e1:SetOperation(cm.activate) e1:SetOperation(cm.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
...@@ -15,7 +15,7 @@ end ...@@ -15,7 +15,7 @@ end
function cm.cfilter(c) function cm.cfilter(c)
return c:IsFaceup() and c:IsRace(RACE_CYBERSE) and c:IsAttribute(ATTRIBUTE_DARK) return c:IsFaceup() and c:IsRace(RACE_CYBERSE) and c:IsAttribute(ATTRIBUTE_DARK)
end end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp) function cm.con(e,tp,eg,ep,ev,re,r,rp)
local ct=Duel.GetFieldGroupCount(tp,LOCATION_MZONE,0) local ct=Duel.GetFieldGroupCount(tp,LOCATION_MZONE,0)
return ct==0 or ct==Duel.GetMatchingGroupCount(cm.cfilter,tp,LOCATION_MZONE,0,nil) return ct==0 or ct==Duel.GetMatchingGroupCount(cm.cfilter,tp,LOCATION_MZONE,0,nil)
end end
......
...@@ -37,7 +37,7 @@ function s.spfilter(c,e,tp) ...@@ -37,7 +37,7 @@ function s.spfilter(c,e,tp)
return c.hackclad==1 and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c.hackclad==1 and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
function s.costfilter(c) function s.costfilter(c)
return c:IsType(TYPE_SPELL) and c:IsDiscardable() return c:IsType(TYPE_SPELL) and c:IsAbleToGraveAsCost()
end end
function s.thfilter(c) function s.thfilter(c)
return _G["c"..c:GetCode()] and _G["c"..c:GetCode()].hackclad and not c:IsCode(id) and c:IsAbleToHand() return _G["c"..c:GetCode()] and _G["c"..c:GetCode()].hackclad and not c:IsCode(id) and c:IsAbleToHand()
...@@ -106,8 +106,10 @@ function s.mvalue(e,fp,rp,r) ...@@ -106,8 +106,10 @@ function s.mvalue(e,fp,rp,r)
return 1-Duel.GetFieldGroupCount(fp,LOCATION_SZONE,0) return 1-Duel.GetFieldGroupCount(fp,LOCATION_SZONE,0)
end end
function s.drcost(e,tp,eg,ep,ev,re,r,rp,chk) function s.drcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.costfilter,tp,LOCATION_HAND,0,1,e:GetHandler()) end if chk==0 then return Duel.IsExistingMatchingCard(s.costfilter,tp,LOCATION_HAND+LOCATION_ONFIELD,0,1,e:GetHandler()) end
Duel.DiscardHand(tp,s.costfilter,1,1,REASON_COST+REASON_DISCARD) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TOGRAVE)
local g=Duel.SelectMatchingCard(tp,s.costfilter,tp,LOCATION_ONFIELD+LOCATION_HAND,0,1,1,nil)
Duel.SendtoGrave(g,REASON_COST)
end end
function s.drtg(e,tp,eg,ep,ev,re,r,rp,chk) function s.drtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then if chk==0 then
......
...@@ -17,6 +17,7 @@ function s.initial_effect(c) ...@@ -17,6 +17,7 @@ function s.initial_effect(c)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_FLIP) e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_FLIP)
e2:SetCountLimit(1,id)
e2:SetCost(s.drcost) e2:SetCost(s.drcost)
e2:SetTarget(s.drtg) e2:SetTarget(s.drtg)
e2:SetOperation(s.drop) e2:SetOperation(s.drop)
......
...@@ -53,6 +53,9 @@ function c91300031.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -53,6 +53,9 @@ function c91300031.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local g=Duel.SelectTarget(tp,c91300031.filter1,tp,LOCATION_MZONE,0,1,1,nil,e,tp) local g=Duel.SelectTarget(tp,c91300031.filter1,tp,LOCATION_MZONE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_EXTRA) Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,1,tp,LOCATION_EXTRA)
if e:IsHasType(EFFECT_TYPE_ACTIVATE) then
Duel.SetChainLimit(aux.FALSE)
end
end end
function c91300031.activate(e,tp,eg,ep,ev,re,r,rp) function c91300031.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
......
...@@ -4,27 +4,14 @@ function s.initial_effect(c) ...@@ -4,27 +4,14 @@ function s.initial_effect(c)
--spsummon --spsummon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_QUICK_O) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetCode(EVENT_TO_GRAVE)
e1:SetRange(LOCATION_HAND) e1:SetRange(LOCATION_HAND)
e1:SetCountLimit(1,EFFECT_COUNT_CODE_CHAIN) e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_MAIN_END)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCondition(s.spcon) e1:SetCondition(s.spcon)
e1:SetTarget(s.sptg) e1:SetTarget(s.sptg)
e1:SetOperation(s.spop) e1:SetOperation(s.spop)
c:RegisterEffect(e1) c:RegisterEffect(e1)
if not s.global_check then
s.global_check=true
local ge1=Effect.CreateEffect(c)
ge1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge1:SetCode(EVENT_TO_GRAVE)
ge1:SetCondition(s.checkcon)
ge1:SetOperation(s.checkop)
Duel.RegisterEffect(ge1,0)
local ge2=ge1:Clone()
ge2:SetCode(EVENT_REMOVE)
Duel.RegisterEffect(ge2,0)
end
--sno0 --sno0
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_DRAW+CATEGORY_HANDES) e2:SetCategory(CATEGORY_DRAW+CATEGORY_HANDES)
...@@ -46,17 +33,6 @@ function s.initial_effect(c) ...@@ -46,17 +33,6 @@ function s.initial_effect(c)
c:RegisterEffect(e3) c:RegisterEffect(e3)
end end
s.hackclad=2 s.hackclad=2
function s.checkcon(e,tp,eg,ep,ev,re,r,rp)
return not re or not re:IsActivated()
end
function s.checkop(e,tp,eg,ep,ev,re,r,rp)
local tc=eg:GetFirst()
while tc do
Duel.RegisterFlagEffect(tp,id,RESET_PHASE+PHASE_END,0,1)
Duel.RegisterFlagEffect(1-tp,id,RESET_PHASE+PHASE_END,0,1)
tc=eg:GetNext()
end
end
function s.spfilter(c,e,tp) function s.spfilter(c,e,tp)
return c.hackclad==1 and c:IsCanBeSpecialSummoned(e,0,tp,false,false) return c.hackclad==1 and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end end
...@@ -76,7 +52,7 @@ function s.drfilter2(c,code) ...@@ -76,7 +52,7 @@ function s.drfilter2(c,code)
return c:IsCode(code) and c:IsAbleToHand() return c:IsCode(code) and c:IsAbleToHand()
end end
function s.spcon(e,tp,eg,ep,ev,re,r,rp) function s.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFlagEffect(tp,id)>=3 return #eg>=2
end end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(1-tp,LOCATION_MZONE,tp)>0 if chk==0 then return Duel.GetLocationCount(1-tp,LOCATION_MZONE,tp)>0
......
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