Commit ef626d74 authored by Chrono-Genex's avatar Chrono-Genex Committed by GitHub

fix for Pandemonium (#1588)

parent 2d674fe0
......@@ -44,8 +44,12 @@ function c35606858.mtcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp
end
function c35606858.mtop(e,tp,eg,ep,ev,re,r,rp)
if Duel.CheckLPCost(tp,500) and Duel.SelectYesNo(tp,aux.Stringid(35606858,2)) then
if (Duel.CheckLPCost(tp,500) or Duel.IsPlayerAffectedByEffect(tp,94585852))
and Duel.SelectEffectYesNo(tp,e:GetHandler(),aux.Stringid(35606858,2)) then
if not Duel.IsPlayerAffectedByEffect(tp,94585852)
or not Duel.SelectEffectYesNo(tp,e:GetHandler(),aux.Stringid(94585852,1)) then
Duel.PayLPCost(tp,500)
end
else
Duel.Destroy(e:GetHandler(),REASON_COST)
end
......
......@@ -23,8 +23,11 @@ function c35798491.mtcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp
end
function c35798491.mtop(e,tp,eg,ep,ev,re,r,rp)
if Duel.CheckLPCost(tp,500) then
if Duel.CheckLPCost(tp,500) or Duel.IsPlayerAffectedByEffect(tp,94585852) then
if not Duel.IsPlayerAffectedByEffect(tp,94585852)
or not Duel.SelectEffectYesNo(tp,e:GetHandler(),aux.Stringid(94585852,1)) then
Duel.PayLPCost(tp,500)
end
else
Duel.Destroy(e:GetHandler(),REASON_COST)
end
......
......@@ -45,8 +45,11 @@ function c35975813.mtcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp
end
function c35975813.mtop(e,tp,eg,ep,ev,re,r,rp)
if Duel.CheckLPCost(tp,800) then
if Duel.CheckLPCost(tp,800) or Duel.IsPlayerAffectedByEffect(tp,94585852) then
if not Duel.IsPlayerAffectedByEffect(tp,94585852)
or not Duel.SelectEffectYesNo(tp,e:GetHandler(),aux.Stringid(94585852,1)) then
Duel.PayLPCost(tp,800)
end
else
Duel.Destroy(e:GetHandler(),REASON_COST)
end
......
......@@ -27,8 +27,11 @@ function c52248570.mtcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp
end
function c52248570.mtop(e,tp,eg,ep,ev,re,r,rp)
if Duel.CheckLPCost(tp,1000) then
if Duel.CheckLPCost(tp,1000) or Duel.IsPlayerAffectedByEffect(tp,94585852) then
if not Duel.IsPlayerAffectedByEffect(tp,94585852)
or not Duel.SelectEffectYesNo(tp,e:GetHandler(),aux.Stringid(94585852,1)) then
Duel.PayLPCost(tp,1000)
end
else
Duel.Destroy(e:GetHandler(),REASON_COST)
end
......
......@@ -23,8 +23,11 @@ function c61370518.mtcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp
end
function c61370518.mtop(e,tp,eg,ep,ev,re,r,rp)
if Duel.CheckLPCost(tp,500) then
if Duel.CheckLPCost(tp,500) or Duel.IsPlayerAffectedByEffect(tp,94585852) then
if not Duel.IsPlayerAffectedByEffect(tp,94585852)
or not Duel.SelectEffectYesNo(tp,e:GetHandler(),aux.Stringid(94585852,1)) then
Duel.PayLPCost(tp,500)
end
else
Duel.Destroy(e:GetHandler(),REASON_COST)
end
......
......@@ -54,8 +54,11 @@ function c70780151.discon(e,tp,eg,ep,ev,re,r,rp)
return re:IsHasType(EFFECT_TYPE_ACTIVATE) and Duel.IsChainNegatable(ev)
end
function c70780151.discost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.CheckLPCost(tp,1000) end
if chk==0 then return Duel.CheckLPCost(tp,1000) or Duel.IsPlayerAffectedByEffect(tp,94585852) end
if not Duel.IsPlayerAffectedByEffect(tp,94585852)
or not Duel.SelectEffectYesNo(tp,e:GetHandler(),aux.Stringid(94585852,1)) then
Duel.PayLPCost(tp,1000)
end
end
function c70780151.distg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
......
......@@ -35,8 +35,11 @@ function c72192100.mtcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp
end
function c72192100.mtop(e,tp,eg,ep,ev,re,r,rp)
if Duel.CheckLPCost(tp,500) then
if Duel.CheckLPCost(tp,500) or Duel.IsPlayerAffectedByEffect(tp,94585852) then
if not Duel.IsPlayerAffectedByEffect(tp,94585852)
or not Duel.SelectEffectYesNo(tp,e:GetHandler(),aux.Stringid(94585852,1)) then
Duel.PayLPCost(tp,500)
end
else
Duel.Destroy(e:GetHandler(),REASON_COST)
end
......
......@@ -31,8 +31,11 @@ function c73219648.mtcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp
end
function c73219648.mtop(e,tp,eg,ep,ev,re,r,rp)
if Duel.CheckLPCost(tp,500) then
if Duel.CheckLPCost(tp,500) or Duel.IsPlayerAffectedByEffect(tp,94585852) then
if not Duel.IsPlayerAffectedByEffect(tp,94585852)
or not Duel.SelectEffectYesNo(tp,e:GetHandler(),aux.Stringid(94585852,1)) then
Duel.PayLPCost(tp,500)
end
else
Duel.Destroy(e:GetHandler(),REASON_COST)
end
......
......@@ -22,9 +22,12 @@ function c84341431.initial_effect(c)
c:RegisterEffect(e2)
end
function c84341431.reptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsReason(REASON_EFFECT) and not e:GetHandler():IsReason(REASON_REPLACE) and Duel.CheckLPCost(tp,500) end
if chk==0 then return e:GetHandler():IsReason(REASON_EFFECT) and not e:GetHandler():IsReason(REASON_REPLACE) and (Duel.CheckLPCost(tp,500) or Duel.IsPlayerAffectedByEffect(tp,94585852)) end
if Duel.SelectEffectYesNo(tp,e:GetHandler(),96) then
if not Duel.IsPlayerAffectedByEffect(tp,94585852)
or not Duel.SelectEffectYesNo(tp,e:GetHandler(),aux.Stringid(94585852,1)) then
Duel.PayLPCost(tp,500)
end
return true
else return false end
end
......
......@@ -34,8 +34,11 @@ function c8581705.mtcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp
end
function c8581705.mtop(e,tp,eg,ep,ev,re,r,rp)
if Duel.CheckLPCost(tp,500) then
if Duel.CheckLPCost(tp,500) or Duel.IsPlayerAffectedByEffect(tp,94585852) then
if not Duel.IsPlayerAffectedByEffect(tp,94585852)
or not Duel.SelectEffectYesNo(tp,e:GetHandler(),aux.Stringid(94585852,1)) then
Duel.PayLPCost(tp,500)
end
else
Duel.Destroy(e:GetHandler(),REASON_COST)
end
......
......@@ -8,11 +8,11 @@ function c94585852.initial_effect(c)
--cost change
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_LPCOST_CHANGE)
e2:SetCode(94585852)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetRange(LOCATION_FZONE)
e2:SetTargetRange(1,1)
e2:SetValue(c94585852.costchange)
e2:SetCondition(c94585852.costcon)
c:RegisterEffect(e2)
--search
local e4=Effect.CreateEffect(c)
......@@ -34,12 +34,8 @@ function c94585852.initial_effect(c)
Duel.RegisterEffect(ge1,0)
end
end
function c94585852.costchange(e,re,rp,val)
if Duel.GetCurrentPhase()==PHASE_STANDBY and re and re:GetHandler():IsSetCard(0x45) and re:GetHandler():IsType(TYPE_MONSTER) then
return 0
else
return val
end
function c94585852.costcon(e)
return Duel.GetCurrentPhase()==PHASE_STANDBY
end
function c94585852.regop(e,tp,eg,ep,ev,re,r,rp)
local lv1=0
......
......@@ -29,8 +29,11 @@ function c9603356.mtcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetTurnPlayer()==tp
end
function c9603356.mtop(e,tp,eg,ep,ev,re,r,rp)
if Duel.CheckLPCost(tp,900) then
if Duel.CheckLPCost(tp,900) or Duel.IsPlayerAffectedByEffect(tp,94585852) then
if not Duel.IsPlayerAffectedByEffect(tp,94585852)
or not Duel.SelectEffectYesNo(tp,e:GetHandler(),aux.Stringid(94585852,1)) then
Duel.PayLPCost(tp,900)
end
else
Duel.Destroy(e:GetHandler(),REASON_COST)
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