Commit c68f6d64 authored by Amiya's avatar Amiya

Merge branch 'master' of git.moenext.com:mycard/pre-release-database-cdb

parents bb2e873a 2d96a6fd
Pipeline #41668 passed with stages
in 3 minutes and 25 seconds
......@@ -31,7 +31,7 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp)
local ft=Duel.GetLocationCount(tp,LOCATION_MZONE)
local ct=Duel.GetMatchingGroupCount(s.eqfilter,tp,LOCATION_GRAVE,0,nil)
if ft>ct then ft=ct end
if ft<=0 then return end
if ft>0 then
if Duel.IsPlayerAffectedByEffect(tp,59822133) then ft=1 end
if not Duel.IsPlayerCanSpecialSummonMonster(tp,id+o,0,TYPES_TOKEN_MONSTER,500,500,1,RACE_WARRIOR,ATTRIBUTE_EARTH) then return end
local ctn=true
......@@ -61,6 +61,7 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp)
end
end
end
end
local e1=Effect.CreateEffect(e:GetHandler())
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
......
--ミラーバリア
local s,id,o=GetID()
function s.initial_effect(c)
aux.AddCodeList(c,100255002)
--Activate
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_EQUIP)
......@@ -69,7 +70,8 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp)
e1:SetCategory(CATEGORY_ATKCHANGE)
e1:SetType(EFFECT_TYPE_QUICK_O)
e1:SetRange(LOCATION_SZONE)
e1:SetCode(EVENT_PRE_DAMAGE_CALCULATE)
e1:SetCode(EVENT_FREE_CHAIN)
e1:SetCondition(s.atkcon)
e1:SetCost(s.atkcost)
e1:SetOperation(s.atkop)
c:RegisterEffect(e1)
......@@ -79,12 +81,18 @@ function s.operation(e,tp,eg,ep,ev,re,r,rp)
e3:SetCode(EFFECT_EQUIP_LIMIT)
e3:SetProperty(EFFECT_FLAG_CANNOT_DISABLE)
e3:SetValue(1)
e3:SetValue(s.eqlimit)
e3:SetReset(RESET_EVENT+RESETS_STANDARD)
c:RegisterEffect(e3)
else
c:CancelToGrave(false)
end
end
function s.atkcon(e,tp,eg,ep,ev,re,r,rp)
local c=e:GetHandler():GetEquipTarget()
local bc=c:GetBattleTarget()
return bc
end
function s.atkcost(e,tp,eg,ep,ev,re,r,rp,chk)
local c=e:GetHandler()
if chk==0 then return c:GetFlagEffect(id)==0 end
......@@ -97,6 +105,9 @@ function s.atkop(e,tp,eg,ep,ev,re,r,rp)
Duel.Destroy(bc,REASON_EFFECT)
end
end
function s.eqlimit(e,c)
return e:GetHandler():GetEquipTarget()==c or c:IsControler(e:GetHandlerPlayer())
end
function s.filter(c)
return c:IsCode(100255002) and c:IsAbleToHand()
end
......
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