Commit c8e80a62 authored by VanillaSalt's avatar VanillaSalt

fix

parent 07e925ec
...@@ -48,13 +48,13 @@ function c23187256.xyzcon(e,c,og) ...@@ -48,13 +48,13 @@ function c23187256.xyzcon(e,c,og)
if c==nil then return true end if c==nil then return true end
local tp=c:GetControler() local tp=c:GetControler()
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE) local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
local ct=-ft local ct=math.max(1,-ft)
local mg=Duel.GetMatchingGroup(c23187256.mfilter,tp,LOCATION_MZONE,0,nil,c) local mg=Duel.GetMatchingGroup(c23187256.mfilter,tp,LOCATION_MZONE,0,nil,c)
return mg:IsExists(c23187256.xyzfilter1,1,nil,mg,ct) return mg:IsExists(c23187256.xyzfilter1,1,nil,mg,ct)
end end
function c23187256.xyzop(e,tp,eg,ep,ev,re,r,rp,c,og) function c23187256.xyzop(e,tp,eg,ep,ev,re,r,rp,c,og)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE) local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
local ct=-ft local ct=math.max(1,-ft)
local mg=Duel.GetMatchingGroup(c23187256.mfilter,tp,LOCATION_MZONE,0,nil,c) local mg=Duel.GetMatchingGroup(c23187256.mfilter,tp,LOCATION_MZONE,0,nil,c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_XMATERIAL) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_XMATERIAL)
local g1=mg:FilterSelect(tp,c23187256.xyzfilter1,1,1,nil,mg,ct) local g1=mg:FilterSelect(tp,c23187256.xyzfilter1,1,1,nil,mg,ct)
......
...@@ -36,17 +36,18 @@ function c36076683.atkop(e,tp,eg,ep,ev,re,r,rp) ...@@ -36,17 +36,18 @@ function c36076683.atkop(e,tp,eg,ep,ev,re,r,rp)
e1:SetReset(RESET_EVENT+0x1ff0000+RESET_PHASE+PHASE_END+RESET_OPPO_TURN) e1:SetReset(RESET_EVENT+0x1ff0000+RESET_PHASE+PHASE_END+RESET_OPPO_TURN)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS) e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EVENT_PRE_BATTLE_DAMAGE) e2:SetCode(EFFECT_CHANGE_DAMAGE)
e2:SetCondition(c36076683.rdcon) e2:SetRange(LOCATION_MZONE)
e2:SetOperation(c36076683.rdop) e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetTargetRange(0,1)
e2:SetValue(c36076683.damval)
e2:SetReset(RESET_EVENT+0x1ff0000+RESET_PHASE+PHASE_END) e2:SetReset(RESET_EVENT+0x1ff0000+RESET_PHASE+PHASE_END)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
end end
function c36076683.rdcon(e,tp,eg,ep,ev,re,r,rp) function c36076683.damval(e,re,dam,r,rp,rc)
return ep~=tp if bit.band(r,REASON_BATTLE)~=0 and rc==e:GetHandler() then
end return dam/2
function c36076683.rdop(e,tp,eg,ep,ev,re,r,rp) else return dam end
Duel.ChangeBattleDamage(ep,ev/2)
end end
...@@ -25,11 +25,12 @@ function c37364101.initial_effect(c) ...@@ -25,11 +25,12 @@ function c37364101.initial_effect(c)
c:RegisterEffect(e3) c:RegisterEffect(e3)
--damage change --damage change
local e4=Effect.CreateEffect(c) local e4=Effect.CreateEffect(c)
e4:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS) e4:SetType(EFFECT_TYPE_FIELD)
e4:SetCode(EFFECT_CHANGE_DAMAGE)
e4:SetRange(LOCATION_SZONE) e4:SetRange(LOCATION_SZONE)
e4:SetCode(EVENT_PRE_BATTLE_DAMAGE) e4:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e4:SetCondition(c37364101.damcon) e4:SetTargetRange(0,1)
e4:SetOperation(c37364101.damop) e4:SetValue(c37364101.damval)
c:RegisterEffect(e4) c:RegisterEffect(e4)
-- --
local e5=Effect.CreateEffect(c) local e5=Effect.CreateEffect(c)
...@@ -76,11 +77,10 @@ end ...@@ -76,11 +77,10 @@ end
function c37364101.atkval(e,c) function c37364101.atkval(e,c)
return Duel.GetOverlayCount(e:GetHandlerPlayer(),1,0)*600 return Duel.GetOverlayCount(e:GetHandlerPlayer(),1,0)*600
end end
function c37364101.damcon(e,tp,eg,ep,ev,re,r,rp) function c37364101.damval(e,re,dam,r,rp,rc)
return eg:GetFirst()==e:GetHandler():GetEquipTarget() and ep~=tp and eg:GetFirst():GetBattleTarget()~=nil if bit.band(r,REASON_BATTLE)~=0 and rc==e:GetHandler():GetEquipTarget() and rc:GetBattleTarget()~=nil then
end return dam*2
function c37364101.damop(e,tp,eg,ep,ev,re,r,rp) else return dam end
Duel.ChangeBattleDamage(ep,ev*2)
end end
function c37364101.tgcon(e,tp,eg,ep,ev,re,r,rp) function c37364101.tgcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()~=tp return Duel.GetTurnPlayer()~=tp
......
...@@ -60,5 +60,4 @@ function c51196805.rmop(e,tp,eg,ep,ev,re,r,rp) ...@@ -60,5 +60,4 @@ function c51196805.rmop(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetDecktopGroup(1-tp,ac) local g=Duel.GetDecktopGroup(1-tp,ac)
Duel.DisableShuffleCheck() Duel.DisableShuffleCheck()
Duel.Remove(g,POS_FACEDOWN,REASON_EFFECT) Duel.Remove(g,POS_FACEDOWN,REASON_EFFECT)
Duel.ConfirmCards(1-tp,g)
end 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