Commit f70c669c authored by wind2009's avatar wind2009

Fix 壊獄神ユピテル

parent 92f80459
......@@ -46,12 +46,12 @@ end
function s.eqcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_XYZ)
end
function s.eqfilter(c,tp)
return c:IsType(TYPE_EQUIP) and not c:IsForbidden() and c:CheckUniqueOnField(tp,LOCATION_SZONE)
function s.eqfilter(c,tp,ec)
return c:IsType(TYPE_EQUIP) and not c:IsForbidden() and c:CheckUniqueOnField(tp,LOCATION_SZONE) and c:CheckEquipTarget(ec)
end
function s.eqtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0
and Duel.IsExistingMatchingCard(s.eqfilter,tp,LOCATION_GRAVE,0,1,nil,tp) end
and Duel.IsExistingMatchingCard(s.eqfilter,tp,LOCATION_GRAVE,0,1,nil,tp,e:GetHandler()) end
Duel.SetOperationInfo(0,CATEGORY_EQUIP,nil,1,tp,LOCATION_GRAVE)
end
function s.eqop(e,tp,eg,ep,ev,re,r,rp)
......@@ -60,7 +60,7 @@ function s.eqop(e,tp,eg,ep,ev,re,r,rp)
local ft=Duel.GetLocationCount(tp,LOCATION_SZONE)
if ft<1 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.eqfilter),tp,LOCATION_GRAVE,0,1,ft,nil,tp)
local g=Duel.SelectMatchingCard(tp,aux.NecroValleyFilter(s.eqfilter),tp,LOCATION_GRAVE,0,1,ft,nil,tp,c)
if g:GetCount()>0 then
for tc in aux.Next(g) do
Duel.Equip(tp,tc,c,false,true)
......
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