Commit c0b537d7 authored by POLYMER's avatar POLYMER

fix

parent c3a2d611
......@@ -36,7 +36,7 @@ function c98346592.concon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_SYNCHRO)
end
function c98346592.confilter(c)
return c:IsFaceup() and c:IsControlerCanBeChanged()
return c:IsControlerCanBeChanged()
end
function c98346592.contg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsLocation(LOCATION_MZONE) and chkc:IsControler(1-tp) and c98346592.confilter(chkc) end
......@@ -72,9 +72,9 @@ function c98346592.rmcon(e,tp,eg,ep,ev,re,r,rp)
end
function c98346592.rmtg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() and chkc:IsControler(tp) and chkc:IsAbleToHand() and chkc:IsFaceup() end
if chk==0 then return Duel.IsExistingTarget(Card.IsAbleToHand and Card.IsFaceup,tp,LOCATION_ONFIELD,0,1,e:GetHandler()) and e:GetHandler():IsAbleToRemove() end
if chk==0 then return Duel.IsExistingTarget(Card.IsAbleToHand,tp,LOCATION_ONFIELD,0,1,e:GetHandler()) and e:GetHandler():IsAbleToRemove() end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RTOHAND)
local g=Duel.SelectTarget(tp,Card.IsAbleToHand and Card.IsFaceup,tp,LOCATION_ONFIELD,0,1,1,e:GetHandler())
local g=Duel.SelectTarget(tp,Card.IsAbleToHand,tp,LOCATION_ONFIELD,0,1,1,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_TOHAND,g,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_REMOVE,e:GetHandler(),1,0,0)
end
......
--电王·超cliamx形态
function c9981293.initial_effect(c)
c:EnableReviveLimit()
--
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(9981293,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_RELEASE)
e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_HAND+LOCATION_GRAVE)
e1:SetCountLimit(1,9981293)
e1:SetTarget(c9981293.tg1)
e1:SetOperation(c9981293.op1)
c:RegisterEffect(e1)
--damage
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(9981293,1))
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCategory(CATEGORY_DAMAGE)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,99812930)
e1:SetCost(c9981293.cost)
e1:SetTarget(c9981293.target)
e1:SetOperation(c9981293.operation)
c:RegisterEffect(e1)
--disable
local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e3:SetCode(EVENT_ATTACK_ANNOUNCE)
e3:SetRange(LOCATION_MZONE)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e3:SetCondition(c9981293.discon)
e3:SetOperation(c9981293.disop)
c:RegisterEffect(e3)
local e4=e3:Clone()
e4:SetCode(EVENT_BE_BATTLE_TARGET)
c:RegisterEffect(e4)
local e6=Effect.CreateEffect(c)
e6:SetType(EFFECT_TYPE_FIELD)
e6:SetCode(EFFECT_DISABLE)
e6:SetRange(LOCATION_MZONE)
e6:SetTargetRange(0,LOCATION_MZONE)
e6:SetTarget(c9981293.distg)
c:RegisterEffect(e6)
local e7=e6:Clone()
e7:SetCode(EFFECT_DISABLE_EFFECT)
c:RegisterEffect(e7)
--spsummon bgm
local e8=Effect.CreateEffect(c)
e8:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e8:SetCode(EVENT_SPSUMMON_SUCCESS)
e8:SetOperation(c9981293.sumsuc)
c:RegisterEffect(e8)
local e9=e8:Clone()
e9:SetCode(EVENT_SUMMON_SUCCESS)
c:RegisterEffect(e9)
end
function c9981293.sumsuc(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9981293,0))
end
function c9981293.mat_filter(c)
return c:IsRace(RACE_FIEND,RACE_WARRIOR)
end
function c9981293.tfilter1(c,tp,mg,rc)
if c:IsControler(tp) and c:IsLocation(LOCATION_MZONE) and c:GetSequence()<5 then
Duel.SetSelectedCard(c)
return mg:CheckWithSumGreater(Card.GetRitualLevel,4,rc)
else return false end
end
function c9981293.tg1(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then
local mg=Duel.GetRitualMaterial(tp):Filter(Card.IsCanBeRitualMaterial,c,c)
local ft=Duel.GetMZoneCount(tp)
if not c:IsCanBeSpecialSummoned(e,SUMMON_TYPE_RITUAL,tp,false,true) then return false end
if ft>0 then
return mg:CheckWithSumGreater(Card.GetRitualLevel,4,c)
else
return mg:IsExists(c9981293.tfilter1,1,nil,tp,mg,c)
end
end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_HAND+LOCATION_GRAVE)
end
function c9981293.op1(e,tp,eg,ep,ev,re,r,rp)
local tc=e:GetHandler()
local mg=Duel.GetRitualMaterial(tp)
local ft=Duel.GetMZoneCount(tp)
if tc then
mg=mg:Filter(Card.IsCanBeRitualMaterial,tc,tc)
local mat=nil
if ft>0 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
mat=mg:SelectWithSumGreater(tp,Card.GetRitualLevel,4,tc)
else
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
mat=mg:FilterSelect(tp,c9981293.tfilter1,1,1,nil,tp,mg,tc)
Duel.SetSelectedCard(mat)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local mat2=mg:SelectWithSumGreater(tp,Card.GetRitualLevel,4,tc)
mat:Merge(mat2)
end
tc:SetMaterial(mat)
Duel.ReleaseRitualMaterial(mat)
e:SetLabel(mat:GetCount())
if not tc:IsRelateToEffect(e) then return end
Duel.BreakEffect()
Duel.SpecialSummon(tc,SUMMON_TYPE_RITUAL,tp,tp,false,true,POS_FACEUP)
tc:CompleteProcedure()
end
end
function c9981293.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(Card.IsReleasable,tp,0,LOCATION_ONFIELD,1,nil) end
local g=Duel.SelectMatchingCard(tp,Card.IsReleasable,tp,0,LOCATION_ONFIELD,1,1,nil)
Duel.Release(g,REASON_COST)
end
function c9981293.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetTargetPlayer(1-tp)
Duel.SetTargetParam(1000)
Duel.SetOperationInfo(0,CATEGORY_DAMAGE,nil,0,1-tp,1000)
end
function c9981293.operation(e,tp,eg,ep,ev,re,r,rp)
local p,d=Duel.GetChainInfo(0,CHAININFO_TARGET_PLAYER,CHAININFO_TARGET_PARAM)
Duel.Damage(p,d,REASON_EFFECT)
Duel.Hint(HINT_MUSIC,0,aux.Stringid(9981293,1))
end
function c9981293.cfilter(c,tp)
return c:IsFaceup() and c:IsSetCard(0x3bcd) and c:IsControler(tp)
end
function c9981293.discon(e,tp,eg,ep,ev,re,r,rp)
local c=Duel.GetAttackTarget()
if not c then return false end
if c:IsControler(1-tp) then c=Duel.GetAttacker() end
return c and c9981293.cfilter(c,tp)
end
function c9981293.disop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetAttackTarget()
if tc:IsControler(tp) then tc=Duel.GetAttacker() end
tc:RegisterFlagEffect(9981293,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_BATTLE,0,1)
end
function c9981293.distg(e,c)
return c:GetFlagEffect(9981293)~=0
end
\ No newline at end of file
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