Commit a7b26c62 authored by Grajade's avatar Grajade

Update c74562019.lua

parent 07c7838f
Pipeline #8950 passed with stage
in 32 seconds
...@@ -46,9 +46,12 @@ function cCardno.actcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -46,9 +46,12 @@ function cCardno.actcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetCurrentPhase()==PHASE_MAIN1 and not Duel.CheckPhaseActivity() return Duel.GetCurrentPhase()==PHASE_MAIN1 and not Duel.CheckPhaseActivity()
end end
--to field --to field
function cCardno.tfilter(c)
return c:IsSetCard(0x8a1) and c:IsType(TYPE_MONSTER) and c:IsFaceup()
end
function cCardno.tfcon(e,tp,eg,ep,ev,re,r,rp) function cCardno.tfcon(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetMatchingGroup(Card.IsSetCard,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,nil,0x8a1) local g=Duel.GetMatchingGroup(cCardno.tfilter,tp,LOCATION_MZONE,LOCATION_MZONE,nil)
return g:GetClassCount(Card.GetCode)==g:GetCount() and g:GetCount() >= 2 return g:GetClassCount(Card.GetCode)==g:GetCount() and g:GetCount()>=2 and not e:GetHandler():IsForbidden()
end end
function cCardno.tfop(e,tp,eg,ep,ev,re,r,rp) function cCardno.tfop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
...@@ -66,28 +69,25 @@ function cCardno.discost(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -66,28 +69,25 @@ function cCardno.discost(e,tp,eg,ep,ev,re,r,rp,chk)
end end
function cCardno.distg(e,tp,eg,ep,ev,re,r,rp,chk) function cCardno.distg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_DISABLE,e:GetHandler(),1,tp,LOCATION_FZONE) Duel.SetOperationInfo(0,CATEGORY_DISABLE,eg,1,0,0)
end end
function cCardno.disop(e,tp,eg,ep,ev,re,r,rp) function cCardno.disop(e,tp,eg,ep,ev,re,r,rp)
if e:GetHandler():IsRelateToEffect(e) then Duel.NegateEffect(ev)
Duel.NegateEffect(ev)
end
end end
--Destroy --Destroy
function cCardno.decost(e,tp,eg,ep,ev,re,r,rp,chk) function cCardno.decost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,nil) end
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsDiscardable,tp,LOCATION_HAND,0,1,nil) and not c:IsStatus(STATUS_CHAINING) end
Duel.DiscardHand(tp,nil,1,1,REASON_COST,nil) Duel.DiscardHand(tp,nil,1,1,REASON_COST,nil)
end end
function cCardno.detg(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function cCardno.detg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_ONFIELD) and chkc:IsDestructable() end if chkc then return chkc:IsLocation(LOCATION_ONFIELD) and chkc~=e:GetHandler() end
if chk==0 then return Duel.IsExistingTarget(Card.IsDestructable,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) end if chk==0 then return Duel.IsExistingTarget(aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) end
Duel.SelectTarget(tp,Card.IsDestructable,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,e:GetHandler()) local g=Duel.SelectTarget(tp,aux.TRUE,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_DESTROY,nil,1,tp,LOCATION_ONFIELD) Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,1,0,0)
end end
function cCardno.deop(e,tp,eg,ep,ev,re,r,rp) function cCardno.deop(e,tp,eg,ep,ev,re,r,rp)
if e:GetHandler():IsRelateToEffect(e) then local tc=Duel.GetFirstTarget()
local tc=Duel.GetFirstTarget() if tc:IsRelateToEffect(e) then
Duel.Destroy(tc,REASON_EFFECT) Duel.Destroy(tc,REASON_EFFECT)
end end
end end
\ No newline at end of file
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