Commit 759d5d5e authored by POLYMER's avatar POLYMER

fix

parent 7a33cbe7
......@@ -97,7 +97,7 @@ function cm.imop(e,tp,eg,ep,ev,re,r,rp)
Duel.RegisterEffect(e1,tp)
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(0x20000000+m)
e2:SetCode(0x20000000+m+1)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetRange(LOCATION_GRAVE)
e2:SetTargetRange(1,0)
......@@ -105,7 +105,7 @@ function cm.imop(e,tp,eg,ep,ev,re,r,rp)
e:GetHandler():RegisterEffect(e2)
end
function cm.flcon(e)
return Duel.GetFlagEffect(e:GetHandlerPlayer(),m)~=0
return Duel.GetFlagEffect(e:GetHandlerPlayer(),m+1)~=0
end
function cm.thop(e,tp,eg,ep,ev,re,r,rp)
if rp==1-tp and e:GetLabel()==1 then return end
......
--D.H.P.K.-奈娜
local s,id,o=GetID()
function s.initial_effect(c)
--act limit
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_CANNOT_NEGATE)
e1:SetCode(EFFECT_CANNOT_TRIGGER)
e1:SetRange(0xff)
e1:SetCondition(s.actcon)
c:RegisterEffect(e1)
if not s.global_flag then
s.global_flag=true
--act limit
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_TRIGGER)
e1:SetTargetRange(0xff,0xff)
e1:SetTarget(s.disable)
Duel.RegisterEffect(e1,0)
end
--search
local e2=Effect.CreateEffect(c)
e2:SetDescription(1109)
......@@ -34,9 +36,12 @@ function s.initial_effect(c)
e3:SetOperation(s.spop)
c:RegisterEffect(e3)
end
function s.actcon(e)
local tp=e:GetHandlerPlayer()
return Duel.IsExistingMatchingCard(s.ndcfilter,tp,LOCATION_MZONE,0,1,nil)
s.limt_name_hpk=id
function s.disable(e,c)
if c.limt_name_hpk~=id then return end
local tp=c:GetControler()
return (c:IsType(TYPE_EFFECT) or c:GetOriginalType()&TYPE_EFFECT~=0)
and Duel.IsExistingMatchingCard(s.ndcfilter,tp,LOCATION_MZONE,0,1,nil)
end
function s.ndcfilter(c)
return c:IsFacedown() or not c:IsSetCard(0x5a71)
......@@ -71,7 +76,10 @@ function s.spfilter(c,e,tp,ec)
end
function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return Duel.CheckReleaseGroup(REASON_EFFECT,tp,s.tgfilter,1,c,e,tp) end
if chk==0 then
local res=Duel.CheckReleaseGroup(REASON_EFFECT,tp,s.tgfilter,1,c,e,tp)
if res==nil then res=Duel.CheckReleaseGroup(tp,s.tgfilter,1,c,e,tp) end
return res end
Duel.SetOperationInfo(0,CATEGORY_RELEASE,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_EXTRA)
end
......@@ -79,6 +87,7 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local g=Duel.SelectReleaseGroup(REASON_EFFECT,tp,s.tgfilter,1,1,c,e,tp)
if g==nil then g=Duel.SelectReleaseGroup(tp,s.tgfilter,1,1,c,e,tp) end
local tc=g:GetFirst()
if tc and Duel.Release(tc,REASON_EFFECT)~=0 then
local sg=Duel.GetMatchingGroup(s.spfilter,tp,LOCATION_EXTRA,0,nil,e,tp,tc)
......
......@@ -46,6 +46,7 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
end
e:SetCategory(ctgy)
Duel.Hint(HINT_OPSELECTED,1-tp,aux.Stringid(id,1))
end
s.chain_id_scl[cct] = op
end
......
......@@ -45,6 +45,7 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
ctgy = ctgy + CATEGORY_DRAW
end
e:SetCategory(ctgy)
Duel.Hint(HINT_OPSELECTED,1-tp,aux.Stringid(id,1))
end
s.chain_id_scl[cct] = op
end
......
......@@ -42,6 +42,7 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
ctgy = ctgy + CATEGORY_DISABLE
end
e:SetCategory(ctgy)
Duel.Hint(HINT_OPSELECTED,1-tp,aux.Stringid(id,1))
end
s.chain_id_scl[cct] = op
end
......
......@@ -60,6 +60,7 @@ function s.mixtg(e,tp,eg,ep,ev,re,r,rp,chk)
ctgy = ctgy + CATEGORY_DISABLE
end
e:SetCategory(ctgy)
Duel.Hint(HINT_OPSELECTED,1-tp,aux.Stringid(id,1))
end
s.chain_id_scl[cct] = op
end
......
......@@ -74,10 +74,10 @@ function cm.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SendtoDeck(tc,nil,SEQ_DECKSHUFFLE,REASON_EFFECT)~=0 and (tc:IsLocation(LOCATION_EXTRA)or tc:IsLocation(LOCATION_DECK)) then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g2=Duel.SelectMatchingCard(tp,cmspfilter,tp,LOCATION_DECK+LOCATION_EXTRA,0,1,1,nil,e,tp)
local g2=Duel.SelectMatchingCard(tp,cm.spfilter,tp,LOCATION_DECK+LOCATION_EXTRA,0,1,1,nil,e,tp)
if g2:GetCount()>0 then
Duel.BreakEffect()
Duel.SpecialSummon(g2,0,tp,tp,false,false,POS_FACEUP)
Duel.SpecialSummon(g2,0,tp,tp,true,false,POS_FACEUP)
end
end
end
\ No newline at end of file
......@@ -46,7 +46,7 @@ end
function s.Xyzfilter(c,sc)
return c:IsFaceup() and c:IsCanBeXyzMaterial(sc) and c:IsXyzLevel(sc,4)
end
function s.XyzCondition(e,c,og)
function s.XyzCondition(e,c,og,min,max)
if c==nil then return true end
if c:IsType(TYPE_PENDULUM) and c:IsFaceup() then return false end
local tp=c:GetControler()
......@@ -59,7 +59,7 @@ function s.XyzCondition(e,c,og)
end
end
function s.XyzTarget(e,tp,eg,ep,ev,re,r,rp,chk,c,og)
function s.XyzTarget(e,tp,eg,ep,ev,re,r,rp,chk,c,og,min,max)
local g=Group.CreateGroup()
if og then
g=Duel.SelectXyzMaterial(tp,c,aux.TRUE,4,3,3,og)
......@@ -76,8 +76,8 @@ function s.XyzTarget(e,tp,eg,ep,ev,re,r,rp,chk,c,og)
return true
else return false end
end
function s.XyzOperation(e,tp,eg,ep,ev,re,r,rp,c,og)
if og then
function s.XyzOperation(e,tp,eg,ep,ev,re,r,rp,c,og,min,max)
if og and not min then
local sg=Group.CreateGroup()
local tc=og:GetFirst()
while tc do
......
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