Commit 1503a2e1 authored by wind2009's avatar wind2009

Fix

parent 595c0b38
Pipeline #26486 passed with stages
in 55 seconds
No preview for this file type
...@@ -63,7 +63,7 @@ end ...@@ -63,7 +63,7 @@ end
function s.slop(e,tp,eg,ep,ev,re,r,rp) function s.slop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if not tc:IsRelateToEffect(e) or tc:IsFacedown() then return end if not tc:IsRelateToEffect(e) or tc:IsFacedown() or not tc:IsType(TYPE_MONSTER) then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local sg=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.lvfilter),tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,tc:GetLevel(),e,tp) local sg=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.lvfilter),tp,LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,tc:GetLevel(),e,tp)
if sg:GetCount()>0 then if sg:GetCount()>0 then
......
--Krishnerd Witch --Krishnerd Witch
local s,id,o=GetID() local s,id,o=GetID()
function s.initial_effect(c) function s.initial_effect(c)
aux.AddCodeList(c,101204086)
--effect indestructable --effect indestructable
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
...@@ -42,7 +43,7 @@ function s.indcon(e) ...@@ -42,7 +43,7 @@ function s.indcon(e)
return Duel.IsExistingMatchingCard(s.indfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) return Duel.IsExistingMatchingCard(s.indfilter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil)
end end
function s.spfilter(c,tp) function s.spfilter(c,tp)
return c:IsPreviousControler(tp) and c:IsReason(REASON_EFFECT) and c:IsPreviousLocation(LOCATION_FZONE) return c:IsReason(REASON_EFFECT) and c:IsPreviousLocation(LOCATION_FZONE)
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 eg:IsExists(s.spfilter,1,nil,tp) and not eg:IsContains(e:GetHandler()) return eg:IsExists(s.spfilter,1,nil,tp) and not eg:IsContains(e:GetHandler())
...@@ -58,7 +59,6 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -58,7 +59,6 @@ function s.spop(e,tp,eg,ep,ev,re,r,rp)
end end
function s.tdcon(e,tp,eg,ep,ev,re,r,rp) function s.tdcon(e,tp,eg,ep,ev,re,r,rp)
local rc=re:GetHandler() local rc=re:GetHandler()
e:SetLabel(rc:GetCode())
return rc:IsOnField() and rc:IsRelateToEffect(re) and rc:IsLocation(LOCATION_FZONE) and not re:IsHasType(EFFECT_TYPE_ACTIVATE) return rc:IsOnField() and rc:IsRelateToEffect(re) and rc:IsLocation(LOCATION_FZONE) and not re:IsHasType(EFFECT_TYPE_ACTIVATE)
end end
function s.tdfilter(c,e,tp) function s.tdfilter(c,e,tp)
...@@ -74,11 +74,12 @@ function s.tdop(e,tp,eg,ep,ev,re,r,rp) ...@@ -74,11 +74,12 @@ function s.tdop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.tdfilter),tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.tdfilter),tp,LOCATION_GRAVE+LOCATION_REMOVED,0,1,1,nil)
if g:GetCount()>0 then if g:GetCount()>0 then
local tc=g:GetFirst() local tc=g:GetFirst()
local res=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and tc:IsCanBeSpecialSummoned(e,0,tp,false,false) and aux.IsCodeListed(tc,e:GetLabel()) local rc=re:GetHandler()
local res=Duel.GetLocationCount(tp,LOCATION_MZONE)>0 and tc:IsCanBeSpecialSummoned(e,0,tp,false,false) and aux.IsCodeListed(tc,re:GetHandler():GetCode())
if res and Duel.SelectYesNo(tp,aux.Stringid(id,0)) then if res and Duel.SelectYesNo(tp,aux.Stringid(id,0)) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
else else
Duel.ConfirmCards(1-tp,tc) Duel.HintSelection(g)
Duel.SendtoDeck(tc,nil,SEQ_DECKSHUFFLE,REASON_EFFECT) Duel.SendtoDeck(tc,nil,SEQ_DECKSHUFFLE,REASON_EFFECT)
end end
end end
......
...@@ -85,6 +85,7 @@ function s.tdop(e,tp,eg,ep,ev,re,r,rp) ...@@ -85,6 +85,7 @@ function s.tdop(e,tp,eg,ep,ev,re,r,rp)
Duel.BreakEffect() Duel.BreakEffect()
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local dg=Duel.SelectMatchingCard(tp,nil,tp,0,LOCATION_ONFIELD,1,#tg,nil) local dg=Duel.SelectMatchingCard(tp,nil,tp,0,LOCATION_ONFIELD,1,#tg,nil)
Duel.HintSelection(dg)
Duel.Destroy(dg,REASON_EFFECT) Duel.Destroy(dg,REASON_EFFECT)
end end
end end
......
...@@ -31,7 +31,6 @@ function s.accon(e,tp,eg,ep,ev,re,r,rp) ...@@ -31,7 +31,6 @@ function s.accon(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(Card.IsFaceup,tp,LOCATION_FZONE,0,1,nil) return not Duel.IsExistingMatchingCard(Card.IsFaceup,tp,LOCATION_FZONE,0,1,nil)
end end
function s.filter(c) function s.filter(c)
Debug.Message("TestA")
return c:IsType(TYPE_FIELD) and not c:IsForbidden() and c:IsFaceup() return c:IsType(TYPE_FIELD) and not c:IsForbidden() and c:IsFaceup()
end end
function s.mvtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function s.mvtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
...@@ -48,8 +47,8 @@ function s.mvop(e,tp,eg,ep,ev,re,r,rp) ...@@ -48,8 +47,8 @@ function s.mvop(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 not tc:IsImmuneToEffect(e) if tc:IsRelateToEffect(e) and not tc:IsImmuneToEffect(e)
and c:IsRelateToEffect(e) and Duel.Destroy(c,REASON_EFFECT)~=0 then and Duel.Destroy(c,REASON_EFFECT)~=0 and c:IsRelateToEffect(e) then
Duel.MoveToField(tc,tp,tp,LOCATION_FZONE,POS_FACEUP,true) Duel.MoveToField(tc,tp,tp,LOCATION_FZONE,POS_FACEUP,true)
end end
end end
function s.repfilter(c) function s.repfilter(c)
......
--Vouiburial the Dragon Undertaker --Vouiburial the Dragon Undertaker
local s,id,o=GetID() local s,id,o=GetID()
function s.initial_effect(c) function s.initial_effect(c)
aux.AddCodeList(c,63136489)
--indes --indes
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
...@@ -43,7 +42,8 @@ function s.cfilter(c,tp) ...@@ -43,7 +42,8 @@ function s.cfilter(c,tp)
return c:IsPreviousLocation(LOCATION_MZONE) and c:IsPreviousControler(1-tp) return c:IsPreviousLocation(LOCATION_MZONE) and c:IsPreviousControler(1-tp)
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 eg:IsExists(s.cfilter,1,nil,tp) local ph=Duel.GetCurrentPhase()
return (ph==PHASE_MAIN1 or ph==PHASE_MAIN2) and eg:IsExists(s.cfilter,1,nil,tp)
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(tp,LOCATION_MZONE)>0 if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
...@@ -52,7 +52,7 @@ function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -52,7 +52,7 @@ function s.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function s.spop(e,tp,eg,ep,ev,re,r,rp) function s.spop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
if not c:IsRelateToEffect(e) or Duel.GetLocationCount(tp,LOCATION_MZONE)==0 then return end if not c:IsRelateToEffect(e) then return end
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP) Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end end
function s.adfilter(c) function s.adfilter(c)
...@@ -65,6 +65,7 @@ function s.adop(e,tp,eg,ep,ev,re,r,rp) ...@@ -65,6 +65,7 @@ function s.adop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
local g=Duel.SelectMatchingCard(tp,s.adfilter,tp,0,LOCATION_MZONE,1,1,nil) local g=Duel.SelectMatchingCard(tp,s.adfilter,tp,0,LOCATION_MZONE,1,1,nil)
if #g>0 then if #g>0 then
Duel.HintSelection(g)
local tc=g:GetFirst() local tc=g:GetFirst()
local preatk=tc:GetAttack() local preatk=tc:GetAttack()
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
...@@ -73,6 +74,9 @@ function s.adop(e,tp,eg,ep,ev,re,r,rp) ...@@ -73,6 +74,9 @@ function s.adop(e,tp,eg,ep,ev,re,r,rp)
e1:SetValue(-1500) e1:SetValue(-1500)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1) tc:RegisterEffect(e1)
if preatk~=0 and tc:IsAttack(0) then Duel.Destroy(tc,REASON_EFFECT) end if preatk~=0 and tc:IsAttack(0) then
Duel.BreakEffect()
Duel.Destroy(tc,REASON_EFFECT)
end
end end
end end
\ No newline at end of file
--Embres of the Ashened City --Embres of the Ashened
local s,id,o=GetID() local s,id,o=GetID()
function s.initial_effect(c) function s.initial_effect(c)
--fusion material --fusion material
......
--Spearhead of the Ashened City --Spearhead of the Ashened City
local s,id,o=GetID() local s,id,o=GetID()
function s.initial_effect(c) function s.initial_effect(c)
aux.AddCodeList(c,3055018)
--spsummon --spsummon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
......
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