Commit 7aafaf12 authored by POLYMER's avatar POLYMER

fix

parent a1369023
...@@ -14,7 +14,6 @@ function c10111122.initial_effect(c) ...@@ -14,7 +14,6 @@ function c10111122.initial_effect(c)
e7:SetType(EFFECT_TYPE_QUICK_O+EFFECT_TYPE_TRIGGER_F) e7:SetType(EFFECT_TYPE_QUICK_O+EFFECT_TYPE_TRIGGER_F)
e7:SetCode(EVENT_BATTLE_START) e7:SetCode(EVENT_BATTLE_START)
e7:SetRange(LOCATION_MZONE) e7:SetRange(LOCATION_MZONE)
e7:SetCountLimit(1)
e7:SetCondition(c10111122.ctcon) e7:SetCondition(c10111122.ctcon)
e7:SetTarget(c10111122.cttg) e7:SetTarget(c10111122.cttg)
e7:SetOperation(c10111122.ctop) e7:SetOperation(c10111122.ctop)
......
...@@ -32,7 +32,7 @@ function s.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -32,7 +32,7 @@ function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
if e:IsHasType(EFFECT_TYPE_ACTIVATE) then if e:IsHasType(EFFECT_TYPE_ACTIVATE) then
if Duel.GetTurnPlayer()==1-tp then if Duel.GetTurnPlayer()==1-tp then
e:SetCategory(CATEGORY_SPECIAL_SUMMON) e:SetCategory(CATEGORY_SPECIAL_SUMMON)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
e:SetLabel(1) e:SetLabel(1)
else else
e:SetLabel(0) e:SetLabel(0)
......
...@@ -34,6 +34,7 @@ function cm.initial_effect(c) ...@@ -34,6 +34,7 @@ function cm.initial_effect(c)
e3:SetType(EFFECT_TYPE_QUICK_O) e3:SetType(EFFECT_TYPE_QUICK_O)
e3:SetCode(EVENT_CHAINING) e3:SetCode(EVENT_CHAINING)
e3:SetRange(LOCATION_MZONE) e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,EFFECT_COUNT_CODE_CHAIN)
e3:SetCondition(cm.dscon) e3:SetCondition(cm.dscon)
e3:SetTarget(cm.rmtg) e3:SetTarget(cm.rmtg)
e3:SetOperation(cm.rmop) e3:SetOperation(cm.rmop)
......
...@@ -40,7 +40,7 @@ function cm.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -40,7 +40,7 @@ function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) end
if chk==0 then return Duel.IsExistingMatchingCard(nil,tp,LOCATION_MZONE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(nil,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
Duel.SelectTarget(tp,nil,tp,LOCATION_MZONE,0,1,1,nil,) Duel.SelectTarget(tp,nil,tp,LOCATION_MZONE,0,1,1,nil)
Duel.SetOperationInfo(0,CATEGORY_ATKCHANGE,nil,0,tp,0) Duel.SetOperationInfo(0,CATEGORY_ATKCHANGE,nil,0,tp,0)
end end
function cm.atkop(e,tp,eg,ep,ev,re,r,rp) function cm.atkop(e,tp,eg,ep,ev,re,r,rp)
...@@ -53,7 +53,7 @@ function cm.atkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -53,7 +53,7 @@ function cm.atkop(e,tp,eg,ep,ev,re,r,rp)
e0:SetCode(EFFECT_UPDATE_ATTACK) e0:SetCode(EFFECT_UPDATE_ATTACK)
e0:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE) e0:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
e0:SetValue(1000) e0:SetValue(1000)
c:RegisterEffect(e0) tc:RegisterEffect(e0)
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_EXTRA_ATTACK) e1:SetCode(EFFECT_EXTRA_ATTACK)
...@@ -68,7 +68,7 @@ function cm.atkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -68,7 +68,7 @@ function cm.atkop(e,tp,eg,ep,ev,re,r,rp)
e2:SetReset(RESET_PHASE+PHASE_END) e2:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
end end
if tc:IsType(TYPE_XYZ) and g:CheckSubGroup(cm.filter,1,99,1-tp) then if tc:IsType(TYPE_XYZ) and g:IsExists(cm.filter,1,nil,1-tp) then
local aa=g:FilterSelect(1-tp,cm.filter,1,1,nil,1-tp) local aa=g:FilterSelect(1-tp,cm.filter,1,1,nil,1-tp)
Duel.SendtoGrave(aa,REASON_RULE) Duel.SendtoGrave(aa,REASON_RULE)
end end
......
...@@ -178,7 +178,7 @@ function c28322413.ruop(e,tp,eg,ep,ev,re,r,rp) ...@@ -178,7 +178,7 @@ function c28322413.ruop(e,tp,eg,ep,ev,re,r,rp)
local og=Duel.GetOperatedGroup() local og=Duel.GetOperatedGroup()
local ct=og:FilterCount(Card.IsLocation,nil,LOCATION_DECK+LOCATION_EXTRA) local ct=og:FilterCount(Card.IsLocation,nil,LOCATION_DECK+LOCATION_EXTRA)
if ct>0 then if ct>0 then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_ADJUST) e1:SetCode(EVENT_ADJUST)
e1:SetCondition(c28322413.adcon) e1:SetCondition(c28322413.adcon)
......
...@@ -149,12 +149,12 @@ function s.chtg(_tg) ...@@ -149,12 +149,12 @@ function s.chtg(_tg)
return _tg(e,c,...) return _tg(e,c,...)
end end
end end
function s.GetSynMaterials(tp,syncard) function s.SMatCatch(tp,syncard)
local g=aux.GetSynMaterials(tp,syncard) local g=aux.GetSynMaterials(tp,syncard)
local mg=Duel.GetMatchingGroup(s.IsCanBeSynchroMaterial,tp,0x10,0x1c,g,syncard) local mg=Duel.GetMatchingGroup(s.SMatCheck,tp,0x10,0x1c,g,syncard)
return Group.__add(g,mg) return Group.__add(g,mg)
end end
function s.IsCanBeSynchroMaterial(c,syncard) function s.SMatCheck(c,syncard)
if not (c:IsCanBeSynchroMaterial(syncard) or c:IsLevel(0)) then return false end if not (c:IsCanBeSynchroMaterial(syncard) or c:IsLevel(0)) then return false end
if c:IsStatus(STATUS_FORBIDDEN) then return false end if c:IsStatus(STATUS_FORBIDDEN) then return false end
if c:IsHasEffect(EFFECT_CANNOT_BE_SYNCHRO_MATERIAL) then return false end if c:IsHasEffect(EFFECT_CANNOT_BE_SYNCHRO_MATERIAL) then return false end
...@@ -170,7 +170,7 @@ function s.IsCanBeSynchroMaterial(c,syncard) ...@@ -170,7 +170,7 @@ function s.IsCanBeSynchroMaterial(c,syncard)
else return false end else return false end
return true return true
end end
function s.GetSynchroLevel(c,sc) function s.SLevelCal(c,sc)
local lv=c:GetSynchroLevel(sc) local lv=c:GetSynchroLevel(sc)
local tp=sc:GetControler() local tp=sc:GetControler()
local b1=c:IsLocation(LOCATION_GRAVE) and c:IsLevel(0) and (c:GetControler()~=tp or sc:GetOriginalCode()==53752002) local b1=c:IsLocation(LOCATION_GRAVE) and c:IsLevel(0) and (c:GetControler()~=tp or sc:GetOriginalCode()==53752002)
...@@ -186,7 +186,7 @@ function s.lindfilter(c) ...@@ -186,7 +186,7 @@ function s.lindfilter(c)
end end
function s.lvs(c,syncard) function s.lvs(c,syncard)
if not c then return 0 end if not c then return 0 end
local lv=s.GetSynchroLevel(c,syncard) local lv=s.SLevelCal(c,syncard)
local lv2=lv>>16 local lv2=lv>>16
lv=lv&0xffff lv=lv&0xffff
if lv2>0 then return lv,lv2 else return lv end if lv2>0 then return lv,lv2 else return lv end
...@@ -260,21 +260,21 @@ function s.SynMixCondition(e,c,smat,mg1,min,max) ...@@ -260,21 +260,21 @@ function s.SynMixCondition(e,c,smat,mg1,min,max)
if Duel.IsPlayerAffectedByEffect(tp,8173184) then if Duel.IsPlayerAffectedByEffect(tp,8173184) then
Duel.RegisterFlagEffect(tp,8173184+1,0,0,1) Duel.RegisterFlagEffect(tp,8173184+1,0,0,1)
end end
if smat and not s.IsCanBeSynchroMaterial(smat,c) then if smat and not s.SMatCheck(smat,c) then
Duel.ResetFlagEffect(tp,8173184+1) Duel.ResetFlagEffect(tp,8173184+1)
return false return false
end end
local mg local mg
local mgchk=false local mgchk=false
if mg1 then if mg1 then
mg=mg1:Filter(s.IsCanBeSynchroMaterial,nil,c) mg=mg1:Filter(s.SMatCheck,nil,c)
mgchk=true mgchk=true
else else
mg=s.GetSynMaterials(tp,c) mg=s.SMatCatch(tp,c)
end end
if smat~=nil then mg:AddCard(smat) end if smat~=nil then mg:AddCard(smat) end
Auxiliary.SubGroupCaptured=Group.CreateGroup() Auxiliary.SubGroupCaptured=Group.CreateGroup()
SNNM.SubGroupParams={s.slfilter,s.GetSynchroLevel,nil,true,true,{c},{c}} SNNM.SubGroupParams={s.slfilter,s.SLevelCal,nil,true,true,{c},{c}}
aux.GCheckAdditional=s.gcheck(c) aux.GCheckAdditional=s.gcheck(c)
local res=SNNM.SelectSubGroup(mg,tp,s.syngoal,Duel.IsSummonCancelable(),2,#mg,c,smat,tp,mgchk) local res=SNNM.SelectSubGroup(mg,tp,s.syngoal,Duel.IsSummonCancelable(),2,#mg,c,smat,tp,mgchk)
aux.GCheckAdditional=nil aux.GCheckAdditional=nil
...@@ -327,13 +327,13 @@ function s.SynMixTarget(e,tp,eg,ep,ev,re,r,rp,chk,c) ...@@ -327,13 +327,13 @@ function s.SynMixTarget(e,tp,eg,ep,ev,re,r,rp,chk,c)
local mg local mg
local mgchk=false local mgchk=false
if mg1 then if mg1 then
mg=mg1:Filter(s.IsCanBeSynchroMaterial,nil,c) mg=mg1:Filter(s.SMatCheck,nil,c)
mgchk=true mgchk=true
else else
mg=s.GetSynMaterials(tp,c) mg=s.SMatCatch(tp,c)
end end
if smat~=nil then mg:AddCard(smat) end if smat~=nil then mg:AddCard(smat) end
SNNM.SubGroupParams={s.slfilter,s.GetSynchroLevel,nil,true,false,{c},{c}} SNNM.SubGroupParams={s.slfilter,s.SLevelCal,nil,true,false,{c},{c}}
aux.GCheckAdditional=s.gcheck(c) aux.GCheckAdditional=s.gcheck(c)
local sg=SNNM.SelectSubGroup(mg,tp,s.syngoal,Duel.IsSummonCancelable(),2,#mg,c,smat,tp,mgchk) local sg=SNNM.SelectSubGroup(mg,tp,s.syngoal,Duel.IsSummonCancelable(),2,#mg,c,smat,tp,mgchk)
aux.GCheckAdditional=nil aux.GCheckAdditional=nil
......
...@@ -36,10 +36,10 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -36,10 +36,10 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
local e12=e1:Clone() local e12=e1:Clone()
e12:SetCode(EVENT_SUMMON_SUCCESS) e12:SetCode(EVENT_SUMMON_SUCCESS)
c:RegisterEffect(e12) Duel.RegisterEffect(e12,tp)
local e13=e1:Clone() local e13=e1:Clone()
e13:SetCode(EVENT_FLIP_SUMMON_SUCCESS) e13:SetCode(EVENT_FLIP_SUMMON_SUCCESS)
c:RegisterEffect(e13) Duel.RegisterEffect(e13,tp)
--sp_summon effect --sp_summon effect
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD) e2:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
...@@ -51,10 +51,10 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -51,10 +51,10 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
local e22=e2:Clone() local e22=e2:Clone()
e22:SetCode(EVENT_SUMMON_SUCCESS) e22:SetCode(EVENT_SUMMON_SUCCESS)
c:RegisterEffect(e22) Duel.RegisterEffect(e22,tp)
local e23=e2:Clone() local e23=e2:Clone()
e23:SetCode(EVENT_FLIP_SUMMON_SUCCESS) e23:SetCode(EVENT_FLIP_SUMMON_SUCCESS)
c:RegisterEffect(e23) Duel.RegisterEffect(e23,tp)
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD) e3:SetType(EFFECT_TYPE_CONTINUOUS+EFFECT_TYPE_FIELD)
e3:SetCode(EVENT_CHAIN_SOLVED) e3:SetCode(EVENT_CHAIN_SOLVED)
......
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