Commit b8dc3df5 authored by mercury233's avatar mercury233

fix

parent 589945b9
......@@ -17,11 +17,11 @@ function c101105004.initial_effect(c)
e1:SetOperation(c101105004.disop)
c:RegisterEffect(e1)
--special summon itself
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(101105004,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(101105004,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetHintTiming(0,TIMING_END_PHASE)
e2:SetRange(LOCATION_GRAVE)
e2:SetCountLimit(1,101105004)
......
......@@ -14,13 +14,13 @@ function c101105005.initial_effect(c)
e1:SetTarget(c101105005.thtg)
e1:SetOperation(c101105005.thop)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EVENT_REMOVE)
local e2=e1:Clone()
e2:SetCode(EVENT_REMOVE)
c:RegisterEffect(e2)
--set to your field
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(101105005,1))
e3:SetType(EFFECT_TYPE_IGNITION)
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(101105005,1))
e3:SetType(EFFECT_TYPE_IGNITION)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetRange(LOCATION_GRAVE)
e3:SetCountLimit(1,101105005)
......
......@@ -13,8 +13,8 @@ function c101105006.initial_effect(c)
e1:SetTarget(c101105006.thtg)
e1:SetOperation(c101105006.thop)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetCode(EVENT_SPUMMON_SUCCESS)
local e2=e1:Clone()
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e2)
--special summon & disable
local e3=Effect.CreateEffect(c)
......
......@@ -16,9 +16,9 @@ function c101105007.initial_effect(c)
e1:SetOperation(c101105007.disop)
c:RegisterEffect(e1)
--special summon itself
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(101105007,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(101105007,1))
e2:SetCategory(CATEGORY_SPECIAL_SUMMON)
e2:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCode(EVENT_BE_MATERIAL)
......@@ -64,7 +64,7 @@ function c101105007.disop(e,tp,eg,ep,ev,re,r,rp)
end
function c101105007.spcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
return c:IsPreviousLocation(LOCATION_HAND+LOCATION_ONFIELD)
return c:IsPreviousLocation(LOCATION_HAND+LOCATION_ONFIELD)
and c:IsLocation(LOCATION_GRAVE+LOCATION_REMOVED) and r==REASON_FUSION
end
function c101105007.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
......
......@@ -71,7 +71,7 @@ function c101105015.atkop(e,tp,eg,ep,ev,re,r,rp)
e1:SetValue(atk)
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
tc:RegisterEffect(e1)
local e2=e1:Clone()
local e2=e1:Clone()
e2:SetCode(EFFECT_SET_DEFENSE_FINAL)
tc:RegisterEffect(e2)
local e3=Effect.CreateEffect(c)
......
......@@ -12,7 +12,7 @@ function c101105017.initial_effect(c)
e1:SetTarget(c101105017.tdtg)
e1:SetOperation(c101105017.tdop)
c:RegisterEffect(e1)
local e2=e1:Clone()
local e2=e1:Clone()
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e2)
--revive
......
......@@ -27,7 +27,7 @@ end
function c101105020.cfilter(c)
return c:IsSetCard(0x15c) and c:IsType(TYPE_TRAP) and not c:IsPublic()
end
function c101105020.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
function c101105020.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.IsExistingMatchingCard(c101105020.cfilter,tp,LOCATION_HAND,0,1,nil) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_CONFIRM)
local g=Duel.SelectMatchingCard(tp,c101105020.cfilter,tp,LOCATION_HAND,0,1,1,nil)
......
......@@ -27,7 +27,7 @@ function c101105021.initial_effect(c)
c:RegisterEffect(e2)
end
c101105021.counter_add_list={0x100e}
function c101105021.ctfilter(c)
function c101105021.ctfilter(c)
return c:IsFaceup() and c:IsType(TYPE_MONSTER)
end
function c101105021.cttg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
......
......@@ -25,8 +25,8 @@ function c101105022.initial_effect(c)
e2:SetTarget(c101105022.thtg)
e2:SetOperation(c101105022.thop)
c:RegisterEffect(e2)
local e3=e2:Clone()
e3:SetCode(EVENT_SPSUMMON_SUCCESS)
local e3=e2:Clone()
e3:SetCode(EVENT_SPSUMMON_SUCCESS)
c:RegisterEffect(e3)
end
function c101105022.spcon(e,tp,eg,ep,ev,re,r,rp)
......
......@@ -63,7 +63,7 @@ function c101105031.seqop(e,tp,eg,ep,ev,re,r,rp)
local seq1=math.log(flag,2)
local seq2=4-math.log(flag,2)
if Duel.MoveSequence(c,seq1)~=0 then
Duel.MoveSequence(tc,seq2)
Duel.MoveSequence(tc,seq2)
if tc:IsFaceup() then
Duel.BreakEffect()
tc:AddCounter(0x1162,1)
......
......@@ -72,7 +72,7 @@ function c101105032.disop(e,tp,eg,ep,ev,re,r,rp)
Duel.Hint(HINT_SELECTMSG,p,HINTMSG_TODECK)
local g=Duel.SelectMatchingCard(p,Card.IsAbleToDeck,p,LOCATION_HAND,0,1,63,nil)
if g:GetCount()==0 then return end
if Duel.SendtoDeck(g,nil,1,REASON_EFFECT)~=0 and tc and tc:IsRelateToBattle() and tc:IsControler(1-tp)
if Duel.SendtoDeck(g,nil,1,REASON_EFFECT)~=0 and tc and tc:IsRelateToBattle() and tc:IsControler(1-tp)
and not tc:IsStatus(STATUS_DISABLED) and not tc:IsImmuneToEffect(e) then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
......
......@@ -8,7 +8,7 @@ function c101105033.initial_effect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_MATERIAL_CHECK)
e0:SetValue(c101105033.valcheck)
c:RegisterEffect(e0)
c:RegisterEffect(e0)
--atkup
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
......@@ -51,7 +51,7 @@ function c101105033.initial_effect(c)
c:RegisterEffect(e4)
end
function c101105033.atkval(e,c)
local g=Duel.GetMatchingGroup(Card.IsType,tp,LOCATION_GRAVE,0,nil,TYPE_MONSTER)
local g=Duel.GetMatchingGroup(Card.IsType,c:GetControler(),LOCATION_GRAVE,0,nil,TYPE_MONSTER)
return g:GetClassCount(Card.GetAttribute)*300
end
function c101105033.matcon(e,tp,eg,ep,ev,re,r,rp)
......
......@@ -6,14 +6,14 @@ function c101105034.initial_effect(c)
c:EnableReviveLimit()
aux.AddFusionProcFun2(c,aux.FilterBoolFunction(Card.IsFusionSetCard,0x269),c101105034.matfilter,true)
--atk change
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(101105034,0))
e1:SetCategory(CATEGORY_ATKCHANGE)
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(101105034,0))
e1:SetCategory(CATEGORY_ATKCHANGE)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetHintTiming(0,TIMING_MAIN_END)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,101105034)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,101105034)
e1:SetCondition(c101105034.atkcon)
e1:SetTarget(c101105034.atktg)
e1:SetOperation(c101105034.atkop)
......@@ -57,7 +57,7 @@ function c101105034.atkop(e,tp,eg,ep,ev,re,r,rp)
end
end
function c101105034.thcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
local c=e:GetHandler()
return rp==1-tp and c:IsReason(REASON_EFFECT) and c:IsPreviousPosition(POS_FACEUP) and c:IsPreviousLocation(LOCATION_MZONE)
end
function c101105034.thfilter(c,e,tp,check)
......
......@@ -6,8 +6,8 @@ function c101105035.initial_effect(c)
c:EnableReviveLimit()
aux.AddFusionProcMix(c,false,true,aux.FilterBoolFunction(Card.IsFusionSetCard,0x269),c101105035.matfilter1,c101105035.matfilter2,nil)
--special summon or banish
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(101105035,0))
local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(101105035,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_REMOVE)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetProperty(EFFECT_FLAG_TARGET)
......
......@@ -10,14 +10,14 @@ function c101105037.initial_effect(c)
e0:SetType(EFFECT_TYPE_SINGLE)
e0:SetCode(EFFECT_MATERIAL_CHECK)
e0:SetValue(c101105037.valcheck)
c:RegisterEffect(e0)
c:RegisterEffect(e0)
--summon success
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_CONTINUOUS)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCondition(c101105037.limcon)
e1:SetOperation(c101105037.limop)
c:RegisterEffect(e1)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_CONTINUOUS)
e2:SetRange(LOCATION_MZONE)
......@@ -108,11 +108,11 @@ function c101105037.destg(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local g=Duel.SelectTarget(tp,c101105037.ckfilter,tp,LOCATION_GRAVE,0,1,1,nil,tp)
local tc=g:GetFirst()
local tg=Duel.GetMatchingGroup(c101105037.desfilter,tp,0,LOCATION_MZONE,nil,tc:GetAttribute())
Duel.SetOperationInfo(0,CATEGORY_DESTROY,tg,tg:GetCount(),0,0)
Duel.SetOperationInfo(0,CATEGORY_DESTROY,tg,tg:GetCount(),0,0)
end
function c101105037.desop(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then
if tc:IsRelateToEffect(e) then
local g=Duel.GetMatchingGroup(c101105037.desfilter,tp,0,LOCATION_MZONE,nil,tc:GetAttribute())
Duel.Destroy(g,REASON_EFFECT)
end
......
......@@ -18,8 +18,8 @@ function c101105045.initial_effect(c)
e1:SetTarget(c101105045.destg)
e1:SetOperation(c101105045.desop)
c:RegisterEffect(e1)
local e2=e1:Clone()
e2:SetType(EFFECT_TYPE_QUICK_O)
local e2=e1:Clone()
e2:SetType(EFFECT_TYPE_QUICK_O)
e2:SetCode(EVENT_FREE_CHAIN)
e2:SetCondition(c101105045.matcon)
c:RegisterEffect(e2)
......@@ -59,14 +59,14 @@ function c101105045.desop(e,tp,eg,ep,ev,re,r,rp)
if tc:IsRelateToEffect(e) and tc:IsFaceup() then
Duel.Destroy(tc,REASON_EFFECT)
local og=Duel.GetOperatedGroup()
local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,0,nil)
local g=Duel.GetMatchingGroup(Card.IsFaceup,tp,LOCATION_MZONE,0,nil)
if og:IsExists(c101105045.checkfilter,1,nil) and #g>0
and Duel.SelectYesNo(tp,aux.Stringid(101105045,1)) then
if tc:IsType(TYPE_XYZ) then atk=tc:GetOriginalRank() else atk=tc:GetOriginalLevel() end
Duel.Hint(HINT_SELECTMSG,tp,aux.Stringid(101105045,2))
local sg=g:Select(tp,1,1,nil)
Duel.HintSelection(sg)
local tc=sg:GetFirst()
local tc=sg:GetFirst()
if tc then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
......
......@@ -17,24 +17,24 @@ function c101105046.initial_effect(c)
e2:SetCode(EFFECT_INDESTRUCTABLE_EFFECT)
c:RegisterEffect(e2)
--special summon
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(101105046,0))
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(101105046,0))
e3:SetCategory(CATEGORY_SPECIAL_SUMMON)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetProperty(EFFECT_FLAG_CARD_TARGET)
e3:SetCode(EVENT_PHASE+PHASE_STANDBY)
e3:SetRange(LOCATION_MZONE)
e3:SetCountLimit(1,101105046)
e3:SetCountLimit(1,101105046)
e3:SetCost(c101105046.spcost)
e3:SetTarget(c101105046.sptg)
e3:SetOperation(c101105046.spop)
c:RegisterEffect(e3)
end
function c101105046.indesfilter(c)
function c101105046.indesfilter(c)
return c:IsSummonLocation(LOCATION_GRAVE) and (c:IsFacedown() or not c:IsCode(101105046))
end
function c101105046.indescon(e)
return Duel.IsExistingMatchingCard(c101105046.indesfilter,e:GetHandlerPlayer(),LOCATION_MZONE,LOCATION_MZONE,1,nil)
return Duel.IsExistingMatchingCard(c101105046.indesfilter,e:GetHandlerPlayer(),LOCATION_MZONE,LOCATION_MZONE,1,nil)
end
function c101105046.spcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
......
......@@ -37,12 +37,12 @@ function c101105047.initial_effect(c)
e3:SetTarget(c101105047.actg)
e3:SetValue(POS_FACEUP_DEFENSE)
c:RegisterEffect(e3)
local e4=e3:Clone()
e4:SetCode(EFFECT_CANNOT_TRIGGER)
e4:SetValue(aux.TRUE)
local e4=e3:Clone()
e4:SetCode(EFFECT_CANNOT_TRIGGER)
e4:SetValue(aux.TRUE)
c:RegisterEffect(e4)
end
function c101105047.thcon(e,tp,eg,ep,ev,re,r,rp)
function c101105047.thcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsSummonType(SUMMON_TYPE_LINK)
end
function c101105047.thfilter(c)
......
......@@ -38,7 +38,7 @@ function c101105054.activate(e,tp,eg,ep,ev,re,r,rp)
local check=Duel.GetLocationCount(tp,LOCATION_MZONE)>0
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_OPERATECARD)
local g=Duel.SelectMatchingCard(tp,c101105054.selfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,check)
local tc=g:GetFirst()
local tc=g:GetFirst()
if check and tc:IsCanBeSpecialSummoned(e,0,tp,false,false)
and (not tc:IsAbleToHand() or Duel.SelectOption(tp,1190,1152)==1) then
Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP_DEFENSE)
......@@ -59,7 +59,7 @@ function c101105054.activate(e,tp,eg,ep,ev,re,r,rp)
end
end
function c101105054.splimit(e,c)
return c:IsLocation(LOCATION_EXTRA) and not c:IsType(TYPE_FUSION)
return c:IsLocation(LOCATION_EXTRA) and not c:IsType(TYPE_FUSION)
end
function c101105054.repfilter(c,tp)
return c:IsFaceup() and c:IsType(TYPE_FUSION) and c:IsLocation(LOCATION_MZONE)
......
......@@ -27,7 +27,7 @@ function c101105060.initial_effect(c)
e3:SetCondition(c101105060.countercon)
e3:SetOperation(c101105060.counterop)
c:RegisterEffect(e3)
local e4=e3:Clone()
local e4=e3:Clone()
e4:SetCode(EVENT_SUMMON_SUCCESS)
c:RegisterEffect(e4)
--act limit
......
......@@ -29,7 +29,7 @@ function c101105073.target(e,tp,eg,ep,ev,re,r,rp,chk)
end
end
function c101105073.attfilter(c)
return c:IsFaceup() and c:IsType(TYPE_MONSTER)
return c:IsFaceup() and c:IsType(TYPE_MONSTER)
end
function c101105073.activate(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler()
......
......@@ -26,7 +26,7 @@ function c101105074.initial_effect(c)
c:RegisterEffect(e2)
end
function c101105074.cfilter(c)
return c:IsCode(101105011) and not c:IsPublic()
return c:IsCode(101105011) and not c:IsPublic()
end
function c101105074.cost(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
......@@ -42,7 +42,7 @@ function c101105074.cost(e,tp,eg,ep,ev,re,r,rp,chk)
end
end
function c101105074.thfilter(c)
return c:IsType(TYPE_MONSTER) and c:IsSetCard(0x267) and c:IsAbleToHand()
return c:IsType(TYPE_MONSTER) and c:IsSetCard(0x267) and c:IsAbleToHand()
end
function c101105074.target(e,tp,eg,ep,ev,re,r,rp,chk)
local g=Duel.GetMatchingGroup(c101105074.thfilter,tp,LOCATION_DECK,0,nil)
......
......@@ -24,7 +24,7 @@ function c101105206.initial_effect(c)
e2:SetOperation(c101105206.lvlop)
c:RegisterEffect(e2)
end
function c101105206.tgfilter(c,check)
function c101105206.tgfilter(c,e,tp,check)
return c:IsType(TYPE_MONSTER) and c:IsSetCard(0xa3)
and (c:IsAbleToGrave() or check and c:IsCanBeSpecialSummoned(e,0,tp,false,false))
end
......@@ -35,14 +35,14 @@ function c101105206.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local check=Duel.IsExistingMatchingCard(c101105206.cfilter,tp,LOCATION_MZONE,0,1,nil)
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
return Duel.IsExistingMatchingCard(c101105206.tgfilter,tp,LOCATION_DECK,0,1,nil,check)
return Duel.IsExistingMatchingCard(c101105206.tgfilter,tp,LOCATION_DECK,0,1,nil,e,tp,check)
end
end
function c101105206.activate(e,tp,eg,ep,ev,re,r,rp)
local check=Duel.IsExistingMatchingCard(c101105206.cfilter,tp,LOCATION_MZONE,0,1,nil)
and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_OPERATECARD)
local g=Duel.SelectMatchingCard(tp,c101105206.tgfilter,tp,LOCATION_DECK,0,1,1,nil,check)
local g=Duel.SelectMatchingCard(tp,c101105206.tgfilter,tp,LOCATION_DECK,0,1,1,nil,e,tp,check)
local tc=g:GetFirst()
if tc then
if check and tc:IsCanBeSpecialSummoned(e,0,tp,false,false)
......
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