Commit 04c752fa authored by Tachibana's avatar Tachibana

得得得得得

parent 4703fbbc
Pipeline #13387 passed with stages
in 25 minutes and 16 seconds
No preview for this file type
......@@ -53,8 +53,8 @@ function cm.ltg(...)
aux.GetLinkMaterials=f
return res
end
function cm.GetLinkMaterials(tp,f,lc)
local mg=Duel.GetMatchingGroup(Auxiliary.LConditionFilter,tp,LOCATION_MZONE,0,nil,f,lc)
function cm.GetLinkMaterials(tp,f,lc,e)
local mg=Duel.GetMatchingGroup(Auxiliary.LConditionFilter,tp,LOCATION_MZONE,0,nil,f,lc,e)
local mg2=Duel.GetMatchingGroup(Auxiliary.LExtraFilter,tp,LOCATION_HAND+LOCATION_SZONE,LOCATION_ONFIELD,nil,f,lc,tp)
local mg3=Duel.GetMatchingGroup(cm.mfilter,tp,LOCATION_SZONE,0,nil)
if mg2:GetCount()>0 then mg:Merge(mg2) end
......@@ -110,20 +110,18 @@ end
function cm.hkop(e,tp,eg,ep,ev,re,r,rp)
local typ=e:GetLabel()
local c=e:GetHandler()
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_FIELD)
e1:SetCode(EFFECT_CANNOT_SPECIAL_SUMMON)
e1:SetProperty(EFFECT_FLAG_PLAYER_TARGET)
e1:SetTargetRange(1,0)
e1:SetTarget(function(e,c)return not c:IsLocation(LOCATION_GRAVE)end)
e1:SetReset(RESET_PHASE+PHASE_END)
Duel.RegisterEffect(e1,tp)
local tc=Duel.GetFirstTarget()
local zone=c:GetLinkedZone(tp)
if c:IsFacedown() or Duel.GetLocationCount(tp,LOCATION_MZONE,tp,LOCATION_REASON_TOFIELD,zone)<=0 then return end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SPSUMMON)
local g=Duel.SelectMatchingCard(tp,cm.spopfilter,tp,LOCATION_GRAVE,0,1,1,nil,e,tp,typ,zone)
if #g>0 and Duel.SpecialSummonStep(g:GetFirst(),0,tp,tp,false,false,POS_FACEUP,zone) then
local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_CANNOT_BE_LINK_MATERIAL)
e1:SetValue(1)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
g:GetFirst():RegisterEffect(e1,true)
local fid=c:GetFieldID()
g:GetFirst():RegisterFlagEffect(m,RESET_EVENT+RESETS_STANDARD,0,1,fid)
local e2=Effect.CreateEffect(c)
......
......@@ -37,6 +37,10 @@ function cm.initial_effect(c)
e1:SetLabelObject(ex)
e2:SetLabelObject(ex)
end
function cm.matval(e,lc,mg,c,tp)
if e:GetHandler()~=lc then return false,nil end
return true,true
end
function cm.valcheck(e,c)
e:SetLabel(0)
if c:GetMaterial():IsExists(Card.IsLinkType,1,nil,TYPE_FUSION) then e:SetLabel(1) end
......@@ -55,8 +59,8 @@ function cm.ltg(...)
aux.GetLinkMaterials=f
return res
end
function cm.GetLinkMaterials(tp,f,lc)
local mg=Duel.GetMatchingGroup(Auxiliary.LConditionFilter,tp,LOCATION_MZONE,0,nil,f,lc)
function cm.GetLinkMaterials(tp,f,lc,e)
local mg=Duel.GetMatchingGroup(Auxiliary.LConditionFilter,tp,LOCATION_MZONE,0,nil,f,lc,e)
local mg2=Duel.GetMatchingGroup(Auxiliary.LExtraFilter,tp,LOCATION_HAND+LOCATION_SZONE,LOCATION_ONFIELD,nil,f,lc,tp)
local mg3=Duel.GetMatchingGroup(function(c)return aux.IsCodeListed(c,53727003) and c:IsFacedown()end,tp,LOCATION_ONFIELD,0,nil)
if mg2:GetCount()>0 then mg:Merge(mg2) 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