Commit e7390149 authored by Nemo Ma's avatar Nemo Ma

fix

parent 682d4c78
......@@ -31,8 +31,8 @@ function cm.tgop(e,tp)
rsop.SelectOperate("tg",tp,Card.IsAbleToGrave,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,1,nil)
end
function cm.condition(e,tp,eg,ep,ev,re,r,rp)
local loc = Duel.GetOperationInfo(ev,CHAININFO_TRIGGERING_LOCATION)
return Duel.IsChainNegatable(ev) and re:IsActiveType(TYPE_MONSTER) and (re:IsHasCategory(CATEGORY_DESTROY) or re:IsHasCategory(CATEGORY_REMOVE)) and loc & LOCATION_ONFIELD ~= 0
local loc = Duel.GetChainInfo(ev,CHAININFO_TRIGGERING_LOCATION)
return Duel.IsChainNegatable(ev) and (re:IsHasCategory(CATEGORY_DESTROY) or re:IsHasCategory(CATEGORY_REMOVE)) and loc & LOCATION_ONFIELD ~= 0
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsAbleToRemove,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,nil) end
......
......@@ -208,8 +208,8 @@ function cm.filter6(c)
end
function cm.retcon(e,tp,eg,ep,ev,re,r,rp)
local g=e:GetLabelObject()
if g and not g:IsExists(cm.filter6,1,nil) then
g:DeleteGroup()
if not (g and aux.GetValueType(g)=="Group") or not g:IsExists(cm.filter6,1,nil) then
if aux.GetValueType(g)=="Group" then g:DeleteGroup() end
e:Reset()
return false
else return true end
......
......@@ -206,8 +206,8 @@ function cm.filter6(c)
end
function cm.retcon(e,tp,eg,ep,ev,re,r,rp)
local g=e:GetLabelObject()
if g and not g:IsExists(cm.filter6,1,nil) then
g:DeleteGroup()
if not (g and aux.GetValueType(g)=="Group") or not g:IsExists(cm.filter6,1,nil) then
if aux.GetValueType(g)=="Group" then g:DeleteGroup() end
e:Reset()
return false
else return true end
......
......@@ -183,8 +183,8 @@ function cm.filter6(c)
end
function cm.retcon(e,tp,eg,ep,ev,re,r,rp)
local g=e:GetLabelObject()
if g and not g:IsExists(cm.filter6,1,nil) then
g:DeleteGroup()
if not (g and aux.GetValueType(g)=="Group") or not g:IsExists(cm.filter6,1,nil) then
if aux.GetValueType(g)=="Group" then g:DeleteGroup() end
e:Reset()
return false
else return true end
......
......@@ -257,8 +257,8 @@ function cm.filter6(c)
end
function cm.retcon(e,tp,eg,ep,ev,re,r,rp)
local g=e:GetLabelObject()
if g and not g:IsExists(cm.filter6,1,nil) then
g:DeleteGroup()
if not (g and aux.GetValueType(g)=="Group") or not g:IsExists(cm.filter6,1,nil) then
if aux.GetValueType(g)=="Group" then g:DeleteGroup() end
e:Reset()
return false
else return true end
......
......@@ -193,8 +193,8 @@ function cm.filter6(c)
end
function cm.retcon(e,tp,eg,ep,ev,re,r,rp)
local g=e:GetLabelObject()
if g and not g:IsExists(cm.filter6,1,nil) then
g:DeleteGroup()
if not (g and aux.GetValueType(g)=="Group") or not g:IsExists(cm.filter6,1,nil) then
if aux.GetValueType(g)=="Group" then g:DeleteGroup() end
e:Reset()
return false
else return true end
......
......@@ -220,8 +220,8 @@ function cm.filter7(c)
end
function cm.retcon(e,tp,eg,ep,ev,re,r,rp)
local g=e:GetLabelObject()
if not g:IsExists(cm.filter6,1,nil) then
g:DeleteGroup()
if not (g and aux.GetValueType(g)=="Group") or not g:IsExists(cm.filter6,1,nil) then
if aux.GetValueType(g)=="Group" then g:DeleteGroup() end
e:Reset()
return false
else return true end
......@@ -235,8 +235,8 @@ function cm.retop(e,tp,eg,ep,ev,re,r,rp)
end
function cm.retcon2(e,tp,eg,ep,ev,re,r,rp)
local g=e:GetLabelObject()
if g and not g:IsExists(cm.filter7,1,nil) then
g:DeleteGroup()
if not (g and aux.GetValueType(g)=="Group") or not g:IsExists(cm.filter7,1,nil) then
if aux.GetValueType(g)=="Group" then g:DeleteGroup() end
e:Reset()
return false
else return true end
......
......@@ -178,8 +178,8 @@ function cm.filter6(c)
end
function cm.retcon(e,tp,eg,ep,ev,re,r,rp)
local g=e:GetLabelObject()
if g and not g:IsExists(cm.filter6,1,nil) then
g:DeleteGroup()
if not (g and aux.GetValueType(g)=="Group") or not g:IsExists(cm.filter6,1,nil) then
if aux.GetValueType(g)=="Group" then g:DeleteGroup() end
e:Reset()
return false
else return true end
......
......@@ -184,8 +184,8 @@ function cm.filter6(c)
end
function cm.retcon(e,tp,eg,ep,ev,re,r,rp)
local g=e:GetLabelObject()
if g and not g:IsExists(cm.filter6,1,nil) then
g:DeleteGroup()
if not (g and aux.GetValueType(g)=="Group") or not g:IsExists(cm.filter6,1,nil) then
if aux.GetValueType(g)=="Group" then g:DeleteGroup() end
e:Reset()
return false
else return true end
......
......@@ -59,7 +59,7 @@ function cm.thop(e,tp,eg,ep,ev,re,r,rp)
end
end
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
function cm.thtg2(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then return Duel.IsExistingTarget(aux.TRUE,tp,LOCATION_GRAVE,0,10,nil) end
Duel.SetOperationInfo(0,CATEGORY_REMOVE,nil,0,tp,15)
end
......
......@@ -169,7 +169,13 @@ function c98920279.synop(e,tp,eg,ep,ev,re,r,rp,c,tuner,mg)
g:DeleteGroup()
end
function c98920279.valcheck(e,c)
local ct=e:GetHandler():GetMaterial():GetClassCount(Card.GetType)
local ct=0
local g=c:GetMaterial()
for i,type in ipairs({TYPE_FUSION,TYPE_RITUAL,TYPE_SYNCHRO,TYPE_XYZ,TYPE_LINK}) do
if g:IsExists(Card.IsType,1,nil,type) then
ct=ct+1
end
end
e:GetLabelObject():SetLabel(ct)
end
function c98920279.con(e,tp,eg,ep,ev,re,r,rp)
......
......@@ -73,4 +73,11 @@ function c9910586.thop(e,tp,eg,ep,ev,re,r,rp)
Duel.SendtoHand(g,nil,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_ATTACK_ANNOUNCE)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTargetRange(0,1)
Duel.RegisterEffect(e1,tp)
end
......@@ -9,6 +9,7 @@ function c9910668.initial_effect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCountLimit(1,9910668)
e1:SetCondition(c9910668.discon)
e1:SetTarget(c9910668.distg)
e1:SetOperation(c9910668.disop)
......
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