Commit f3896e74 authored by salix5's avatar salix5

Merge pull request #1545 from Tianchenglipu/patch-5

aux.nfbdncon
parents 2d72c2ef 76f7181a
......@@ -14,7 +14,7 @@ function c10117149.initial_effect(c)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetCondition(c10117149.splimcon)
e2:SetCondition(aux.nfbdncon)
e2:SetTarget(c10117149.splimit)
c:RegisterEffect(e2)
--destroy
......@@ -49,9 +49,6 @@ function c10117149.initial_effect(c)
e6:SetOperation(c10117149.spop)
c:RegisterEffect(e6)
end
function c10117149.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c10117149.splimit(e,c,tp,sumtp,sumpos)
return not c:IsSetCard(0xab) and bit.band(sumtp,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
......
......@@ -14,7 +14,7 @@ function c11609969.initial_effect(c)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetCondition(c11609969.splimcon)
e2:SetCondition(aux.nfbdncon)
e2:SetTarget(c11609969.splimit)
c:RegisterEffect(e2)
--scale change
......@@ -42,9 +42,6 @@ function c11609969.initial_effect(c)
e5:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e5)
end
function c11609969.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c11609969.splimit(e,c,tp,sumtp,sumpos)
return not c:IsSetCard(0xaf) and bit.band(sumtp,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
......
......@@ -15,7 +15,7 @@ function c20773176.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetTarget(c20773176.splimit)
e2:SetCondition(c20773176.splimcon)
e2:SetCondition(aux.nfbdncon)
c:RegisterEffect(e2)
--spsummon
local e3=Effect.CreateEffect(c)
......@@ -34,9 +34,6 @@ function c20773176.splimit(e,c,sump,sumtype,sumpos,targetp)
if c:IsSetCard(0xb4) or c:IsSetCard(0xc4) then return false end
return bit.band(sumtype,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function c20773176.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c20773176.filter(c,tp)
return c:IsReason(REASON_BATTLE+REASON_EFFECT)
and (c:IsSetCard(0xb4) or c:IsSetCard(0xc4)) and not c:IsCode(20773176)
......
......@@ -15,7 +15,7 @@ function c21495657.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetTarget(c21495657.splimit)
e2:SetCondition(c21495657.splimcon)
e2:SetCondition(aux.nfbdncon)
c:RegisterEffect(e2)
--spsummon success
local e3=Effect.CreateEffect(c)
......@@ -32,9 +32,6 @@ function c21495657.splimit(e,c,sump,sumtype,sumpos,targetp)
if c:IsSetCard(0x9e) or c:IsSetCard(0xc4) then return false end
return bit.band(sumtype,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function c21495657.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c21495657.condition(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_PENDULUM or e:GetHandler():IsPreviousLocation(LOCATION_DECK)
end
......
......@@ -15,7 +15,7 @@ function c22617205.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetTarget(c22617205.splimit)
e2:SetCondition(c22617205.splimcon)
e2:SetCondition(aux.nfbdncon)
c:RegisterEffect(e2)
--destroy
local e3=Effect.CreateEffect(c)
......@@ -39,9 +39,6 @@ function c22617205.splimit(e,c,sump,sumtype,sumpos,targetp)
if c:IsSetCard(0x9c) or c:IsSetCard(0xc4) then return false end
return bit.band(sumtype,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function c22617205.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c22617205.condition(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_PENDULUM
end
......
......@@ -16,7 +16,7 @@ function c23166823.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetTarget(c23166823.splimit)
e2:SetCondition(c23166823.splimcon)
e2:SetCondition(aux.nfbdncon)
c:RegisterEffect(e2)
--to hand
local e3=Effect.CreateEffect(c)
......@@ -35,9 +35,6 @@ function c23166823.splimit(e,c,sump,sumtype,sumpos,targetp)
if c:IsSetCard(0xb5) or c:IsSetCard(0xc4) then return false end
return bit.band(sumtype,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function c23166823.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c23166823.condition(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_PENDULUM
end
......
......@@ -14,7 +14,7 @@ function c37991342.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetRange(LOCATION_PZONE)
e2:SetTargetRange(1,0)
e2:SetCondition(c37991342.splimcon)
e2:SetCondition(aux.nfbdncon)
e2:SetTarget(c37991342.splimit)
c:RegisterEffect(e2)
--atk down
......@@ -64,9 +64,6 @@ function c37991342.initial_effect(c)
e8:SetOperation(c37991342.desop)
c:RegisterEffect(e8)
end
function c37991342.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c37991342.splimit(e,c)
return not c:IsSetCard(0xaa)
end
......
......@@ -14,7 +14,7 @@ function c40318957.initial_effect(c)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetCondition(c40318957.splimcon)
e2:SetCondition(aux.nfbdncon)
e2:SetTarget(c40318957.splimit)
c:RegisterEffect(e2)
--search
......@@ -30,9 +30,6 @@ end
function c40318957.filter(c)
return c:IsSetCard(0x9f) or (c:IsSetCard(0x98) and c:IsType(TYPE_PENDULUM)) or c:IsSetCard(0x99)
end
function c40318957.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c40318957.splimit(e,c,tp,sumtp,sumpos)
return not c40318957.filter(c) and bit.band(sumtp,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
......
......@@ -14,7 +14,7 @@ function c51194046.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetRange(LOCATION_PZONE)
e2:SetTargetRange(1,0)
e2:SetCondition(c51194046.splimcon)
e2:SetCondition(aux.nfbdncon)
e2:SetTarget(c51194046.splimit)
c:RegisterEffect(e2)
--draw
......@@ -57,9 +57,6 @@ function c51194046.initial_effect(c)
Duel.RegisterEffect(ge4,0)
end
end
function c51194046.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c51194046.splimit(e,c)
return not c:IsSetCard(0xaa)
end
......
......@@ -14,7 +14,7 @@ function c55106249.initial_effect(c)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetCondition(c55106249.splimcon)
e2:SetCondition(aux.nfbdncon)
e2:SetTarget(c55106249.splimit)
c:RegisterEffect(e2)
--pos
......@@ -49,9 +49,6 @@ function c55106249.initial_effect(c)
e6:SetOperation(c55106249.thop)
c:RegisterEffect(e6)
end
function c55106249.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c55106249.splimit(e,c,tp,sumtp,sumpos)
return not c:IsSetCard(0xab) and bit.band(sumtp,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
......
......@@ -16,7 +16,7 @@ function c57777714.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetTarget(c57777714.splimit)
e2:SetCondition(c57777714.splimcon)
e2:SetCondition(aux.nfbdncon)
c:RegisterEffect(e2)
--spsummon
local e3=Effect.CreateEffect(c)
......@@ -36,9 +36,6 @@ function c57777714.splimit(e,c,sump,sumtype,sumpos,targetp)
if c:IsSetCard(0xb5) or c:IsSetCard(0xc4) then return false end
return bit.band(sumtype,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function c57777714.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c57777714.condition(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_PENDULUM
end
......
......@@ -15,7 +15,7 @@ function c58016954.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetTarget(c58016954.splimit)
e2:SetCondition(c58016954.splimcon)
e2:SetCondition(aux.nfbdncon)
c:RegisterEffect(e2)
--spsummon
local e3=Effect.CreateEffect(c)
......@@ -37,9 +37,6 @@ function c58016954.splimit(e,c,sump,sumtype,sumpos,targetp)
if c:IsSetCard(0x9d) or c:IsSetCard(0xc4) then return false end
return bit.band(sumtype,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function c58016954.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c58016954.condition1(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_PENDULUM
end
......
......@@ -15,7 +15,7 @@ function c58990362.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetTarget(c58990362.splimit)
e2:SetCondition(c58990362.splimcon)
e2:SetCondition(aux.nfbdncon)
c:RegisterEffect(e2)
--search
local e3=Effect.CreateEffect(c)
......@@ -37,9 +37,6 @@ function c58990362.splimit(e,c,sump,sumtype,sumpos,targetp)
if c:IsSetCard(0x9e) or c:IsSetCard(0xc4) then return false end
return bit.band(sumtype,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function c58990362.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c58990362.condition1(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_PENDULUM
end
......
......@@ -14,7 +14,7 @@ function c64496451.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetRange(LOCATION_PZONE)
e2:SetTargetRange(1,0)
e2:SetCondition(c64496451.splimcon)
e2:SetCondition(aux.nfbdncon)
e2:SetTarget(c64496451.splimit)
c:RegisterEffect(e2)
--atk up
......@@ -72,9 +72,6 @@ function c64496451.initial_effect(c)
e9:SetLabelObject(e8)
c:RegisterEffect(e9)
end
function c64496451.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c64496451.splimit(e,c)
return not c:IsSetCard(0xaa)
end
......
......@@ -14,7 +14,7 @@ function c65518099.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetRange(LOCATION_PZONE)
e2:SetTargetRange(1,0)
e2:SetCondition(c65518099.splimcon)
e2:SetCondition(aux.nfbdncon)
e2:SetTarget(c65518099.splimit)
c:RegisterEffect(e2)
--tohand
......@@ -29,9 +29,6 @@ function c65518099.initial_effect(c)
e3:SetOperation(c65518099.operation)
c:RegisterEffect(e3)
end
function c65518099.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c65518099.splimit(e,c,tp,sumtp,sumpos)
return not c:IsSetCard(0xaa)
end
......
......@@ -15,7 +15,7 @@ function c74605254.initial_effect(c)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetCondition(c74605254.splimcon)
e2:SetCondition(aux.nfbdncon)
e2:SetTarget(c74605254.splimit)
c:RegisterEffect(e2)
--scale change
......@@ -43,9 +43,6 @@ function c74605254.initial_effect(c)
e4:SetOperation(c74605254.thop)
c:RegisterEffect(e4)
end
function c74605254.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c74605254.splimit(e,c,sump,sumtype,sumpos,targetp)
return not c:IsSetCard(0xaf) and bit.band(sumtype,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
......
......@@ -16,7 +16,7 @@ function c84388461.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetTarget(c84388461.splimit)
e2:SetCondition(c84388461.splimcon)
e2:SetCondition(aux.nfbdncon)
c:RegisterEffect(e2)
--spsummon
local e3=Effect.CreateEffect(c)
......@@ -34,9 +34,6 @@ function c84388461.splimit(e,c,sump,sumtype,sumpos,targetp)
if c:IsSetCard(0xb4) or c:IsSetCard(0xc4) then return false end
return bit.band(sumtype,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function c84388461.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c84388461.filter(c,e,tp,m)
if not c:IsSetCard(0xb4) or bit.band(c:GetType(),0x81)~=0x81
or not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end
......
......@@ -14,7 +14,7 @@ function c87588741.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetRange(LOCATION_PZONE)
e2:SetTargetRange(1,0)
e2:SetCondition(c87588741.splimcon)
e2:SetCondition(aux.nfbdncon)
e2:SetTarget(c87588741.splimit)
c:RegisterEffect(e2)
--atk down
......@@ -72,9 +72,6 @@ function c87588741.initial_effect(c)
e9:SetLabelObject(e8)
c:RegisterEffect(e9)
end
function c87588741.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c87588741.splimit(e,c)
return not c:IsSetCard(0xaa)
end
......
......@@ -14,7 +14,7 @@ function c90885155.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetRange(LOCATION_PZONE)
e2:SetTargetRange(1,0)
e2:SetCondition(c90885155.splimcon)
e2:SetCondition(aux.nfbdncon)
e2:SetTarget(c90885155.splimit)
c:RegisterEffect(e2)
--atk down
......@@ -70,9 +70,6 @@ function c90885155.initial_effect(c)
e9:SetLabelObject(e8)
c:RegisterEffect(e9)
end
function c90885155.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c90885155.splimit(e,c)
return not c:IsSetCard(0xaa)
end
......
......@@ -14,7 +14,7 @@ function c91907707.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetRange(LOCATION_PZONE)
e2:SetTargetRange(1,0)
e2:SetCondition(c91907707.splimcon)
e2:SetCondition(aux.nfbdncon)
e2:SetTarget(c91907707.splimit)
c:RegisterEffect(e2)
--atk up
......@@ -65,9 +65,6 @@ function c91907707.initial_effect(c)
e8:SetOperation(c91907707.thop)
c:RegisterEffect(e8)
end
function c91907707.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c91907707.splimit(e,c)
return not c:IsSetCard(0xaa)
end
......
......@@ -15,7 +15,7 @@ function c95401059.initial_effect(c)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_CANNOT_DISABLE)
e2:SetTargetRange(1,0)
e2:SetTarget(c95401059.splimit)
e2:SetCondition(c95401059.splimcon)
e2:SetCondition(aux.nfbdncon)
c:RegisterEffect(e2)
--spsummon
local e3=Effect.CreateEffect(c)
......@@ -37,9 +37,6 @@ function c95401059.splimit(e,c,sump,sumtype,sumpos,targetp)
if c:IsSetCard(0x9d) or c:IsSetCard(0xc4) then return false end
return bit.band(sumtype,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function c95401059.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c95401059.condition1(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_PENDULUM
end
......
......@@ -15,7 +15,7 @@ function c96223501.initial_effect(c)
e2:SetRange(LOCATION_PZONE)
e2:SetTargetRange(1,0)
e2:SetTarget(c96223501.splimit)
e2:SetCondition(c96223501.splimcon)
e2:SetCondition(aux.nfbdncon)
c:RegisterEffect(e2)
--destroy
local e3=Effect.CreateEffect(c)
......@@ -39,9 +39,6 @@ function c96223501.splimit(e,c,sump,sumtype,sumpos,targetp)
if c:IsSetCard(0x9c) or c:IsSetCard(0xc4) then return false end
return bit.band(sumtype,SUMMON_TYPE_PENDULUM)==SUMMON_TYPE_PENDULUM
end
function c96223501.splimcon(e)
return not e:GetHandler():IsForbidden()
end
function c96223501.condition(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonType()==SUMMON_TYPE_PENDULUM
end
......
......@@ -1180,6 +1180,10 @@ function Auxiliary.bdogcon(e,tp,eg,ep,ev,re,r,rp)
local bc=c:GetBattleTarget()
return c:IsRelateToBattle() and c:IsStatus(STATUS_OPPO_BATTLE) and bc:IsLocation(LOCATION_GRAVE) and bc:IsType(TYPE_MONSTER)
end
--condition of handler not forbidden
function Auxiliary.nfbdncon(e)
return not e:GetHandler():IsForbidden()
end
--flag effect for spell counter
function Auxiliary.chainreg(e,tp,eg,ep,ev,re,r,rp)
if e:GetHandler():GetFlagEffect(1)==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