Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-scripts
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
八宫一月
ygopro-scripts
Commits
819847e7
Commit
819847e7
authored
Sep 30, 2017
by
mercury233
Committed by
GitHub
Sep 30, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update synchro (#936)
parent
44b257bb
Changes
27
Hide whitespace changes
Inline
Side-by-side
Showing
27 changed files
with
285 additions
and
965 deletions
+285
-965
c13455674.lua
c13455674.lua
+2
-84
c14943837.lua
c14943837.lua
+0
-3
c16172067.lua
c16172067.lua
+2
-193
c16825874.lua
c16825874.lua
+0
-1
c25165047.lua
c25165047.lua
+17
-0
c33541430.lua
c33541430.lua
+6
-0
c37953640.lua
c37953640.lua
+0
-1
c55863245.lua
c55863245.lua
+2
-1
c56897896.lua
c56897896.lua
+0
-1
c57261568.lua
c57261568.lua
+6
-0
c61777313.lua
c61777313.lua
+0
-3
c62242678.lua
c62242678.lua
+3
-131
c64910482.lua
c64910482.lua
+10
-0
c67030233.lua
c67030233.lua
+5
-50
c67038874.lua
c67038874.lua
+0
-3
c73417207.lua
c73417207.lua
+0
-1
c73941492.lua
c73941492.lua
+0
-3
c74509280.lua
c74509280.lua
+0
-1
c7841112.lua
c7841112.lua
+5
-50
c80896940.lua
c80896940.lua
+10
-112
c89818984.lua
c89818984.lua
+6
-0
c9047460.lua
c9047460.lua
+0
-1
c93157004.lua
c93157004.lua
+1
-158
c93369354.lua
c93369354.lua
+0
-1
c97489701.lua
c97489701.lua
+1
-155
constant.lua
constant.lua
+12
-12
utility.lua
utility.lua
+197
-0
No files found.
c13455674.lua
View file @
819847e7
--水晶機巧-グリオンガンド
--水晶機巧-グリオンガンド
function
c13455674
.
initial_effect
(
c
)
function
c13455674
.
initial_effect
(
c
)
c
:
EnableReviveLimit
()
--synchro summon
--synchro summon
local
e1
=
Effect
.
CreateEffect
(
c
)
aux
.
AddSynchroMixProcedure
(
c
,
aux
.
NonTuner
(
nil
),
nil
,
nil
,
aux
.
Tuner
(
nil
),
2
,
99
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
c
:
EnableReviveLimit
()
e1
:
SetProperty
(
EFFECT_FLAG_UNCOPYABLE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
e1
:
SetRange
(
LOCATION_EXTRA
)
e1
:
SetCondition
(
c13455674
.
syncon
)
e1
:
SetOperation
(
c13455674
.
synop
)
e1
:
SetValue
(
SUMMON_TYPE_SYNCHRO
)
c
:
RegisterEffect
(
e1
)
--remove
--remove
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
13455674
,
0
))
e2
:
SetDescription
(
aux
.
Stringid
(
13455674
,
0
))
...
@@ -40,80 +32,6 @@ function c13455674.initial_effect(c)
...
@@ -40,80 +32,6 @@ function c13455674.initial_effect(c)
e4
:
SetCode
(
21142671
)
e4
:
SetCode
(
21142671
)
c
:
RegisterEffect
(
e4
)
c
:
RegisterEffect
(
e4
)
end
end
function
c13455674
.
matfilter1
(
c
,
syncard
)
return
c
:
IsType
(
TYPE_TUNER
)
and
c
:
IsFaceup
()
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
end
function
c13455674
.
matfilter2
(
c
,
syncard
)
return
c
:
IsNotTuner
()
and
c
:
IsFaceup
()
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
end
function
c13455674
.
synfilter
(
c
,
syncard
,
lv
,
g1
,
pg
,
ct
)
local
g
=
Group
.
FromCards
(
c
)
g
:
Merge
(
pg
)
Duel
.
SetSelectedCard
(
g
)
return
g1
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
lv
,
ct
,
63
,
syncard
)
end
function
c13455674
.
syncon
(
e
,
c
,
tuner
,
mg
)
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<-
2
then
return
false
end
local
g1
=
nil
local
g2
=
nil
if
mg
then
g1
=
mg
:
Filter
(
c13455674
.
matfilter1
,
nil
,
c
)
g2
=
mg
:
Filter
(
c13455674
.
matfilter2
,
nil
,
c
)
else
g1
=
Duel
.
GetMatchingGroup
(
c13455674
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g2
=
Duel
.
GetMatchingGroup
(
c13455674
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
local
pg
=
Group
.
CreateGroup
()
local
ct
=
2
if
tuner
then
pg
:
AddCard
(
tuner
)
ct
=
ct
-
1
end
if
pe
then
pg
:
AddCard
(
pe
:
GetOwner
())
ct
=
ct
-
1
end
return
g2
:
IsExists
(
c13455674
.
synfilter
,
1
,
nil
,
c
,
lv
,
g1
,
pg
,
ct
)
end
function
c13455674
.
synop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
tuner
,
mg
)
local
g
=
Group
.
CreateGroup
()
local
g1
=
nil
local
g2
=
nil
if
mg
then
g1
=
mg
:
Filter
(
c13455674
.
matfilter1
,
nil
,
c
)
g2
=
mg
:
Filter
(
c13455674
.
matfilter2
,
nil
,
c
)
else
g1
=
Duel
.
GetMatchingGroup
(
c13455674
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g2
=
Duel
.
GetMatchingGroup
(
c13455674
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
local
ct
=
2
if
tuner
then
g
:
AddCard
(
tuner
)
ct
=
ct
-
1
end
if
pe
then
local
pc
=
pe
:
GetOwner
()
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
Group
.
FromCards
(
pc
):
Select
(
tp
,
1
,
1
,
nil
)
g
:
AddCard
(
pc
)
ct
=
ct
-
1
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
m2
=
g2
:
FilterSelect
(
tp
,
c13455674
.
synfilter
,
1
,
1
,
nil
,
c
,
lv
,
g1
,
g
,
ct
)
g
:
Merge
(
m2
)
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
m1
=
g1
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
ct
,
63
,
c
)
g
:
Merge
(
m1
)
c
:
SetMaterial
(
g
)
Duel
.
SendtoGrave
(
g
,
REASON_MATERIAL
+
REASON_SYNCHRO
)
end
function
c13455674
.
rmcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c13455674
.
rmcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_SYNCHRO
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_SYNCHRO
)
end
end
...
...
c14943837.lua
View file @
819847e7
...
@@ -28,9 +28,6 @@ function c14943837.synlimit(e,c)
...
@@ -28,9 +28,6 @@ function c14943837.synlimit(e,c)
if
not
c
then
return
false
end
if
not
c
then
return
false
end
return
not
c
:
IsRace
(
RACE_DRAGON
)
return
not
c
:
IsRace
(
RACE_DRAGON
)
end
end
function
c14943837
.
tuner_filter
(
c
)
return
c
:
GetLevel
()
~=
4
end
function
c14943837
.
synlimit2
(
e
,
c
)
function
c14943837
.
synlimit2
(
e
,
c
)
return
c
:
GetLevel
()
~=
4
return
c
:
GetLevel
()
~=
4
end
end
...
...
c16172067.lua
View file @
819847e7
--レッド・デーモンズ・ドラゴン・タイラント
--レッド・デーモンズ・ドラゴン・タイラント
function
c16172067
.
initial_effect
(
c
)
function
c16172067
.
initial_effect
(
c
)
--synchro summon
aux
.
AddSynchroMixProcedure
(
c
,
aux
.
Tuner
(
nil
),
aux
.
Tuner
(
nil
),
nil
,
aux
.
NonTuner
(
nil
),
1
,
99
)
c
:
EnableReviveLimit
()
c
:
EnableReviveLimit
()
--cannot special summon
--cannot special summon
local
e0
=
Effect
.
CreateEffect
(
c
)
local
e0
=
Effect
.
CreateEffect
(
c
)
...
@@ -8,16 +10,6 @@ function c16172067.initial_effect(c)
...
@@ -8,16 +10,6 @@ function c16172067.initial_effect(c)
e0
:
SetCode
(
EFFECT_SPSUMMON_CONDITION
)
e0
:
SetCode
(
EFFECT_SPSUMMON_CONDITION
)
e0
:
SetValue
(
aux
.
synlimit
)
e0
:
SetValue
(
aux
.
synlimit
)
c
:
RegisterEffect
(
e0
)
c
:
RegisterEffect
(
e0
)
--synchro summon
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
e1
:
SetProperty
(
EFFECT_FLAG_UNCOPYABLE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetRange
(
LOCATION_EXTRA
)
e1
:
SetCondition
(
c16172067
.
syncon
)
e1
:
SetOperation
(
c16172067
.
synop
)
e1
:
SetValue
(
SUMMON_TYPE_SYNCHRO
)
c
:
RegisterEffect
(
e1
)
--destroy
--destroy
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetCategory
(
CATEGORY_DESTROY
)
e2
:
SetCategory
(
CATEGORY_DESTROY
)
...
@@ -47,189 +39,6 @@ function c16172067.initial_effect(c)
...
@@ -47,189 +39,6 @@ function c16172067.initial_effect(c)
e4
:
SetCode
(
21142671
)
e4
:
SetCode
(
21142671
)
c
:
RegisterEffect
(
e4
)
c
:
RegisterEffect
(
e4
)
end
end
function
c16172067
.
matfilter1
(
c
,
syncard
)
return
c
:
IsType
(
TYPE_TUNER
)
and
(
c
:
IsLocation
(
LOCATION_HAND
)
or
c
:
IsFaceup
())
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
end
function
c16172067
.
matfilter2
(
c
,
syncard
)
return
c
:
IsNotTuner
()
and
(
c
:
IsLocation
(
LOCATION_HAND
)
or
c
:
IsFaceup
())
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
end
function
c16172067
.
synfilter1
(
c
,
syncard
,
lv
,
g1
,
g2
,
g3
,
g4
,
mc
)
if
c
==
mc
then
return
false
end
local
f1
=
c
.
tuner_filter
if
mc
and
f1
and
not
f1
(
mc
)
then
return
false
end
if
c
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
return
g3
:
IsExists
(
c16172067
.
synfilter2
,
1
,
c
,
syncard
,
lv
,
g2
,
g4
,
f1
,
c
,
mc
)
else
return
g1
:
IsExists
(
c16172067
.
synfilter2
,
1
,
c
,
syncard
,
lv
,
g2
,
g4
,
f1
,
c
,
mc
)
end
end
function
c16172067
.
synfilter2
(
c
,
syncard
,
lv
,
g2
,
g4
,
f1
,
tuner1
,
mc
)
if
c
==
tuner1
or
c
==
mc
then
return
false
end
local
f2
=
c
.
tuner_filter
if
f1
and
not
f1
(
c
)
then
return
false
end
if
f2
and
not
f2
(
tuner1
)
then
return
false
end
if
mc
and
f2
and
not
f2
(
mc
)
then
return
false
end
if
(
tuner1
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
and
not
c
:
IsLocation
(
LOCATION_HAND
))
or
c
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
return
g4
:
IsExists
(
c16172067
.
synfilter3
,
1
,
nil
,
syncard
,
lv
,
f1
,
f2
,
g2
,
tuner1
,
c
,
mc
)
else
local
mg
=
g2
:
Filter
(
c16172067
.
synfilter4
,
nil
,
f1
,
f2
)
if
not
mc
then
Duel
.
SetSelectedCard
(
Group
.
FromCards
(
c
,
tuner1
))
return
mg
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
lv
,
1
,
99
,
syncard
)
else
Duel
.
SetSelectedCard
(
Group
.
FromCards
(
c
,
tuner1
,
mc
))
return
mg
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
lv
,
0
,
99
,
syncard
)
end
end
end
function
c16172067
.
synfilter3
(
c
,
syncard
,
lv
,
f1
,
f2
,
g2
,
tuner1
,
tuner2
,
mc
)
if
c
==
tuner1
or
c
==
tuner2
or
c
==
mc
then
return
false
end
if
(
f1
and
not
f1
(
c
))
or
(
f2
and
not
f2
(
c
))
then
return
false
end
local
mg
=
g2
:
Filter
(
c16172067
.
synfilter4
,
nil
,
f1
,
f2
)
if
not
mc
then
Duel
.
SetSelectedCard
(
Group
.
FromCards
(
c
,
tuner1
,
tuner2
))
else
Duel
.
SetSelectedCard
(
Group
.
FromCards
(
c
,
tuner1
,
tuner2
,
mc
))
end
return
mg
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
lv
,
0
,
99
,
syncard
)
end
function
c16172067
.
synfilter4
(
c
,
f1
,
f2
)
return
(
not
f1
or
f1
(
c
))
and
(
not
f2
or
f2
(
c
))
end
function
c16172067
.
syncon
(
e
,
c
,
tuner
,
mg
)
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<-
2
then
return
false
end
if
tuner
and
not
tuner
:
IsCanBeSynchroMaterial
(
c
)
then
return
false
end
local
g1
=
nil
local
g2
=
nil
local
g3
=
nil
local
g4
=
nil
if
mg
then
g1
=
mg
:
Filter
(
c16172067
.
matfilter1
,
nil
,
c
)
g2
=
mg
:
Filter
(
c16172067
.
matfilter2
,
nil
,
c
)
g3
=
g1
:
Clone
()
g4
=
g2
:
Clone
()
else
g1
=
Duel
.
GetMatchingGroup
(
c16172067
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g2
=
Duel
.
GetMatchingGroup
(
c16172067
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g3
=
Duel
.
GetMatchingGroup
(
c16172067
.
matfilter1
,
tp
,
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
,
nil
,
c
)
g4
=
Duel
.
GetMatchingGroup
(
c16172067
.
matfilter2
,
tp
,
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
,
nil
,
c
)
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
if
tuner
and
tuner
:
IsType
(
TYPE_TUNER
)
then
local
f1
=
tuner
.
tuner_filter
if
not
pe
then
return
g1
:
IsExists
(
c16172067
.
synfilter2
,
1
,
tuner
,
c
,
lv
,
g2
,
g4
,
f1
,
tuner
)
else
return
c16172067
.
synfilter2
(
pe
:
GetOwner
(),
c
,
lv
,
g2
,
nil
,
f1
,
tuner
)
end
end
if
not
pe
then
return
g1
:
IsExists
(
c16172067
.
synfilter1
,
1
,
nil
,
c
,
lv
,
g1
,
g2
,
g3
,
g4
,
tuner
)
else
return
c16172067
.
synfilter1
(
pe
:
GetOwner
(),
c
,
lv
,
g1
,
g2
,
g3
,
g4
,
tuner
)
end
end
function
c16172067
.
synop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
tuner
,
mg
)
local
g
=
Group
.
CreateGroup
()
local
g1
=
nil
local
g2
=
nil
local
g3
=
nil
local
g4
=
nil
if
mg
then
g1
=
mg
:
Filter
(
c16172067
.
matfilter1
,
nil
,
c
)
g2
=
mg
:
Filter
(
c16172067
.
matfilter2
,
nil
,
c
)
g3
=
g1
:
Clone
()
g4
=
g2
:
Clone
()
else
g1
=
Duel
.
GetMatchingGroup
(
c16172067
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g2
=
Duel
.
GetMatchingGroup
(
c16172067
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g3
=
Duel
.
GetMatchingGroup
(
c16172067
.
matfilter1
,
tp
,
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
,
nil
,
c
)
g4
=
Duel
.
GetMatchingGroup
(
c16172067
.
matfilter2
,
tp
,
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
,
nil
,
c
)
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
if
tuner
and
tuner
:
IsType
(
TYPE_TUNER
)
then
g
:
AddCard
(
tuner
)
local
f1
=
tuner
.
tuner_filter
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner2
=
nil
if
not
pe
then
local
t2
=
g1
:
FilterSelect
(
tp
,
c16172067
.
synfilter2
,
1
,
1
,
tuner
,
c
,
lv
,
g2
,
g4
,
f1
,
tuner
)
tuner2
=
t2
:
GetFirst
()
else
tuner2
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner2
):
Select
(
tp
,
1
,
1
,
nil
)
end
g
:
AddCard
(
tuner2
)
local
f2
=
tuner2
.
tuner_filter
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
if
tuner2
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
local
m3
=
g4
:
FilterSelect
(
tp
,
c16172067
.
synfilter3
,
1
,
1
,
nil
,
c
,
lv
,
f1
,
f2
,
g2
,
tuner
,
tuner2
)
g
:
Merge
(
m3
)
local
mg2
=
g2
:
Filter
(
c16172067
.
synfilter4
,
nil
,
f1
,
f2
)
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
m4
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
0
,
99
,
c
)
g
:
Merge
(
m4
)
else
local
mg2
=
g2
:
Filter
(
c16172067
.
synfilter4
,
nil
,
f1
,
f2
)
Duel
.
SetSelectedCard
(
g
)
local
m3
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
99
,
c
)
g
:
Merge
(
m3
)
end
else
if
tuner
then
g
:
AddCard
(
tuner
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner1
=
nil
if
not
pe
then
local
t1
=
g1
:
FilterSelect
(
tp
,
c16172067
.
synfilter1
,
1
,
1
,
nil
,
c
,
lv
,
g1
,
g2
,
g3
,
g4
,
tuner
)
tuner1
=
t1
:
GetFirst
()
else
tuner1
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner1
):
Select
(
tp
,
1
,
1
,
nil
)
end
g
:
AddCard
(
tuner1
)
local
f1
=
tuner1
.
tuner_filter
local
tuner2
=
nil
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
if
tuner1
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
local
t2
=
g3
:
FilterSelect
(
tp
,
c16172067
.
synfilter2
,
1
,
1
,
tuner1
,
c
,
lv
,
g2
,
g4
,
f1
,
tuner1
,
tuner
)
tuner2
=
t2
:
GetFirst
()
else
local
t2
=
g1
:
FilterSelect
(
tp
,
c16172067
.
synfilter2
,
1
,
1
,
tuner1
,
c
,
lv
,
g2
,
g4
,
f1
,
tuner1
,
tuner
)
tuner2
=
t2
:
GetFirst
()
end
g
:
AddCard
(
tuner2
)
local
f2
=
tuner2
.
tuner_filter
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
if
(
tuner1
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
and
not
tuner2
:
IsLocation
(
LOCATION_HAND
))
or
tuner2
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
local
m3
=
g4
:
FilterSelect
(
tp
,
c16172067
.
synfilter3
,
1
,
1
,
nil
,
c
,
lv
,
f1
,
f2
,
g2
,
tuner1
,
tuner2
,
tuner
)
g
:
Merge
(
m3
)
local
mg2
=
g2
:
Filter
(
c16172067
.
synfilter4
,
nil
,
f1
,
f2
)
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
m4
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
0
,
99
,
c
)
g
:
Merge
(
m4
)
else
local
mg2
=
g2
:
Filter
(
c16172067
.
synfilter4
,
nil
,
f1
,
f2
)
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
if
not
tuner
then
local
m3
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
99
,
c
)
g
:
Merge
(
m3
)
else
local
m3
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
0
,
99
,
c
)
g
:
Merge
(
m3
)
end
end
end
c
:
SetMaterial
(
g
)
Duel
.
SendtoGrave
(
g
,
REASON_MATERIAL
+
REASON_SYNCHRO
)
end
function
c16172067
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c16172067
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetCurrentPhase
()
==
PHASE_MAIN1
return
Duel
.
GetCurrentPhase
()
==
PHASE_MAIN1
end
end
...
...
c16825874.lua
View file @
819847e7
...
@@ -23,7 +23,6 @@ function c16825874.initial_effect(c)
...
@@ -23,7 +23,6 @@ function c16825874.initial_effect(c)
e3
:
SetCode
(
EFFECT_HAND_SYNCHRO
)
e3
:
SetCode
(
EFFECT_HAND_SYNCHRO
)
c
:
RegisterEffect
(
e3
)
c
:
RegisterEffect
(
e3
)
end
end
c16825874
.
tuner_filter
=
aux
.
FALSE
function
c16825874
.
ccon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c16825874
.
ccon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
r
==
REASON_SYNCHRO
return
r
==
REASON_SYNCHRO
end
end
...
...
c25165047.lua
View file @
819847e7
...
@@ -31,6 +31,12 @@ function c25165047.initial_effect(c)
...
@@ -31,6 +31,12 @@ function c25165047.initial_effect(c)
e4
:
SetCode
(
EFFECT_DESTROY_REPLACE
)
e4
:
SetCode
(
EFFECT_DESTROY_REPLACE
)
e4
:
SetTarget
(
c25165047
.
desreptg
)
e4
:
SetTarget
(
c25165047
.
desreptg
)
c
:
RegisterEffect
(
e4
)
c
:
RegisterEffect
(
e4
)
--double tuner check
local
e5
=
Effect
.
CreateEffect
(
c
)
e5
:
SetType
(
EFFECT_TYPE_SINGLE
)
e5
:
SetCode
(
EFFECT_MATERIAL_CHECK
)
e5
:
SetValue
(
c25165047
.
valcheck
)
c
:
RegisterEffect
(
e5
)
end
end
function
c25165047
.
lpcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c25165047
.
lpcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_SYNCHRO
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_SYNCHRO
)
...
@@ -56,3 +62,14 @@ function c25165047.desreptg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -56,3 +62,14 @@ function c25165047.desreptg(e,tp,eg,ep,ev,re,r,rp,chk)
return
true
return
true
else
return
false
end
else
return
false
end
end
end
function
c25165047
.
valcheck
(
e
,
c
)
local
g
=
c
:
GetMaterial
()
if
g
:
IsExists
(
Card
.
IsType
,
2
,
nil
,
TYPE_TUNER
)
then
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e1
:
SetCode
(
21142671
)
e1
:
SetReset
(
RESET_EVENT
+
0xfe0000
+
RESET_PHASE
+
PHASE_END
)
c
:
RegisterEffect
(
e1
)
end
end
c33541430.lua
View file @
819847e7
...
@@ -23,6 +23,12 @@ function c33541430.initial_effect(c)
...
@@ -23,6 +23,12 @@ function c33541430.initial_effect(c)
e3
:
SetValue
(
1
)
e3
:
SetValue
(
1
)
e3
:
SetOperation
(
c33541430
.
synop
)
e3
:
SetOperation
(
c33541430
.
synop
)
c
:
RegisterEffect
(
e3
)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e4
:
SetCode
(
89818984
)
e4
:
SetRange
(
LOCATION_MZONE
)
c
:
RegisterEffect
(
e4
)
end
end
function
c33541430
.
drcost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
function
c33541430
.
drcost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
if
chk
==
0
then
return
true
end
...
...
c37953640.lua
View file @
819847e7
...
@@ -8,7 +8,6 @@ function c37953640.initial_effect(c)
...
@@ -8,7 +8,6 @@ function c37953640.initial_effect(c)
e1
:
SetTarget
(
c37953640
.
synlimit
)
e1
:
SetTarget
(
c37953640
.
synlimit
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
end
end
c37953640
.
tuner_filter
=
aux
.
FilterBoolFunction
(
Card
.
IsRace
,
RACE_FISH
)
function
c37953640
.
synlimit
(
e
,
c
)
function
c37953640
.
synlimit
(
e
,
c
)
return
c
:
IsRace
(
RACE_FISH
)
return
c
:
IsRace
(
RACE_FISH
)
end
end
c55863245.lua
View file @
819847e7
...
@@ -21,12 +21,13 @@ function c55863245.initial_effect(c)
...
@@ -21,12 +21,13 @@ function c55863245.initial_effect(c)
e2
:
SetCode
(
EFFECT_IMMUNE_EFFECT
)
e2
:
SetCode
(
EFFECT_IMMUNE_EFFECT
)
e2
:
SetValue
(
c55863245
.
efilter
)
e2
:
SetValue
(
c55863245
.
efilter
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
--hand synchro
for double tuner
--hand synchro
local
e3
=
Effect
.
CreateEffect
(
c
)
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e3
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e3
:
SetCondition
(
c55863245
.
syncon
)
e3
:
SetCondition
(
c55863245
.
syncon
)
e3
:
SetCode
(
EFFECT_HAND_SYNCHRO
)
e3
:
SetCode
(
EFFECT_HAND_SYNCHRO
)
e3
:
SetTargetRange
(
0
,
1
)
c
:
RegisterEffect
(
e3
)
c
:
RegisterEffect
(
e3
)
end
end
function
c55863245
.
synfilter
(
c
,
syncard
,
tuner
,
f
)
function
c55863245
.
synfilter
(
c
,
syncard
,
tuner
,
f
)
...
...
c56897896.lua
View file @
819847e7
...
@@ -14,7 +14,6 @@ function c56897896.initial_effect(c)
...
@@ -14,7 +14,6 @@ function c56897896.initial_effect(c)
e2
:
SetValue
(
c56897896
.
syncheck
)
e2
:
SetValue
(
c56897896
.
syncheck
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
end
end
c56897896
.
tuner_filter
=
aux
.
FALSE
function
c56897896
.
synlimit
(
e
,
c
)
function
c56897896
.
synlimit
(
e
,
c
)
return
c
:
IsLevelBelow
(
4
)
and
c
:
IsRace
(
RACE_WARRIOR
+
RACE_MACHINE
)
return
c
:
IsLevelBelow
(
4
)
and
c
:
IsRace
(
RACE_WARRIOR
+
RACE_MACHINE
)
end
end
...
...
c57261568.lua
View file @
819847e7
...
@@ -27,6 +27,12 @@ function c57261568.initial_effect(c)
...
@@ -27,6 +27,12 @@ function c57261568.initial_effect(c)
e3
:
SetValue
(
1
)
e3
:
SetValue
(
1
)
e3
:
SetOperation
(
c57261568
.
synop
)
e3
:
SetOperation
(
c57261568
.
synop
)
c
:
RegisterEffect
(
e3
)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e4
:
SetCode
(
89818984
)
e4
:
SetRange
(
LOCATION_MZONE
)
c
:
RegisterEffect
(
e4
)
end
end
function
c57261568
.
hspfilter
(
c
,
ft
,
tp
)
function
c57261568
.
hspfilter
(
c
,
ft
,
tp
)
return
c
:
IsSetCard
(
0xe6
)
and
not
c
:
IsCode
(
57261568
)
return
c
:
IsSetCard
(
0xe6
)
and
not
c
:
IsCode
(
57261568
)
...
...
c61777313.lua
View file @
819847e7
...
@@ -17,9 +17,6 @@ function c61777313.initial_effect(c)
...
@@ -17,9 +17,6 @@ function c61777313.initial_effect(c)
e2
:
SetOperation
(
c61777313
.
operation
)
e2
:
SetOperation
(
c61777313
.
operation
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
end
end
function
c61777313
.
tuner_filter
(
c
)
return
c
:
IsSetCard
(
0x42
)
end
function
c61777313
.
synlimit
(
e
,
c
)
function
c61777313
.
synlimit
(
e
,
c
)
return
c
:
IsSetCard
(
0x42
)
return
c
:
IsSetCard
(
0x42
)
end
end
...
...
c62242678.lua
View file @
819847e7
--琰魔竜王 レッド・デーモン・カラミティ
--琰魔竜王 レッド・デーモン・カラミティ
function
c62242678
.
initial_effect
(
c
)
function
c62242678
.
initial_effect
(
c
)
--synchro summon
--synchro summon
aux
.
AddSynchroMixProcedure
(
c
,
aux
.
Tuner
(
nil
),
aux
.
Tuner
(
nil
),
nil
,
aux
.
NonTuner
(
c62242678
.
sfilter
),
1
,
1
)
c
:
EnableReviveLimit
()
c
:
EnableReviveLimit
()
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
e1
:
SetProperty
(
EFFECT_FLAG_UNCOPYABLE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetRange
(
LOCATION_EXTRA
)
e1
:
SetCondition
(
c62242678
.
syncon
)
e1
:
SetOperation
(
c62242678
.
synop
)
e1
:
SetValue
(
SUMMON_TYPE_SYNCHRO
)
c
:
RegisterEffect
(
e1
)
--act limit
--act limit
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
62242678
,
0
))
e2
:
SetDescription
(
aux
.
Stringid
(
62242678
,
0
))
...
@@ -49,128 +41,8 @@ function c62242678.initial_effect(c)
...
@@ -49,128 +41,8 @@ function c62242678.initial_effect(c)
e5
:
SetCode
(
21142671
)
e5
:
SetCode
(
21142671
)
c
:
RegisterEffect
(
e5
)
c
:
RegisterEffect
(
e5
)
end
end
function
c62242678
.
matfilter1
(
c
,
syncard
)
function
c62242678
.
sfilter
(
c
)
return
c
:
IsType
(
TYPE_TUNER
)
and
(
c
:
IsLocation
(
LOCATION_HAND
)
or
c
:
IsFaceup
())
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
return
c
:
IsRace
(
RACE_DRAGON
)
and
c
:
IsAttribute
(
ATTRIBUTE_DARK
)
and
c
:
IsType
(
TYPE_SYNCHRO
)
end
function
c62242678
.
matfilter2
(
c
,
syncard
)
return
c
:
IsNotTuner
()
and
c
:
IsFaceup
()
and
c
:
IsRace
(
RACE_DRAGON
)
and
c
:
IsAttribute
(
ATTRIBUTE_DARK
)
and
c
:
IsType
(
TYPE_SYNCHRO
)
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
end
function
c62242678
.
synfilter1
(
c
,
syncard
,
lv
,
g1
,
g2
,
g3
)
local
f1
=
c
.
tuner_filter
if
c
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
return
g3
:
IsExists
(
c62242678
.
synfilter2
,
1
,
c
,
syncard
,
lv
,
g2
,
f1
,
c
)
else
return
g1
:
IsExists
(
c62242678
.
synfilter2
,
1
,
c
,
syncard
,
lv
,
g2
,
f1
,
c
)
end
end
function
c62242678
.
synfilter2
(
c
,
syncard
,
lv
,
g2
,
f1
,
tuner1
)
local
f2
=
c
.
tuner_filter
if
f1
and
not
f1
(
c
)
then
return
false
end
if
f2
and
not
f2
(
tuner1
)
then
return
false
end
local
mg
=
g2
:
Filter
(
c62242678
.
synfilter3
,
nil
,
f1
,
f2
)
Duel
.
SetSelectedCard
(
Group
.
FromCards
(
c
,
tuner1
))
return
mg
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
syncard
)
end
function
c62242678
.
synfilter3
(
c
,
f1
,
f2
)
return
(
not
f1
or
f1
(
c
))
and
(
not
f2
or
f2
(
c
))
end
function
c62242678
.
syncon
(
e
,
c
,
tuner
,
mg
)
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<-
2
then
return
false
end
local
g1
=
nil
local
g2
=
nil
local
g3
=
nil
if
mg
then
g1
=
mg
:
Filter
(
c62242678
.
matfilter1
,
nil
,
c
)
g2
=
mg
:
Filter
(
c62242678
.
matfilter2
,
nil
,
c
)
g3
=
g1
:
Clone
()
else
g1
=
Duel
.
GetMatchingGroup
(
c62242678
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g2
=
Duel
.
GetMatchingGroup
(
c62242678
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g3
=
Duel
.
GetMatchingGroup
(
c62242678
.
matfilter1
,
tp
,
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
,
nil
,
c
)
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
if
tuner
then
local
f1
=
tuner
.
tuner_filter
if
not
pe
then
return
g1
:
IsExists
(
c62242678
.
synfilter2
,
1
,
tuner
,
c
,
lv
,
g2
,
f1
,
tuner
)
else
return
c62242678
.
synfilter2
(
pe
:
GetOwner
(),
c
,
lv
,
g2
,
f1
,
tuner
)
end
end
if
not
pe
then
return
g1
:
IsExists
(
c62242678
.
synfilter1
,
1
,
nil
,
c
,
lv
,
g1
,
g2
,
g3
)
else
return
c62242678
.
synfilter1
(
pe
:
GetOwner
(),
c
,
lv
,
g1
,
g2
,
g3
)
end
end
function
c62242678
.
synop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
tuner
,
mg
)
local
g
=
Group
.
CreateGroup
()
local
g1
=
nil
local
g2
=
nil
local
g3
=
nil
if
mg
then
g1
=
mg
:
Filter
(
c62242678
.
matfilter1
,
nil
,
c
)
g2
=
mg
:
Filter
(
c62242678
.
matfilter2
,
nil
,
c
)
g3
=
g1
:
Clone
()
else
g1
=
Duel
.
GetMatchingGroup
(
c62242678
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g2
=
Duel
.
GetMatchingGroup
(
c62242678
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g3
=
Duel
.
GetMatchingGroup
(
c62242678
.
matfilter1
,
tp
,
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
,
nil
,
c
)
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
if
tuner
then
g
:
AddCard
(
tuner
)
local
f1
=
tuner
.
tuner_filter
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner2
=
nil
if
not
pe
then
local
t2
=
g1
:
FilterSelect
(
tp
,
c62242678
.
synfilter2
,
1
,
1
,
tuner
,
c
,
lv
,
g2
,
f1
,
tuner
)
tuner2
=
t2
:
GetFirst
()
else
tuner2
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner2
):
Select
(
tp
,
1
,
1
,
nil
)
end
g
:
AddCard
(
tuner2
)
local
f2
=
tuner2
.
tuner_filter
local
mg2
=
g2
:
Filter
(
c62242678
.
synfilter3
,
nil
,
f1
,
f2
)
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
m3
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
c
)
g
:
Merge
(
m3
)
else
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner1
=
nil
if
not
pe
then
local
t1
=
g1
:
FilterSelect
(
tp
,
c62242678
.
synfilter1
,
1
,
1
,
nil
,
c
,
lv
,
g1
,
g2
,
g3
)
tuner1
=
t1
:
GetFirst
()
else
tuner1
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner1
):
Select
(
tp
,
1
,
1
,
nil
)
end
g
:
AddCard
(
tuner1
)
local
f1
=
tuner1
.
tuner_filter
local
t2
=
nil
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
if
tuner1
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
t2
=
g3
:
FilterSelect
(
tp
,
c62242678
.
synfilter2
,
1
,
1
,
tuner1
,
c
,
lv
,
g2
,
f1
,
tuner1
)
else
t2
=
g1
:
FilterSelect
(
tp
,
c62242678
.
synfilter2
,
1
,
1
,
tuner1
,
c
,
lv
,
g2
,
f1
,
tuner1
)
end
local
tuner2
=
t2
:
GetFirst
()
g
:
AddCard
(
tuner2
)
local
f2
=
tuner2
.
tuner_filter
local
mg2
=
g2
:
Filter
(
c62242678
.
synfilter3
,
nil
,
f1
,
f2
)
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
m3
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
c
)
g
:
Merge
(
m3
)
end
c
:
SetMaterial
(
g
)
Duel
.
SendtoGrave
(
g
,
REASON_MATERIAL
+
REASON_SYNCHRO
)
end
end
function
c62242678
.
limcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c62242678
.
limcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_SYNCHRO
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_SYNCHRO
)
...
...
c64910482.lua
View file @
819847e7
...
@@ -16,6 +16,13 @@ function c64910482.initial_effect(c)
...
@@ -16,6 +16,13 @@ function c64910482.initial_effect(c)
e2
:
SetCode
(
EVENT_TO_GRAVE
)
e2
:
SetCode
(
EVENT_TO_GRAVE
)
e2
:
SetOperation
(
c64910482
.
regop
)
e2
:
SetOperation
(
c64910482
.
regop
)
c
:
RegisterEffect
(
e2
)
c
:
RegisterEffect
(
e2
)
--hand synchro
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e3
:
SetCode
(
EFFECT_HAND_SYNCHRO
)
e3
:
SetTarget
(
c64910482
.
hsyntg
)
c
:
RegisterEffect
(
e3
)
end
end
function
c64910482
.
synfilter1
(
c
,
syncard
,
tuner
,
f
)
function
c64910482
.
synfilter1
(
c
,
syncard
,
tuner
,
f
)
return
c
:
IsFaceup
()
and
c
:
IsCanBeSynchroMaterial
(
syncard
,
tuner
)
and
(
f
==
nil
or
f
(
c
))
return
c
:
IsFaceup
()
and
c
:
IsCanBeSynchroMaterial
(
syncard
,
tuner
)
and
(
f
==
nil
or
f
(
c
))
...
@@ -108,3 +115,6 @@ function c64910482.thop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -108,3 +115,6 @@ function c64910482.thop(e,tp,eg,ep,ev,re,r,rp)
Duel
.
ConfirmCards
(
1
-
tp
,
g
)
Duel
.
ConfirmCards
(
1
-
tp
,
g
)
end
end
end
end
function
c64910482
.
hsyntg
(
e
,
c
)
return
c
:
IsSetCard
(
0x27
)
and
c
:
IsNotTuner
()
end
c67030233.lua
View file @
819847e7
--セイヴァー・デモン・ドラゴン
--セイヴァー・デモン・ドラゴン
function
c67030233
.
initial_effect
(
c
)
function
c67030233
.
initial_effect
(
c
)
--synchro summon
--synchro summon
aux
.
AddSynchroMixProcedure
(
c
,
c67030233
.
mfilter1
,
c67030233
.
mfilter2
,
nil
,
aux
.
NonTuner
(
nil
),
1
,
1
)
c
:
EnableReviveLimit
()
c
:
EnableReviveLimit
()
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
e1
:
SetProperty
(
EFFECT_FLAG_UNCOPYABLE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetRange
(
LOCATION_EXTRA
)
e1
:
SetCondition
(
c67030233
.
syncon
)
e1
:
SetOperation
(
c67030233
.
synop
)
e1
:
SetValue
(
SUMMON_TYPE_SYNCHRO
)
c
:
RegisterEffect
(
e1
)
--destroy
--destroy
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
67030233
,
0
))
e2
:
SetDescription
(
aux
.
Stringid
(
67030233
,
0
))
...
@@ -53,48 +45,11 @@ function c67030233.initial_effect(c)
...
@@ -53,48 +45,11 @@ function c67030233.initial_effect(c)
e5
:
SetValue
(
1
)
e5
:
SetValue
(
1
)
c
:
RegisterEffect
(
e5
)
c
:
RegisterEffect
(
e5
)
end
end
function
c67030233
.
m
atfilter
(
c
,
syncard
)
function
c67030233
.
m
filter1
(
c
)
return
c
:
Is
Faceup
()
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
return
c
:
Is
Code
(
21159309
)
end
end
function
c67030233
.
synfilter1
(
c
,
syncard
,
lv
,
g
)
function
c67030233
.
mfilter2
(
c
)
return
c
:
IsCode
(
21159309
)
and
g
:
IsExists
(
c67030233
.
synfilter2
,
1
,
c
,
syncard
,
lv
,
g
,
c
)
return
c
:
IsCode
(
70902743
)
end
function
c67030233
.
synfilter2
(
c
,
syncard
,
lv
,
g
,
mc
)
if
not
c
:
IsCode
(
70902743
)
then
return
false
end
if
c
:
IsType
(
TYPE_TUNER
)
==
mc
:
IsType
(
TYPE_TUNER
)
then
return
false
end
local
mg
=
g
:
Filter
(
Card
.
IsNotTuner
,
nil
)
Duel
.
SetSelectedCard
(
Group
.
FromCards
(
c
,
mc
))
return
mg
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
syncard
)
end
function
c67030233
.
syncon
(
e
,
c
,
tuner
)
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
local
mg
=
Duel
.
GetMatchingGroup
(
c67030233
.
matfilter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
lv
=
c
:
GetLevel
()
if
tuner
then
return
c67030233
.
synfilter1
(
tuner
,
c
,
lv
,
mg
)
end
return
mg
:
IsExists
(
c67030233
.
synfilter1
,
1
,
nil
,
c
,
lv
,
mg
)
end
function
c67030233
.
synop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
tuner
)
local
g
=
Group
.
CreateGroup
()
local
mg
=
Duel
.
GetMatchingGroup
(
c67030233
.
matfilter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
lv
=
c
:
GetLevel
()
local
m1
=
tuner
if
not
tuner
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
t1
=
mg
:
FilterSelect
(
tp
,
c67030233
.
synfilter1
,
1
,
1
,
nil
,
c
,
lv
,
mg
)
m1
=
t1
:
GetFirst
()
g
:
AddCard
(
m1
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
t2
=
mg
:
FilterSelect
(
tp
,
c67030233
.
synfilter2
,
1
,
1
,
m1
,
c
,
lv
,
mg
,
m1
)
g
:
Merge
(
t2
)
local
mg2
=
mg
:
Filter
(
Card
.
IsNotTuner
,
nil
)
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
t3
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
c
)
g
:
Merge
(
t3
)
c
:
SetMaterial
(
g
)
Duel
.
SendtoGrave
(
g
,
REASON_MATERIAL
+
REASON_SYNCHRO
)
end
end
function
c67030233
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c67030233
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
()
==
Duel
.
GetAttacker
()
return
e
:
GetHandler
()
==
Duel
.
GetAttacker
()
...
...
c67038874.lua
View file @
819847e7
...
@@ -47,9 +47,6 @@ function c67038874.operation(e,tp,eg,ep,ev,re,r,rp)
...
@@ -47,9 +47,6 @@ function c67038874.operation(e,tp,eg,ep,ev,re,r,rp)
c
:
RegisterEffect
(
e1
,
true
)
c
:
RegisterEffect
(
e1
,
true
)
end
end
end
end
function
c67038874
.
tuner_filter
(
c
)
return
c
:
IsSetCard
(
0x24
)
end
function
c67038874
.
synlimit
(
e
,
c
)
function
c67038874
.
synlimit
(
e
,
c
)
return
c
:
IsSetCard
(
0x24
)
return
c
:
IsSetCard
(
0x24
)
end
end
c73417207.lua
View file @
819847e7
...
@@ -10,7 +10,6 @@ function c73417207.initial_effect(c)
...
@@ -10,7 +10,6 @@ function c73417207.initial_effect(c)
e1
:
SetValue
(
LOCATION_HAND
)
e1
:
SetValue
(
LOCATION_HAND
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
end
end
c73417207
.
tuner_filter
=
aux
.
FALSE
function
c73417207
.
synlimit
(
e
,
c
)
function
c73417207
.
synlimit
(
e
,
c
)
return
c
:
IsSetCard
(
0x42
)
return
c
:
IsSetCard
(
0x42
)
end
end
c73941492.lua
View file @
819847e7
...
@@ -54,9 +54,6 @@ function c73941492.initial_effect(c)
...
@@ -54,9 +54,6 @@ function c73941492.initial_effect(c)
e7
:
SetOperation
(
c73941492
.
spop
)
e7
:
SetOperation
(
c73941492
.
spop
)
c
:
RegisterEffect
(
e7
)
c
:
RegisterEffect
(
e7
)
end
end
function
c73941492
.
tuner_filter
(
c
)
return
c
:
IsSetCard
(
0x98
)
and
c
:
IsType
(
TYPE_PENDULUM
)
end
function
c73941492
.
synlimit
(
e
,
c
)
function
c73941492
.
synlimit
(
e
,
c
)
return
c
:
IsSetCard
(
0x98
)
and
c
:
IsType
(
TYPE_PENDULUM
)
return
c
:
IsSetCard
(
0x98
)
and
c
:
IsType
(
TYPE_PENDULUM
)
end
end
...
...
c74509280.lua
View file @
819847e7
...
@@ -10,7 +10,6 @@ function c74509280.initial_effect(c)
...
@@ -10,7 +10,6 @@ function c74509280.initial_effect(c)
e1
:
SetValue
(
LOCATION_HAND
)
e1
:
SetValue
(
LOCATION_HAND
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
end
end
c74509280
.
tuner_filter
=
aux
.
FALSE
function
c74509280
.
synlimit
(
e
,
c
)
function
c74509280
.
synlimit
(
e
,
c
)
return
c
:
IsSetCard
(
0x23
)
return
c
:
IsSetCard
(
0x23
)
end
end
c7841112.lua
View file @
819847e7
--セイヴァー・スター・ドラゴン
--セイヴァー・スター・ドラゴン
function
c7841112
.
initial_effect
(
c
)
function
c7841112
.
initial_effect
(
c
)
--synchro summon
--synchro summon
aux
.
AddSynchroMixProcedure
(
c
,
c7841112
.
mfilter1
,
c7841112
.
mfilter2
,
nil
,
aux
.
NonTuner
(
nil
),
1
,
1
)
c
:
EnableReviveLimit
()
c
:
EnableReviveLimit
()
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
e1
:
SetProperty
(
EFFECT_FLAG_UNCOPYABLE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetRange
(
LOCATION_EXTRA
)
e1
:
SetCondition
(
c7841112
.
syncon
)
e1
:
SetOperation
(
c7841112
.
synop
)
e1
:
SetValue
(
SUMMON_TYPE_SYNCHRO
)
c
:
RegisterEffect
(
e1
)
--Negate
--Negate
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
7841112
,
0
))
e2
:
SetDescription
(
aux
.
Stringid
(
7841112
,
0
))
...
@@ -55,48 +47,11 @@ function c7841112.initial_effect(c)
...
@@ -55,48 +47,11 @@ function c7841112.initial_effect(c)
e5
:
SetOperation
(
c7841112
.
spop
)
e5
:
SetOperation
(
c7841112
.
spop
)
c
:
RegisterEffect
(
e5
)
c
:
RegisterEffect
(
e5
)
end
end
function
c7841112
.
m
atfilter
(
c
,
syncard
)
function
c7841112
.
m
filter1
(
c
)
return
c
:
Is
Faceup
()
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
return
c
:
Is
Code
(
21159309
)
end
end
function
c7841112
.
synfilter1
(
c
,
syncard
,
lv
,
g
)
function
c7841112
.
mfilter2
(
c
)
return
c
:
IsCode
(
21159309
)
and
g
:
IsExists
(
c7841112
.
synfilter2
,
1
,
c
,
syncard
,
lv
,
g
,
c
)
return
c
:
IsCode
(
44508094
)
end
function
c7841112
.
synfilter2
(
c
,
syncard
,
lv
,
g
,
mc
)
if
not
c
:
IsCode
(
44508094
)
then
return
false
end
if
c
:
IsType
(
TYPE_TUNER
)
==
mc
:
IsType
(
TYPE_TUNER
)
then
return
false
end
local
mg
=
g
:
Filter
(
Card
.
IsNotTuner
,
nil
)
Duel
.
SetSelectedCard
(
Group
.
FromCards
(
c
,
mc
))
return
mg
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
syncard
)
end
function
c7841112
.
syncon
(
e
,
c
,
tuner
)
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
local
mg
=
Duel
.
GetMatchingGroup
(
c7841112
.
matfilter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
lv
=
c
:
GetLevel
()
if
tuner
then
return
c7841112
.
synfilter1
(
tuner
,
c
,
lv
,
mg
)
end
return
mg
:
IsExists
(
c7841112
.
synfilter1
,
1
,
nil
,
c
,
lv
,
mg
)
end
function
c7841112
.
synop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
tuner
)
local
g
=
Group
.
CreateGroup
()
local
mg
=
Duel
.
GetMatchingGroup
(
c7841112
.
matfilter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
lv
=
c
:
GetLevel
()
local
m1
=
tuner
if
not
tuner
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
t1
=
mg
:
FilterSelect
(
tp
,
c7841112
.
synfilter1
,
1
,
1
,
nil
,
c
,
lv
,
mg
)
m1
=
t1
:
GetFirst
()
g
:
AddCard
(
m1
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
t2
=
mg
:
FilterSelect
(
tp
,
c7841112
.
synfilter2
,
1
,
1
,
m1
,
c
,
lv
,
mg
,
m1
)
g
:
Merge
(
t2
)
local
mg2
=
mg
:
Filter
(
Card
.
IsNotTuner
,
nil
)
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
t3
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
c
)
g
:
Merge
(
t3
)
c
:
SetMaterial
(
g
)
Duel
.
SendtoGrave
(
g
,
REASON_MATERIAL
+
REASON_SYNCHRO
)
end
end
function
c7841112
.
negcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c7841112
.
negcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
not
e
:
GetHandler
():
IsStatus
(
STATUS_BATTLE_DESTROYED
)
and
ep
~=
tp
and
Duel
.
IsChainNegatable
(
ev
)
return
not
e
:
GetHandler
():
IsStatus
(
STATUS_BATTLE_DESTROYED
)
and
ep
~=
tp
and
Duel
.
IsChainNegatable
(
ev
)
...
...
c80896940.lua
View file @
819847e7
...
@@ -4,24 +4,13 @@ function c80896940.initial_effect(c)
...
@@ -4,24 +4,13 @@ function c80896940.initial_effect(c)
--pendulum summon
--pendulum summon
aux
.
EnablePendulumAttribute
(
c
,
false
)
aux
.
EnablePendulumAttribute
(
c
,
false
)
--synchro summon
--synchro summon
aux
.
AddSynchroMixProcedure
(
c
,
c80896940
.
matfilter1
,
nil
,
nil
,
aux
.
NonTuner
(
Card
.
IsType
,
TYPE_SYNCHRO
),
1
,
99
)
--no tuner check
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
80896940
,
0
))
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
e1
:
SetCode
(
80896940
)
e1
:
SetProperty
(
EFFECT_FLAG_UNCOPYABLE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetRange
(
LOCATION_EXTRA
)
e1
:
SetCondition
(
aux
.
SynCondition
(
nil
,
aux
.
NonTuner
(
Card
.
IsType
,
TYPE_SYNCHRO
),
1
,
99
))
e1
:
SetTarget
(
aux
.
SynTarget
(
nil
,
aux
.
NonTuner
(
Card
.
IsType
,
TYPE_SYNCHRO
),
1
,
99
))
e1
:
SetOperation
(
aux
.
SynOperation
(
nil
,
aux
.
NonTuner
(
Card
.
IsType
,
TYPE_SYNCHRO
),
1
,
99
))
e1
:
SetValue
(
SUMMON_TYPE_SYNCHRO
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetDescription
(
aux
.
Stringid
(
80896940
,
1
))
e2
:
SetCondition
(
c80896940
.
syncon
)
e2
:
SetTarget
(
c80896940
.
syntg
)
e2
:
SetOperation
(
c80896940
.
synop
)
e2
:
SetValue
(
SUMMON_TYPE_SYNCHRO
)
c
:
RegisterEffect
(
e2
)
--indes
--indes
local
e3
=
Effect
.
CreateEffect
(
c
)
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e3
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
...
@@ -76,99 +65,9 @@ function c80896940.initial_effect(c)
...
@@ -76,99 +65,9 @@ function c80896940.initial_effect(c)
e7
:
SetOperation
(
c80896940
.
penop
)
e7
:
SetOperation
(
c80896940
.
penop
)
c
:
RegisterEffect
(
e7
)
c
:
RegisterEffect
(
e7
)
end
end
function
c80896940
.
matfilter1
(
c
,
syncard
)
function
c80896940
.
matfilter1
(
c
)
return
c
:
IsType
(
TYPE_PENDULUM
)
and
c
:
IsSummonType
(
SUMMON_TYPE_PENDULUM
)
and
c
:
IsNotTuner
()
and
c
:
IsFaceup
()
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
return
c
:
IsType
(
TYPE_TUNER
)
and
Duel
.
IsExistingMatchingCard
(
c80896940
.
matfilter2
,
0
,
LOCATION_MZONE
,
LOCATION_MZONE
,
1
,
c
,
syncard
)
or
(
c
:
IsType
(
TYPE_PENDULUM
)
and
c
:
IsSummonType
(
SUMMON_TYPE_PENDULUM
)
and
c
:
IsNotTuner
())
end
function
c80896940
.
matfilter2
(
c
,
syncard
)
return
c
:
IsNotTuner
()
and
c
:
IsFaceup
()
and
c
:
IsType
(
TYPE_SYNCHRO
)
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
end
function
c80896940
.
synfilter
(
c
,
syncard
,
lv
,
g2
,
minc
)
local
tlv
=
c
:
GetSynchroLevel
(
syncard
)
if
lv
-
tlv
<=
0
then
return
false
end
local
g
=
g2
:
Clone
()
g
:
RemoveCard
(
c
)
return
g
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
lv
-
tlv
,
minc
-
1
,
63
,
syncard
)
end
function
c80896940
.
syncon
(
e
,
c
,
tuner
,
mg
)
if
c
==
nil
then
return
true
end
if
c
:
IsType
(
TYPE_PENDULUM
)
and
c
:
IsFaceup
()
then
return
false
end
local
tp
=
c
:
GetControler
()
local
ct
=-
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
local
minc
=
2
if
minc
<
ct
then
minc
=
ct
end
local
g1
=
nil
local
g2
=
nil
if
mg
then
g1
=
mg
:
Filter
(
c80896940
.
matfilter1
,
nil
,
c
)
g2
=
mg
:
Filter
(
c80896940
.
matfilter2
,
nil
,
c
)
else
g1
=
Duel
.
GetMatchingGroup
(
c80896940
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g2
=
Duel
.
GetMatchingGroup
(
c80896940
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
if
tuner
then
return
c80896940
.
synfilter
(
tuner
,
c
,
lv
,
g2
,
minc
)
end
if
not
pe
then
return
g1
:
IsExists
(
c80896940
.
synfilter
,
1
,
nil
,
c
,
lv
,
g2
,
minc
)
else
return
c80896940
.
synfilter
(
pe
:
GetOwner
(),
c
,
lv
,
g2
,
minc
)
end
end
function
c80896940
.
syntg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
c
,
tuner
,
mg
)
local
g
=
Group
.
CreateGroup
()
local
g1
=
nil
local
g2
=
nil
if
mg
then
g1
=
mg
:
Filter
(
c80896940
.
matfilter1
,
nil
,
c
)
g2
=
mg
:
Filter
(
c80896940
.
matfilter2
,
nil
,
c
)
else
g1
=
Duel
.
GetMatchingGroup
(
c80896940
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g2
=
Duel
.
GetMatchingGroup
(
c80896940
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
end
local
ct
=-
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
local
minc
=
2
if
minc
<
ct
then
minc
=
ct
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
if
tuner
then
g
:
AddCard
(
tuner
)
g2
:
RemoveCard
(
tuner
)
local
lv1
=
tuner
:
GetSynchroLevel
(
c
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
m2
=
g2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
-
lv1
,
minc
-
1
,
63
,
c
)
g
:
Merge
(
m2
)
else
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner
=
nil
if
not
pe
then
local
t1
=
g1
:
FilterSelect
(
tp
,
c80896940
.
synfilter
,
1
,
1
,
nil
,
c
,
lv
,
g2
,
minc
)
tuner
=
t1
:
GetFirst
()
else
tuner
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner
):
Select
(
tp
,
1
,
1
,
nil
)
end
tuner
:
RegisterFlagEffect
(
80896940
,
RESET_EVENT
+
0x1fe0000
,
0
,
1
)
g
:
AddCard
(
tuner
)
g2
:
RemoveCard
(
tuner
)
local
lv1
=
tuner
:
GetSynchroLevel
(
c
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
m2
=
g2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
-
lv1
,
minc
-
1
,
63
,
c
)
g
:
Merge
(
m2
)
end
if
g
then
g
:
KeepAlive
()
e
:
SetLabelObject
(
g
)
return
true
else
return
false
end
end
function
c80896940
.
synop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
tuner
,
mg
)
local
g
=
e
:
GetLabelObject
()
c
:
SetMaterial
(
g
)
Duel
.
SendtoGrave
(
g
,
REASON_MATERIAL
+
REASON_SYNCHRO
)
g
:
DeleteGroup
()
end
end
function
c80896940
.
indcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c80896940
.
indcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
a
=
Duel
.
GetAttacker
()
local
a
=
Duel
.
GetAttacker
()
...
@@ -225,12 +124,11 @@ function c80896940.thop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -225,12 +124,11 @@ function c80896940.thop(e,tp,eg,ep,ev,re,r,rp)
end
end
end
end
function
c80896940
.
mfilter
(
c
)
function
c80896940
.
mfilter
(
c
)
return
c
:
IsType
(
TYPE_PENDULUM
)
and
c
:
IsSummonType
(
SUMMON_TYPE_PENDULUM
)
return
c
:
IsType
(
TYPE_PENDULUM
)
and
c
:
IsSummonType
(
SUMMON_TYPE_PENDULUM
)
and
c
:
IsType
(
TYPE_TUNER
)
and
(
c
:
IsType
(
TYPE_TUNER
)
or
c
:
GetFlagEffect
(
80896940
)
~=
0
)
end
end
function
c80896940
.
valcheck
(
e
,
c
)
function
c80896940
.
valcheck
(
e
,
c
)
local
g
=
c
:
GetMaterial
()
local
g
=
c
:
GetMaterial
()
if
g
:
IsExists
(
c80896940
.
mfilter
,
1
,
nil
)
then
if
c
:
GetFlagEffect
(
80896940
)
~=
0
or
g
:
IsExists
(
c80896940
.
mfilter
,
1
,
nil
)
then
e
:
GetLabelObject
():
SetLabel
(
1
)
e
:
GetLabelObject
():
SetLabel
(
1
)
else
else
e
:
GetLabelObject
():
SetLabel
(
0
)
e
:
GetLabelObject
():
SetLabel
(
0
)
...
...
c89818984.lua
View file @
819847e7
...
@@ -27,6 +27,12 @@ function c89818984.initial_effect(c)
...
@@ -27,6 +27,12 @@ function c89818984.initial_effect(c)
e3
:
SetValue
(
1
)
e3
:
SetValue
(
1
)
e3
:
SetOperation
(
c89818984
.
synop
)
e3
:
SetOperation
(
c89818984
.
synop
)
c
:
RegisterEffect
(
e3
)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e4
:
SetCode
(
89818984
)
e4
:
SetRange
(
LOCATION_MZONE
)
c
:
RegisterEffect
(
e4
)
end
end
function
c89818984
.
hspfilter
(
c
,
ft
,
tp
)
function
c89818984
.
hspfilter
(
c
,
ft
,
tp
)
return
c
:
IsSetCard
(
0xe6
)
and
c
:
GetLevel
()
==
11
and
not
c
:
IsCode
(
89818984
)
return
c
:
IsSetCard
(
0xe6
)
and
c
:
GetLevel
()
==
11
and
not
c
:
IsCode
(
89818984
)
...
...
c9047460.lua
View file @
819847e7
...
@@ -64,7 +64,6 @@ function c9047460.spop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -64,7 +64,6 @@ function c9047460.spop(e,tp,eg,ep,ev,re,r,rp)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
end
end
end
end
c9047460
.
tuner_filter
=
aux
.
FilterBoolFunction
(
Card
.
IsSetCard
,
0x33
)
function
c9047460
.
synlimit
(
e
,
c
)
function
c9047460
.
synlimit
(
e
,
c
)
return
c
:
IsSetCard
(
0x33
)
return
c
:
IsSetCard
(
0x33
)
end
end
c93157004.lua
View file @
819847e7
--ヴァイロン・オメガ
--ヴァイロン・オメガ
function
c93157004
.
initial_effect
(
c
)
function
c93157004
.
initial_effect
(
c
)
--synchro summon
--synchro summon
aux
.
AddSynchroMixProcedure
(
c
,
aux
.
Tuner
(
nil
),
aux
.
Tuner
(
nil
),
nil
,
aux
.
NonTuner
(
Card
.
IsSetCard
,
0x30
),
1
,
1
)
c
:
EnableReviveLimit
()
c
:
EnableReviveLimit
()
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
e1
:
SetProperty
(
EFFECT_FLAG_UNCOPYABLE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetRange
(
LOCATION_EXTRA
)
e1
:
SetCondition
(
c93157004
.
syncon
)
e1
:
SetOperation
(
c93157004
.
synop
)
e1
:
SetValue
(
SUMMON_TYPE_SYNCHRO
)
c
:
RegisterEffect
(
e1
)
--destroy
--destroy
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetDescription
(
aux
.
Stringid
(
93157004
,
0
))
e2
:
SetDescription
(
aux
.
Stringid
(
93157004
,
0
))
...
@@ -51,155 +43,6 @@ function c93157004.initial_effect(c)
...
@@ -51,155 +43,6 @@ function c93157004.initial_effect(c)
e5
:
SetCode
(
21142671
)
e5
:
SetCode
(
21142671
)
c
:
RegisterEffect
(
e5
)
c
:
RegisterEffect
(
e5
)
end
end
function
c93157004
.
matfilter1
(
c
,
syncard
)
return
c
:
IsType
(
TYPE_TUNER
)
and
(
c
:
IsLocation
(
LOCATION_HAND
)
or
c
:
IsFaceup
())
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
end
function
c93157004
.
matfilter2
(
c
,
syncard
)
return
c
:
IsNotTuner
()
and
(
c
:
IsLocation
(
LOCATION_HAND
)
or
c
:
IsFaceup
())
and
c
:
IsSetCard
(
0x30
)
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
end
function
c93157004
.
synfilter1
(
c
,
syncard
,
lv
,
g1
,
g2
,
g3
,
g4
)
local
f1
=
c
.
tuner_filter
if
c
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
return
g3
:
IsExists
(
c93157004
.
synfilter2
,
1
,
c
,
syncard
,
lv
,
g2
,
g4
,
f1
,
c
)
else
return
g1
:
IsExists
(
c93157004
.
synfilter2
,
1
,
c
,
syncard
,
lv
,
g2
,
g4
,
f1
,
c
)
end
end
function
c93157004
.
synfilter2
(
c
,
syncard
,
lv
,
g2
,
g4
,
f1
,
tuner1
)
if
c
==
tuner1
then
return
false
end
local
f2
=
c
.
tuner_filter
if
f1
and
not
f1
(
c
)
then
return
false
end
if
f2
and
not
f2
(
tuner1
)
then
return
false
end
Duel
.
SetSelectedCard
(
Group
.
FromCards
(
c
,
tuner1
))
if
(
tuner1
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
and
not
c
:
IsLocation
(
LOCATION_HAND
))
or
c
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
local
mg
=
g4
:
Filter
(
c93157004
.
synfilter3
,
nil
,
f1
,
f2
)
return
mg
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
syncard
)
else
local
mg
=
g2
:
Filter
(
c93157004
.
synfilter3
,
nil
,
f1
,
f2
)
return
mg
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
syncard
)
end
end
function
c93157004
.
synfilter3
(
c
,
f1
,
f2
)
return
(
not
f1
or
f1
(
c
))
and
(
not
f2
or
f2
(
c
))
end
function
c93157004
.
syncon
(
e
,
c
,
tuner
,
mg
)
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<-
2
then
return
false
end
local
g1
=
nil
local
g2
=
nil
local
g3
=
nil
local
g4
=
nil
if
mg
then
g1
=
mg
:
Filter
(
c93157004
.
matfilter1
,
nil
,
c
)
g2
=
mg
:
Filter
(
c93157004
.
matfilter2
,
nil
,
c
)
g3
=
g1
:
Clone
()
g4
=
g2
:
Clone
()
else
g1
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g2
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g3
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter1
,
tp
,
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
,
nil
,
c
)
g4
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter2
,
tp
,
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
,
nil
,
c
)
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
if
tuner
then
local
f1
=
tuner
.
tuner_filter
if
not
pe
then
return
g1
:
IsExists
(
c93157004
.
synfilter2
,
1
,
tuner
,
c
,
lv
,
g2
,
g4
,
f1
,
tuner
)
else
return
c93157004
.
synfilter2
(
pe
:
GetOwner
(),
c
,
lv
,
g2
,
nil
,
f1
,
tuner
)
end
end
if
not
pe
then
return
g1
:
IsExists
(
c93157004
.
synfilter1
,
1
,
nil
,
c
,
lv
,
g1
,
g2
,
g3
,
g4
)
else
return
c93157004
.
synfilter1
(
pe
:
GetOwner
(),
c
,
lv
,
g1
,
g2
,
g3
,
g4
)
end
end
function
c93157004
.
synop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
tuner
,
mg
)
local
g
=
Group
.
CreateGroup
()
local
g1
=
nil
local
g2
=
nil
local
g3
=
nil
local
g4
=
nil
if
mg
then
g1
=
mg
:
Filter
(
c93157004
.
matfilter1
,
nil
,
c
)
g2
=
mg
:
Filter
(
c93157004
.
matfilter2
,
nil
,
c
)
g3
=
g1
:
Clone
()
g4
=
g2
:
Clone
()
else
g1
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g2
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g3
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter1
,
tp
,
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
,
nil
,
c
)
g4
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter2
,
tp
,
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
,
nil
,
c
)
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
if
tuner
then
g
:
AddCard
(
tuner
)
local
f1
=
tuner
.
tuner_filter
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner2
=
nil
if
not
pe
then
local
t2
=
g1
:
FilterSelect
(
tp
,
c93157004
.
synfilter2
,
1
,
1
,
tuner
,
c
,
lv
,
g2
,
g4
,
f1
,
tuner
)
tuner2
=
t2
:
GetFirst
()
else
tuner2
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner2
):
Select
(
tp
,
1
,
1
,
nil
)
end
g
:
AddCard
(
tuner2
)
local
f2
=
tuner2
.
tuner_filter
local
m3
=
nil
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
if
tuner2
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
local
mg4
=
g4
:
Filter
(
c93157004
.
synfilter3
,
nil
,
f1
,
f2
)
m3
=
mg4
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
c
)
else
local
mg2
=
g2
:
Filter
(
c93157004
.
synfilter3
,
nil
,
f1
,
f2
)
m3
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
c
)
end
g
:
Merge
(
m3
)
else
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner1
=
nil
if
not
pe
then
local
t1
=
g1
:
FilterSelect
(
tp
,
c93157004
.
synfilter1
,
1
,
1
,
nil
,
c
,
lv
,
g1
,
g2
,
g3
,
g4
)
tuner1
=
t1
:
GetFirst
()
else
tuner1
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner1
):
Select
(
tp
,
1
,
1
,
nil
)
end
g
:
AddCard
(
tuner1
)
local
f1
=
tuner1
.
tuner_filter
local
tuner2
=
nil
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
if
tuner1
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
local
t2
=
g3
:
FilterSelect
(
tp
,
c93157004
.
synfilter2
,
1
,
1
,
tuner1
,
c
,
lv
,
g2
,
g4
,
f1
,
tuner1
)
tuner2
=
t2
:
GetFirst
()
else
local
t2
=
g1
:
FilterSelect
(
tp
,
c93157004
.
synfilter2
,
1
,
1
,
tuner1
,
c
,
lv
,
g2
,
g4
,
f1
,
tuner1
)
tuner2
=
t2
:
GetFirst
()
end
g
:
AddCard
(
tuner2
)
local
f2
=
tuner2
.
tuner_filter
local
m3
=
nil
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
if
(
tuner1
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
and
not
tuner2
:
IsLocation
(
LOCATION_HAND
))
or
tuner2
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
local
mg4
=
g4
:
Filter
(
c93157004
.
synfilter3
,
nil
,
f1
,
f2
)
m3
=
mg4
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
c
)
else
local
mg2
=
g2
:
Filter
(
c93157004
.
synfilter3
,
nil
,
f1
,
f2
)
m3
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
c
)
end
g
:
Merge
(
m3
)
end
c
:
SetMaterial
(
g
)
Duel
.
SendtoGrave
(
g
,
REASON_MATERIAL
+
REASON_SYNCHRO
)
end
function
c93157004
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c93157004
.
descon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_SYNCHRO
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_SYNCHRO
)
end
end
...
...
c93369354.lua
View file @
819847e7
...
@@ -40,7 +40,6 @@ function c93369354.spop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -40,7 +40,6 @@ function c93369354.spop(e,tp,eg,ep,ev,re,r,rp)
if
not
c
:
IsRelateToEffect
(
e
)
then
return
end
if
not
c
:
IsRelateToEffect
(
e
)
then
return
end
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
end
end
c93369354
.
tuner_filter
=
aux
.
FilterBoolFunction
(
Card
.
IsAttribute
,
ATTRIBUTE_WATER
)
function
c93369354
.
synlimit
(
e
,
c
)
function
c93369354
.
synlimit
(
e
,
c
)
return
c
:
IsAttribute
(
ATTRIBUTE_WATER
)
return
c
:
IsAttribute
(
ATTRIBUTE_WATER
)
end
end
c97489701.lua
View file @
819847e7
--スカーレッド・ノヴァ・ドラゴン
--スカーレッド・ノヴァ・ドラゴン
function
c97489701
.
initial_effect
(
c
)
function
c97489701
.
initial_effect
(
c
)
--synchro summon
--synchro summon
aux
.
AddSynchroMixProcedure
(
c
,
aux
.
Tuner
(
nil
),
aux
.
Tuner
(
nil
),
nil
,
aux
.
NonTuner
(
Card
.
IsCode
,
70902743
),
1
,
1
)
c
:
EnableReviveLimit
()
c
:
EnableReviveLimit
()
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
e1
:
SetProperty
(
EFFECT_FLAG_UNCOPYABLE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetRange
(
LOCATION_EXTRA
)
e1
:
SetCondition
(
c97489701
.
syncon
)
e1
:
SetOperation
(
c97489701
.
synop
)
e1
:
SetValue
(
SUMMON_TYPE_SYNCHRO
)
c
:
RegisterEffect
(
e1
)
--atk
--atk
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
e2
:
SetType
(
EFFECT_TYPE_SINGLE
)
...
@@ -58,152 +50,6 @@ function c97489701.initial_effect(c)
...
@@ -58,152 +50,6 @@ function c97489701.initial_effect(c)
e6
:
SetCode
(
21142671
)
e6
:
SetCode
(
21142671
)
c
:
RegisterEffect
(
e6
)
c
:
RegisterEffect
(
e6
)
end
end
function
c97489701
.
matfilter1
(
c
,
syncard
)
return
c
:
IsType
(
TYPE_TUNER
)
and
(
c
:
IsLocation
(
LOCATION_HAND
)
or
c
:
IsFaceup
())
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
end
function
c97489701
.
matfilter2
(
c
,
syncard
)
return
c
:
IsFaceup
()
and
c
:
IsCode
(
70902743
)
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
end
function
c97489701
.
synfilter1
(
c
,
syncard
,
lv
,
g1
,
g2
,
g3
,
mc
)
local
f1
=
c
.
tuner_filter
if
mc
then
if
f1
and
not
f1
(
mc
)
then
return
false
end
local
mg
=
g1
:
Filter
(
c97489701
.
synfilter4
,
nil
,
f1
,
mc
)
Duel
.
SetSelectedCard
(
Group
.
FromCards
(
c
,
mc
))
return
mg
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
syncard
)
end
if
c
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
return
g3
:
IsExists
(
c97489701
.
synfilter2
,
1
,
c
,
syncard
,
lv
,
g2
,
f1
,
c
)
else
return
g1
:
IsExists
(
c97489701
.
synfilter2
,
1
,
c
,
syncard
,
lv
,
g2
,
f1
,
c
)
end
end
function
c97489701
.
synfilter2
(
c
,
syncard
,
lv
,
g2
,
f1
,
tuner1
)
local
f2
=
c
.
tuner_filter
if
f1
and
not
f1
(
c
)
then
return
false
end
if
f2
and
not
f2
(
tuner1
)
then
return
false
end
local
mg
=
g2
:
Filter
(
c97489701
.
synfilter3
,
nil
,
f1
,
f2
)
Duel
.
SetSelectedCard
(
Group
.
FromCards
(
c
,
tuner1
))
return
mg
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
syncard
)
end
function
c97489701
.
synfilter3
(
c
,
f1
,
f2
)
return
(
not
f1
or
f1
(
c
))
and
(
not
f2
or
f2
(
c
))
end
function
c97489701
.
synfilter4
(
c
,
f1
,
mc
)
local
f2
=
c
.
tuner_filter
return
(
not
f1
or
f1
(
c
))
and
(
not
f2
or
f2
(
mc
))
end
function
c97489701
.
syncon
(
e
,
c
,
tuner
,
mg
)
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<-
2
then
return
false
end
if
tuner
then
if
not
tuner
:
IsCanBeSynchroMaterial
(
c
)
then
return
false
end
if
not
(
tuner
:
IsType
(
TYPE_TUNER
)
or
tuner
:
IsCode
(
70902743
))
then
return
false
end
end
local
g1
=
nil
local
g2
=
nil
local
g3
=
nil
if
mg
then
g1
=
mg
:
Filter
(
c97489701
.
matfilter1
,
nil
,
c
)
g2
=
mg
:
Filter
(
c97489701
.
matfilter2
,
nil
,
c
)
g3
=
g1
:
Clone
()
else
g1
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g2
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g3
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter1
,
tp
,
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
,
nil
,
c
)
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
if
tuner
and
tuner
:
IsType
(
TYPE_TUNER
)
then
local
f1
=
tuner
.
tuner_filter
if
not
pe
then
return
g1
:
IsExists
(
c97489701
.
synfilter2
,
1
,
tuner
,
c
,
lv
,
g2
,
f1
,
tuner
)
else
return
c97489701
.
synfilter2
(
pe
:
GetOwner
(),
c
,
lv
,
g2
,
f1
,
tuner
)
end
end
if
not
pe
then
return
g1
:
IsExists
(
c97489701
.
synfilter1
,
1
,
nil
,
c
,
lv
,
g1
,
g2
,
g3
,
tuner
)
else
return
c97489701
.
synfilter1
(
pe
:
GetOwner
(),
c
,
lv
,
g1
,
g2
,
g3
,
tuner
)
end
end
function
c97489701
.
synop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
tuner
,
mg
)
local
g
=
Group
.
CreateGroup
()
local
g1
=
nil
local
g2
=
nil
local
g3
=
nil
if
mg
then
g1
=
mg
:
Filter
(
c97489701
.
matfilter1
,
nil
,
c
)
g2
=
mg
:
Filter
(
c97489701
.
matfilter2
,
nil
,
c
)
g3
=
g1
:
Clone
()
else
g1
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g2
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
g3
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter1
,
tp
,
LOCATION_MZONE
+
LOCATION_HAND
,
LOCATION_MZONE
,
nil
,
c
)
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
if
tuner
and
tuner
:
IsType
(
TYPE_TUNER
)
then
g
:
AddCard
(
tuner
)
local
f1
=
tuner
.
tuner_filter
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner2
=
nil
if
not
pe
then
local
t2
=
g1
:
FilterSelect
(
tp
,
c97489701
.
synfilter2
,
1
,
1
,
tuner
,
c
,
lv
,
g2
,
f1
,
tuner
)
tuner2
=
t2
:
GetFirst
()
else
tuner2
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner2
):
Select
(
tp
,
1
,
1
,
nil
)
end
g
:
AddCard
(
tuner2
)
local
f2
=
tuner2
.
tuner_filter
local
mg2
=
g2
:
Filter
(
c97489701
.
synfilter3
,
nil
,
f1
,
f2
)
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
m3
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
c
)
g
:
Merge
(
m3
)
else
if
tuner
then
g
:
AddCard
(
tuner
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner1
=
nil
if
not
pe
then
local
t1
=
g1
:
FilterSelect
(
tp
,
c97489701
.
synfilter1
,
1
,
1
,
nil
,
c
,
lv
,
g1
,
g2
,
g3
,
tuner
)
tuner1
=
t1
:
GetFirst
()
else
tuner1
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner1
):
Select
(
tp
,
1
,
1
,
nil
)
end
g
:
AddCard
(
tuner1
)
local
f1
=
tuner1
.
tuner_filter
if
tuner
then
local
mg2
=
g1
:
Filter
(
c97489701
.
synfilter4
,
nil
,
f1
,
tuner
)
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
m3
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
c
)
g
:
Merge
(
m3
)
else
local
t2
=
nil
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
if
tuner1
:
IsHasEffect
(
EFFECT_HAND_SYNCHRO
)
then
t2
=
g3
:
FilterSelect
(
tp
,
c97489701
.
synfilter2
,
1
,
1
,
tuner1
,
c
,
lv
,
g2
,
f1
,
tuner1
)
else
t2
=
g1
:
FilterSelect
(
tp
,
c97489701
.
synfilter2
,
1
,
1
,
tuner1
,
c
,
lv
,
g2
,
f1
,
tuner1
)
end
local
tuner2
=
t2
:
GetFirst
()
g
:
AddCard
(
tuner2
)
local
f2
=
tuner2
.
tuner_filter
local
mg2
=
g2
:
Filter
(
c97489701
.
synfilter3
,
nil
,
f1
,
f2
)
Duel
.
SetSelectedCard
(
g
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
m3
=
mg2
:
SelectWithSumEqual
(
tp
,
Card
.
GetSynchroLevel
,
lv
,
1
,
1
,
c
)
g
:
Merge
(
m3
)
end
end
c
:
SetMaterial
(
g
)
Duel
.
SendtoGrave
(
g
,
REASON_MATERIAL
+
REASON_SYNCHRO
)
end
function
c97489701
.
atkval
(
e
,
c
)
function
c97489701
.
atkval
(
e
,
c
)
return
Duel
.
GetMatchingGroupCount
(
Card
.
IsType
,
c
:
GetControler
(),
LOCATION_GRAVE
,
0
,
nil
,
TYPE_TUNER
)
*
500
return
Duel
.
GetMatchingGroupCount
(
Card
.
IsType
,
c
:
GetControler
(),
LOCATION_GRAVE
,
0
,
nil
,
TYPE_TUNER
)
*
500
end
end
...
...
constant.lua
View file @
819847e7
...
@@ -63,7 +63,7 @@ ATTRIBUTE_LIGHT =0x10 --光
...
@@ -63,7 +63,7 @@ ATTRIBUTE_LIGHT =0x10 --光
ATTRIBUTE_DARK
=
0x20
--暗
ATTRIBUTE_DARK
=
0x20
--暗
ATTRIBUTE_DEVINE
=
0x40
--神
ATTRIBUTE_DEVINE
=
0x40
--神
--Races 种族
--Races 种族
RACE_ALL
=
0x1ffffff
--全种族
RACE_ALL
=
0x1ffffff
--全种族
RACE_WARRIOR
=
0x1
--战士
RACE_WARRIOR
=
0x1
--战士
RACE_SPELLCASTER
=
0x2
--魔法师
RACE_SPELLCASTER
=
0x2
--魔法师
RACE_FAIRY
=
0x4
--天使
RACE_FAIRY
=
0x4
--天使
...
@@ -88,7 +88,7 @@ RACE_PSYCHO =0x100000 --念动力
...
@@ -88,7 +88,7 @@ RACE_PSYCHO =0x100000 --念动力
RACE_DEVINE
=
0x200000
--幻神兽
RACE_DEVINE
=
0x200000
--幻神兽
RACE_CREATORGOD
=
0x400000
--创造神
RACE_CREATORGOD
=
0x400000
--创造神
RACE_WYRM
=
0x800000
--幻龙
RACE_WYRM
=
0x800000
--幻龙
RACE_CYBERSE
=
0x1000000
--电子界
RACE_CYBERSE
=
0x1000000
--电子界
--Reason 卡片到当前位置的原因
--Reason 卡片到当前位置的原因
REASON_DESTROY
=
0x1
--破坏
REASON_DESTROY
=
0x1
--破坏
REASON_RELEASE
=
0x2
--解放
REASON_RELEASE
=
0x2
--解放
...
@@ -116,7 +116,7 @@ REASON_REPLACE =0x1000000 --代替
...
@@ -116,7 +116,7 @@ REASON_REPLACE =0x1000000 --代替
REASON_DRAW
=
0x2000000
--抽卡
REASON_DRAW
=
0x2000000
--抽卡
REASON_REDIRECT
=
0x4000000
--改变去向(大宇宙,带菌等)
REASON_REDIRECT
=
0x4000000
--改变去向(大宇宙,带菌等)
REASON_REVEAL
=
0x8000000
--翻开卡组(森罗)
REASON_REVEAL
=
0x8000000
--翻开卡组(森罗)
REASON_LINK
=
0x10000000
--用于连接召唤
REASON_LINK
=
0x10000000
--用于连接召唤
--Location Reason
--Location Reason
LOCATION_REASON_TOFIELD
=
0x1
--Duel.GetLocationCount()預設值,凱薩競技場
LOCATION_REASON_TOFIELD
=
0x1
--Duel.GetLocationCount()預設值,凱薩競技場
LOCATION_REASON_CONTROL
=
0x2
--Card.IsControlerCanBeChanged()使用
LOCATION_REASON_CONTROL
=
0x2
--Card.IsControlerCanBeChanged()使用
...
@@ -131,7 +131,7 @@ SUMMON_TYPE_RITUAL =0x45000000 --仪式召唤
...
@@ -131,7 +131,7 @@ SUMMON_TYPE_RITUAL =0x45000000 --仪式召唤
SUMMON_TYPE_SYNCHRO
=
0x46000000
--同调召唤
SUMMON_TYPE_SYNCHRO
=
0x46000000
--同调召唤
SUMMON_TYPE_XYZ
=
0x49000000
--超量召唤
SUMMON_TYPE_XYZ
=
0x49000000
--超量召唤
SUMMON_TYPE_PENDULUM
=
0x4a000000
--灵摆召唤
SUMMON_TYPE_PENDULUM
=
0x4a000000
--灵摆召唤
SUMMON_TYPE_LINK
=
0x4c000000
--连接召唤
SUMMON_TYPE_LINK
=
0x4c000000
--连接召唤
--Status --卡片当前状态
--Status --卡片当前状态
STATUS_DISABLED
=
0x0001
--效果被无效
STATUS_DISABLED
=
0x0001
--效果被无效
STATUS_TO_ENABLE
=
0x0002
--将变成有效
STATUS_TO_ENABLE
=
0x0002
--将变成有效
...
@@ -214,7 +214,7 @@ CHAININFO_DISABLE_PLAYER =0x400 --无效的玩家
...
@@ -214,7 +214,7 @@ CHAININFO_DISABLE_PLAYER =0x400 --无效的玩家
CHAININFO_CHAIN_ID
=
0x800
--连锁ID
CHAININFO_CHAIN_ID
=
0x800
--连锁ID
CHAININFO_TYPE
=
0x1000
--连锁类型
CHAININFO_TYPE
=
0x1000
--连锁类型
CHAININFO_EXTTYPE
=
0x2000
--连锁额外类型
CHAININFO_EXTTYPE
=
0x2000
--连锁额外类型
CHAININFO_TRIGGERING_POSITION
=
0x4000
--连锁
的表示形式
CHAININFO_TRIGGERING_POSITION
=
0x4000
--连锁发生时
的表示形式
--========== Reset ========== --重置条件(注意:重置条件可以多个相加)
--========== Reset ========== --重置条件(注意:重置条件可以多个相加)
RESET_SELF_TURN
=
0x10000000
--自己回合的階段重置
RESET_SELF_TURN
=
0x10000000
--自己回合的階段重置
RESET_OPPO_TURN
=
0x20000000
--对方回合的階段重置
RESET_OPPO_TURN
=
0x20000000
--对方回合的階段重置
...
@@ -418,7 +418,7 @@ EFFECT_DECREASE_TRIBUTE_SET =152 --减少放置怪兽的祭品
...
@@ -418,7 +418,7 @@ EFFECT_DECREASE_TRIBUTE_SET =152 --减少放置怪兽的祭品
EFFECT_EXTRA_RELEASE
=
153
--必須使用的代替解放(灵魂交错)
EFFECT_EXTRA_RELEASE
=
153
--必須使用的代替解放(灵魂交错)
EFFECT_TRIBUTE_LIMIT
=
154
--祭品限制
EFFECT_TRIBUTE_LIMIT
=
154
--祭品限制
EFFECT_EXTRA_RELEASE_SUM
=
155
--代替召唤解放(帝王的烈旋)
EFFECT_EXTRA_RELEASE_SUM
=
155
--代替召唤解放(帝王的烈旋)
EFFECT_TRIPLE_TRIBUTE
=
156
EFFECT_TRIPLE_TRIBUTE
=
156
--N/A
EFFECT_PUBLIC
=
160
--公开手牌
EFFECT_PUBLIC
=
160
--公开手牌
EFFECT_COUNTER_PERMIT
=
0x10000
--允许放置指示物类型
EFFECT_COUNTER_PERMIT
=
0x10000
--允许放置指示物类型
EFFECT_COUNTER_LIMIT
=
0x20000
--允许放置指示物数量
EFFECT_COUNTER_LIMIT
=
0x20000
--允许放置指示物数量
...
@@ -457,7 +457,7 @@ EFFECT_XYZ_MATERIAL =233 --可以当作超量素材
...
@@ -457,7 +457,7 @@ EFFECT_XYZ_MATERIAL =233 --可以当作超量素材
EFFECT_FUSION_SUBSTITUTE
=
234
--代替融合素材
EFFECT_FUSION_SUBSTITUTE
=
234
--代替融合素材
EFFECT_CANNOT_BE_FUSION_MATERIAL
=
235
--不能做融合素材
EFFECT_CANNOT_BE_FUSION_MATERIAL
=
235
--不能做融合素材
EFFECT_CANNOT_BE_SYNCHRO_MATERIAL
=
236
--不能做同调素材
EFFECT_CANNOT_BE_SYNCHRO_MATERIAL
=
236
--不能做同调素材
EFFECT_SYNCHRO_MATERIAL_CUSTOM
=
237
--
同调素材限制
EFFECT_SYNCHRO_MATERIAL_CUSTOM
=
237
--
自定义Tuner的同调过程
EFFECT_CANNOT_BE_XYZ_MATERIAL
=
238
--不能做超量素材
EFFECT_CANNOT_BE_XYZ_MATERIAL
=
238
--不能做超量素材
EFFECT_CANNOT_BE_LINK_MATERIAL
=
239
--不能做连接素材
EFFECT_CANNOT_BE_LINK_MATERIAL
=
239
--不能做连接素材
EFFECT_SYNCHRO_LEVEL
=
240
--做同调素材时的等级
EFFECT_SYNCHRO_LEVEL
=
240
--做同调素材时的等级
...
@@ -518,8 +518,8 @@ EFFECT_OLDUNION_STATUS =348 --旧同盟状态
...
@@ -518,8 +518,8 @@ EFFECT_OLDUNION_STATUS =348 --旧同盟状态
EFFECT_ADD_FUSION_ATTRIBUTE
=
349
--reserve
EFFECT_ADD_FUSION_ATTRIBUTE
=
349
--reserve
EFFECT_REMOVE_FUSION_ATTRIBUTE
=
350
--reserve
EFFECT_REMOVE_FUSION_ATTRIBUTE
=
350
--reserve
EFFECT_CHANGE_FUSION_ATTRIBUTE
=
351
--用作融合素材时的属性
EFFECT_CHANGE_FUSION_ATTRIBUTE
=
351
--用作融合素材时的属性
EFFECT_EXTRA_FUSION_MATERIAL
=
352
--
EFFECT_EXTRA_FUSION_MATERIAL
=
352
--
增加融合素材(万溶炼金师)
EFFECT_TUNER_MATERIAL_LIMIT
=
353
--
EFFECT_TUNER_MATERIAL_LIMIT
=
353
--同调素材限制
--下面是诱发效果的诱发事件、时点 (如果是TYPE_SINGLE则自己发生以下事件后触发,如果TYPE_FIELD则场上任何卡发生以下事件都触发)
--下面是诱发效果的诱发事件、时点 (如果是TYPE_SINGLE则自己发生以下事件后触发,如果TYPE_FIELD则场上任何卡发生以下事件都触发)
EVENT_STARTUP
=
1000
--游戏开始时
EVENT_STARTUP
=
1000
--游戏开始时
...
@@ -621,7 +621,7 @@ CATEGORY_LEAVE_GRAVE =0x4000000 --离开墓地效果
...
@@ -621,7 +621,7 @@ CATEGORY_LEAVE_GRAVE =0x4000000 --离开墓地效果
CATEGORY_LVCHANGE
=
0x8000000
--改变等级效果
CATEGORY_LVCHANGE
=
0x8000000
--改变等级效果
CATEGORY_NEGATE
=
0x10000000
--使发动无效效果
CATEGORY_NEGATE
=
0x10000000
--使发动无效效果
CATEGORY_ANNOUNCE
=
0x20000000
--發動時宣言卡名的效果
CATEGORY_ANNOUNCE
=
0x20000000
--發動時宣言卡名的效果
CATEGORY_FUSION_SUMMON
=
0x40000000
--融合召唤效果(暴走魔法阵)
CATEGORY_FUSION_SUMMON
=
0x40000000
--融合召唤效果(暴走魔法阵)
--Hint
--Hint
HINT_EVENT
=
1
HINT_EVENT
=
1
HINT_MESSAGE
=
2
HINT_MESSAGE
=
2
...
@@ -745,7 +745,7 @@ GLOBALFLAG_SPSUMMON_COUNT =0x40 --玩家的特殊召唤次数限制
...
@@ -745,7 +745,7 @@ GLOBALFLAG_SPSUMMON_COUNT =0x40 --玩家的特殊召唤次数限制
GLOBALFLAG_XMAT_COUNT_LIMIT
=
0x80
--超量素材数量限制标记(光天使 天座)
GLOBALFLAG_XMAT_COUNT_LIMIT
=
0x80
--超量素材数量限制标记(光天使 天座)
GLOBALFLAG_SELF_TOGRAVE
=
0x100
--不入連鎖的送墓檢查(EFFECT_SELF_TOGRAVE)
GLOBALFLAG_SELF_TOGRAVE
=
0x100
--不入連鎖的送墓檢查(EFFECT_SELF_TOGRAVE)
GLOBALFLAG_SPSUMMON_ONCE
=
0x200
--1回合只能特殊召喚1次(Card.SetSPSummonOnce())
GLOBALFLAG_SPSUMMON_ONCE
=
0x200
--1回合只能特殊召喚1次(Card.SetSPSummonOnce())
GLOBALFLAG_TUNE_MAGICIAN
=
0x400
--
GLOBALFLAG_TUNE_MAGICIAN
=
0x400
--
超量素材检查标记(调弦之魔术师)
--count_code
--count_code
EFFECT_COUNT_CODE_OATH
=
0x10000000
--发动次数限制(誓约次数, 发动被无效不计数)
EFFECT_COUNT_CODE_OATH
=
0x10000000
--发动次数限制(誓约次数, 发动被无效不计数)
EFFECT_COUNT_CODE_DUEL
=
0x20000000
--决斗中使用次数
EFFECT_COUNT_CODE_DUEL
=
0x20000000
--决斗中使用次数
...
@@ -770,7 +770,7 @@ ACTIVITY_BATTLE_PHASE =6 -- not available in custom counter
...
@@ -770,7 +770,7 @@ ACTIVITY_BATTLE_PHASE =6 -- not available in custom counter
ACTIVITY_CHAIN
=
7
-- only available in custom counter
ACTIVITY_CHAIN
=
7
-- only available in custom counter
--announce type(宣言类型,CATEGORY_ANNOUNCE的OperationInfo的target_param)
--announce type(宣言类型,CATEGORY_ANNOUNCE的OperationInfo的target_param)
ANNOUNCE_CARD
=
0x7
--宣言卡片
ANNOUNCE_CARD
=
0x7
--宣言卡片
ANNOUNCE_CARD_FILTER
=
0x8
--
ANNOUNCE_CARD_FILTER
=
0x8
--宣言符合条件的卡片
--cards with double names
--cards with double names
CARD_MARINE_DOLPHIN
=
78734254
--海洋海豚
CARD_MARINE_DOLPHIN
=
78734254
--海洋海豚
CARD_TWINKLE_MOSS
=
13857930
--光輝苔蘚
CARD_TWINKLE_MOSS
=
13857930
--光輝苔蘚
utility.lua
View file @
819847e7
...
@@ -181,6 +181,11 @@ function Auxiliary.FilterBoolFunction(f,a,b,c)
...
@@ -181,6 +181,11 @@ function Auxiliary.FilterBoolFunction(f,a,b,c)
return
f
(
target
,
a
,
b
,
c
)
return
f
(
target
,
a
,
b
,
c
)
end
end
end
end
function
Auxiliary
.
Tuner
(
f
,
a
,
b
,
c
)
return
function
(
target
)
return
target
:
IsType
(
TYPE_TUNER
)
and
(
not
f
or
f
(
target
,
a
,
b
,
c
))
end
end
function
Auxiliary
.
NonTuner
(
f
,
a
,
b
,
c
)
function
Auxiliary
.
NonTuner
(
f
,
a
,
b
,
c
)
return
function
(
target
)
return
function
(
target
)
return
target
:
IsNotTuner
()
and
(
not
f
or
f
(
target
,
a
,
b
,
c
))
return
target
:
IsNotTuner
()
and
(
not
f
or
f
(
target
,
a
,
b
,
c
))
...
@@ -237,6 +242,198 @@ end
...
@@ -237,6 +242,198 @@ end
function
Auxiliary
.
AddSynchroProcedure2
(
c
,
f1
,
f2
)
function
Auxiliary
.
AddSynchroProcedure2
(
c
,
f1
,
f2
)
Auxiliary
.
AddSynchroProcedure
(
c
,
f1
,
f2
,
1
,
1
)
Auxiliary
.
AddSynchroProcedure
(
c
,
f1
,
f2
,
1
,
1
)
end
end
--Synchro monster, f1~f3 each 1 MONSTER + f4 min to max monsters
function
Auxiliary
.
AddSynchroMixProcedure
(
c
,
f1
,
f2
,
f3
,
f4
,
minc
,
maxc
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
e1
:
SetProperty
(
EFFECT_FLAG_UNCOPYABLE
+
EFFECT_FLAG_IGNORE_IMMUNE
)
e1
:
SetRange
(
LOCATION_EXTRA
)
e1
:
SetCondition
(
Auxiliary
.
SynMixCondition
(
f1
,
f2
,
f3
,
f4
,
minc
,
maxc
))
e1
:
SetTarget
(
Auxiliary
.
SynMixTarget
(
f1
,
f2
,
f3
,
f4
,
minc
,
maxc
))
e1
:
SetOperation
(
Auxiliary
.
SynMixOperation
(
f1
,
f2
,
f3
,
f4
,
minc
,
maxc
))
e1
:
SetValue
(
SUMMON_TYPE_SYNCHRO
)
c
:
RegisterEffect
(
e1
)
end
function
Auxiliary
.
SynMaterialFilter
(
c
,
syncard
)
return
c
:
IsFaceup
()
and
c
:
IsCanBeSynchroMaterial
(
syncard
)
end
function
Auxiliary
.
SynLimitFilter
(
c
,
f
,
e
)
return
f
and
not
f
(
e
,
c
)
end
function
Auxiliary
.
GetSynchroLevelFlowerCardian
(
c
)
return
2
end
function
Auxiliary
.
GetSynMaterials
(
tp
,
syncard
)
local
mg
=
Duel
.
GetMatchingGroup
(
Auxiliary
.
SynMaterialFilter
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
syncard
)
if
mg
:
IsExists
(
Card
.
GetHandSynchro
,
1
,
nil
)
then
local
mg2
=
Duel
.
GetMatchingGroup
(
Card
.
IsCanBeSynchroMaterial
,
tp
,
LOCATION_HAND
,
0
,
nil
,
syncard
)
if
mg2
:
GetCount
()
>
0
then
mg
:
Merge
(
mg2
)
end
end
return
mg
end
function
Auxiliary
.
SynMixCondition
(
f1
,
f2
,
f3
,
f4
,
minc
,
maxc
)
return
function
(
e
,
c
,
smat
,
mg1
)
if
c
==
nil
then
return
true
end
if
c
:
IsType
(
TYPE_PENDULUM
)
and
c
:
IsFaceup
()
then
return
false
end
local
tp
=
c
:
GetControler
()
local
mg
if
mg1
then
mg
=
mg1
else
mg
=
Auxiliary
.
GetSynMaterials
(
tp
,
c
)
end
return
mg
:
IsExists
(
Auxiliary
.
SynMixFilter1
,
1
,
nil
,
f1
,
f2
,
f3
,
f4
,
minc
,
maxc
,
c
,
mg
,
smat
)
end
end
function
Auxiliary
.
SynMixTarget
(
f1
,
f2
,
f3
,
f4
,
minc
,
maxc
)
return
function
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
c
,
smat
,
mg1
)
local
g
=
Group
.
CreateGroup
()
local
mg
if
mg1
then
mg
=
mg1
else
mg
=
Auxiliary
.
GetSynMaterials
(
tp
,
c
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
c1
=
mg
:
FilterSelect
(
tp
,
Auxiliary
.
SynMixFilter1
,
1
,
1
,
nil
,
f1
,
f2
,
f3
,
f4
,
minc
,
maxc
,
c
,
mg
,
smat
):
GetFirst
()
g
:
AddCard
(
c1
)
if
f2
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
c2
=
mg
:
FilterSelect
(
tp
,
Auxiliary
.
SynMixFilter2
,
1
,
1
,
c1
,
f2
,
f3
,
f4
,
minc
,
maxc
,
c
,
mg
,
smat
,
c1
):
GetFirst
()
g
:
AddCard
(
c2
)
if
f3
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
c3
=
mg
:
FilterSelect
(
tp
,
Auxiliary
.
SynMixFilter3
,
1
,
1
,
Group
.
FromCards
(
c1
,
c2
),
f3
,
f4
,
minc
,
maxc
,
c
,
mg
,
smat
,
c1
,
c2
):
GetFirst
()
g
:
AddCard
(
c3
)
end
end
local
g4
=
Group
.
CreateGroup
()
for
i
=
0
,
maxc
-
1
do
local
mg2
=
mg
:
Clone
()
if
f4
then
mg2
=
mg2
:
Filter
(
f4
,
nil
)
end
local
cg
=
mg2
:
Filter
(
Auxiliary
.
SynMixCheckRecursive
,
g4
,
tp
,
g4
,
mg2
,
i
,
minc
,
maxc
,
c
,
g
,
smat
)
if
cg
:
GetCount
()
==
0
then
break
end
local
minct
=
1
if
Auxiliary
.
SynMixCheckGoal
(
tp
,
g4
,
minc
,
i
,
c
,
g
,
smat
)
then
if
not
Duel
.
SelectYesNo
(
tp
,
210
)
then
break
end
minct
=
0
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tg
=
cg
:
Select
(
tp
,
minct
,
1
,
nil
)
if
tg
:
GetCount
()
==
0
then
break
end
g4
:
Merge
(
tg
)
end
g
:
Merge
(
g4
)
if
g
:
GetCount
()
>
0
then
g
:
KeepAlive
()
e
:
SetLabelObject
(
g
)
return
true
else
return
false
end
end
end
function
Auxiliary
.
SynMixOperation
(
f1
,
f2
,
f3
,
f4
,
minct
,
maxc
)
return
function
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
smat
,
mg
)
local
g
=
e
:
GetLabelObject
()
if
not
g
:
IsExists
(
Card
.
IsType
,
1
,
nil
,
TYPE_TUNER
)
and
c
:
IsHasEffect
(
80896940
)
then
c
:
RegisterFlagEffect
(
80896940
,
RESET_EVENT
+
0x1fe0000
,
0
,
1
)
end
c
:
SetMaterial
(
g
)
Duel
.
SendtoGrave
(
g
,
REASON_MATERIAL
+
REASON_SYNCHRO
)
g
:
DeleteGroup
()
end
end
function
Auxiliary
.
SynMixFilter1
(
c
,
f1
,
f2
,
f3
,
f4
,
minc
,
maxc
,
syncard
,
mg
,
smat
)
return
(
not
f1
or
f1
(
c
))
and
mg
:
IsExists
(
Auxiliary
.
SynMixFilter2
,
1
,
c
,
f2
,
f3
,
f4
,
minc
,
maxc
,
syncard
,
mg
,
smat
,
c
)
end
function
Auxiliary
.
SynMixFilter2
(
c
,
f2
,
f3
,
f4
,
minc
,
maxc
,
syncard
,
mg
,
smat
,
c1
)
if
f2
then
return
f2
(
c
)
and
mg
:
IsExists
(
Auxiliary
.
SynMixFilter3
,
1
,
Group
.
FromCards
(
c1
,
c
),
f3
,
f4
,
minc
,
maxc
,
syncard
,
mg
,
smat
,
c1
,
c
)
else
return
mg
:
IsExists
(
Auxiliary
.
SynMixFilter4
,
1
,
c1
,
f4
,
minc
,
maxc
,
syncard
,
mg
,
smat
,
c1
,
nil
,
nil
)
end
end
function
Auxiliary
.
SynMixFilter3
(
c
,
f3
,
f4
,
minc
,
maxc
,
syncard
,
mg
,
smat
,
c1
,
c2
)
if
f3
then
return
f3
(
c
)
and
mg
:
IsExists
(
Auxiliary
.
SynMixFilter4
,
1
,
Group
.
FromCards
(
c1
,
c2
,
c
),
f3
,
f4
,
minc
,
maxc
,
syncard
,
mg
,
smat
,
c1
,
c2
)
else
return
mg
:
IsExists
(
Auxiliary
.
SynMixFilter4
,
1
,
Group
.
FromCards
(
c1
,
c2
),
f4
,
minc
,
maxc
,
syncard
,
mg
,
smat
,
c1
,
c2
,
nil
)
end
end
function
Auxiliary
.
SynMixFilter4
(
c
,
f4
,
minc
,
maxc
,
syncard
,
mg1
,
smat
,
c1
,
c2
,
c3
)
if
f4
and
not
f4
(
c
)
then
return
false
end
local
sg
=
Group
.
FromCards
(
c1
,
c
)
sg
:
AddCard
(
c1
)
if
c2
then
sg
:
AddCard
(
c2
)
end
if
c3
then
sg
:
AddCard
(
c3
)
end
local
mg
=
mg1
:
Clone
()
if
f4
then
mg
=
mg
:
Filter
(
f4
,
nil
)
end
return
aux
.
SynMixCheck
(
mg
,
sg
,
minc
-
1
,
maxc
-
1
,
syncard
,
smat
)
end
function
Auxiliary
.
SynMixCheck
(
mg
,
sg1
,
minc
,
maxc
,
syncard
,
smat
)
local
tp
=
syncard
:
GetControler
()
for
c
in
aux
.
Next
(
sg1
)
do
mg
:
RemoveCard
(
c
)
end
local
sg
=
Group
.
CreateGroup
()
if
minc
==
0
and
Auxiliary
.
SynMixCheckGoal
(
tp
,
sg1
,
0
,
0
,
syncard
,
sg
,
smat
)
then
return
true
end
if
maxc
==
0
then
return
false
end
return
mg
:
IsExists
(
Auxiliary
.
SynMixCheckRecursive
,
1
,
nil
,
tp
,
sg
,
mg
,
0
,
minc
,
maxc
,
syncard
,
sg1
,
smat
)
end
function
Auxiliary
.
SynMixCheckRecursive
(
c
,
tp
,
sg
,
mg
,
ct
,
minc
,
maxc
,
syncard
,
sg1
,
smat
)
sg
:
AddCard
(
c
)
ct
=
ct
+
1
local
res
=
Auxiliary
.
SynMixCheckGoal
(
tp
,
sg
,
minc
,
ct
,
syncard
,
sg1
,
smat
)
or
(
ct
<
maxc
and
mg
:
IsExists
(
Auxiliary
.
SynMixCheckRecursive
,
1
,
sg
,
tp
,
sg
,
mg
,
ct
,
minc
,
maxc
,
syncard
,
sg1
,
smat
))
sg
:
RemoveCard
(
c
)
ct
=
ct
-
1
return
res
end
function
Auxiliary
.
SynMixCheckGoal
(
tp
,
sg
,
minc
,
ct
,
syncard
,
sg1
,
smat
)
if
ct
<
minc
then
return
false
end
local
g
=
sg
:
Clone
()
g
:
Merge
(
sg1
)
if
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
g
,
syncard
)
<=
0
then
return
false
end
if
smat
and
not
g
:
IsContains
(
smat
)
then
return
false
end
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
if
pe
and
not
g
:
IsContains
(
pe
:
GetOwner
())
then
return
false
end
if
not
g
:
IsExists
(
Card
.
IsType
,
1
,
nil
,
TYPE_TUNER
)
and
not
syncard
:
IsHasEffect
(
80896940
)
then
return
false
end
if
not
g
:
CheckWithSumEqual
(
Card
.
GetSynchroLevel
,
syncard
:
GetLevel
(),
g
:
GetCount
(),
g
:
GetCount
(),
syncard
)
and
(
not
g
:
IsExists
(
Card
.
IsHasEffect
,
1
,
nil
,
89818984
)
or
not
g
:
CheckWithSumEqual
(
Auxiliary
.
GetSynchroLevelFlowerCardian
,
syncard
:
GetLevel
(),
g
:
GetCount
(),
g
:
GetCount
(),
syncard
))
then
return
false
end
local
hg
=
g
:
Filter
(
Card
.
IsLocation
,
nil
,
LOCATION_HAND
)
local
hct
=
hg
:
GetCount
()
if
hct
>
0
then
local
found
=
false
for
c
in
aux
.
Next
(
g
)
do
local
he
,
hf
,
min
,
max
=
c
:
GetHandSynchro
()
if
he
then
found
=
true
if
hf
and
hg
:
IsExists
(
Auxiliary
.
SynLimitFilter
,
1
,
c
,
hf
,
he
)
then
return
false
end
if
(
hmin
and
ct
<
hmin
)
or
(
hmax
and
ct
>
hmax
)
then
return
false
end
end
end
if
not
found
then
return
false
end
end
for
c
in
aux
.
Next
(
g
)
do
local
le
,
lf
,
lloc
,
lmin
,
lmax
=
c
:
GetTunerLimit
()
if
le
then
local
ct
=
g
:
GetCount
()
-
1
if
lloc
then
local
lg
=
g
:
Filter
(
Card
.
IsLocation
,
c
,
lloc
)
if
lg
:
GetCount
()
~=
ct
then
return
false
end
end
if
lf
and
g
:
IsExists
(
Auxiliary
.
SynLimitFilter
,
1
,
c
,
lf
,
lf
)
then
return
false
end
if
(
lmin
and
ct
<
lmin
)
or
(
lmax
and
ct
>
lmax
)
then
return
false
end
end
end
return
true
end
function
Auxiliary
.
XyzAlterFilter
(
c
,
alterf
,
xyzc
,
e
,
tp
,
op
)
function
Auxiliary
.
XyzAlterFilter
(
c
,
alterf
,
xyzc
,
e
,
tp
,
op
)
return
alterf
(
c
)
and
c
:
IsCanBeXyzMaterial
(
xyzc
)
and
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
Group
.
FromCards
(
c
),
xyzc
)
>
0
and
(
not
op
or
op
(
e
,
tp
,
0
,
c
))
return
alterf
(
c
)
and
c
:
IsCanBeXyzMaterial
(
xyzc
)
and
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
Group
.
FromCards
(
c
),
xyzc
)
>
0
and
(
not
op
or
op
(
e
,
tp
,
0
,
c
))
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment