Commit c6fb91db authored by mercury233's avatar mercury233

update

parent eea9ea94
...@@ -36,10 +36,10 @@ function c12615446.poscost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -36,10 +36,10 @@ function c12615446.poscost(e,tp,eg,ep,ev,re,r,rp,chk)
e:GetHandler():RemoveOverlayCard(tp,2,2,REASON_COST) e:GetHandler():RemoveOverlayCard(tp,2,2,REASON_COST)
end end
function c12615446.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c12615446.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_MZONE) end if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsCanChangePosition() end
if chk==0 then return Duel.IsExistingTarget(nil,tp,0,LOCATION_MZONE,1,nil) end if chk==0 then return Duel.IsExistingTarget(Card.IsCanChangePosition,tp,0,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
Duel.SelectTarget(tp,nil,tp,0,LOCATION_MZONE,1,1,nil) Duel.SelectTarget(tp,Card.IsCanChangePosition,tp,0,LOCATION_MZONE,1,1,nil)
end end
function c12615446.posop(e,tp,eg,ep,ev,re,r,rp) function c12615446.posop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
......
...@@ -20,11 +20,14 @@ function c15914410.poscost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -20,11 +20,14 @@ function c15914410.poscost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end
e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST) e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST)
end end
function c15914410.filter(c)
return c:IsPosition(POS_FACEUP_ATTACK) and c:IsCanChangePosition()
end
function c15914410.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c15914410.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsPosition(POS_FACEUP_ATTACK) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c15914410.filter(chkc) end
if chk==0 then return Duel.IsExistingTarget(Card.IsPosition,tp,LOCATION_MZONE,0,1,nil,POS_FACEUP_ATTACK) end if chk==0 then return Duel.IsExistingTarget(c15914410.filter,tp,LOCATION_MZONE,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUPATTACK) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUPATTACK)
Duel.SelectTarget(tp,Card.IsPosition,tp,LOCATION_MZONE,0,1,1,nil,POS_FACEUP_ATTACK) Duel.SelectTarget(tp,c15914410.filter,tp,LOCATION_MZONE,0,1,1,nil)
end end
function c15914410.posop(e,tp,eg,ep,ev,re,r,rp) function c15914410.posop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
......
...@@ -31,7 +31,7 @@ function c16021142.spcon(e,c) ...@@ -31,7 +31,7 @@ function c16021142.spcon(e,c)
and Duel.IsExistingMatchingCard(c16021142.cfilter,tp,LOCATION_MZONE,0,1,nil) and Duel.IsExistingMatchingCard(c16021142.cfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function c16021142.filter(c) function c16021142.filter(c)
return c:IsFaceup() and c:IsSetCard(0x9b) return c:IsFaceup() and c:IsSetCard(0x9b) and c:IsCanChangePosition()
end end
function c16021142.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c16021142.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c16021142.filter(chkc) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c16021142.filter(chkc) end
......
...@@ -34,8 +34,9 @@ function c22751868.poscon(e,tp,eg,ep,ev,re,r,rp) ...@@ -34,8 +34,9 @@ function c22751868.poscon(e,tp,eg,ep,ev,re,r,rp)
return a:IsControler(tp) and a:IsSetCard(0x11) and d:IsFaceup() return a:IsControler(tp) and a:IsSetCard(0x11) and d:IsFaceup()
end end
function c22751868.postg(e,tp,eg,ep,ev,re,r,rp,chk) function c22751868.postg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end local d=Duel.GetAttackTarget()
Duel.GetAttackTarget():CreateEffectRelation(e) if chk==0 then return d:IsCanChangePosition() end
d:CreateEffectRelation(e)
end end
function c22751868.posop(e,tp,eg,ep,ev,re,r,rp) function c22751868.posop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetAttackTarget() local tc=Duel.GetAttackTarget()
......
...@@ -46,7 +46,7 @@ function c26570480.poscon(e,tp,eg,ep,ev,re,r,rp) ...@@ -46,7 +46,7 @@ function c26570480.poscon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c26570480.cfilter,1,nil,tp) return eg:IsExists(c26570480.cfilter,1,nil,tp)
end end
function c26570480.filter(c) function c26570480.filter(c)
return not c:IsPosition(POS_FACEUP_DEFENSE) return not c:IsPosition(POS_FACEUP_DEFENSE) and c:IsCanChangePosition()
end end
function c26570480.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c26570480.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and c26570480.filter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and c26570480.filter(chkc) end
......
...@@ -23,7 +23,7 @@ function c28284902.initial_effect(c) ...@@ -23,7 +23,7 @@ function c28284902.initial_effect(c)
c:RegisterEffect(e4) c:RegisterEffect(e4)
end end
function c28284902.cfilter(c) function c28284902.cfilter(c)
return c:IsFaceup() and c:IsSetCard(0x26) and c:IsAttackPos() return c:IsFaceup() and c:IsSetCard(0x26) and c:IsAttackPos() and c:IsCanChangePosition()
end end
function c28284902.target(e,tp,eg,ep,ev,re,r,rp,chk) function c28284902.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return eg:IsExists(c28284902.cfilter,1,nil) end if chk==0 then return eg:IsExists(c28284902.cfilter,1,nil) end
......
...@@ -38,7 +38,7 @@ function c34614289.spop(e,tp,eg,ep,ev,re,r,rp,c) ...@@ -38,7 +38,7 @@ function c34614289.spop(e,tp,eg,ep,ev,re,r,rp,c)
Duel.SendtoHand(g,nil,REASON_COST) Duel.SendtoHand(g,nil,REASON_COST)
end end
function c34614289.filter(c,sp) function c34614289.filter(c,sp)
return c:GetSummonPlayer()==sp return c:GetSummonPlayer()==sp and c:IsCanChangePosition()
end end
function c34614289.postg(e,tp,eg,ep,ev,re,r,rp,chk) function c34614289.postg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return eg:IsExists(c34614289.filter,1,nil,1-tp) end if chk==0 then return eg:IsExists(c34614289.filter,1,nil,1-tp) end
......
...@@ -37,10 +37,10 @@ function c41147577.poscost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -37,10 +37,10 @@ function c41147577.poscost(e,tp,eg,ep,ev,re,r,rp,chk)
e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST) e:GetHandler():RemoveOverlayCard(tp,1,1,REASON_COST)
end end
function c41147577.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c41147577.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_MZONE) end if chkc then return chkc:IsControler(1-tp) and chkc:IsLocation(LOCATION_MZONE) and chkc:IsCanChangePosition() end
if chk==0 then return Duel.IsExistingTarget(nil,tp,0,LOCATION_MZONE,1,nil) end if chk==0 then return Duel.IsExistingTarget(Card.IsCanChangePosition,tp,0,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
Duel.SelectTarget(tp,nil,tp,0,LOCATION_MZONE,1,1,nil) Duel.SelectTarget(tp,Card.IsCanChangePosition,tp,0,LOCATION_MZONE,1,1,nil)
end end
function c41147577.posop(e,tp,eg,ep,ev,re,r,rp) function c41147577.posop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
......
...@@ -20,7 +20,7 @@ function c42551040.poscon(e,tp,eg,ep,ev,re,r,rp) ...@@ -20,7 +20,7 @@ function c42551040.poscon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c42551040.cfilter,tp,LOCATION_MZONE,0,1,nil) return Duel.IsExistingMatchingCard(c42551040.cfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function c42551040.filter(c) function c42551040.filter(c)
return c:IsPosition(POS_FACEUP_ATTACK) return c:IsPosition(POS_FACEUP_ATTACK) and c:IsCanChangePosition()
end end
function c42551040.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c42551040.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and c42551040.filter(chkc) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and c42551040.filter(chkc) end
......
...@@ -36,10 +36,10 @@ function c49374988.retop(e,tp,eg,ep,ev,re,r,rp) ...@@ -36,10 +36,10 @@ function c49374988.retop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c49374988.filter1(c) function c49374988.filter1(c)
return c:IsPosition(POS_FACEUP_ATTACK) and c:IsSetCard(0x71) return c:IsPosition(POS_FACEUP_ATTACK) and c:IsCanChangePosition() and c:IsSetCard(0x71)
end end
function c49374988.filter2(c) function c49374988.filter2(c)
return c:IsPosition(POS_FACEUP_ATTACK) return c:IsPosition(POS_FACEUP_ATTACK) and c:IsCanChangePosition()
end end
function c49374988.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c49374988.postg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return false end if chkc then return false end
......
...@@ -49,8 +49,8 @@ function c54490275.poscon2(e,tp,eg,ep,ev,re,r,rp) ...@@ -49,8 +49,8 @@ function c54490275.poscon2(e,tp,eg,ep,ev,re,r,rp)
and e:GetHandler():GetReasonCard():IsRelateToBattle() and e:GetHandler():GetReasonCard():IsRelateToBattle()
end end
function c54490275.postg2(e,tp,eg,ep,ev,re,r,rp,chk) function c54490275.postg2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
local rc=e:GetHandler():GetReasonCard() local rc=e:GetHandler():GetReasonCard()
if chk==0 then return rc:IsCanTurnSet() end
Duel.SetTargetCard(rc) Duel.SetTargetCard(rc)
Duel.SetOperationInfo(0,CATEGORY_POSITION,rc,1,0,0) Duel.SetOperationInfo(0,CATEGORY_POSITION,rc,1,0,0)
end end
......
...@@ -10,12 +10,15 @@ function c59744639.initial_effect(c) ...@@ -10,12 +10,15 @@ function c59744639.initial_effect(c)
e1:SetOperation(c59744639.operation) e1:SetOperation(c59744639.operation)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c59744639.filter(c)
return c:IsFaceup() and c:IsCanChangePosition()
end
function c59744639.target(e,tp,eg,ep,ev,re,r,rp,chk) function c59744639.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsFaceup,tp,0,LOCATION_MZONE,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c59744639.filter,tp,0,LOCATION_MZONE,1,nil) end
local sg=Duel.GetMatchingGroup(Card.IsFaceup,tp,0,LOCATION_MZONE,nil) local sg=Duel.GetMatchingGroup(c59744639.filter,tp,0,LOCATION_MZONE,nil)
Duel.SetOperationInfo(0,CATEGORY_POSITION,sg,sg:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_POSITION,sg,sg:GetCount(),0,0)
end end
function c59744639.operation(e,tp,eg,ep,ev,re,r,rp) function c59744639.operation(e,tp,eg,ep,ev,re,r,rp)
local sg=Duel.GetMatchingGroup(Card.IsFaceup,tp,0,LOCATION_MZONE,nil) local sg=Duel.GetMatchingGroup(c59744639.filter,tp,0,LOCATION_MZONE,nil)
Duel.ChangePosition(sg,POS_FACEUP_DEFENSE,0,POS_FACEUP_ATTACK,0) Duel.ChangePosition(sg,POS_FACEUP_DEFENSE,0,POS_FACEUP_ATTACK,0)
end end
...@@ -10,11 +10,14 @@ function c63630268.initial_effect(c) ...@@ -10,11 +10,14 @@ function c63630268.initial_effect(c)
e1:SetOperation(c63630268.operation) e1:SetOperation(c63630268.operation)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c63630268.filter(c)
return c:IsPosition(POS_FACEUP_ATTACK) and c:IsCanChangePosition()
end
function c63630268.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c63630268.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsPosition(POS_FACEUP_ATTACK) end if chkc then return chkc:IsLocation(LOCATION_MZONE) and c63630268.filter(chkc) end
if chk==0 then return Duel.IsExistingTarget(Card.IsPosition,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil,POS_FACEUP_ATTACK) end if chk==0 then return Duel.IsExistingTarget(c63630268.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_POSCHANGE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_POSCHANGE)
Duel.SelectTarget(tp,Card.IsPosition,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil,POS_FACEUP_ATTACK) Duel.SelectTarget(tp,c63630268.filter,tp,LOCATION_MZONE,LOCATION_MZONE,1,1,nil)
end end
function c63630268.operation(e,tp,eg,ep,ev,re,r,rp) function c63630268.operation(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
......
...@@ -13,6 +13,7 @@ end ...@@ -13,6 +13,7 @@ end
function c71098407.condition(e,tp,eg,ep,ev,re,r,rp) function c71098407.condition(e,tp,eg,ep,ev,re,r,rp)
return rp~=tp and re:IsActiveType(TYPE_MONSTER) and Duel.IsChainDisablable(ev) return rp~=tp and re:IsActiveType(TYPE_MONSTER) and Duel.IsChainDisablable(ev)
and re:GetHandler():IsLocation(LOCATION_MZONE) and re:GetHandler():IsPosition(POS_FACEUP_ATTACK) and re:GetHandler():IsLocation(LOCATION_MZONE) and re:GetHandler():IsPosition(POS_FACEUP_ATTACK)
and re:GetHandler():IsCanChangePosition()
end end
function c71098407.target(e,tp,eg,ep,ev,re,r,rp,chk) function c71098407.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
......
...@@ -14,7 +14,7 @@ function c80204957.filter1(c) ...@@ -14,7 +14,7 @@ function c80204957.filter1(c)
return c:IsLevelBelow(4) and c:IsSetCard(0x11) and c:IsAbleToHand() return c:IsLevelBelow(4) and c:IsSetCard(0x11) and c:IsAbleToHand()
end end
function c80204957.filter2(c) function c80204957.filter2(c)
return c:IsFaceup() and c:IsSetCard(0x11) return c:IsFaceup() and c:IsSetCard(0x11) and c:IsCanChangePosition()
end end
function c80204957.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c80204957.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c80204957.filter2(chkc) end if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_MZONE) and c80204957.filter2(chkc) end
......
...@@ -10,7 +10,7 @@ function c93747864.initial_effect(c) ...@@ -10,7 +10,7 @@ function c93747864.initial_effect(c)
c:RegisterEffect(e1) c:RegisterEffect(e1)
end end
function c93747864.filter(c) function c93747864.filter(c)
return not c:IsPosition(POS_FACEUP_DEFENSE) return not c:IsPosition(POS_FACEUP_DEFENSE) and c:IsCanChangePosition()
end end
function c93747864.target(e,tp,eg,ep,ev,re,r,rp,chk) function c93747864.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c93747864.filter,tp,LOCATION_MZONE,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c93747864.filter,tp,LOCATION_MZONE,0,1,nil) end
......
...@@ -18,7 +18,7 @@ function c9780364.condition(e,tp,eg,ep,ev,re,r,rp) ...@@ -18,7 +18,7 @@ function c9780364.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c9780364.cfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil) return Duel.IsExistingMatchingCard(c9780364.cfilter,tp,LOCATION_MZONE,LOCATION_MZONE,1,nil)
end end
function c9780364.filter(c,e) function c9780364.filter(c,e)
return c:IsFaceup() and c:IsCanBeEffectTarget(e) return c:IsFaceup() and c:IsCanBeEffectTarget(e) and c:IsCanChangePosition()
end end
function c9780364.filter2(c) function c9780364.filter2(c)
return c:IsFaceup() and c:IsSetCard(0x19) and c:IsAbleToChangeControler() return c:IsFaceup() and c:IsSetCard(0x19) and c:IsAbleToChangeControler()
...@@ -27,7 +27,7 @@ function c9780364.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -27,7 +27,7 @@ function c9780364.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and chkc:IsFaceup() end if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and chkc:IsFaceup() end
if chk==0 then return Duel.IsExistingTarget(Card.IsFaceup,tp,0,LOCATION_MZONE,1,nil) end if chk==0 then return Duel.IsExistingTarget(Card.IsFaceup,tp,0,LOCATION_MZONE,1,nil) end
local g=Duel.GetMatchingGroup(c9780364.filter,tp,0,LOCATION_MZONE,nil,e) local g=Duel.GetMatchingGroup(c9780364.filter,tp,0,LOCATION_MZONE,nil,e)
local cg=g:Filter(c9780364.filter2,nil) local cg=Duel.GetMatchingGroup(c9780364.filter2,tp,0,LOCATION_MZONE,nil)
local sel=0 local sel=0
Duel.Hint(HINT_SELECTMSG,tp,550) Duel.Hint(HINT_SELECTMSG,tp,550)
if cg:GetCount()==0 then if cg:GetCount()==0 then
......
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