Commit 7bc5ac7b authored by POLYMER's avatar POLYMER

fix

parent 0fd7fd99
...@@ -129,6 +129,6 @@ function cm.act2con(e) ...@@ -129,6 +129,6 @@ function cm.act2con(e)
end end
function cm.ac2limit(e,re,tp) function cm.ac2limit(e,re,tp)
return re:GetHandler():IsType(TYPE_MONSTER) and (re:GetHandler():IsLocation(LOCATION_ONFIELD) or re:GetHandler():IsLocation(LOCATION_GRAVE)) and not (re:IsHasType(EFFECT_TYPE_SINGLE) return re:GetHandler():IsType(TYPE_MONSTER) and (re:GetHandler():IsLocation(LOCATION_ONFIELD) or re:GetHandler():IsLocation(LOCATION_GRAVE)) and not (re:IsHasType(EFFECT_TYPE_SINGLE)
and ((bit.band(re:GetCode(),EVENT_SUMMON_SUCCESS)~=0) or (bit.band(re:GetCode(),EVENT_SPSUMMON_SUCCESS)~=0) or (bit.band(re:GetCode(),EVENT_FLIP)~=0)) and (re:GetCode()==EVENT_SUMMON_SUCCESS or re:GetCode()==EVENT_SPSUMMON_SUCCESS or re:GetCode()==EVENT_FLIP)
and (re:IsHasType(EFFECT_TYPE_TRIGGER_F) or re:IsHasType(EFFECT_TYPE_TRIGGER_O) or re:IsHasType(EFFECT_TYPE_QUICK_F) or re:IsHasType(EFFECT_TYPE_QUICK_O))) and (re:IsHasType(EFFECT_TYPE_TRIGGER_F) or re:IsHasType(EFFECT_TYPE_TRIGGER_O) or re:IsHasType(EFFECT_TYPE_QUICK_F) or re:IsHasType(EFFECT_TYPE_QUICK_O)))
end end
\ No newline at end of file
...@@ -39,7 +39,7 @@ end ...@@ -39,7 +39,7 @@ end
function cm.con(e,c) function cm.con(e,c)
if c==nil then return true end if c==nil then return true end
local tp=c:GetControler() local tp=c:GetControler()
return Duel.IsExistingMatchingCard(cm.resfilter,tp,LOCATION_SZONE,0,1,nil) return Duel.GetLocationCountFromEx(tp,tp,nil,c)>0 and Duel.IsExistingMatchingCard(cm.resfilter,tp,LOCATION_SZONE,0,1,nil)
end end
function cm.resfilter(c) function cm.resfilter(c)
return c:GetOriginalType()&TYPE_MONSTER ~=0 and c:IsReleasable() and c:IsType(TYPE_TRAP) return c:GetOriginalType()&TYPE_MONSTER ~=0 and c:IsReleasable() and c:IsType(TYPE_TRAP)
......
...@@ -24,12 +24,12 @@ function c88800025.initial_effect(c) ...@@ -24,12 +24,12 @@ function c88800025.initial_effect(c)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c88800025.costfilter(c,tp) function c88800025.costfilter(c,tp)
return c:IsRace(RACE_WARRIOR) and c:IsAttribute(ATTRIBUTE_DARK) and c:IsType(TYPE_MONSTER) and c:IsReleasable() return c:IsRace(RACE_WARRIOR) and c:IsAttribute(ATTRIBUTE_DARK) and Duel.GetMZoneCount(tp,c)>0
end end
function c88800025.spcost1(e,tp,eg,ep,ev,re,r,rp,chk) function c88800025.spcost1(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckReleaseGroupEx(tp,c88800025.costfilter,1,e:GetHandler()) end if chk==0 then return Duel.CheckReleaseGroupEx(tp,c88800025.costfilter,1,REASON_COST,true,e:GetHandler(),tp) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local g=Duel.SelectReleaseGroupEx(tp,c88800025.costfilter,1,1,e:GetHandler()) local g=Duel.SelectReleaseGroupEx(tp,c88800025.costfilter,1,1,REASON_COST,true,e:GetHandler(),tp)
Duel.Release(g,REASON_COST) Duel.Release(g,REASON_COST)
end end
function c88800025.sptg1(e,tp,eg,ep,ev,re,r,rp,chk) function c88800025.sptg1(e,tp,eg,ep,ev,re,r,rp,chk)
......
...@@ -12,7 +12,7 @@ function Auxiliary.PreloadUds() ...@@ -12,7 +12,7 @@ function Auxiliary.PreloadUds()
end end
return require_list[str] return require_list[str]
end end
--[[local release_set={"CheckReleaseGroup","SelectReleaseGroup","CheckReleaseGroupEx","SelectReleaseGroupEx"} local release_set={"CheckReleaseGroup","SelectReleaseGroup"}
for i,fname in pairs(release_set) do for i,fname in pairs(release_set) do
local temp_f=Duel[fname] local temp_f=Duel[fname]
Duel[fname]=function(...) Duel[fname]=function(...)
...@@ -38,7 +38,7 @@ function Auxiliary.PreloadUds() ...@@ -38,7 +38,7 @@ function Auxiliary.PreloadUds()
end end
return temp_f(...) return temp_f(...)
end end
end--]] end
if not Auxiliary.GetMustMaterialGroup then if not Auxiliary.GetMustMaterialGroup then
Auxiliary.GetMustMaterialGroup=Duel.GetMustMaterial Auxiliary.GetMustMaterialGroup=Duel.GetMustMaterial
end end
......
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