Commit 316da72c authored by fallenstardust's avatar fallenstardust

同步脚本修复

parent 2210858f
......@@ -63,22 +63,31 @@ function s.thop(e,tp,eg,ep,ev,re,r,rp)
end
end
function s.lvfilter(c)
return c:IsFaceup() and c:IsLevelAbove(0) and c:IsSetCard(0xba)
return c:IsFaceup() and c:IsLevelAbove(1) and c:IsSetCard(0xba)
end
function s.lvtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(s.lvfilter,tp,LOCATION_MZONE,0,1,nil) end
end
function s.lvop(e,tp,eg,ep,ev,re,r,rp)
--local g=Duel.GetMatchingGroup(s.lvfilter,tp,LOCATION_MZONE,0,nil)
local g=Duel.GetMatchingGroup(s.lvfilter,tp,LOCATION_MZONE,0,nil)
local tc=g:GetFirst()
while tc do
local sel=0
local lv=1
if not g:IsExists(Card.IsLevelAbove,1,nil,2) then
sel=Duel.SelectOption(tp,aux.Stringid(id,0))
else
sel=Duel.SelectOption(tp,aux.Stringid(id,0),aux.Stringid(id,1))
end
if sel==1 then
lv=-1
end
for tc in aux.Next(g) do
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_LEVEL)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(1)
e1:SetCode(EFFECT_UPDATE_LEVEL)
e1:SetValue(lv)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1)
tc=g:GetNext()
end
end
\ No newline at end of file
......@@ -61,13 +61,13 @@ function s.desop(e,tp,eg,ep,ev,re,r,rp)
end
end
function s.filter(c)
return c:IsSetCard(0xba) and c:IsType(TYPE_MONSTER) and not c:IsForbidden()
return c:IsSetCard(0xba) and c:IsType(TYPE_XYZ) and not c:IsForbidden()
end
function s.copycost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,3,REASON_COST) end
e:GetHandler():RemoveOverlayCard(tp,3,3,REASON_COST)
end
function s.copytg(e,tp,eg,ep,ev,re,r,rp,chk)
function s.copytg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_GRAVE) and chkc:IsControler(tp) and s.filter(chkc) end
if chk==0 then return Duel.IsExistingTarget(s.filter,tp,LOCATION_GRAVE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
......
......@@ -13,6 +13,7 @@ function s.initial_effect(c)
e2:SetCategory(CATEGORY_TOHAND+CATEGORY_SEARCH)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e2:SetRange(LOCATION_SZONE)
e2:SetCountLimit(1,id)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetTarget(s.thtg)
e2:SetOperation(s.thop)
......@@ -24,7 +25,7 @@ function s.initial_effect(c)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetRange(LOCATION_SZONE)
e3:SetCountLimit(1)
e3:SetCountLimit(1,id+o)
e3:SetTarget(s.drtg)
e3:SetOperation(s.drop)
c:RegisterEffect(e3)
......
No preview for this file type
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