Commit d59c68c1 authored by mercury233's avatar mercury233

fix

parent 98916bc3
......@@ -41,7 +41,7 @@ function c100233001.initial_effect(c)
e5:SetOperation(c100233001.spop)
c:RegisterEffect(e5)
end
function c100233001.rmcond(e)
function c100233001.rmcond(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetSummonLocation()&LOCATION_EXTRA==LOCATION_EXTRA
end
function c100233001.rmtg(e,tp,eg,ep,ev,re,r,rp,chk)
......
......@@ -19,11 +19,11 @@ function c100234001.initial_effect(c)
c:RegisterEffect(e2)
end
function c100234001.atktg(e,c)
return (e:GetHandler():GetLinkedGroup():IsContains(c) or c==e:GetHandler()) and c:IsSetCard(0x8) and c:IsFaceup()
return (c==e:GetHandler() or (e:GetHandler():GetLinkedGroup():IsContains(c) and c:IsSetCard(0x8) and c:IsFaceup()))
end
function c100234001.atkfilter(c)
return c:IsSetCard(0x8) and c:IsType(TYPE_MONSTER)
end
function c100234001.atkval(e,c)
return Duel.GetMatchingGroup(c100234001.atkfilter,e:GetHandlerPlayer(),LOCATION_GRAVE,0,nil):GetClassCount(Card.GetCode)*100
end
\ No newline at end of file
end
......@@ -100,7 +100,7 @@ function c100234002.spop(e,tp,eg,ep,ev,re,r,rp)
e2:SetTargetRange(1,0)
Duel.RegisterEffect(e2,tp)
local e3=e2:Clone()
e3:SetCode(EFFECT_CANNOT_SET)
e3:SetCode(EFFECT_CANNOT_MSET)
Duel.RegisterEffect(e3,tp)
end
function c100234002.splimit(e,c)
......
......@@ -31,13 +31,13 @@ function c101007011.tkcon(e,tp,eg,ep,ev,re,r,rp)
end
function c101007011.tktg(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsPlayerCanSpecialSummonMonster(tp,101007111,0x27,0x4011,0,0,1,RACE_MACHINE,ATTRIBUTE_EARTH) end
and Duel.IsPlayerCanSpecialSummonMonster(tp,101007111,0x27,0x4011,0,0,1,RACE_MACHINE,ATTRIBUTE_EARTH,POS_FACEUP_ATTACK) end
Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
end
function c101007011.tkop(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
if not Duel.IsPlayerCanSpecialSummonMonster(tp,101007111,0x27,0x4011,0,0,1,RACE_MACHINE,ATTRIBUTE_EARTH) then return end
if not Duel.IsPlayerCanSpecialSummonMonster(tp,101007111,0x27,0x4011,0,0,1,RACE_MACHINE,ATTRIBUTE_EARTH,POS_FACEUP_ATTACK) then return end
local token=Duel.CreateToken(tp,101007111)
Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP)
Duel.SpecialSummon(token,0,tp,tp,false,false,POS_FACEUP_ATTACK)
end
......@@ -21,7 +21,6 @@ function c101007023.initial_effect(c)
e2:SetCode(EVENT_SPSUMMON_SUCCESS)
e2:SetProperty(EFFECT_FLAG_DELAY)
e2:SetCountLimit(1,101007023+100)
e2:SetCost(c101007023.spcost2)
e2:SetTarget(c101007023.sptg2)
e2:SetOperation(c101007023.spop2)
c:RegisterEffect(e2)
......@@ -35,10 +34,6 @@ function c101007023.initial_effect(c)
e3:SetTarget(c101007023.rettg)
e3:SetOperation(c101007023.retop)
c:RegisterEffect(e3)
Duel.AddCustomActivityCounter(101007023,ACTIVITY_SPSUMMON,c101007023.counterfilter)
end
function c101007023.counterfilter(c)
return c:IsSetCard(0x71)
end
function c101007023.spcon1(e,tp,eg,ep,ev,re,r,rp)
return not Duel.IsExistingMatchingCard(Card.IsType,tp,LOCATION_GRAVE,0,1,nil,TYPE_MONSTER)
......@@ -54,32 +49,18 @@ function c101007023.spop1(e,tp,eg,ep,ev,re,r,rp)
Duel.SpecialSummon(c,0,tp,tp,false,false,POS_FACEUP)
end
end
function c101007023.spcost2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetCustomActivityCount(101007023,tp,ACTIVITY_SPSUMMON)==0 end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetReset(RESET_PHASE+PHASE_END)
e1:SetTargetRange(1,0)
e1:SetTarget(c101007023.splimit)
Duel.RegisterEffect(e1,tp)
end
function c101007023.splimit(e,c,sump,sumtype,sumpos,targetp,se)
return not c:IsSetCard(0x71)
end
function c101007023.spfilter2(c,e,tp)
return c:IsSetCard(0x71) and not c:IsCode(101007023) and c:IsCanBeSpecialSummoned(e,0,tp,false,false,POS_FACEUP)
end
function c101007023.sptg2(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then return Duel.GetLocationCount(tp,LOCATION_MZONE)>0
and Duel.IsExistingMatchingCard(c101007023.spfilter2,tp,LOCATION_DECK,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK)
and Duel.IsExistingMatchingCard(c101007023.spfilter2,tp,LOCATION_DECK+LOCATION_HAND,0,1,nil,e,tp) end
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,tp,LOCATION_DECK+LOCATION_HAND)
end
function c101007023.spop2(e,tp,eg,ep,ev,re,r,rp)
if Duel.GetLocationCount(tp,LOCATION_MZONE)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,c101007023.spfilter2,tp,LOCATION_DECK,0,1,1,nil,e,tp)
local g=Duel.SelectMatchingCard(tp,c101007023.spfilter2,tp,LOCATION_DECK+LOCATION_HAND,0,1,1,nil,e,tp)
if g:GetCount()>0 and Duel.SpecialSummon(g,0,tp,tp,false,false,POS_FACEUP)>0 then
local tc=g:GetFirst()
local e1=Effect.CreateEffect(e:GetHandler())
......@@ -89,6 +70,17 @@ function c101007023.spop2(e,tp,eg,ep,ev,re,r,rp)
e1:SetValue(-1)
tc:RegisterEffect(e1)
end
local e2=Effect.CreateEffect(e:GetHandler())
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e2:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e2:SetReset(RESET_PHASE+PHASE_END)
e2:SetTargetRange(1,0)
e2:SetTarget(c101007023.splimit)
Duel.RegisterEffect(e2,tp)
end
function c101007023.splimit(e,c,sump,sumtype,sumpos,targetp,se)
return not c:IsSetCard(0x71)
end
function c101007023.retcon(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():IsReason(REASON_DESTROY) and e:GetHandler():GetReasonPlayer()==1-tp
......
......@@ -26,7 +26,7 @@ function c101007033.initial_effect(c)
--recycle
local e3=Effect.CreateEffect(c)
e3:SetDescription(aux.Stringid(101007033,1))
e3:SetCategory(CATEGORY_TOHAND+CATEGORY_LEAVE_GRAVE)
e3:SetCategory(CATEGORY_TOHAND)
e3:SetType(EFFECT_TYPE_FIELD+EFFECT_TYPE_TRIGGER_F)
e3:SetCode(EVENT_PHASE+PHASE_END)
e3:SetRange(LOCATION_MZONE)
......@@ -37,7 +37,6 @@ function c101007033.initial_effect(c)
e3:SetOperation(c101007033.operation)
c:RegisterEffect(e3)
end
c101007033.material_setcode={0xfb}
function c101007033.matfilter(c)
return c:IsFusionType(TYPE_LINK) and c:IsFusionSetCard(0xfb)
end
......@@ -73,15 +72,7 @@ function c101007033.condition(e,tp,eg,ep,ev,re,r,rp)
return e:GetHandler():GetAttackedCount()>0
end
function c101007033.target(e,tp,eg,ep,ev,re,r,rp,chk)
if chk==0 then
local effs={e:GetHandler():IsHasEffect(EFFECT_UPDATE_ATTACK)}
for _,eff in ipairs(effs) do
if eff:GetLabelObject()==e:GetLabelObject() then
return true
end
end
return false
end
if chk==0 then return true end
Duel.SetOperationInfo(0,CATEGORY_TOHAND,nil,1,tp,LOCATION_GRAVE)
end
function c101007033.operation(e,tp,eg,ep,ev,re,r,rp)
......
......@@ -52,8 +52,8 @@ function c101007034.atkop1(e,tp,eg,ep,ev,re,r,rp)
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_UPDATE_ATTACK)
e1:SetValue(math.ceil(atk))
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE)
e1:SetValue(math.ceil(atk/2))
e1:SetReset(RESET_EVENT+RESETS_STANDARD+RESET_DISABLE+RESET_PHASE+PHASE_END)
c:RegisterEffect(e1)
end
function c101007034.atkcon2(e,tp,eg,ep,ev,re,r,rp)
......
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