Commit 76e5fb31 authored by mercury233's avatar mercury233

fix

parent e9ebaf24
......@@ -37,12 +37,11 @@ function c101008008.atkcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:IsAbleToGraveAsCost() end
Duel.SendtoGrave(c,REASON_COST)
c:RegisterFlagEffect(101008008,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,0,0)
end
function c101008008.atkop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=e:GetLabelObject()
if tc:IsRelateToBattle() then
local c=e:GetHandler()
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_INDESTRUCTABLE_BATTLE)
......@@ -57,6 +56,7 @@ function c101008008.atkop(e,tp,eg,ep,ev,re,r,rp)
e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_DAMAGE)
tc:RegisterEffect(e2)
end
c:RegisterFlagEffect(101008008,RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END,0,1)
end
function c101008008.skipop(e,tp,eg,ep,ev,re,r,rp)
Duel.SkipPhase(1-tp,PHASE_BATTLE,RESET_PHASE+PHASE_BATTLE_STEP,1)
......
......@@ -39,7 +39,7 @@ function c101008022.initial_effect(c)
c:RegisterEffect(e3)
end
function c101008022.cfilter(c)
return c:IsAbleToRemoveAsCost() and c:IsAttribute(ATTRIBUTE_FIRE+ATTRIBUTE_WIND) and not c:IsCode(101008022)
return c:IsAbleToRemoveAsCost() and c:IsAttribute(ATTRIBUTE_FIRE+ATTRIBUTE_WIND)
end
function c101008022.cfilter1(c,g)
return c:IsAttribute(ATTRIBUTE_FIRE) and g:IsExists(Card.IsAttribute,1,c,ATTRIBUTE_WIND)
......@@ -90,7 +90,8 @@ function c101008022.desop1(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
local atk=math.max(tc:GetTextAttack(),0)
if tc:IsRelateToEffect(e) then
if Duel.Destroy(tc,REASON_EFFECT)~=0 and c:IsFaceup() and atk>0 then
if Duel.Destroy(tc,REASON_EFFECT)~=0
and c:IsFaceup() and c:IsRelateToEffect(e) and atk>0 then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetProperty(EFFECT_FLAG_COPY_INHERIT)
......
......@@ -29,7 +29,7 @@ function c101008023.initial_effect(c)
c:RegisterEffect(e2)
end
function c101008023.spfilter(c,tp)
return c:IsControler(tp) and c:IsType(TYPE_XYZ)
return c:IsControler(tp) and c:IsType(TYPE_XYZ) and c:IsFaceup()
end
function c101008023.spcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c101008023.spfilter,1,nil,tp)
......@@ -67,7 +67,7 @@ end
function c101008023.matop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local tc=Duel.GetFirstTarget()
if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and tc:IsFaceup() and tc:IsControler(tp) then
if c:IsRelateToEffect(e) and tc:IsRelateToEffect(e) and not tc:IsImmuneToEffect(e) then
Duel.Overlay(tc,Group.FromCards(c))
end
end
......@@ -70,7 +70,7 @@ function c101008031.spcon(e,tp,eg,ep,ev,re,r,rp)
return c:IsPreviousLocation(LOCATION_MZONE) and c:IsSummonType(SUMMON_TYPE_FUSION) and bit.band(r,REASON_EFFECT+REASON_BATTLE)~=0
end
function c101008031.spfilter(c,e,tp)
return c:IsSetCard(0xc008) and c:IsType(TYPE_MONSTER) and c:IsLevelBelow(9) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
return c:IsSetCard(0xc008) and c:IsLevelBelow(9) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
and c:IsCanBeEffectTarget(e)
end
function c101008031.spcheck(g)
......
......@@ -56,7 +56,7 @@ function c101008035.spcon(e,tp,eg,ep,ev,re,r,rp)
return c:IsPreviousLocation(LOCATION_MZONE) and c:IsSummonType(SUMMON_TYPE_SYNCHRO)
end
function c101008035.spfilter(c,e,tp)
return c:IsSetCard(0xfd) and c:IsType(TYPE_MONSTER) and not c:IsCode(101008035) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
return c:IsSetCard(0xfd) and not c:IsCode(101008035) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c101008035.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
......
......@@ -77,7 +77,7 @@ function c101008040.spcon(e,tp,eg,ep,ev,re,r,rp)
and c:IsPreviousLocation(LOCATION_MZONE) and c:IsSummonType(SUMMON_TYPE_XYZ)
end
function c101008040.spfilter(c,e,tp)
return c:IsRace(RACE_CYBERSE) and c:IsType(TYPE_MONSTER) and c:IsLevel(4) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
return c:IsRace(RACE_CYBERSE) and c:IsLevel(4) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c101008040.spcheck(g)
return g:GetClassCount(Card.GetCode)==#g
......
......@@ -62,7 +62,7 @@ function c101008042.spcon(e,tp,eg,ep,ev,re,r,rp)
return c:IsLocation(LOCATION_GRAVE) and r==REASON_LINK
end
function c101008042.spfilter(c,e,tp)
return c:IsType(TYPE_MONSTER) and c:IsSetCard(0x11a) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE)
return c:IsSetCard(0x11a) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP_DEFENSE)
end
function c101008042.sptg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsControler(tp) and chkc:IsLocation(LOCATION_GRAVE) and c101008042.spfilter(chkc,e,tp) end
......
......@@ -100,7 +100,7 @@ function c101008048.spcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c101008048.cfilter,1,nil,1-tp)
end
function c101008048.spfilter(c,e,tp)
return c:IsSetCard(0xfe) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
return c:IsSetCard(0xfe) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c101008048.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
......
......@@ -19,7 +19,7 @@ function c101008049.initial_effect(c)
c:RegisterEffect(e1)
--destroy
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(101008049,0))
e2:SetDescription(aux.Stringid(101008049,1))
e2:SetCategory(CATEGORY_DESTROY)
e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetCountLimit(1,101008049+100)
......
......@@ -77,7 +77,7 @@ function c101008057.cfilter(c,e,tp)
and Duel.IsExistingTarget(c101008057.spfilter,tp,LOCATION_GRAVE,0,1,c,e,tp)
end
function c101008057.spfilter(c,e,tp)
return c:IsSetCard(0x121) and c:IsType(TYPE_MONSTER) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
return c:IsSetCard(0x121) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c101008057.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return e:GetHandler():IsAbleToRemoveAsCost()
......
......@@ -62,7 +62,7 @@ function c101008058.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.Remove(g,POS_FACEUP,REASON_COST)
end
function c101008058.spfilter(c,e,tp)
return c:IsType(TYPE_MONSTER) and c:IsSetCard(0x18) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
return c:IsSetCard(0x18) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c101008058.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
......
......@@ -29,7 +29,7 @@ function c101008062.filter(c,e,tp)
and Duel.IsExistingMatchingCard(c101008062.spfilter,tp,LOCATION_DECK,0,2,nil,e,tp,c:GetCode())
end
function c101008062.spfilter(c,e,tp,code)
return c:IsType(TYPE_MONSTER) and c:IsCode(code) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
return c:IsCode(code) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c101008062.activate(e,tp,eg,ep,ev,re,r,rp)
if not e:GetHandler():IsRelateToEffect(e) or Duel.IsPlayerAffectedByEffect(tp,59822133) then return end
......
......@@ -55,7 +55,8 @@ function c101008065.operation(e,tp,eg,ep,ev,re,r,rp)
end
end
function c101008065.efilter(e,te)
return te:GetOwnerPlayer()~=e:GetHandlerPlayer() and te:GetActivateLocation()==LOCATION_MZONE and te:GetHandler():IsSummonType(SUMMON_TYPE_SPECIAL)
return te:GetOwnerPlayer()~=e:GetHandlerPlayer() and te:GetActivateLocation()==LOCATION_MZONE
and te:IsActivated() and te:GetHandler():IsSummonType(SUMMON_TYPE_SPECIAL)
end
function c101008065.atkcon(e,tp,eg,ep,ev,re,r,rp)
local ec=e:GetHandler():GetEquipTarget()
......
......@@ -50,7 +50,6 @@ function c101008066.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,sg,1,0,0)
end
function c101008066.activate(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetMZoneCount(tp)<1 then return end
local tc=Duel.GetFirstTarget()
if not tc:IsRelateToEffect(e) then return end
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)
......
......@@ -36,7 +36,7 @@ function c101008073.spcon(e,tp,eg,ep,ev,re,r,rp)
return Duel.GetFieldGroupCount(tp,0,LOCATION_MZONE)>0
end
function c101008073.spfilter(c,e,tp,code)
return c:IsSetCard(0x109) and c:IsType(TYPE_MONSTER) and not c:IsCode(code) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
return c:IsSetCard(0x109) and not c:IsCode(code) and c:IsCanBeSpecialSummoned(e,0,tp,false,false)
end
function c101008073.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>-1
......
......@@ -9,12 +9,13 @@ function c101008075.initial_effect(c)
c:RegisterEffect(e1)
--boost
local e2=Effect.CreateEffect(c)
e2:SetCategory(CATEGORY_ATKCHANGE+CATEGORY_DEFCHANGE)
e2:SetCategory(CATEGORY_ATKCHANGE)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET+EFFECT_FLAG_DAMAGE_STEP)
e2:SetRange(LOCATION_SZONE)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetLabel(0)
e2:SetHintTiming(TIMING_DAMAGE_STEP)
e2:SetCountLimit(1,101008075)
e2:SetCost(c101008075.atkcost)
e2:SetTarget(c101008075.atktg)
......@@ -51,11 +52,11 @@ function c101008075.atktg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chk==0 then
if e:GetLabel()~=1 then return false end
e:SetLabel(0)
return Duel.IsExistingMatchingCard(c101008075.cfilter,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_ONFIELD,0,1,nil,e)
return Duel.IsExistingMatchingCard(c101008075.cfilter,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_MZONE,0,1,nil,e)
end
e:SetLabel(0)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g=Duel.SelectMatchingCard(tp,c101008075.cfilter,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_ONFIELD,0,1,1,nil,e)
local g=Duel.SelectMatchingCard(tp,c101008075.cfilter,tp,LOCATION_HAND+LOCATION_GRAVE+LOCATION_MZONE,0,1,1,nil,e)
Duel.Remove(g,POS_FACEUP,REASON_COST)
e:SetLabelObject(g:GetFirst())
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FACEUP)
......
......@@ -21,19 +21,19 @@ function c101008076.tdfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsAbleToDeck()
end
function c101008076.target(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.GetMatchingGroup(c101008076.tdfilter,tp,LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD+LOCATION_GRAVE,nil)
local g=Duel.GetMatchingGroup(c101008076.tdfilter,tp,LOCATION_MZONE+LOCATION_GRAVE,LOCATION_MZONE+LOCATION_GRAVE,nil)
if chk==0 then return g:GetCount()>0 end
Duel.SetOperationInfo(0,CATEGORY_TODECK,g,g:GetCount(),0,0)
end
function c101008076.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local g=Duel.GetMatchingGroup(c101008076.tdfilter,tp,LOCATION_ONFIELD+LOCATION_GRAVE,LOCATION_ONFIELD+LOCATION_GRAVE,nil)
local g=Duel.GetMatchingGroup(c101008076.tdfilter,tp,LOCATION_MZONE+LOCATION_GRAVE,LOCATION_MZONE+LOCATION_GRAVE,nil)
if g:GetCount()>0 then
Duel.SendtoDeck(g,nil,2,REASON_EFFECT)
end
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET+EFFECT_FLAG_OATH)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetTargetRange(1,1)
e1:SetTarget(c101008076.splimit)
......
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