Commit 3c794f51 authored by VanillaSalt's avatar VanillaSalt

Merge pull request #664 from sidschingis/master

fix
parents 164ae303 34b3e793
......@@ -48,7 +48,7 @@ function c14001430.repfilter(c,tp)
return c:IsControler(tp) and c:IsLocation(LOCATION_GRAVE) and c:GetDestination()==LOCATION_DECK and c:IsType(TYPE_MONSTER)
end
function c14001430.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return bit.band(r,REASON_EFFECT)~=0 and re:IsActiveType(TYPE_MONSTER)
if chk==0 then return bit.band(r,REASON_EFFECT)~=0 and re and re:IsActiveType(TYPE_MONSTER)
and re:GetHandler():IsSetCard(0x71) and eg:IsExists(c14001430.repfilter,1,nil,tp) end
if Duel.SelectYesNo(tp,aux.Stringid(14001430,0)) then
local g=eg:Filter(c14001430.repfilter,nil,tp)
......
......@@ -21,7 +21,7 @@ function c16037007.discon(e,tp,eg,ep,ev,re,r,rp)
if e:GetHandler():IsStatus(STATUS_BATTLE_DESTROYED) then return false end
if not re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then return false end
local tg=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS)
return tg:IsContains(e:GetHandler()) and Duel.IsChainNegatable(ev)
return tg and tg:IsContains(e:GetHandler()) and Duel.IsChainNegatable(ev)
end
function c16037007.discost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():CheckRemoveOverlayCard(tp,1,REASON_COST) end
......
......@@ -42,7 +42,8 @@ function c21702241.operation(e,tp,eg,ep,ev,re,r,rp)
end
end
function c21702241.damcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsContains(e:GetHandler():GetEquipTarget())
local tg=e:GetHandler():GetEquipTarget()
return tg and eg:IsContains(tg)
end
function c21702241.damtg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsRelateToEffect(e)
......
......@@ -14,6 +14,7 @@ function c4206964.initial_effect(c)
c:RegisterEffect(e2)
end
function c4206964.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if not eg then return false end
local tc=eg:GetFirst()
if chkc then return chkc==tc end
if chk==0 then return ep~=tp and tc:IsFaceup() and tc:GetAttack()>=1000 and tc:IsOnField()
......
......@@ -81,7 +81,7 @@ function c50903514.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
end
function c50903514.spop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
if tc and tc:IsRelateToEffect(e) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
end
end
......@@ -49,7 +49,7 @@ function c63227401.discon(e,tp,eg,ep,ev,re,r,rp)
local tc=e:GetLabelObject()
if tc:GetFlagEffect(63227401)==0 or not re:IsHasProperty(EFFECT_FLAG_CARD_TARGET) then return false end
local g=Duel.GetChainInfo(ev,CHAININFO_TARGET_CARDS)
return g:IsContains(tc) and re:IsActiveType(TYPE_MONSTER)
return g and g:IsContains(tc) and re:IsActiveType(TYPE_MONSTER)
end
function c63227401.disop(e,tp,eg,ep,ev,re,r,rp)
Duel.NegateEffect(ev)
......
......@@ -50,7 +50,8 @@ function c70423794.operation(e,tp,eg,ep,ev,re,r,rp)
end
end
function c70423794.descon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsContains(e:GetHandler():GetEquipTarget())
local tg=e:GetHandler():GetEquipTarget()
return tg and eg:IsContains(tg)
end
function c70423794.desfilter(c)
return c:IsType(TYPE_SPELL+TYPE_TRAP) and c:IsDestructable()
......
......@@ -51,7 +51,8 @@ function c75524092.operation(e,tp,eg,ep,ev,re,r,rp)
end
end
function c75524092.desreptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():GetEquipTarget():IsReason(REASON_BATTLE) end
local tg=e:GetHandler():GetEquipTarget()
if chk==0 then return tg and tg:IsReason(REASON_BATTLE) end
return true
end
function c75524092.desrepop(e,tp,eg,ep,ev,re,r,rp)
......
......@@ -20,9 +20,9 @@ end
function c93108839.eqtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(tp) and c93108839.filter(chkc) end
if chk==0 then return e:GetHandler():GetFlagEffect(93108839)==0 and Duel.GetLocationCount(tp,LOCATION_SZONE)>0
and Duel.IsExistingTarget(Card.IsFaceup,tp,LOCATION_MZONE,0,1,e:GetHandler()) end
and Duel.IsExistingTarget(c93108839.filter,tp,LOCATION_MZONE,0,1,e:GetHandler()) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_EQUIP)
local g=Duel.SelectTarget(tp,Card.IsFaceup,tp,LOCATION_MZONE,0,1,1,e:GetHandler())
local g=Duel.SelectTarget(tp,c93108839.filter,tp,LOCATION_MZONE,0,1,1,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_EQUIP,g,1,0,0)
e:GetHandler():RegisterFlagEffect(93108839,RESET_EVENT+0x7e0000+RESET_PHASE+PHASE_END,0,1)
end
......
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