Commit 10f122f1 authored by wind2009's avatar wind2009

Fix 武装転生

parent bb5d7622
No preview for this file type
...@@ -4,10 +4,9 @@ function s.initial_effect(c) ...@@ -4,10 +4,9 @@ function s.initial_effect(c)
--Activate --Activate
local e1=Effect.CreateEffect(c) local e1=Effect.CreateEffect(c)
e1:SetDescription(aux.Stringid(id,0)) e1:SetDescription(aux.Stringid(id,0))
e1:SetCategory(CATEGORY_SPECIAL_SUMMON) e1:SetCategory(CATEGORY_SPECIAL_SUMMON+CATEGORY_TOKEN)
e1:SetType(EFFECT_TYPE_ACTIVATE) e1:SetType(EFFECT_TYPE_ACTIVATE)
e1:SetCode(EVENT_FREE_CHAIN) e1:SetCode(EVENT_FREE_CHAIN)
e1:SetHintTiming(0,TIMING_END_PHASE)
e1:SetTarget(s.target) e1:SetTarget(s.target)
e1:SetOperation(s.activate) e1:SetOperation(s.activate)
c:RegisterEffect(e1) c:RegisterEffect(e1)
...@@ -24,6 +23,9 @@ function s.target(e,tp,eg,ep,ev,re,r,rp,chk) ...@@ -24,6 +23,9 @@ function s.target(e,tp,eg,ep,ev,re,r,rp,chk)
Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,1,0,0) Duel.SetOperationInfo(0,CATEGORY_TOKEN,nil,1,0,0)
Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0) Duel.SetOperationInfo(0,CATEGORY_SPECIAL_SUMMON,nil,1,0,0)
end end
function s.desfilter(c)
return c:GetSequence()<5
end
function s.eqfilter2(c) function s.eqfilter2(c)
return c:IsSSetable() and s.eqfilter(c) return c:IsSSetable() and s.eqfilter(c)
end end
...@@ -32,8 +34,8 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -32,8 +34,8 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp)
local ct=Duel.GetMatchingGroupCount(s.eqfilter,tp,LOCATION_GRAVE,0,nil) local ct=Duel.GetMatchingGroupCount(s.eqfilter,tp,LOCATION_GRAVE,0,nil)
if ft>ct then ft=ct end if ft>ct then ft=ct end
if ft>0 then 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 if not Duel.IsPlayerCanSpecialSummonMonster(tp,id+o,0,TYPES_TOKEN_MONSTER,500,500,1,RACE_WARRIOR,ATTRIBUTE_EARTH) then return end
if Duel.IsPlayerAffectedByEffect(tp,59822133) then ft=1 end
local ctn=true local ctn=true
while ft>0 and ctn do while ft>0 and ctn do
local token=Duel.CreateToken(tp,id+o) local token=Duel.CreateToken(tp,id+o)
...@@ -42,22 +44,26 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp) ...@@ -42,22 +44,26 @@ function s.activate(e,tp,eg,ep,ev,re,r,rp)
if ft<=0 or not Duel.SelectYesNo(tp,aux.Stringid(id,1)) then ctn=false end if ft<=0 or not Duel.SelectYesNo(tp,aux.Stringid(id,1)) then ctn=false end
end end
Duel.SpecialSummonComplete() Duel.SpecialSummonComplete()
if e:GetHandler():IsRelateToEffect(e) then if e:GetHandler():IsRelateToChain() then
local g=Duel.GetMatchingGroup(aux.TRUE,tp,LOCATION_SZONE,0,nil) local dg=Duel.GetMatchingGroup(s.desfilter,tp,LOCATION_SZONE,0,nil)
if Duel.Destroy(g,REASON_EFFECT)>0 then if dg:GetCount()>0 and Duel.SelectYesNo(tp,aux.Stringid(id,2)) then
local sg=Duel.GetMatchingGroup(s.eqfilter2,tp,LOCATION_GRAVE,0,nil) Duel.BreakEffect()
local count=Duel.GetLocationCount(tp,LOCATION_SZONE) if Duel.Destroy(dg,REASON_EFFECT)>0 then
if count>sg:GetCount() then count=sg:GetCount() end local sg=Duel.GetMatchingGroup(s.eqfilter2,tp,LOCATION_GRAVE,0,nil)
local tg=sg:Select(tp,count,count,nil) local count=Duel.GetLocationCount(tp,LOCATION_SZONE)
Duel.SSet(tp,tg) if count>sg:GetCount() then count=sg:GetCount() end
for tc in aux.Next(tg) do Duel.Hint(HINT_SELECTMSG,tp,HINTMSG_SET)
local e1=Effect.CreateEffect(e:GetHandler()) local tg=sg:Select(tp,count,count,nil)
e1:SetDescription(aux.Stringid(id,2)) Duel.SSet(tp,tg)
e1:SetType(EFFECT_TYPE_SINGLE) for tc in aux.Next(tg) do
e1:SetCode(EFFECT_TRAP_ACT_IN_SET_TURN) local e1=Effect.CreateEffect(e:GetHandler())
e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE) e1:SetDescription(aux.Stringid(id,3))
e1:SetReset(RESET_EVENT+RESETS_STANDARD) e1:SetType(EFFECT_TYPE_SINGLE)
tc:RegisterEffect(e1) e1:SetCode(EFFECT_TRAP_ACT_IN_SET_TURN)
e1:SetProperty(EFFECT_FLAG_SET_AVAILABLE)
e1:SetReset(RESET_EVENT+RESETS_STANDARD)
tc:RegisterEffect(e1)
end
end end
end end
end end
......
--閃刀機アディルセイバー --閃刀機アディルセイバー
local s,id,o=GetID() local s,id,o=GetID()
function s.initial_effect(c) function s.initial_effect(c)
--atkup --atkup
......
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