Commit 88e397d7 authored by TanakaKotoha's avatar TanakaKotoha

fix

parent c0b06eb5
...@@ -46,7 +46,7 @@ function c12004022.initial_effect(c) ...@@ -46,7 +46,7 @@ function c12004022.initial_effect(c)
c:RegisterEffect(e6) c:RegisterEffect(e6)
end end
function cm.mfilter(c) function cm.mfilter(c)
return c:IsRace(RACE_MACHINE) and not c:GetOriginalRace(RACE_MACHINE) return c:IsRace(RACE_MACHINE) and c:GetOriginalRace()~=RACE_MACHINE
end end
function c12004022.condition(e,tp,eg,ep,ev,re,r,rp) function c12004022.condition(e,tp,eg,ep,ev,re,r,rp)
return re:IsActiveType(TYPE_MONSTER) and re:GetHandler():IsLocation(LOCATION_MZONE) return re:IsActiveType(TYPE_MONSTER) and re:GetHandler():IsLocation(LOCATION_MZONE)
......
...@@ -99,7 +99,7 @@ function c12004023.fsfilter2(c) ...@@ -99,7 +99,7 @@ function c12004023.fsfilter2(c)
end end
function c12004023.destg(e,tp,eg,ep,ev,re,r,rp,chk) function c12004023.destg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end if chk==0 then return true end
local g=GetMatchingGroup(aux.TRUE,tp,LOCATION_MZONE,LOCATION_MZONE,e:GetHandler()) local g=Duel.GetMatchingGroup(aux.TRUE,tp,LOCATION_MZONE,LOCATION_MZONE,e:GetHandler())
if g:GetCount()>0 then if g:GetCount()>0 then
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0) Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
end end
......
...@@ -45,19 +45,10 @@ function c12008008.initial_effect(c) ...@@ -45,19 +45,10 @@ function c12008008.initial_effect(c)
e5:SetTarget(c12008008.target) e5:SetTarget(c12008008.target)
e5:SetOperation(c12008008.operation) e5:SetOperation(c12008008.operation)
c:RegisterEffect(e5) c:RegisterEffect(e5)
local e5=Effect.CreateEffect(c)
e5:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e5:SetCode(EVENT_PRE_BATTLE_DAMAGE)
e5:SetCondition(c12008008.condition)
e5:SetOperation(c12008008.damop)
c:RegisterEffect(e5)
end
function c12008008.damop(e,tp,eg,ep,ev,re,r,rp)
Duel.ChangeBattleDamage(ep,ev*2)
end end
function c12008008.condition(e,tp,eg,ep,ev,re,r,rp) function c12008008.condition(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetLP(0)<Duel.GetLP(1) local tp=e:GetHandler()
return Duel.GetLP(tp)<Duel.GetLP(1-tp)
end end
function c12008008.filter(c,lp) function c12008008.filter(c,lp)
return c:IsFacedown() or (c:IsFaceup() and c:GetAttack()>0 and c:GetAttack()<=lp) return c:IsFacedown() or (c:IsFaceup() and c:GetAttack()>0 and c:GetAttack()<=lp)
......
...@@ -50,12 +50,13 @@ function cm.efcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -50,12 +50,13 @@ function cm.efcon(e,tp,eg,ep,ev,re,r,rp)
end end
function cm.efop(e,tp,eg,ep,ev,re,r,rp) function cm.efop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local g=eg:Filter(Card.IsType,1,nil,TYPE_PENDULUM) local g=eg:Filter(Card.IsType,nil,TYPE_PENDULUM)
local rc=g:GetFirst() local rc=g:GetFirst()
if not rc then return end if not rc then return end
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(0,LOCATION_MZONE) e1:SetTargetRange(0,LOCATION_MZONE)
e1:SetValue(cm.atkval) e1:SetValue(cm.atkval)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
......
...@@ -69,13 +69,15 @@ function cm.efcon(e,tp,eg,ep,ev,re,r,rp) ...@@ -69,13 +69,15 @@ function cm.efcon(e,tp,eg,ep,ev,re,r,rp)
end end
function cm.efop(e,tp,eg,ep,ev,re,r,rp) function cm.efop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local g=eg:Filter(Card.IsType,1,nil,TYPE_PENDULUM) local g=eg:Filter(Card.IsType,nil,TYPE_PENDULUM)
local rc=g:GetFirst() local rc=g:GetFirst()
if not rc then return end if not rc then return end
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_IMMUNE_EFFECT) e1:SetCode(EFFECT_IMMUNE_EFFECT)
e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE) e1:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e1:SetRange(LOCATION_MZONE)
e1:SetTargetRange(0,LOCATION_MZONE)
e1:SetValue(cm.immval) e1:SetValue(cm.immval)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
rc:RegisterEffect(e1,true) rc:RegisterEffect(e1,true)
......
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