Commit 7e657579 authored by Nemo Ma's avatar Nemo Ma

fix

parent 98d8f17a
......@@ -23,7 +23,7 @@ function cm.initial_effect(c)
end
function cm.fselect(g,tp)
return g:IsExists(cm.tdfilter,1,nil) and Duel.IsExistingMatchingCard(aux.NecroValleyFilter(cm.thfilter1),tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,tama.tamas_sumElements(g))
return g:IsExists(cm.tdfilter,1,nil) and Duel.IsExistingMatchingCard(aux.NecroValleyFilter(cm.thfilter),tp,LOCATION_DECK+LOCATION_GRAVE,0,1,nil,tama.tamas_sumElements(g))
end
function cm.tdfilter(c)
return #tama.tamas_getElements(c)>0 and c:IsAbleToDeck()
......
......@@ -2,10 +2,6 @@
local m=40006881
local cm=_G["c"..m]
cm.named_with_AShapeShifter=1
function cm.AShapeShifter(c)
local m=_G["c"..c:GetCode()]
return m and m.named_with_AShapeShifter
end
function cm.initial_effect(c)
--search
local e1=Effect.CreateEffect(c)
......@@ -62,8 +58,7 @@ function cm.ssop(e,tp,eg,ep,ev,re,r,rp)
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end
function cm.spcon2(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return re and cm.AShapeShifter(re)
return re and cm.AShapeShifter(re:GetHandler())
end
function cm.eqfilter(c)
return c:IsRace(RACE_PSYCHO) and c:IsAttribute(ATTRIBUTE_DARK) and not c:IsForbidden()
......
......@@ -15,6 +15,7 @@ function cm.initial_effect(c)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_EXTRA)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
e1:SetCountLimit(1,m)
e1:SetCost(cm.cost)
e1:SetTarget(cm.tg)
e1:SetOperation(cm.op)
......
......@@ -16,6 +16,7 @@ function cm.initial_effect(c)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_EXTRA)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_END_PHASE)
e1:SetCountLimit(1,m)
e1:SetCost(cm.cost)
e1:SetTarget(cm.tg)
e1:SetOperation(cm.op)
......
......@@ -37,7 +37,7 @@ function cm.cfilter(c,tp)
return c:IsRace(RACE_FIEND) and bit.band(c:GetReason(),0x41)==0x41 and c:IsControler(tp)
end
function cm.regcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(cm.cfilter,2,nil,tp)
return eg:IsExists(cm.cfilter,2,nil,e:GetHandler():GetControler())
end
function cm.regop(e,tp,eg,ep,ev,re,r,rp)
Duel.RaiseEvent(eg,EVENT_CUSTOM+m,re,r,rp,ep,ev)
......
......@@ -14,6 +14,7 @@ function cm.initial_effect(c)
e1:SetHintTiming(0,TIMINGS_CHECK_MONSTER+TIMING_MAIN_END)
e1:SetCountLimit(1,m)
e1:SetCondition(cm.spcon)
e1:SetCost(cm.spcost)
e1:SetTarget(cm.sptg)
e1:SetOperation(cm.spop)
c:RegisterEffect(e1)
......@@ -33,6 +34,10 @@ end
function cm.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2
end
function cm.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end
e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST)
end
function cm.spfilter(c,e,tp)
return c:IsSetCard(0x45) and c:IsLevelAbove(6) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
......
......@@ -42,7 +42,7 @@ function c67200267.activate(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_ATOHAND)
local hg=Duel.SelectMatchingCard(tp,c67200267.thfilter,tp,LOCATION_EXTRA,0,1,ct,nil)
if hg:GetCount()>0 and Duel.SendtoHand(hg,nil,REASON_EFFECT)~=0 then
local e1=Effect.CreateEffect(c)
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
......
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