Commit 1ef07d04 authored by POLYMER's avatar POLYMER

fix

parent 1211158f
...@@ -14,7 +14,7 @@ function cm.initial_effect(c) ...@@ -14,7 +14,7 @@ function cm.initial_effect(c)
e10:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE) e10:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e10:SetCondition(cm.condition0) e10:SetCondition(cm.condition0)
e10:SetOperation(cm.operation0) e10:SetOperation(cm.operation0)
--c:RegisterEffect(e10) c:RegisterEffect(e10)
--cannot be destroyed --cannot be destroyed
local e7=Effect.CreateEffect(c) local e7=Effect.CreateEffect(c)
e7:SetType(EFFECT_TYPE_SINGLE) e7:SetType(EFFECT_TYPE_SINGLE)
...@@ -93,11 +93,13 @@ function cm.operation0(e,tp,eg,ep,ev,re,r,rp) ...@@ -93,11 +93,13 @@ function cm.operation0(e,tp,eg,ep,ev,re,r,rp)
e1:SetDescription(aux.Stringid(m,1)) e1:SetDescription(aux.Stringid(m,1))
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_OATH)
e1:SetCode(EVENT_PHASE+PHASE_END) if e:IsHasType(EFFECT_TYPE_ACTIVATE) then
e1:SetCode(EVENT_PHASE+PHASE_END)
end
e1:SetCountLimit(1) e1:SetCountLimit(1)
e1:SetRange(LOCATION_FZONE) e1:SetRange(LOCATION_FZONE)
e1:SetOperation(cm.tgop) e1:SetOperation(cm.tgop)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,5) e1:SetReset(RESET_EVENT+RESETS_STANDARD) --+RESET_PHASE+PHASE_END,5)
c:SetTurnCounter(0) c:SetTurnCounter(0)
c:RegisterEffect(e1) c:RegisterEffect(e1)
cm[c]=e1 cm[c]=e1
......
...@@ -6,6 +6,7 @@ function s.initial_effect(c) ...@@ -6,6 +6,7 @@ function s.initial_effect(c)
e1:SetDescription(aux.Stringid(id,0)) e1:SetDescription(aux.Stringid(id,0))
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(TIMING_STANDBY_PHASE)
e1:SetOperation(s.activate) e1:SetOperation(s.activate)
e1:SetCountLimit(1,id+EFFECT_COUNT_CODE_OATH) e1:SetCountLimit(1,id+EFFECT_COUNT_CODE_OATH)
c:RegisterEffect(e1) c:RegisterEffect(e1)
...@@ -15,6 +16,9 @@ function s.initial_effect(c) ...@@ -15,6 +16,9 @@ function s.initial_effect(c)
e2:SetCondition(s.handcon) e2:SetCondition(s.handcon)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function s.handcon(e)
return Duel.GetCurrentPhase()==PHASE_STANDBY
end
function s.activate(e,tp,eg,ep,ev,re,r,rp) function s.activate(e,tp,eg,ep,ev,re,r,rp)
local e4=Effect.CreateEffect(e:GetHandler()) local e4=Effect.CreateEffect(e:GetHandler())
e4:SetDescription(aux.Stringid(id,2)) e4:SetDescription(aux.Stringid(id,2))
...@@ -28,9 +32,6 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -28,9 +32,6 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp)
e4:SetReset(RESET_PHASE+PHASE_END) e4:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e4,tp) Duel.RegisterEffect(e4,tp)
end end
function s.handcon(e)
return Duel.GetCurrentPhase()==PHASE_STANDBY
end
function s.costtg(e,te,tp) function s.costtg(e,te,tp)
e:SetLabelObject(te:GetHandler()) e:SetLabelObject(te:GetHandler())
return true return true
......
...@@ -46,15 +46,31 @@ function cm.initial_effect(c) ...@@ -46,15 +46,31 @@ function cm.initial_effect(c)
ge1:SetCode(EVENT_ADJUST) ge1:SetCode(EVENT_ADJUST)
ge1:SetOperation(c22348060.checkop1) ge1:SetOperation(c22348060.checkop1)
Duel.RegisterEffect(ge1,0) Duel.RegisterEffect(ge1,0)
local ge2=Effect.CreateEffect(c)
ge2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge2:SetCode(EVENT_LEAVE_FIELD)
ge2:SetOperation(c22348060.checkop2)
Duel.RegisterEffect(ge2,0)
end end
end end
local KOISHI_CHECK=false local KOISHI_CHECK=false
if Card.SetCardData then KOISHI_CHECK=true end if Card.SetCardData then KOISHI_CHECK=true end
function c22348060.checkfilter(c)
return c:IsOriginalCodeRule(22348060)
end
function c22348060.checkop2(e,tp,eg,ep,ev,re,r,rp)
local g=eg:Filter(c22348060.checkfilter,nil)
local tc=g:GetFirst()
while tc do
tc:RegisterFlagEffect(22348060,RESET_CHAIN,0,1)
tc=g:GetNext()
end
end
function c22348060.filter1(c) function c22348060.filter1(c)
return c:IsOriginalCodeRule(22348060) and c:IsFacedown() and c:IsHasEffect(EFFECT_CHANGE_TYPE) and c:IsType(TYPE_TRAP) and c:GetOriginalType()~=TYPE_TRAP return c:IsOriginalCodeRule(22348060) and c:IsFacedown() and c:IsHasEffect(EFFECT_CHANGE_TYPE) and c:IsType(TYPE_TRAP) and c:GetOriginalType()~=TYPE_TRAP
end end
function c22348060.filter2(c) function c22348060.filter2(c)
return c:IsOriginalCodeRule(22348060) and c:IsFaceup() and c:GetOriginalType()~=0x200021 return c:IsOriginalCodeRule(22348060) and c:IsFaceup() and c:GetOriginalType()~=0x200021 and not Duel.GetFlagEffect(tp,22348060)
end end
function c22348060.checkop1(e,tp,eg,ep,ev,re,r,rp) function c22348060.checkop1(e,tp,eg,ep,ev,re,r,rp)
local phase=Duel.GetCurrentPhase() local phase=Duel.GetCurrentPhase()
......
...@@ -46,15 +46,31 @@ function cm.initial_effect(c) ...@@ -46,15 +46,31 @@ function cm.initial_effect(c)
ge1:SetCode(EVENT_ADJUST) ge1:SetCode(EVENT_ADJUST)
ge1:SetOperation(c22348061.checkop1) ge1:SetOperation(c22348061.checkop1)
Duel.RegisterEffect(ge1,0) Duel.RegisterEffect(ge1,0)
local ge2=Effect.CreateEffect(c)
ge2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge2:SetCode(EVENT_LEAVE_FIELD)
ge2:SetOperation(c22348061.checkop2)
Duel.RegisterEffect(ge2,0)
end end
end end
local KOISHI_CHECK=false local KOISHI_CHECK=false
if Card.SetCardData then KOISHI_CHECK=true end if Card.SetCardData then KOISHI_CHECK=true end
function c22348061.checkfilter(c)
return c:IsOriginalCodeRule(22348061)
end
function c22348061.checkop2(e,tp,eg,ep,ev,re,r,rp)
local g=eg:Filter(c22348061.checkfilter,nil)
local tc=g:GetFirst()
while tc do
tc:RegisterFlagEffect(22348061,RESET_CHAIN,0,1)
tc=g:GetNext()
end
end
function c22348061.filter1(c) function c22348061.filter1(c)
return c:IsOriginalCodeRule(22348061) and c:IsFacedown() and c:IsHasEffect(EFFECT_CHANGE_TYPE) and c:IsType(TYPE_TRAP) and c:GetOriginalType()~=TYPE_TRAP return c:IsOriginalCodeRule(22348061) and c:IsFacedown() and c:IsHasEffect(EFFECT_CHANGE_TYPE) and c:IsType(TYPE_TRAP) and c:GetOriginalType()~=TYPE_TRAP
end end
function c22348061.filter2(c) function c22348061.filter2(c)
return c:IsOriginalCodeRule(22348061) and c:IsFaceup() and c:GetOriginalType()~=0x200021 return c:IsOriginalCodeRule(22348061) and c:IsFaceup() and c:GetOriginalType()~=0x200021 and not Duel.GetFlagEffect(tp,22348061)
end end
function c22348061.checkop1(e,tp,eg,ep,ev,re,r,rp) function c22348061.checkop1(e,tp,eg,ep,ev,re,r,rp)
local phase=Duel.GetCurrentPhase() local phase=Duel.GetCurrentPhase()
......
...@@ -35,6 +35,7 @@ function cm.initial_effect(c) ...@@ -35,6 +35,7 @@ function cm.initial_effect(c)
e3:SetCode(EVENT_CHAINING) e3:SetCode(EVENT_CHAINING)
e3:SetRange(LOCATION_GRAVE) e3:SetRange(LOCATION_GRAVE)
e3:SetCondition(c22348062.spcon) e3:SetCondition(c22348062.spcon)
e3:SetCost(aux.bfgcost)
e3:SetTarget(c22348062.sttg) e3:SetTarget(c22348062.sttg)
e3:SetOperation(c22348062.stop) e3:SetOperation(c22348062.stop)
c:RegisterEffect(e3) c:RegisterEffect(e3)
...@@ -45,15 +46,31 @@ function cm.initial_effect(c) ...@@ -45,15 +46,31 @@ function cm.initial_effect(c)
ge1:SetCode(EVENT_ADJUST) ge1:SetCode(EVENT_ADJUST)
ge1:SetOperation(c22348062.checkop1) ge1:SetOperation(c22348062.checkop1)
Duel.RegisterEffect(ge1,0) Duel.RegisterEffect(ge1,0)
local ge2=Effect.CreateEffect(c)
ge2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge2:SetCode(EVENT_LEAVE_FIELD)
ge2:SetOperation(c22348062.checkop2)
Duel.RegisterEffect(ge2,0)
end end
end end
local KOISHI_CHECK=false local KOISHI_CHECK=false
if Card.SetCardData then KOISHI_CHECK=true end if Card.SetCardData then KOISHI_CHECK=true end
function c22348062.checkfilter(c)
return c:IsOriginalCodeRule(22348062)
end
function c22348062.checkop2(e,tp,eg,ep,ev,re,r,rp)
local g=eg:Filter(c22348062.checkfilter,nil)
local tc=g:GetFirst()
while tc do
tc:RegisterFlagEffect(22348062,RESET_CHAIN,0,1)
tc=g:GetNext()
end
end
function c22348062.filter1(c) function c22348062.filter1(c)
return c:IsOriginalCodeRule(22348062) and c:IsFacedown() and c:IsHasEffect(EFFECT_CHANGE_TYPE) and c:IsType(TYPE_TRAP) and c:GetOriginalType()~=TYPE_TRAP return c:IsOriginalCodeRule(22348062) and c:IsFacedown() and c:IsHasEffect(EFFECT_CHANGE_TYPE) and c:IsType(TYPE_TRAP) and c:GetOriginalType()~=TYPE_TRAP
end end
function c22348062.filter2(c) function c22348062.filter2(c)
return c:IsOriginalCodeRule(22348062) and c:IsFaceup() and c:GetOriginalType()~=0x200021 return c:IsOriginalCodeRule(22348062) and c:IsFaceup() and c:GetOriginalType()~=0x200021 and not Duel.GetFlagEffect(tp,22348062)
end end
function c22348062.checkop1(e,tp,eg,ep,ev,re,r,rp) function c22348062.checkop1(e,tp,eg,ep,ev,re,r,rp)
local phase=Duel.GetCurrentPhase() local phase=Duel.GetCurrentPhase()
......
...@@ -34,6 +34,7 @@ function cm.initial_effect(c) ...@@ -34,6 +34,7 @@ function cm.initial_effect(c)
e3:SetCode(EVENT_CHAINING) e3:SetCode(EVENT_CHAINING)
e3:SetRange(LOCATION_GRAVE) e3:SetRange(LOCATION_GRAVE)
e3:SetCondition(c22348063.spcon) e3:SetCondition(c22348063.spcon)
e3:SetCost(aux.bfgcost)
e3:SetTarget(c22348063.thtg) e3:SetTarget(c22348063.thtg)
e3:SetOperation(c22348063.thop) e3:SetOperation(c22348063.thop)
c:RegisterEffect(e3) c:RegisterEffect(e3)
...@@ -44,15 +45,31 @@ function cm.initial_effect(c) ...@@ -44,15 +45,31 @@ function cm.initial_effect(c)
ge1:SetCode(EVENT_ADJUST) ge1:SetCode(EVENT_ADJUST)
ge1:SetOperation(c22348063.checkop1) ge1:SetOperation(c22348063.checkop1)
Duel.RegisterEffect(ge1,0) Duel.RegisterEffect(ge1,0)
local ge2=Effect.CreateEffect(c)
ge2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge2:SetCode(EVENT_LEAVE_FIELD)
ge2:SetOperation(c22348063.checkop2)
Duel.RegisterEffect(ge2,0)
end end
end end
local KOISHI_CHECK=false local KOISHI_CHECK=false
if Card.SetCardData then KOISHI_CHECK=true end if Card.SetCardData then KOISHI_CHECK=true end
function c22348063.checkfilter(c)
return c:IsOriginalCodeRule(22348063)
end
function c22348063.checkop2(e,tp,eg,ep,ev,re,r,rp)
local g=eg:Filter(c22348063.checkfilter,nil)
local tc=g:GetFirst()
while tc do
tc:RegisterFlagEffect(22348063,RESET_CHAIN,0,1)
tc=g:GetNext()
end
end
function c22348063.filter1(c) function c22348063.filter1(c)
return c:IsOriginalCodeRule(22348063) and c:IsFacedown() and c:IsHasEffect(EFFECT_CHANGE_TYPE) and c:IsType(TYPE_TRAP) and c:GetOriginalType()~=TYPE_TRAP return c:IsOriginalCodeRule(22348063) and c:IsFacedown() and c:IsHasEffect(EFFECT_CHANGE_TYPE) and c:IsType(TYPE_TRAP) and c:GetOriginalType()~=TYPE_TRAP
end end
function c22348063.filter2(c) function c22348063.filter2(c)
return c:IsOriginalCodeRule(22348063) and c:IsFaceup() and c:GetOriginalType()~=0x200021 return c:IsOriginalCodeRule(22348063) and c:IsFaceup() and c:GetOriginalType()~=0x200021 and not Duel.GetFlagEffect(tp,22348063)
end end
function c22348063.checkop1(e,tp,eg,ep,ev,re,r,rp) function c22348063.checkop1(e,tp,eg,ep,ev,re,r,rp)
local phase=Duel.GetCurrentPhase() local phase=Duel.GetCurrentPhase()
......
...@@ -47,15 +47,31 @@ function cm.initial_effect(c) ...@@ -47,15 +47,31 @@ function cm.initial_effect(c)
ge1:SetCode(EVENT_ADJUST) ge1:SetCode(EVENT_ADJUST)
ge1:SetOperation(c22348064.checkop1) ge1:SetOperation(c22348064.checkop1)
Duel.RegisterEffect(ge1,0) Duel.RegisterEffect(ge1,0)
local ge2=Effect.CreateEffect(c)
ge2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
ge2:SetCode(EVENT_LEAVE_FIELD)
ge2:SetOperation(c22348064.checkop2)
Duel.RegisterEffect(ge2,0)
end end
end end
local KOISHI_CHECK=false local KOISHI_CHECK=false
if Card.SetCardData then KOISHI_CHECK=true end if Card.SetCardData then KOISHI_CHECK=true end
function c22348064.checkfilter(c)
return c:IsOriginalCodeRule(22348064)
end
function c22348064.checkop2(e,tp,eg,ep,ev,re,r,rp)
local g=eg:Filter(c22348064.checkfilter,nil)
local tc=g:GetFirst()
while tc do
tc:RegisterFlagEffect(22348064,RESET_CHAIN,0,1)
tc=g:GetNext()
end
end
function c22348064.filter1(c) function c22348064.filter1(c)
return c:IsOriginalCodeRule(22348064) and c:IsFacedown() and c:IsHasEffect(EFFECT_CHANGE_TYPE) and c:IsType(TYPE_TRAP) and c:GetOriginalType()~=TYPE_TRAP return c:IsOriginalCodeRule(22348064) and c:IsFacedown() and c:IsHasEffect(EFFECT_CHANGE_TYPE) and c:IsType(TYPE_TRAP) and c:GetOriginalType()~=TYPE_TRAP
end end
function c22348064.filter2(c) function c22348064.filter2(c)
return c:IsOriginalCodeRule(22348064) and c:IsFaceup() and c:GetOriginalType()~=0x200021 return c:IsOriginalCodeRule(22348064) and c:IsFaceup() and c:GetOriginalType()~=0x200021 and not Duel.GetFlagEffect(tp,22348064)
end end
function c22348064.checkop1(e,tp,eg,ep,ev,re,r,rp) function c22348064.checkop1(e,tp,eg,ep,ev,re,r,rp)
local phase=Duel.GetCurrentPhase() local phase=Duel.GetCurrentPhase()
......
...@@ -89,8 +89,9 @@ function c28318027.Operation(f,gf,minct,maxct) ...@@ -89,8 +89,9 @@ function c28318027.Operation(f,gf,minct,maxct)
end end
c:SetMaterial(mg) c:SetMaterial(mg)
c:RegisterFlagEffect(28318027,RESET_EVENT+RESETS_STANDARD-RESET_TOFIELD,0,1,mg:GetFirst():GetLevel()) c:RegisterFlagEffect(28318027,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)
......
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