Commit 61371f07 authored by nanahira's avatar nanahira

Auto Push by Nanahira

parent e40a7117
...@@ -5,10 +5,11 @@ xpcall(function() require("expansions/script/c37564765") end,function() require( ...@@ -5,10 +5,11 @@ xpcall(function() require("expansions/script/c37564765") end,function() require(
function cm.initial_effect(c) function cm.initial_effect(c)
local ct=Senya.master_rule_3_flag and 3 or 2 local ct=Senya.master_rule_3_flag and 3 or 2
Senya.AddXyzProcedureRank(c,nil,nil,ct,ct) Senya.AddXyzProcedureRank(c,nil,nil,ct,ct)
Senya.AddSummonMusic(c,aux.Stringid(m,4),SUMMON_TYPE_XYZ)
Senya.MokouReborn(c,7,m,false,cm.dogcon) Senya.MokouReborn(c,7,m,false,cm.dogcon)
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_ATKCHANGE) e1:SetCategory(CATEGORY_ATKCHANGE)
e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F) e1:SetType(EFFECT_TYPE_SINGLE+EFFECT_TYPE_TRIGGER_F)
e1:SetCode(EVENT_SPSUMMON_SUCCESS) e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetProperty(0x14000) e1:SetProperty(0x14000)
e1:SetTarget(cm.atktg) e1:SetTarget(cm.atktg)
......
--超盖亚黑魔术师
local m=37564341
local cm=_G["c"..m]
xpcall(function() require("expansions/script/c37564765") end,function() require("script/c37564765") end)
function cm.initial_effect(c)
c:EnableReviveLimit()
--cannot special summon
local e1=Effect.CreateEffect(c)
e1:SetProperty(EFFECT_FLAG_CANNOT_DISABLE+EFFECT_FLAG_UNCOPYABLE)
e1:SetType(EFFECT_TYPE_SINGLE)
e1:SetCode(EFFECT_SPSUMMON_CONDITION)
c:RegisterEffect(e1)
--special summon
local e2=Effect.CreateEffect(c)
e2:SetDescription(aux.Stringid(m,0))
e2:SetType(EFFECT_TYPE_FIELD)
e2:SetCode(EFFECT_SPSUMMON_PROC)
e2:SetProperty(EFFECT_FLAG_UNCOPYABLE)
e2:SetRange(LOCATION_HAND | LOCATION_GRAVE)
e2:SetCondition(cm.spcon)
e2:SetOperation(cm.spop)
c:RegisterEffect(e2)
local e1=Effect.CreateEffect(c)
e1:SetCategory(CATEGORY_DESTROY)
e1:SetType(EFFECT_TYPE_SINGLE | EFFECT_TYPE_TRIGGER_O)
e1:SetProperty(EFFECT_FLAG_CARD_TARGET | 0x14000)
e1:SetCode(EVENT_SPSUMMON_SUCCESS)
e1:SetTarget(cm.target)
e1:SetOperation(cm.activate)
c:RegisterEffect(e1)
local e2=Effect.CreateEffect(c)
e2:SetType(EFFECT_TYPE_SINGLE)
e2:SetCode(EFFECT_IMMUNE_EFFECT)
e2:SetProperty(EFFECT_FLAG_SINGLE_RANGE)
e2:SetRange(LOCATION_MZONE)
e2:SetValue(cm.efilter)
c:RegisterEffect(e2)
end
function cm.spfilter(c)
return c:IsAbleToRemoveAsCost()
end
function cm.spcon(e,c)
if c==nil then return true end
local tp=c:GetControler()
return Duel.GetMZoneCount(tp)>0
and Duel.IsExistingMatchingCard(cm.spfilter,tp,LOCATION_HAND,0,3,nil)
end
function cm.spop(e,tp,eg,ep,ev,re,r,rp,c)
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_REMOVE)
local g1=Duel.SelectMatchingCard(tp,cm.spfilter,tp,LOCATION_HAND,0,3,3,nil)
Duel.Remove(g1,POS_FACEUP,REASON_COST)
end
function cm.filter(c)
return true
end
function cm.target(e,tp,eg,ep,ev,re,r,rp,chk,chkc)
local maxc=Duel.GetMatchingGroup(Card.IsType,tp,LOCATION_GRAVE,0,nil,TYPE_MONSTER):GetClassCount(Card.GetCode)
if chkc then return chkc:IsOnField() and cm.filter(chkc) and chkc~=e:GetHandler() end
if chk==0 then return maxc>0 and Duel.IsExistingTarget(cm.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,e:GetHandler()) end
Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_DESTROY)
local g=Duel.SelectTarget(tp,cm.filter,tp,LOCATION_ONFIELD,LOCATION_ONFIELD,1,maxc,e:GetHandler())
Duel.SetOperationInfo(0,CATEGORY_DESTROY,g,g:GetCount(),0,0)
end
function cm.activate(e,tp,eg,ep,ev,re,r,rp)
local g=Duel.GetChainInfo(0,CHAININFO_TARGET_CARDS):Filter(Card.IsRelateToEffect,nil,e)
Duel.Destroy(g,REASON_EFFECT)
end
function cm.efilter(e,te)
return te:IsActiveType(TYPE_SPELL | TYPE_TRAP) and te:GetOwner()~=e:GetHandler()
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