Commit 1fdfdd9b authored by 未闻皂名's avatar 未闻皂名

2023/8/14 用临时的方法实现青眼幻影龙的效果,可能有bug

parent cf14e19b
Pipeline #23114 passed with stages
in 6 minutes and 30 seconds
...@@ -4,6 +4,54 @@ local cm=_G["c"..m] ...@@ -4,6 +4,54 @@ local cm=_G["c"..m]
cm.name="青眼究极龙" cm.name="青眼究极龙"
function cm.initial_effect(c) function cm.initial_effect(c)
RD.AddCodeList(c,list) RD.AddCodeList(c,list)
local mt=getmetatable(c)
if mt.material==nil then
mat={}
mat[120120000]=true
mt.material=mat
end
if mt.material_count==nil then
mt.material_count={3,3}
end
--Fusion Material --Fusion Material
RD.AddFusionProcedure(c,list[1],list[1],list[1]) local e1=Effect.CreateEffect(c)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_FUSION_MATERIAL)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetCondition(cm.target)
e1:SetOperation(cm.operation)
c:RegisterEffect(e1)
end
--Fusion Material
function cm.material(c,fc,sub)
return c:IsFusionCode(list[1]) or (sub and c:CheckFusionSubstitute(fc))
end
function cm.exfilter(c)
return c:IsHasEffect(120252004)
end
function cm.check(g,tp,fc,chkf,gc)
if not (chkf==PLAYER_NONE or Duel.GetLocationCountFromEx(tp,tp,g,fc)>0) then return false end
if gc and not g:IsContains(gc) then return false end
return g:GetCount()==3 or g:IsExists(cm.exfilter,1,nil)
end
function cm.target(e,g,gc,chkfnf)
if g==nil then return Auxiliary.MustMaterialCheck(nil,e:GetHandlerPlayer(),EFFECT_MUST_BE_FMATERIAL) end
local c=e:GetHandler()
local tp=c:GetControler()
local notfusion=chkfnf&0x100>0
local concat_fusion=chkfnf&0x200>0
local sub=not concat_fusion
local mg=g:Filter(Auxiliary.FConditionFilterMix,c,c,sub,concat_fusion,cm.material)
return mg:CheckSubGroup(cm.check,2,3,tp,c,chkfnf,gc)
end
function cm.operation(e,tp,eg,ep,ev,re,r,rp,gc,chkfnf)
local c=e:GetHandler()
local tp=c:GetControler()
local notfusion=chkfnf&0x100>0
local concat_fusion=chkfnf&0x200>0
local sub=not concat_fusion
local mg=eg:Filter(Auxiliary.FConditionFilterMix,c,c,sub,concat_fusion,cm.material)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_FMATERIAL)
local sg=mg:SelectSubGroup(tp,cm.check,false,2,3,tp,c,chkfnf,gc)
Duel.SetFusionMaterial(sg)
end end
\ No newline at end of file
...@@ -39,7 +39,7 @@ function cm.operation(e,tp,eg,ep,ev,re,r,rp) ...@@ -39,7 +39,7 @@ function cm.operation(e,tp,eg,ep,ev,re,r,rp)
--Extra Material --Extra Material
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(m,2)) e1:SetDescription(aux.Stringid(m,2))
e1:SetType(EFFECT_TYPE_FIELD) e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(m) e1:SetCode(m)
e1:SetProperty(EFFECT_FLAG_CLIENT_HINT) e1:SetProperty(EFFECT_FLAG_CLIENT_HINT)
e1:SetRange(LOCATION_MZONE) e1:SetRange(LOCATION_MZONE)
......
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