Commit 239d1e34 authored by mercury233's avatar mercury233

fix

parent cafcf9ec
...@@ -32,41 +32,41 @@ function c43994202.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -32,41 +32,41 @@ function c43994202.target(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function c43994202.activate(e,tp,eg,ep,ev,re,r,rp) function c43994202.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g1=Duel.SelectMatchingCard(tp,c43994202.filter,tp,LOCATION_DECK,1,1,nil,tp) local g1=Duel.SelectMatchingCard(tp,c43994202.filter,tp,LOCATION_DECK,0,1,1,nil,tp)
if g1:GetCount()<=0 then return end if g1:GetCount()<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local g2=Duel.SelectMatchingCard(tp,c43994202.filter2,tp,LOCATION_DECK,2,2,g1,g1:GetFirst():GetCode()) local g2=Duel.SelectMatchingCard(tp,c43994202.filter2,tp,LOCATION_DECK,0,2,2,g1,g1:GetFirst():GetCode())
g1:Merge(g2) g1:Merge(g2)
if Duel.SendtoHand(g1,nil,REASON_EFFECT)>0 then if Duel.SendtoHand(g1,nil,REASON_EFFECT)>0 then
Duel.ConfirmCards(1-tp,g1)
if not e:IsHasType(EFFECT_TYPE_ACTIVATE) then return end if not e:IsHasType(EFFECT_TYPE_ACTIVATE) then return end
local tc=sg:GetFirst() local code=g1:GetFirst():GetCode()
local e0=Effect.CreateEffect(e:GetHandler()) local e0=Effect.CreateEffect(e:GetHandler())
e0:SetType(EFFECT_TYPE_FIELD) e0:SetType(EFFECT_TYPE_FIELD)
e0:SetProperty(EFFECT_FLAG_PLAYER_TARGET) e0:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e0:SetCode(EFFECT_CANNOT_ACTIVATE) e0:SetCode(EFFECT_CANNOT_ACTIVATE)
e0:SetTargetRange(1,0) e0:SetTargetRange(1,0)
e0:SetValue(c43994202.aclimit) e0:SetValue(c43994202.aclimit)
e0:SetLabelObject(tc) e0:SetLabel(code)
e0:SetReset(RESET_PHASE+PHASE_END) e0:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e0,tp) Duel.RegisterEffect(e0,tp)
local e1=e0:Clone() local e1=e0:Clone()
e1:SetCode(EFFECT_CANNOT_SUMMON) e1:SetCode(EFFECT_CANNOT_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH) e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH)
e1:SetTarget(c43994202.splimit) e1:SetTarget(c43994202.splimit)
e1:SetValue(1)
Duel.RegisterEffect(e1,tp) Duel.RegisterEffect(e1,tp)
local e2=e1:Clone() local e2=e1:Clone()
e2:SetCode(EFFECT_CANNOT_SET) e2:SetCode(EFFECT_CANNOT_SET)
Duel.RegisterEffect(e2,tp) Duel.RegisterEffect(e2,tp)
local e3=e1:Clone() local e3=e1:Clone()
e3:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e3:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
Duel.RegisterEffect(e33,tp) Duel.RegisterEffect(e3,tp)
end end
end end
function c43994202.aclimit(e,re,tp) function c43994202.aclimit(e,re,tp)
local tc=e:GetLabelObject() return re:GetHandler():IsCode(e:GetLabel()) and re:IsActiveType(TYPE_MONSTER) and not re:GetHandler():IsImmuneToEffect(e)
return re:GetHandler():IsCode(tc:GetCode()) and re:IsActiveType(TYPE_MONSTER) and not re:GetHandler():IsImmuneToEffect(e)
end end
function c43994202.splimit(e,c,sump,sumtype,sumpos,targetp) function c43994202.splimit(e,c,sump,sumtype,sumpos,targetp)
local tc=e:GetLabelObject() return c:IsCode(e:GetLabel())
return not c:IsCode(tc:GetCode())
end end
...@@ -55,7 +55,7 @@ function c4478086.spcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -55,7 +55,7 @@ function c4478086.spcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c4478086.cfilter,1,nil,lg) return eg:IsExists(c4478086.cfilter,1,nil,lg)
end end
function c4478086.filter(c,e,tp) function c4478086.filter(c,e,tp)
return c:IsLevelBelow(4) and c:IsRace(RACE_CYBERSE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE) return c:IsLevelBelow(4) and c:IsRace(RACE_CYBERSE) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP)
end end
function c4478086.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c4478086.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c4478086.filter(chkc,e,tp) end if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and c4478086.filter(chkc,e,tp) end
...@@ -68,7 +68,7 @@ end ...@@ -68,7 +68,7 @@ end
function c4478086.spop(e,tp,eg,ep,ev,re,r,rp) function c4478086.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) and Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP_DEFENSE)~=0 then if tc:IsRelateToEffect(e) and Duel.SpecialSummonStep(tc,0,tp,tp,false,false,POS_FACEUP)~=0 then
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE) e1:SetCode(EFFECT_DISABLE)
......
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