Commit 8d6ea06a authored by mercury233's avatar mercury233

fix

parent ce21e3ef
...@@ -38,7 +38,7 @@ end ...@@ -38,7 +38,7 @@ end
function c100266015.cost(e,tp,eg,ep,ev,re,r,rp,chk) function c100266015.cost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler() local c=e:GetHandler()
if chk==0 then return Duel.IsExistingMatchingCard(c100266015.costfilter,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil) end if chk==0 then return Duel.IsExistingMatchingCard(c100266015.costfilter,tp,LOCATION_HAND+LOCATION_DECK,0,1,nil) end
local g=Duel.SelectMatchingCard(tp,c100266015.filter,tp,LOCATION_HAND+LOCATION_DECK,0,1,1,nil) local g=Duel.SelectMatchingCard(tp,c100266015.costfilter,tp,LOCATION_HAND+LOCATION_DECK,0,1,1,nil)
Duel.SendtoGrave(g,REASON_COST) Duel.SendtoGrave(g,REASON_COST)
end end
function c100266015.target(e,tp,eg,ep,ev,re,r,rp,chk) function c100266015.target(e,tp,eg,ep,ev,re,r,rp,chk)
......
...@@ -38,16 +38,17 @@ function c100268001.rfilter(c,tp) ...@@ -38,16 +38,17 @@ function c100268001.rfilter(c,tp)
end end
function c100268001.fselect(g,tp) function c100268001.fselect(g,tp)
Duel.SetSelectedCard(g) Duel.SetSelectedCard(g)
return g:CheckWithSumGreater(Card.GetLevel,8) and aux.mzctcheckrel(g,tp) return g:CheckWithSumGreater(Card.GetLevel,8)
and Duel.GetMZoneCount(tp,g)>0 and Duel.CheckReleaseGroupEx(tp,Auxiliary.IsInGroup,#g,nil,g)
end end
function c100268001.hspcon(e,c) function c100268001.hspcon(e,c)
if c==nil then return true end if c==nil then return true end
local tp=c:GetControler() local tp=c:GetControler()
local rg=Duel.GetReleaseGroup(tp,true):Filter(c100268001.rfilter,nil,tp) local rg=Duel.GetReleaseGroup(tp,true):Filter(c100268001.rfilter,c,tp)
return rg:CheckSubGroup(c100268001.fselect,1,rg:GetCount(),tp) return rg:CheckSubGroup(c100268001.fselect,1,rg:GetCount(),tp)
end end
function c100268001.hsptg(e,tp,eg,ep,ev,re,r,rp,chk,c) function c100268001.hsptg(e,tp,eg,ep,ev,re,r,rp,chk,c)
local rg=Duel.GetReleaseGroup(tp,true):Filter(c100268001.rfilter,nil,tp) local rg=Duel.GetReleaseGroup(tp,true):Filter(c100268001.rfilter,c,tp)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_RELEASE)
local sg=rg:SelectSubGroup(tp,c100268001.fselect,true,1,rg:GetCount(),tp) local sg=rg:SelectSubGroup(tp,c100268001.fselect,true,1,rg:GetCount(),tp)
if sg then if sg then
......
...@@ -20,7 +20,7 @@ function c100311001.initial_effect(c) ...@@ -20,7 +20,7 @@ function c100311001.initial_effect(c)
e2:SetCategory(CATEGORY_ATKCHANGE) e2:SetCategory(CATEGORY_ATKCHANGE)
e2:SetType(EFFECT_TYPE_IGNITION) e2:SetType(EFFECT_TYPE_IGNITION)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,100311001+100) e2:SetCountLimit(1,100311001+100)
e2:SetTarget(c100311001.distg) e2:SetTarget(c100311001.distg)
e2:SetOperation(c100311001.disop) e2:SetOperation(c100311001.disop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
...@@ -28,7 +28,8 @@ function c100311001.initial_effect(c) ...@@ -28,7 +28,8 @@ function c100311001.initial_effect(c)
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e3:SetCode(EVENT_BATTLE_DESTROYED) e3:SetCode(EVENT_BATTLE_DESTROYED)
e1:SetCountLimit(1,100311001+200) e3:SetCountLimit(1,100311001+200)
e3:SetRange(LOCATION_MZONE)
e3:SetCondition(c100311001.eqcon) e3:SetCondition(c100311001.eqcon)
e3:SetTarget(c100311001.eqtg) e3:SetTarget(c100311001.eqtg)
e3:SetOperation(c100311001.eqop) e3:SetOperation(c100311001.eqop)
...@@ -69,17 +70,20 @@ function c100311001.disop(e,tp,eg,ep,ev,re,r,rp) ...@@ -69,17 +70,20 @@ function c100311001.disop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE) e1:SetCode(EFFECT_DISABLE)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1) tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT) e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e2:SetReset(RESET_EVENT+RESETS_STANDARD) e2:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e2) tc:RegisterEffect(e2)
if tc:IsType(TYPE_TRAPMONSTER) then if tc:IsType(TYPE_TRAPMONSTER) then
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE) e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_DISABLE_TRAPMONSTER) e3:SetCode(EFFECT_DISABLE_TRAPMONSTER)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e3:SetReset(RESET_EVENT+RESETS_STANDARD) e3:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e3) tc:RegisterEffect(e3)
end end
...@@ -88,6 +92,7 @@ function c100311001.disop(e,tp,eg,ep,ev,re,r,rp) ...@@ -88,6 +92,7 @@ function c100311001.disop(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK) e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e1:SetValue(-ct*1000) e1:SetValue(-ct*1000)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1) tc:RegisterEffect(e1)
...@@ -95,7 +100,7 @@ function c100311001.disop(e,tp,eg,ep,ev,re,r,rp) ...@@ -95,7 +100,7 @@ function c100311001.disop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c100311001.cfilter(c,tp) function c100311001.cfilter(c,tp)
return c:IsReason(REASON_BATTLE) and c:IsLocation(LOCATION_GRAVE) and c:GetPreviousControler()~=tp return c:IsReason(REASON_BATTLE) and c:IsLocation(LOCATION_GRAVE) and c:GetPreviousControler()==1-tp and c:IsType(TYPE_MONSTER)
end end
function c100311001.eqcon(e,tp,eg,ep,ev,re,r,rp) function c100311001.eqcon(e,tp,eg,ep,ev,re,r,rp)
return eg:IsExists(c100311001.cfilter,1,nil,tp) return eg:IsExists(c100311001.cfilter,1,nil,tp)
...@@ -105,37 +110,32 @@ function c100311001.filter(c,e,tp) ...@@ -105,37 +110,32 @@ function c100311001.filter(c,e,tp)
and c:IsLocation(LOCATION_GRAVE) and c:IsReason(REASON_BATTLE) and not c:IsForbidden() and c:IsLocation(LOCATION_GRAVE) and c:IsReason(REASON_BATTLE) and not c:IsForbidden()
end end
function c100311001.eqtg(e,tp,eg,ep,ev,re,r,rp,chk) function c100311001.eqtg(e,tp,eg,ep,ev,re,r,rp,chk)
local ct=Duel.GetLocationCount(tp,LOCATION_SZONE) if chk==0 then return Duel.GetLocationCount(tp,LOCATION_SZONE)>0
if chk==0 then return ct>0
and eg:IsExists(c100311001.filter,1,nil,e,tp) end and eg:IsExists(c100311001.filter,1,nil,e,tp) end
local g=eg:Filter(c100311001.filter,nil,e,tp) local g=eg:Filter(c100311001.filter,nil,e,tp)
local tc=nil local tg=nil
if g:GetCount()>1 then if g:GetCount()>1 then
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET) Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_TARGET)
tc=g:Select(tp,1,ct,nil) tg=g:Select(tp,1,1,nil)
else else
tc=g tg=g
end end
e:SetLabelObject(tc) Duel.SetTargetCard(tg)
tc:ForEach(Card.CreateEffectRelation,e) Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,tg,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_LEAVE_GRAVE,tc,#tc,0,0)
end end
function c100311001.eqop(e,tp,eg,ep,ev,re,r,rp) function c100311001.eqop(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler() local c=e:GetHandler()
local g=e:GetLabelObject() local tc=Duel.GetFirstTarget()
g=g:Filter(Card.IsRelateToEffect,nil,e) if c:IsFaceup() and tc:IsRelateToEffect(e) then
if c:IsFaceup() then if Duel.Equip(tp,tc,c,true,true) then
for tc in aux.Next(g) do local e1=Effect.CreateEffect(c)
if Duel.Equip(tp,tc,c,true,true) then e1:SetType(EFFECT_TYPE_SINGLE)
local e1=Effect.CreateEffect(c) e1:SetCode(EFFECT_EQUIP_LIMIT)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
e1:SetCode(EFFECT_EQUIP_LIMIT) e1:SetValue(c100311001.eqlimit)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) tc:RegisterEffect(e1)
e1:SetValue(c100311001.eqlimit)
tc:RegisterEffect(e1)
end
Duel.EquipComplete()
end end
Duel.EquipComplete()
end end
end end
function c100311001.eqlimit(e,c) function c100311001.eqlimit(e,c)
......
...@@ -8,7 +8,7 @@ function c101102005.initial_effect(c) ...@@ -8,7 +8,7 @@ function c101102005.initial_effect(c)
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_IGNITION) e1:SetType(EFFECT_TYPE_IGNITION)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
e1:SetCountLimit(1,c101102005) e1:SetCountLimit(1,101102005)
e1:SetCondition(c101102005.spcon) e1:SetCondition(c101102005.spcon)
e1:SetTarget(c101102005.sptg) e1:SetTarget(c101102005.sptg)
e1:SetOperation(c101102005.spop) e1:SetOperation(c101102005.spop)
......
...@@ -5,7 +5,7 @@ function c101102019.initial_effect(c) ...@@ -5,7 +5,7 @@ function c101102019.initial_effect(c)
--spsummon --spsummon
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(101102019,0)) e1:SetDescription(aux.Stringid(101102019,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_DRAW) e1:SetCategory(CATEGORY_SPECIAL_SUMMON)
e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY) e1:SetProperty(EFFECT_FLAG_DELAY)
e1:SetCode(EVENT_SUMMON_SUCCESS) e1:SetCode(EVENT_SUMMON_SUCCESS)
...@@ -46,7 +46,7 @@ function c101102019.spop(e,tp,eg,ep,ev,re,r,rp) ...@@ -46,7 +46,7 @@ function c101102019.spop(e,tp,eg,ep,ev,re,r,rp)
end end
end end
function c101102019.negfilter(c) function c101102019.negfilter(c)
return c:IsFaceup() and not c:IsDisabled() and not c:IsSetCard(0xb2) return aux.disfilter1(c) and not c:IsSetCard(0xb2)
end end
function c101102019.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) function c101102019.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
if chkc then return chkc:IsOnField() end if chkc then return chkc:IsOnField() end
...@@ -92,18 +92,18 @@ function c101102019.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -92,18 +92,18 @@ function c101102019.operation(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE) e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
nc:RegisterEffect(e1) nc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT) e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+RESETS_STANDARD) e2:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
nc:RegisterEffect(e2) nc:RegisterEffect(e2)
if nc:IsType(TYPE_TRAPMONSTER) then if nc:IsType(TYPE_TRAPMONSTER) then
local e3=Effect.CreateEffect(c) local e3=Effect.CreateEffect(c)
e3:SetType(EFFECT_TYPE_SINGLE) e3:SetType(EFFECT_TYPE_SINGLE)
e3:SetCode(EFFECT_DISABLE_TRAPMONSTER) e3:SetCode(EFFECT_DISABLE_TRAPMONSTER)
e3:SetReset(RESET_EVENT+RESETS_STANDARD) e3:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_PHASE+PHASE_END)
nc:RegisterEffect(e3) nc:RegisterEffect(e3)
end end
nc=b2:GetNext() nc=b2:GetNext()
......
...@@ -12,6 +12,7 @@ function c101102032.initial_effect(c) ...@@ -12,6 +12,7 @@ function c101102032.initial_effect(c)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET) e1:SetProperty(EFFECT_FLAG_DELAY+EFFECT_FLAG_CARD_TARGET)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetCountLimit(1,101102032)
e1:SetTarget(c101102032.target) e1:SetTarget(c101102032.target)
e1:SetOperation(c101102032.operation) e1:SetOperation(c101102032.operation)
c:RegisterEffect(e1) c:RegisterEffect(e1)
......
...@@ -22,6 +22,7 @@ function c101102033.initial_effect(c) ...@@ -22,6 +22,7 @@ function c101102033.initial_effect(c)
e2:SetCode(EVENT_FREE_CHAIN) e2:SetCode(EVENT_FREE_CHAIN)
e2:SetRange(LOCATION_MZONE) e2:SetRange(LOCATION_MZONE)
e2:SetProperty(EFFECT_FLAG_CARD_TARGET) e2:SetProperty(EFFECT_FLAG_CARD_TARGET)
e2:SetHintTiming(0,TIMING_MAIN_END)
e2:SetCountLimit(1,101102033) e2:SetCountLimit(1,101102033)
e2:SetCondition(c101102033.discon) e2:SetCondition(c101102033.discon)
e2:SetTarget(c101102033.distg) e2:SetTarget(c101102033.distg)
...@@ -30,7 +31,7 @@ function c101102033.initial_effect(c) ...@@ -30,7 +31,7 @@ function c101102033.initial_effect(c)
end end
function c101102033.repfilter(c,tp) function c101102033.repfilter(c,tp)
return c:IsSetCard(0x24d) and c:IsType(TYPE_FUSION) and c:IsControler(tp) and c:IsLocation(LOCATION_ONFIELD) return c:IsSetCard(0x24d) and c:IsType(TYPE_FUSION) and c:IsControler(tp) and c:IsLocation(LOCATION_ONFIELD)
and c:IsReason(REASON_BATTLE+REASON_EFFECT) and not c:IsReason(REASON_REPLACE) and c:IsReason(REASON_EFFECT) and not c:IsReason(REASON_REPLACE)
end end
function c101102033.desfilter(c,e,tp) function c101102033.desfilter(c,e,tp)
return c:IsFaceup() and c:IsControler(tp) and c:IsLocation(LOCATION_MZONE) and c:IsSetCard(0x24d) return c:IsFaceup() and c:IsControler(tp) and c:IsLocation(LOCATION_MZONE) and c:IsSetCard(0x24d)
...@@ -62,7 +63,8 @@ function c101102033.fmfilter(c) ...@@ -62,7 +63,8 @@ function c101102033.fmfilter(c)
return c:IsType(TYPE_FUSION) and c:IsSetCard(0x24d) and c:IsFaceup() and mg and mg:IsExists(Card.IsType,1,nil,TYPE_EFFECT) return c:IsType(TYPE_FUSION) and c:IsSetCard(0x24d) and c:IsFaceup() and mg and mg:IsExists(Card.IsType,1,nil,TYPE_EFFECT)
end end
function c101102033.discon(e,tp,eg,ep,ev,re,r,rp) function c101102033.discon(e,tp,eg,ep,ev,re,r,rp)
return Duel.IsExistingMatchingCard(c101102033.fmfilter,tp,LOCATION_MZONE,0,1,nil) return (Duel.GetCurrentPhase()==PHASE_MAIN1 or Duel.GetCurrentPhase()==PHASE_MAIN2)
and Duel.IsExistingMatchingCard(c101102033.fmfilter,tp,LOCATION_MZONE,0,1,nil)
end end
function c101102033.disfilter(c) function c101102033.disfilter(c)
return aux.disfilter1(c) and c:GetSummonLocation()==LOCATION_EXTRA return aux.disfilter1(c) and c:GetSummonLocation()==LOCATION_EXTRA
......
...@@ -53,20 +53,21 @@ function c101102041.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -53,20 +53,21 @@ function c101102041.operation(e,tp,eg,ep,ev,re,r,rp)
e1:SetValue(atk) e1:SetValue(atk)
c:RegisterEffect(e1) c:RegisterEffect(e1)
local mg=c:GetOverlayGroup() local mg=c:GetOverlayGroup()
if not mg:IsExists(c101102041.mgfilter,1,nil) then return end if mg:IsExists(c101102041.mgfilter,1,nil) then
local exc=aux.ExceptThisCard(e) local exc=aux.ExceptThisCard(e)
local g=Duel.GetMatchingGroup(c101102041.tgfilter,tp,LOCATION_MZONE,LOCATION_MZONE,exc) local g=Duel.GetMatchingGroup(c101102041.tgfilter,tp,LOCATION_MZONE,LOCATION_MZONE,exc)
for tc in aux.Next(g) do for tc in aux.Next(g) do
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_DISABLE) e1:SetCode(EFFECT_DISABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1) tc:RegisterEffect(e1)
local e2=Effect.CreateEffect(c) local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE) e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_DISABLE_EFFECT) e2:SetCode(EFFECT_DISABLE_EFFECT)
e2:SetReset(RESET_EVENT+RESETS_STANDARD) e2:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e2) tc:RegisterEffect(e2)
end
end end
local e0=Effect.CreateEffect(c) local e0=Effect.CreateEffect(c)
e0:SetType(EFFECT_TYPE_FIELD) e0:SetType(EFFECT_TYPE_FIELD)
......
...@@ -8,6 +8,7 @@ function c101102061.initial_effect(c) ...@@ -8,6 +8,7 @@ function c101102061.initial_effect(c)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCountLimit(1,101102061+EFFECT_COUNT_CODE_OATH) e1:SetCountLimit(1,101102061+EFFECT_COUNT_CODE_OATH)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetTarget(c101102061.target)
e1:SetOperation(c101102061.activate) e1:SetOperation(c101102061.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
--extra summon --extra summon
...@@ -20,6 +21,10 @@ function c101102061.initial_effect(c) ...@@ -20,6 +21,10 @@ function c101102061.initial_effect(c)
e2:SetOperation(c101102061.exop) e2:SetOperation(c101102061.exop)
c:RegisterEffect(e2) c:RegisterEffect(e2)
end end
function c101102061.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_DECK+LOCATION_GRAVE)
end
function c101102061.thfilter(c) function c101102061.thfilter(c)
if not c:IsAbleToHand() then return false end if not c:IsAbleToHand() then return false end
return c:IsLocation(LOCATION_DECK) and (c:IsSetCard(0xb2) or c:IsSetCard(0x107)) and c:IsType(TYPE_MONSTER) return c:IsLocation(LOCATION_DECK) and (c:IsSetCard(0xb2) or c:IsSetCard(0x107)) and c:IsType(TYPE_MONSTER)
......
...@@ -24,14 +24,14 @@ function c101102073.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc) ...@@ -24,14 +24,14 @@ function c101102073.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local g=Duel.SelectTarget(tp,c101102073.filter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp) local g=Duel.SelectTarget(tp,c101102073.filter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,g,1,0,0)
local tc=g:GetFirst() local tc=g:GetFirst()
if tc:GetOriginalLevel()==4 then if tc:GetOriginalLevel()<=4 then
Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,1,0,0) Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,1,0,0)
end end
end end
function c101102073.activate(e,tp,eg,ep,ev,re,r,rp) function c101102073.activate(e,tp,eg,ep,ev,re,r,rp)
local tc=Duel.GetFirstTarget() local tc=Duel.GetFirstTarget()
if tc:IsRelateToEffect(e) then if tc:IsRelateToEffect(e) then
if Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)~=0 and tc:GetOriginalLevel()==4 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0 if Duel.SpecialSummon(tc,0,tp,tp,false,false,POS_FACEUP)~=0 and tc:GetOriginalLevel()<=4 and Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,101102173,0x24d,0x4011,0,0,2,RACE_WARRIOR,ATTRIBUTE_LIGHT) and Duel.SelectYesNo(tp,aux.Stringid(101102073,0)) then and Duel.IsPlayerCanSpecialSummonMonster(tp,101102173,0x24d,0x4011,0,0,2,RACE_WARRIOR,ATTRIBUTE_LIGHT) and Duel.SelectYesNo(tp,aux.Stringid(101102073,0)) then
Duel.BreakEffect() Duel.BreakEffect()
local token=Duel.CreateToken(tp,101102173) local token=Duel.CreateToken(tp,101102173)
......
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