Commit 17fbd8fe authored by TanakaKotoha's avatar TanakaKotoha

fix

parent 8d1b03d3
...@@ -10,7 +10,6 @@ function cm.initial_effect(c) ...@@ -10,7 +10,6 @@ function cm.initial_effect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_PREDRAW) e1:SetCode(EVENT_PREDRAW)
e1:SetCondition(cm.actcon) e1:SetCondition(cm.actcon)
e1:SetCost(cm.actcost)
e1:SetTarget(cm.target) e1:SetTarget(cm.target)
e1:SetOperation(cm.activate) e1:SetOperation(cm.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
...@@ -32,9 +31,7 @@ function cm.counterfilter(c) ...@@ -32,9 +31,7 @@ function cm.counterfilter(c)
return c:GetSummonLocation()~=LOCATION_EXTRA return c:GetSummonLocation()~=LOCATION_EXTRA
end end
function cm.actcost(e,tp,eg,ep,ev,re,r,rp,chk) function cm.actcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLP(tp)>14 and Duel.GetCustomActivityCount(m,tp,ACTIVITY_SPSUMMON)==0 and Duel.GetCustomActivityCount(m,1-tp,ACTIVITY_CHAIN)==0 end if chk==0 then return Duel.GetCustomActivityCount(m,tp,ACTIVITY_SPSUMMON)==0 and Duel.GetCustomActivityCount(m,1-tp,ACTIVITY_CHAIN)==0 end
local lp=Duel.GetLP(tp)
Duel.PayLPCost(tp,lp-14)
local e1=Effect.CreateEffect(e:GetHandler()) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON) e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
...@@ -67,18 +64,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -67,18 +64,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.spfilter),tp,LOCATION_HAND+LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,e,tp) local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(cm.spfilter),tp,LOCATION_HAND+LOCATION_DECK+LOCATION_GRAVE,0,1,1,nil,e,tp)
if #g>0 then if #g>0 then
if Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)~=0 then Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)
local turnp=Duel.GetTurnPlayer()
Duel.SkipPhase(turnp,PHASE_STANDBY,RESET_PHASE+PHASE_END,1)
Duel.SkipPhase(turnp,PHASE_MAIN1,RESET_PHASE+PHASE_END,1)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_EP)
e1:SetTargetRange(1,0)
e1:SetReset(RESET_PHASE+PHASE_MAIN1+RESET_SELF_TURN)
Duel.RegisterEffect(e1,tp)
end
end end
end end
local e2=Effect.CreateEffect(e:GetHandler()) local e2=Effect.CreateEffect(e:GetHandler())
......
...@@ -339,11 +339,12 @@ function c60152605.e5op(e,tp,eg,ep,ev,re,r,rp) ...@@ -339,11 +339,12 @@ function c60152605.e5op(e,tp,eg,ep,ev,re,r,rp)
if tc:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) then
if e:GetHandler():GetColumnGroupCount()==0 then if e:GetHandler():GetColumnGroupCount()==0 then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) local g=Duel.GetMatchingGroup(Card.IsAbleToDeck,tp,0,LOCATION_GRAVE,nil)
local g=Duel.SelectMatchingCard(tp,nil,tp,0,LOCATION_GRAVE,1,1,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(60152603,1)) then if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(60152603,1)) then
Duel.HintSelection(g) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
Duel.SendtoDeck(g,nil,2,REASON_EFFECT) local sg=g:Select(tp,1,1,nil)
Duel.HintSelection(sg)
Duel.SendtoDeck(sg,nil,2,REASON_EFFECT)
end end
else else
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
......
...@@ -339,11 +339,12 @@ function c60152606.e5op(e,tp,eg,ep,ev,re,r,rp) ...@@ -339,11 +339,12 @@ function c60152606.e5op(e,tp,eg,ep,ev,re,r,rp)
if tc:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) then
if e:GetHandler():GetColumnGroupCount()==0 then if e:GetHandler():GetColumnGroupCount()==0 then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) local g=Duel.GetMatchingGroup(Card.IsAbleToDeck,tp,0,LOCATION_GRAVE,nil)
local g=Duel.SelectMatchingCard(tp,nil,tp,0,LOCATION_GRAVE,1,1,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(60152603,1)) then if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(60152603,1)) then
Duel.HintSelection(g) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
Duel.SendtoDeck(g,nil,2,REASON_EFFECT) local sg=g:Select(tp,1,1,nil)
Duel.HintSelection(sg)
Duel.SendtoDeck(sg,nil,2,REASON_EFFECT)
end end
else else
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
......
...@@ -339,11 +339,12 @@ function c60152607.e5op(e,tp,eg,ep,ev,re,r,rp) ...@@ -339,11 +339,12 @@ function c60152607.e5op(e,tp,eg,ep,ev,re,r,rp)
if tc:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) then
if e:GetHandler():GetColumnGroupCount()==0 then if e:GetHandler():GetColumnGroupCount()==0 then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) local g=Duel.GetMatchingGroup(Card.IsAbleToDeck,tp,0,LOCATION_GRAVE,nil)
local g=Duel.SelectMatchingCard(tp,nil,tp,0,LOCATION_GRAVE,1,1,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(60152603,1)) then if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(60152603,1)) then
Duel.HintSelection(g) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
Duel.SendtoDeck(g,nil,2,REASON_EFFECT) local sg=g:Select(tp,1,1,nil)
Duel.HintSelection(sg)
Duel.SendtoDeck(sg,nil,2,REASON_EFFECT)
end end
else else
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
......
...@@ -339,11 +339,12 @@ function c60152608.e5op(e,tp,eg,ep,ev,re,r,rp) ...@@ -339,11 +339,12 @@ function c60152608.e5op(e,tp,eg,ep,ev,re,r,rp)
if tc:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) then
if e:GetHandler():GetColumnGroupCount()==0 then if e:GetHandler():GetColumnGroupCount()==0 then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) local g=Duel.GetMatchingGroup(Card.IsAbleToDeck,tp,0,LOCATION_GRAVE,nil)
local g=Duel.SelectMatchingCard(tp,nil,tp,0,LOCATION_GRAVE,1,1,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(60152603,1)) then if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(60152603,1)) then
Duel.HintSelection(g) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
Duel.SendtoDeck(g,nil,2,REASON_EFFECT) local sg=g:Select(tp,1,1,nil)
Duel.HintSelection(sg)
Duel.SendtoDeck(sg,nil,2,REASON_EFFECT)
end end
else else
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
......
...@@ -338,11 +338,12 @@ function c60152609.e5op(e,tp,eg,ep,ev,re,r,rp) ...@@ -338,11 +338,12 @@ function c60152609.e5op(e,tp,eg,ep,ev,re,r,rp)
if tc:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) then
if e:GetHandler():GetColumnGroupCount()==0 then if e:GetHandler():GetColumnGroupCount()==0 then
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK) local g=Duel.GetMatchingGroup(Card.IsAbleToDeck,tp,0,LOCATION_GRAVE,nil)
local g=Duel.SelectMatchingCard(tp,nil,tp,0,LOCATION_GRAVE,1,1,nil)
if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(60152603,1)) then if g:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(60152603,1)) then
Duel.HintSelection(g) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TODECK)
Duel.SendtoDeck(g,nil,2,REASON_EFFECT) local sg=g:Select(tp,1,1,nil)
Duel.HintSelection(sg)
Duel.SendtoDeck(sg,nil,2,REASON_EFFECT)
end end
else else
Duel.SendtoHand(tc,nil,REASON_EFFECT) Duel.SendtoHand(tc,nil,REASON_EFFECT)
......
...@@ -33,14 +33,14 @@ function c81003006.damfilter(c,tp) ...@@ -33,14 +33,14 @@ function c81003006.damfilter(c,tp)
return c:IsType(TYPE_SPELL+TYPE_TRAP) and c:GetOwner()==1-tp return c:IsType(TYPE_SPELL+TYPE_TRAP) and c:GetOwner()==1-tp
end end
function c81003006.damtg(e,tp,eg,ep,ev,re,r,rp,chk) function c81003006.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c81003006.damfilter,tp,LOCATION_ONFIELD,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c81003006.damfilter,tp,LOCATION_ONFIELD,0,1,nil,tp) end
Duel.SetTargetPlayer(1-tp) Duel.SetTargetPlayer(1-tp)
local ct=Duel.GetMatchingGroupCount(c81003006.damfilter,tp,LOCATION_ONFIELD,0,nil) local ct=Duel.GetMatchingGroupCount(c81003006.damfilter,tp,LOCATION_ONFIELD,0,nil,tp)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,ct*400) Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,ct*400)
end end
function c81003006.damop(e,tp,eg,ep,ev,re,r,rp) function c81003006.damop(e,tp,eg,ep,ev,re,r,rp)
local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER) local p=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER)
local ct=Duel.GetMatchingGroupCount(c81003006.damfilter,tp,LOCATION_ONFIELD,0,nil) local ct=Duel.GetMatchingGroupCount(c81003006.damfilter,tp,LOCATION_ONFIELD,0,nil,tp)
Duel.Damage(p,ct*400,REASON_EFFECT) Duel.Damage(p,ct*400,REASON_EFFECT)
end end
function c81003006.eqcon(e,tp,eg,ep,ev,re,r,rp,chk) function c81003006.eqcon(e,tp,eg,ep,ev,re,r,rp,chk)
......
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