Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
no81cards
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
Nemo Ma
no81cards
Commits
49b49e7f
Commit
49b49e7f
authored
Jan 24, 2022
by
Nemo Ma
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
4af8423b
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
195 additions
and
358 deletions
+195
-358
expansions/script/c10121006.lua
expansions/script/c10121006.lua
+2
-1
expansions/script/c15000724.lua
expansions/script/c15000724.lua
+29
-155
expansions/script/c15000726.lua
expansions/script/c15000726.lua
+29
-155
expansions/script/c15000904.lua
expansions/script/c15000904.lua
+2
-1
expansions/script/c65010026.lua
expansions/script/c65010026.lua
+2
-1
expansions/script/c65010028.lua
expansions/script/c65010028.lua
+1
-1
expansions/script/c67200404.lua
expansions/script/c67200404.lua
+45
-15
expansions/script/c67200406.lua
expansions/script/c67200406.lua
+41
-13
expansions/script/c67200408.lua
expansions/script/c67200408.lua
+41
-15
expansions/script/c67200432.lua
expansions/script/c67200432.lua
+3
-1
No files found.
expansions/script/c10121006.lua
View file @
49b49e7f
...
...
@@ -4,7 +4,8 @@ local m=10121006
local
cm
=
_G
[
"c"
..
m
]
function
cm
.
initial_effect
(
c
)
c
:
EnableReviveLimit
()
rsdio
.
XyzEffect
(
c
,
3
)
aux
.
AddXyzProcedure
(
c
,
nil
,
10
,
3
,
nil
,
nil
,
99
)
--rsdio.XyzEffect(c,4)(暂时无法正常使用)
--draw
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
m
,
0
))
...
...
expansions/script/c15000724.lua
View file @
49b49e7f
...
...
@@ -19,9 +19,8 @@ function cm.initial_effect(c)
e2
:
SetType
(
EFFECT_TYPE_IGNITION
)
e2
:
SetRange
(
LOCATION_PZONE
)
e2
:
SetCountLimit
(
1
,
15000724
)
e2
:
SetCondition
(
cm
.
pcon
)
e2
:
SetTarget
(
cm
.
ptg
)
e2
:
SetOperation
(
cm
.
a
op
)
e2
:
SetOperation
(
cm
.
p
op
)
c
:
RegisterEffect
(
e2
)
--only me
local
e3
=
Effect
.
CreateEffect
(
c
)
...
...
@@ -30,15 +29,6 @@ function cm.initial_effect(c)
e3
:
SetCode
(
15000724
)
e3
:
SetRange
(
LOCATION_MZONE
)
c
:
RegisterEffect
(
e3
)
--P
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e4
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e4
:
SetRange
(
LOCATION_PZONE
)
e4
:
SetCode
(
EVENT_CUSTOM
+
15000724
)
e4
:
SetProperty
(
EFFECT_FLAG_DELAY
)
e4
:
SetOperation
(
cm
.
pop
)
c
:
RegisterEffect
(
e4
)
--return
local
e5
=
Effect
.
CreateEffect
(
c
)
e5
:
SetCategory
(
CATEGORY_TOHAND
)
...
...
@@ -61,175 +51,59 @@ end
function
cm
.
sumfilter
(
c
)
return
c
:
IsType
(
TYPE_PENDULUM
)
and
c
:
IsFaceup
()
end
function
cm
.
PConditionFilter
(
c
,
e
,
tp
,
lscale
,
rscale
,
eset
)
local
lv
=
0
if
c
.
pendulum_level
then
lv
=
c
.
pendulum_level
else
lv
=
c
:
GetLevel
()
end
local
bool
=
Auxiliary
.
PendulumSummonableBool
(
c
)
return
(
c
:
IsLocation
(
LOCATION_HAND
)
or
(
c
:
IsFaceup
()
and
c
:
IsType
(
TYPE_PENDULUM
)))
and
lv
>
lscale
and
lv
<
rscale
and
c
:
IsCanBeSpecialSummoned
(
e
,
SUMMON_TYPE_PENDULUM
,
tp
,
bool
,
bool
)
and
not
c
:
IsForbidden
()
and
(
PENDULUM_CHECKLIST
&
(
0x1
<<
tp
)
==
0
or
Auxiliary
.
PConditionExtraFilter
(
c
,
e
,
tp
,
lscale
,
rscale
,
eset
))
end
function
cm
.
pcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
not
PENDULUM_CHECKLIST
then
PENDULUM_CHECKLIST
=
0
local
ge1
=
Effect
.
GlobalEffect
()
ge1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
ge1
:
SetCode
(
EVENT_PHASE_START
+
PHASE_DRAW
)
ge1
:
SetOperation
(
Auxiliary
.
PendulumReset
)
Duel
.
RegisterEffect
(
ge1
,
0
)
end
local
eset
=
{
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_EXTRA_PENDULUM_SUMMON
)}
local
pg
=
Duel
.
GetMatchingGroup
(
nil
,
tp
,
LOCATION_PZONE
,
0
,
nil
)
if
pg
:
GetCount
()
~=
2
then
return
false
end
local
cc
=
pg
:
GetFirst
()
local
lscale
=
cc
:
GetLeftScale
()
local
dc
=
pg
:
GetNext
()
local
rscale
=
dc
:
GetRightScale
()
if
lscale
>
rscale
then
lscale
=
dc
:
GetRightScale
()
rscale
=
cc
:
GetLeftScale
()
end
if
(
lscale
==
rscale
or
lscale
==
rscale
-
1
or
lscale
==
rscale
+
1
)
then
return
false
end
local
loc
=
0
local
sc
=
Duel
.
GetMatchingGroup
(
cm
.
sumfilter
,
tp
,
LOCATION_EXTRA
,
0
,
nil
):
GetFirst
()
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
then
loc
=
loc
+
LOCATION_HAND
end
if
sc
and
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
nil
,
sc
)
>
0
then
loc
=
loc
+
LOCATION_EXTRA
end
if
loc
==
0
then
return
false
end
local
g
=
nil
if
og
then
g
=
og
:
Filter
(
Card
.
IsLocation
,
nil
,
loc
)
else
g
=
Duel
.
GetFieldGroup
(
tp
,
loc
,
0
)
end
return
g
:
IsExists
(
cm
.
PConditionFilter
,
1
,
nil
,
e
,
tp
,
lscale
,
rscale
,
eset
)
and
Duel
.
IsExistingMatchingCard
(
cm
.
cfilter
,
tp
,
LOCATION_PZONE
,
0
,
1
,
e
:
GetHandler
())
function
cm
.
check
(
e
,
tp
)
local
lpz
=
Duel
.
GetFieldCard
(
tp
,
LOCATION_PZONE
,
0
)
if
lpz
==
nil
then
return
false
end
local
pcon
=
aux
.
PendCondition
()
return
pcon
(
e
,
lpz
,
g
)
end
function
cm
.
ptg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
local
eset
=
{
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_EXTRA_PENDULUM_SUMMON
)}
local
pg
=
Duel
.
GetMatchingGroup
(
nil
,
tp
,
LOCATION_PZONE
,
0
,
nil
)
if
pg
:
GetCount
()
~=
2
then
return
false
end
local
cc
=
pg
:
GetFirst
()
local
lscale
=
cc
:
GetLeftScale
()
local
dc
=
pg
:
GetNext
()
local
rscale
=
dc
:
GetRightScale
()
if
lscale
>
rscale
then
lscale
=
dc
:
GetRightScale
()
rscale
=
cc
:
GetLeftScale
()
end
local
loc
=
0
local
sc
=
Duel
.
GetMatchingGroup
(
cm
.
sumfilter
,
tp
,
LOCATION_EXTRA
,
0
,
nil
):
GetFirst
()
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
then
loc
=
loc
+
LOCATION_HAND
end
if
sc
and
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
nil
,
sc
)
>
0
then
loc
=
loc
+
LOCATION_EXTRA
end
local
g
=
nil
if
og
then
g
=
og
:
Filter
(
Card
.
IsLocation
,
nil
,
loc
)
else
g
=
Duel
.
GetFieldGroup
(
tp
,
loc
,
0
)
end
local
yg
=
g
:
Filter
(
cm
.
PConditionFilter
,
nil
,
e
,
tp
,
lscale
,
rscale
,
eset
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
yg
,
yg
:
GetCount
(),
tp
,
0
)
end
function
cm
.
aop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
RaiseEvent
(
e
:
GetHandler
(),
EVENT_CUSTOM
+
15000724
,
re
,
r
,
rp
,
ep
,
ev
)
if
chk
==
0
then
return
cm
.
check
(
e
,
tp
,
nil
)
end
end
function
cm
.
pop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
sg
,
og
)
if
not
PENDULUM_CHECKLIST
then
PENDULUM_CHECKLIST
=
0
local
ge1
=
Effect
.
GlobalEffect
()
ge1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
ge1
:
SetCode
(
EVENT_PHASE_START
+
PHASE_DRAW
)
ge1
:
SetOperation
(
Auxiliary
.
PendulumReset
)
Duel
.
RegisterEffect
(
ge1
,
0
)
end
local
pg
=
Duel
.
GetMatchingGroup
(
nil
,
tp
,
LOCATION_PZONE
,
0
,
nil
)
if
pg
:
GetCount
()
~=
2
then
return
end
local
cc
=
pg
:
GetFirst
()
local
lscale
=
cc
:
GetLeftScale
()
local
dc
=
pg
:
GetNext
()
local
rscale
=
dc
:
GetRightScale
()
if
lscale
>
rscale
then
lscale
=
dc
:
GetRightScale
()
rscale
=
cc
:
GetLeftScale
()
local
lpz
=
Duel
.
GetFieldCard
(
tp
,
LOCATION_PZONE
,
0
)
if
lpz
==
nil
then
return
end
--the summon should be done after the chain end
local
sg
=
Group
.
CreateGroup
()
local
pspop
=
cm
.
pspop
pspop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
lpz
,
sg
,
nil
)
if
Duel
.
SpecialSummon
(
sg
,
SUMMON_TYPE_PENDULUM
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
~=
0
then
Duel
.
RaiseEvent
(
e
:
GetHandler
(),
EVENT_CUSTOM
+
15000725
,
re
,
r
,
rp
,
ep
,
ev
)
end
if
(
lscale
==
rscale
or
lscale
==
rscale
-
1
or
lscale
==
rscale
+
1
)
then
return
end
local
eset
=
{
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_EXTRA_PENDULUM_SUMMON
)}
end
function
cm
.
pspop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
lpz
,
sg
,
og
)
local
rpz
=
Duel
.
GetFieldCard
(
tp
,
LOCATION_PZONE
,
1
)
local
lscale
=
lpz
:
GetLeftScale
()
local
rscale
=
rpz
:
GetRightScale
()
if
lscale
>
rscale
then
lscale
,
rscale
=
rscale
,
lscale
end
local
tg
=
nil
local
loc
=
0
local
sc
=
Duel
.
GetMatchingGroup
(
cm
.
sumfilter
,
tp
,
LOCATION_EXTRA
,
0
,
nil
):
GetFirst
()
local
ft1
=
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
local
ft2
=
0
if
sc
then
ft2
=
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
nil
,
sc
)
end
local
ft2
=
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
nil
,
TYPE_PENDULUM
)
local
ft
=
Duel
.
GetUsableMZoneCount
(
tp
)
local
ect
=
99
if
c29724053
and
Duel
.
IsPlayerAffectedByEffect
(
tp
,
29724053
)
then
ect
=
c29724053
[
tp
]
end
local
ect
=
c29724053
and
Duel
.
IsPlayerAffectedByEffect
(
tp
,
29724053
)
and
c29724053
[
tp
]
if
ect
and
ect
<
ft2
then
ft2
=
ect
end
if
Duel
.
IsPlayerAffectedByEffect
(
tp
,
59822133
)
then
if
ft1
>
0
then
ft1
=
1
end
if
ft2
>
0
then
ft2
=
1
end
ft
=
1
ft
=
1
end
if
ft1
>
0
then
loc
=
loc
|
LOCATION_HAND
end
if
ft2
>
0
then
loc
=
loc
|
LOCATION_EXTRA
end
if
og
then
tg
=
og
:
Filter
(
Card
.
IsLocation
,
nil
,
loc
):
Filter
(
cm
.
PConditionFilter
,
nil
,
e
,
tp
,
lscale
,
rscale
,
eset
)
tg
=
og
:
Filter
(
Card
.
IsLocation
,
nil
,
loc
):
Filter
(
aux
.
PConditionFilter
,
nil
,
e
,
tp
,
lscale
,
rscale
,
eset
)
else
tg
=
Duel
.
GetMatchingGroup
(
cm
.
PConditionFilter
,
tp
,
loc
,
0
,
nil
,
e
,
tp
,
lscale
,
rscale
,
eset
)
tg
=
Duel
.
GetMatchingGroup
(
aux
.
PConditionFilter
,
tp
,
loc
,
0
,
nil
,
e
,
tp
,
lscale
,
rscale
,
eset
)
end
local
ce
=
nil
local
b1
=
PENDULUM_CHECKLIST
&
(
0x1
<<
tp
)
==
0
local
b2
=#
eset
>
0
if
b1
and
b2
then
local
options
=
{
1163
}
for
_
,
te
in
ipairs
(
eset
)
do
table.insert
(
options
,
te
:
GetDescription
())
end
local
op
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
options
))
if
op
>
0
then
ce
=
eset
[
op
]
end
elseif
b2
and
not
b1
then
local
options
=
{}
for
_
,
te
in
ipairs
(
eset
)
do
table.insert
(
options
,
te
:
GetDescription
())
end
local
op
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
options
))
ce
=
eset
[
op
+
1
]
end
if
ce
then
tg
=
tg
:
Filter
(
aux
.
PConditionExtraFilterSpecific
,
nil
,
e
,
tp
,
lscale
,
rscale
,
ce
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
Auxiliary
.
GCheckAdditional
=
Auxiliary
.
PendOperationCheck
(
ft1
,
ft2
,
ft
)
aux
.
GCheckAdditional
=
aux
.
PendOperationCheck
(
ft1
,
ft2
,
ft
)
local
g
=
tg
:
SelectSubGroup
(
tp
,
aux
.
TRUE
,
true
,
1
,
math.min
(
#
tg
,
ft
))
Auxiliary
.
GCheckAdditional
=
nil
aux
.
GCheckAdditional
=
nil
if
not
g
then
return
end
if
ce
then
Duel
.
Hint
(
HINT_CARD
,
0
,
ce
:
GetOwner
():
GetOriginalCode
())
ce
:
Reset
()
end
local
lpz
=
Duel
.
GetFieldCard
(
tp
,
LOCATION_PZONE
,
0
)
local
rpz
=
Duel
.
GetFieldCard
(
tp
,
LOCATION_PZONE
,
1
)
sg
:
Merge
(
g
)
Duel
.
HintSelection
(
Group
.
FromCards
(
lpz
))
Duel
.
HintSelection
(
Group
.
FromCards
(
rpz
))
local
spg
=
Group
.
CreateGroup
()
for
tc
in
aux
.
Next
(
g
)
do
local
bool
=
aux
.
PendulumSummonableBool
(
tc
)
if
Duel
.
SpecialSummonStep
(
tc
,
SUMMON_TYPE_PENDULUM
,
tp
,
tp
,
bool
,
bool
,
POS_FACEUP
)
then
spg
:
AddCard
(
tc
)
end
end
Duel
.
SpecialSummonComplete
()
for
tc
in
aux
.
Next
(
g
)
do
tc
:
CompleteProcedure
()
end
if
spg
:
GetCount
()
~=
0
then
Duel
.
RaiseEvent
(
e
:
GetHandler
(),
EVENT_CUSTOM
+
15000725
,
re
,
r
,
rp
,
ep
,
ev
)
end
end
function
cm
.
dop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
e
:
GetHandler
():
IsAbleToHand
()
then
Duel
.
SendtoHand
(
e
:
GetHandler
(),
nil
,
REASON_EFFECT
)
end
...
...
expansions/script/c15000726.lua
View file @
49b49e7f
...
...
@@ -19,9 +19,8 @@ function cm.initial_effect(c)
e2
:
SetType
(
EFFECT_TYPE_IGNITION
)
e2
:
SetRange
(
LOCATION_PZONE
)
e2
:
SetCountLimit
(
1
,
15000726
)
e2
:
SetCondition
(
cm
.
pcon
)
e2
:
SetTarget
(
cm
.
ptg
)
e2
:
SetOperation
(
cm
.
a
op
)
e2
:
SetOperation
(
cm
.
p
op
)
c
:
RegisterEffect
(
e2
)
--switch and return
local
e3
=
Effect
.
CreateEffect
(
c
)
...
...
@@ -36,15 +35,6 @@ function cm.initial_effect(c)
e4
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e4
:
SetCondition
(
cm
.
condition
)
c
:
RegisterEffect
(
e4
)
--P
local
e5
=
Effect
.
CreateEffect
(
c
)
e5
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e5
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e5
:
SetRange
(
LOCATION_PZONE
)
e5
:
SetCode
(
EVENT_CUSTOM
+
15000726
)
e5
:
SetProperty
(
EFFECT_FLAG_DELAY
)
e5
:
SetOperation
(
cm
.
pop
)
c
:
RegisterEffect
(
e5
)
--return
local
e6
=
Effect
.
CreateEffect
(
c
)
e6
:
SetCategory
(
CATEGORY_TOHAND
)
...
...
@@ -67,175 +57,59 @@ end
function
cm
.
sumfilter
(
c
)
return
c
:
IsType
(
TYPE_PENDULUM
)
and
c
:
IsFaceup
()
end
function
cm
.
PConditionFilter
(
c
,
e
,
tp
,
lscale
,
rscale
,
eset
)
local
lv
=
0
if
c
.
pendulum_level
then
lv
=
c
.
pendulum_level
else
lv
=
c
:
GetLevel
()
end
local
bool
=
Auxiliary
.
PendulumSummonableBool
(
c
)
return
(
c
:
IsLocation
(
LOCATION_HAND
)
or
(
c
:
IsFaceup
()
and
c
:
IsType
(
TYPE_PENDULUM
)))
and
lv
>
lscale
and
lv
<
rscale
and
c
:
IsCanBeSpecialSummoned
(
e
,
SUMMON_TYPE_PENDULUM
,
tp
,
bool
,
bool
)
and
not
c
:
IsForbidden
()
and
(
PENDULUM_CHECKLIST
&
(
0x1
<<
tp
)
==
0
or
Auxiliary
.
PConditionExtraFilter
(
c
,
e
,
tp
,
lscale
,
rscale
,
eset
))
end
function
cm
.
pcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
not
PENDULUM_CHECKLIST
then
PENDULUM_CHECKLIST
=
0
local
ge1
=
Effect
.
GlobalEffect
()
ge1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
ge1
:
SetCode
(
EVENT_PHASE_START
+
PHASE_DRAW
)
ge1
:
SetOperation
(
Auxiliary
.
PendulumReset
)
Duel
.
RegisterEffect
(
ge1
,
0
)
end
local
eset
=
{
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_EXTRA_PENDULUM_SUMMON
)}
local
pg
=
Duel
.
GetMatchingGroup
(
nil
,
tp
,
LOCATION_PZONE
,
0
,
nil
)
if
pg
:
GetCount
()
~=
2
then
return
false
end
local
cc
=
pg
:
GetFirst
()
local
lscale
=
cc
:
GetLeftScale
()
local
dc
=
pg
:
GetNext
()
local
rscale
=
dc
:
GetRightScale
()
if
lscale
>
rscale
then
lscale
=
dc
:
GetRightScale
()
rscale
=
cc
:
GetLeftScale
()
end
if
(
lscale
==
rscale
or
lscale
==
rscale
-
1
or
lscale
==
rscale
+
1
)
then
return
false
end
local
loc
=
0
local
sc
=
Duel
.
GetMatchingGroup
(
cm
.
sumfilter
,
tp
,
LOCATION_EXTRA
,
0
,
nil
):
GetFirst
()
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
then
loc
=
loc
+
LOCATION_HAND
end
if
sc
and
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
nil
,
sc
)
>
0
then
loc
=
loc
+
LOCATION_EXTRA
end
if
loc
==
0
then
return
false
end
local
g
=
nil
if
og
then
g
=
og
:
Filter
(
Card
.
IsLocation
,
nil
,
loc
)
else
g
=
Duel
.
GetFieldGroup
(
tp
,
loc
,
0
)
end
return
g
:
IsExists
(
cm
.
PConditionFilter
,
1
,
nil
,
e
,
tp
,
lscale
,
rscale
,
eset
)
and
Duel
.
IsExistingMatchingCard
(
cm
.
cfilter
,
tp
,
LOCATION_PZONE
,
0
,
1
,
e
:
GetHandler
())
function
cm
.
check
(
e
,
tp
)
local
lpz
=
Duel
.
GetFieldCard
(
tp
,
LOCATION_PZONE
,
0
)
if
lpz
==
nil
then
return
false
end
local
pcon
=
aux
.
PendCondition
()
return
pcon
(
e
,
lpz
,
g
)
end
function
cm
.
ptg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
local
eset
=
{
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_EXTRA_PENDULUM_SUMMON
)}
local
pg
=
Duel
.
GetMatchingGroup
(
nil
,
tp
,
LOCATION_PZONE
,
0
,
nil
)
if
pg
:
GetCount
()
~=
2
then
return
false
end
local
cc
=
pg
:
GetFirst
()
local
lscale
=
cc
:
GetLeftScale
()
local
dc
=
pg
:
GetNext
()
local
rscale
=
dc
:
GetRightScale
()
if
lscale
>
rscale
then
lscale
=
dc
:
GetRightScale
()
rscale
=
cc
:
GetLeftScale
()
end
local
loc
=
0
local
sc
=
Duel
.
GetMatchingGroup
(
cm
.
sumfilter
,
tp
,
LOCATION_EXTRA
,
0
,
nil
):
GetFirst
()
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
then
loc
=
loc
+
LOCATION_HAND
end
if
sc
and
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
nil
,
sc
)
>
0
then
loc
=
loc
+
LOCATION_EXTRA
end
local
g
=
nil
if
og
then
g
=
og
:
Filter
(
Card
.
IsLocation
,
nil
,
loc
)
else
g
=
Duel
.
GetFieldGroup
(
tp
,
loc
,
0
)
end
local
yg
=
g
:
Filter
(
cm
.
PConditionFilter
,
nil
,
e
,
tp
,
lscale
,
rscale
,
eset
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SPECIAL_SUMMON
,
yg
,
yg
:
GetCount
(),
tp
,
0
)
end
function
cm
.
aop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
RaiseEvent
(
e
:
GetHandler
(),
EVENT_CUSTOM
+
15000726
,
re
,
r
,
rp
,
ep
,
ev
)
if
chk
==
0
then
return
cm
.
check
(
e
,
tp
,
nil
)
end
end
function
cm
.
pop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
sg
,
og
)
if
not
PENDULUM_CHECKLIST
then
PENDULUM_CHECKLIST
=
0
local
ge1
=
Effect
.
GlobalEffect
()
ge1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
ge1
:
SetCode
(
EVENT_PHASE_START
+
PHASE_DRAW
)
ge1
:
SetOperation
(
Auxiliary
.
PendulumReset
)
Duel
.
RegisterEffect
(
ge1
,
0
)
end
local
pg
=
Duel
.
GetMatchingGroup
(
nil
,
tp
,
LOCATION_PZONE
,
0
,
nil
)
if
pg
:
GetCount
()
~=
2
then
return
end
local
cc
=
pg
:
GetFirst
()
local
lscale
=
cc
:
GetLeftScale
()
local
dc
=
pg
:
GetNext
()
local
rscale
=
dc
:
GetRightScale
()
if
lscale
>
rscale
then
lscale
=
dc
:
GetRightScale
()
rscale
=
cc
:
GetLeftScale
()
local
lpz
=
Duel
.
GetFieldCard
(
tp
,
LOCATION_PZONE
,
0
)
if
lpz
==
nil
then
return
end
--the summon should be done after the chain end
local
sg
=
Group
.
CreateGroup
()
local
pspop
=
cm
.
pspop
pspop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
lpz
,
sg
,
nil
)
if
Duel
.
SpecialSummon
(
sg
,
SUMMON_TYPE_PENDULUM
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
~=
0
then
Duel
.
RaiseEvent
(
e
:
GetHandler
(),
EVENT_CUSTOM
+
15000727
,
re
,
r
,
rp
,
ep
,
ev
)
end
if
(
lscale
==
rscale
or
lscale
==
rscale
-
1
or
lscale
==
rscale
+
1
)
then
return
end
local
eset
=
{
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_EXTRA_PENDULUM_SUMMON
)}
end
function
cm
.
pspop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
lpz
,
sg
,
og
)
local
rpz
=
Duel
.
GetFieldCard
(
tp
,
LOCATION_PZONE
,
1
)
local
lscale
=
lpz
:
GetLeftScale
()
local
rscale
=
rpz
:
GetRightScale
()
if
lscale
>
rscale
then
lscale
,
rscale
=
rscale
,
lscale
end
local
tg
=
nil
local
loc
=
0
local
sc
=
Duel
.
GetMatchingGroup
(
cm
.
sumfilter
,
tp
,
LOCATION_EXTRA
,
0
,
nil
):
GetFirst
()
local
ft1
=
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
local
ft2
=
0
if
sc
then
ft2
=
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
nil
,
sc
)
end
local
ft2
=
Duel
.
GetLocationCountFromEx
(
tp
,
tp
,
nil
,
TYPE_PENDULUM
)
local
ft
=
Duel
.
GetUsableMZoneCount
(
tp
)
local
ect
=
99
if
c29724053
and
Duel
.
IsPlayerAffectedByEffect
(
tp
,
29724053
)
then
ect
=
c29724053
[
tp
]
end
local
ect
=
c29724053
and
Duel
.
IsPlayerAffectedByEffect
(
tp
,
29724053
)
and
c29724053
[
tp
]
if
ect
and
ect
<
ft2
then
ft2
=
ect
end
if
Duel
.
IsPlayerAffectedByEffect
(
tp
,
59822133
)
then
if
ft1
>
0
then
ft1
=
1
end
if
ft2
>
0
then
ft2
=
1
end
ft
=
1
ft
=
1
end
if
ft1
>
0
then
loc
=
loc
|
LOCATION_HAND
end
if
ft2
>
0
then
loc
=
loc
|
LOCATION_EXTRA
end
if
og
then
tg
=
og
:
Filter
(
Card
.
IsLocation
,
nil
,
loc
):
Filter
(
cm
.
PConditionFilter
,
nil
,
e
,
tp
,
lscale
,
rscale
,
eset
)
tg
=
og
:
Filter
(
Card
.
IsLocation
,
nil
,
loc
):
Filter
(
aux
.
PConditionFilter
,
nil
,
e
,
tp
,
lscale
,
rscale
,
eset
)
else
tg
=
Duel
.
GetMatchingGroup
(
cm
.
PConditionFilter
,
tp
,
loc
,
0
,
nil
,
e
,
tp
,
lscale
,
rscale
,
eset
)
tg
=
Duel
.
GetMatchingGroup
(
aux
.
PConditionFilter
,
tp
,
loc
,
0
,
nil
,
e
,
tp
,
lscale
,
rscale
,
eset
)
end
local
ce
=
nil
local
b1
=
PENDULUM_CHECKLIST
&
(
0x1
<<
tp
)
==
0
local
b2
=#
eset
>
0
if
b1
and
b2
then
local
options
=
{
1163
}
for
_
,
te
in
ipairs
(
eset
)
do
table.insert
(
options
,
te
:
GetDescription
())
end
local
op
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
options
))
if
op
>
0
then
ce
=
eset
[
op
]
end
elseif
b2
and
not
b1
then
local
options
=
{}
for
_
,
te
in
ipairs
(
eset
)
do
table.insert
(
options
,
te
:
GetDescription
())
end
local
op
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
options
))
ce
=
eset
[
op
+
1
]
end
if
ce
then
tg
=
tg
:
Filter
(
aux
.
PConditionExtraFilterSpecific
,
nil
,
e
,
tp
,
lscale
,
rscale
,
ce
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SPSUMMON
)
Auxiliary
.
GCheckAdditional
=
Auxiliary
.
PendOperationCheck
(
ft1
,
ft2
,
ft
)
aux
.
GCheckAdditional
=
aux
.
PendOperationCheck
(
ft1
,
ft2
,
ft
)
local
g
=
tg
:
SelectSubGroup
(
tp
,
aux
.
TRUE
,
true
,
1
,
math.min
(
#
tg
,
ft
))
Auxiliary
.
GCheckAdditional
=
nil
aux
.
GCheckAdditional
=
nil
if
not
g
then
return
end
if
ce
then
Duel
.
Hint
(
HINT_CARD
,
0
,
ce
:
GetOwner
():
GetOriginalCode
())
ce
:
Reset
()
end
local
lpz
=
Duel
.
GetFieldCard
(
tp
,
LOCATION_PZONE
,
0
)
local
rpz
=
Duel
.
GetFieldCard
(
tp
,
LOCATION_PZONE
,
1
)
sg
:
Merge
(
g
)
Duel
.
HintSelection
(
Group
.
FromCards
(
lpz
))
Duel
.
HintSelection
(
Group
.
FromCards
(
rpz
))
local
spg
=
Group
.
CreateGroup
()
for
tc
in
aux
.
Next
(
g
)
do
local
bool
=
aux
.
PendulumSummonableBool
(
tc
)
if
Duel
.
SpecialSummonStep
(
tc
,
SUMMON_TYPE_PENDULUM
,
tp
,
tp
,
bool
,
bool
,
POS_FACEUP
)
then
spg
:
AddCard
(
tc
)
end
end
Duel
.
SpecialSummonComplete
()
for
tc
in
aux
.
Next
(
g
)
do
tc
:
CompleteProcedure
()
end
if
spg
:
GetCount
()
~=
0
then
Duel
.
RaiseEvent
(
e
:
GetHandler
(),
EVENT_CUSTOM
+
15000727
,
re
,
r
,
rp
,
ep
,
ev
)
end
end
function
cm
.
dop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
e
:
GetHandler
():
IsAbleToHand
()
then
Duel
.
SendtoHand
(
e
:
GetHandler
(),
nil
,
REASON_EFFECT
)
end
...
...
expansions/script/c15000904.lua
View file @
49b49e7f
...
...
@@ -106,7 +106,8 @@ end
function
cm
.
tdop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
tg
=
Duel
.
GetChainInfo
(
0
,
CHAININFO_TARGET_CARDS
)
local
sg
=
tg
:
Filter
(
Card
.
IsRelateToEffect
,
nil
,
e
)
if
sg
:
GetCount
()
>
0
and
Duel
.
SendtoDeck
(
sg
,
nil
,
2
,
REASON_EFFECT
)
~=
0
then
if
sg
:
GetCount
()
>
0
and
Duel
.
SendtoDeck
(
sg
,
nil
,
1
,
REASON_EFFECT
)
~=
0
then
Duel
.
ShuffleDeck
(
tp
)
Duel
.
BreakEffect
()
Duel
.
Draw
(
tp
,
1
,
REASON_EFFECT
)
end
...
...
expansions/script/c65010026.lua
View file @
49b49e7f
...
...
@@ -70,9 +70,10 @@ function c65010026.penop(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c65010026
.
ffilter
(
c
,
fc
,
sub
,
mg
,
sg
)
if
c
:
IsType
(
TYPE_TOKEN
)
then
return
false
end
return
not
sg
or
sg
:
FilterCount
(
aux
.
TRUE
,
c
)
==
0
or
(
sg
:
IsExists
(
Card
.
IsFusionAttribute
,
1
,
c
,
c
:
GetFusionAttribute
())
and
not
sg
:
IsExists
(
Card
.
IsRace
,
1
,
c
,
c
:
GetRace
()))
or
c
:
IsType
(
TYPE_TOKEN
)
and
not
sg
:
IsExists
(
Card
.
IsRace
,
1
,
c
,
c
:
GetRace
()))
end
function
c65010026
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
ph
=
Duel
.
GetCurrentPhase
()
...
...
expansions/script/c65010028.lua
View file @
49b49e7f
...
...
@@ -64,9 +64,9 @@ function c65010028.ffilterfil(c,att,rac)
return
c
:
IsAttribute
(
att
)
and
c
:
IsRace
(
rac
)
end
function
c65010028
.
ffilter
(
c
,
fc
,
sub
,
mg
,
sg
)
if
c
:
IsType
(
TYPE_TOKEN
)
then
return
false
end
return
not
sg
or
sg
:
FilterCount
(
aux
.
TRUE
,
c
)
==
0
or
sg
:
IsExists
(
c65010028
.
ffilterfil
,
1
,
c
,
c
:
GetFusionAttribute
(),
c
:
GetRace
())
or
c
:
IsType
(
TYPE_TOKEN
)
end
function
c65010028
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
ph
=
Duel
.
GetCurrentPhase
()
...
...
expansions/script/c67200404.lua
View file @
49b49e7f
...
...
@@ -37,6 +37,7 @@ function c67200404.operation(e,tp,eg,ep,ev,re,r,rp)
Duel
.
ConfirmDecktop
(
tp
,
1
)
--Duel.MoveSequence(tc,1)
if
tc
:
IsType
(
TYPE_MONSTER
)
and
tc
:
IsSetCard
(
0x5671
)
then
Duel
.
DisableShuffleCheck
()
Duel
.
SendtoHand
(
tc
,
nil
,
REASON_EFFECT
)
Duel
.
ConfirmCards
(
1
-
tp
,
tc
)
local
ct
=
tc
:
GetLevel
()
...
...
@@ -49,22 +50,22 @@ function c67200404.operation(e,tp,eg,ep,ev,re,r,rp)
ttc
:
AddCounter
(
0x1
,
1
)
ct
=
ct
-
1
end
Duel
.
BreakEffect
()
c
:
CancelToGrave
()
Duel
.
SendtoDeck
(
e
:
GetHandler
(),
nil
,
1
,
REASON_EFFECT
)
end
end
Duel
.
BreakEffect
()
c
:
CancelToGrave
()
Duel
.
SendtoDeck
(
e
:
GetHandler
(),
nil
,
1
,
REASON_EFFECT
)
end
--
function
c67200404
.
thfilter
(
c
)
function
c67200404
.
thfilter
1
(
c
)
return
c
:
IsSetCard
(
0x5671
)
and
c
:
IsAbleToDeck
()
end
function
c67200404
.
thtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c67200404
.
thfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
)
and
Duel
.
IsCanRemoveCounter
(
tp
,
1
,
0
,
0x1
,
1
,
REASON_COST
)
end
local
g
=
Duel
.
GetMatchingGroup
(
c67200404
.
thfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c67200404
.
thfilter1
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
)
and
Duel
.
IsCanRemoveCounter
(
tp
,
1
,
0
,
0x1
,
1
,
REASON_COST
)
end
--
local
g
=
Duel
.
GetMatchingGroup
(
c67200404
.
thfilter1
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
local
count
=
g
:
GetCount
()
local
lvt
=
{}
local
tc
=
g
:
GetFirst
()
while
count
>
0
do
local
tlv
=
count
lvt
[
tlv
]
=
tlv
...
...
@@ -75,19 +76,48 @@ function c67200404.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if
lvt
[
i
]
then
lvt
[
i
]
=
nil
lvt
[
pc
]
=
i
pc
=
pc
+
1
end
end
lvt
[
pc
]
=
nil
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
67200404
,
2
))
local
lv
=
Duel
.
AnnounceNumber
(
tp
,
table.unpack
(
lvt
))
Duel
.
RemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv
,
REASON_COST
)
e
:
SetLabel
(
lv
)
--
local
dgc
=
Duel
.
GetCounter
(
tp
,
LOCATION_ONFIELD
,
0
,
0x1
)
local
lvt2
=
{}
while
dgc
>
0
do
local
tlv2
=
dgc
lvt2
[
tlv2
]
=
tlv2
dgc
=
dgc
-
1
end
local
pc2
=
1
for
i2
=
1
,
Duel
.
GetCounter
(
tp
,
LOCATION_ONFIELD
,
0
,
0x1
)
do
if
lvt2
[
i2
]
then
lvt2
[
i2
]
=
nil
lvt2
[
pc2
]
=
i2
pc2
=
pc2
+
1
end
end
lvt2
[
pc2
]
=
nil
--
if
g
:
GetCount
()
>
16
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
67200404
,
2
))
local
lv0
=
Duel
.
AnnounceNumber
(
tp
,
1
,
2
,
3
,
4
,
5
,
6
,
7
,
8
,
9
,
10
,
11
,
12
,
13
,
14
,
15
,
16
)
Duel
.
RemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv0
,
REASON_COST
)
e
:
SetLabel
(
lv0
)
else
if
g
:
GetCount
()
>
dgc
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
67200404
,
2
))
local
lv
=
Duel
.
AnnounceNumber
(
tp
,
table.unpack
(
lvt
))
Duel
.
RemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv
,
REASON_COST
)
e
:
SetLabel
(
lv
)
else
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
67200404
,
2
))
local
lv2
=
Duel
.
AnnounceNumber
(
tp
,
table.unpack
(
lvt2
))
Duel
.
RemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv2
,
REASON_COST
)
e
:
SetLabel
(
lv2
)
end
end
end
function
c67200404
.
thop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
lv
=
e
:
GetLabel
()
if
not
Duel
.
IsCanRemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv
,
REASON_COST
)
then
return
end
local
lv
3
=
e
:
GetLabel
()
--if not Duel.IsCanRemoveCounter(tp,1,0,0x1,lv3
,REASON_COST) then return end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TODECK
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c67200404
.
thfilter
,
tp
,
LOCATION_GRAVE
,
0
,
lv
,
lv
,
nil
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c67200404
.
thfilter
1
,
tp
,
LOCATION_GRAVE
,
0
,
lv3
,
lv3
,
nil
)
if
g
:
GetCount
()
>
0
then
--Duel.ConfirmCards(1-tp,g)
Duel
.
SendtoDeck
(
g
,
nil
,
0
,
REASON_EFFECT
)
Duel
.
DisableShuffleCheck
()
Duel
.
SendtoDeck
(
g
,
nil
,
SEQ_DECKTOP
,
REASON_EFFECT
)
local
og
=
Duel
.
GetOperatedGroup
()
local
ct
=
og
:
FilterCount
(
Card
.
IsLocation
,
nil
,
LOCATION_DECK
)
if
ct
==
0
then
return
end
...
...
expansions/script/c67200406.lua
View file @
49b49e7f
...
...
@@ -48,15 +48,15 @@ function c67200406.activate(e,tp,eg,ep,ev,re,r,rp)
Duel
.
SendtoDeck
(
e
:
GetHandler
(),
nil
,
1
,
REASON_EFFECT
)
end
--
function
c67200406
.
thfilter
(
c
)
function
c67200406
.
thfilter
1
(
c
)
return
c
:
IsSetCard
(
0x5671
)
and
c
:
IsAbleToDeck
()
end
function
c67200406
.
thtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c67200406
.
thfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
)
and
Duel
.
IsCanRemoveCounter
(
tp
,
1
,
0
,
0x1
,
1
,
REASON_COST
)
end
local
g
=
Duel
.
GetMatchingGroup
(
c67200406
.
thfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c67200406
.
thfilter1
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
)
and
Duel
.
IsCanRemoveCounter
(
tp
,
1
,
0
,
0x1
,
1
,
REASON_COST
)
end
--
local
g
=
Duel
.
GetMatchingGroup
(
c67200406
.
thfilter1
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
local
count
=
g
:
GetCount
()
local
lvt
=
{}
local
tc
=
g
:
GetFirst
()
while
count
>
0
do
local
tlv
=
count
lvt
[
tlv
]
=
tlv
...
...
@@ -67,19 +67,48 @@ function c67200406.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if
lvt
[
i
]
then
lvt
[
i
]
=
nil
lvt
[
pc
]
=
i
pc
=
pc
+
1
end
end
lvt
[
pc
]
=
nil
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
67200406
,
2
))
local
lv
=
Duel
.
AnnounceNumber
(
tp
,
table.unpack
(
lvt
))
Duel
.
RemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv
,
REASON_COST
)
e
:
SetLabel
(
lv
)
--
local
dgc
=
Duel
.
GetCounter
(
tp
,
LOCATION_ONFIELD
,
0
,
0x1
)
local
lvt2
=
{}
while
dgc
>
0
do
local
tlv2
=
dgc
lvt2
[
tlv2
]
=
tlv2
dgc
=
dgc
-
1
end
local
pc2
=
1
for
i2
=
1
,
Duel
.
GetCounter
(
tp
,
LOCATION_ONFIELD
,
0
,
0x1
)
do
if
lvt2
[
i2
]
then
lvt2
[
i2
]
=
nil
lvt2
[
pc2
]
=
i2
pc2
=
pc2
+
1
end
end
lvt2
[
pc2
]
=
nil
--
if
g
:
GetCount
()
>
16
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
67200406
,
2
))
local
lv0
=
Duel
.
AnnounceNumber
(
tp
,
1
,
2
,
3
,
4
,
5
,
6
,
7
,
8
,
9
,
10
,
11
,
12
,
13
,
14
,
15
,
16
)
Duel
.
RemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv0
,
REASON_COST
)
e
:
SetLabel
(
lv0
)
else
if
g
:
GetCount
()
>
dgc
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
67200406
,
2
))
local
lv
=
Duel
.
AnnounceNumber
(
tp
,
table.unpack
(
lvt
))
Duel
.
RemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv
,
REASON_COST
)
e
:
SetLabel
(
lv
)
else
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
67200406
,
2
))
local
lv2
=
Duel
.
AnnounceNumber
(
tp
,
table.unpack
(
lvt2
))
Duel
.
RemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv2
,
REASON_COST
)
e
:
SetLabel
(
lv2
)
end
end
end
function
c67200406
.
thop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
lv
=
e
:
GetLabel
()
if
not
Duel
.
IsCanRemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv
,
REASON_COST
)
then
return
end
local
lv
3
=
e
:
GetLabel
()
--if not Duel.IsCanRemoveCounter(tp,1,0,0x1,lv3
,REASON_COST) then return end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TODECK
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c67200406
.
thfilter
,
tp
,
LOCATION_GRAVE
,
0
,
lv
,
lv
,
nil
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c67200406
.
thfilter
1
,
tp
,
LOCATION_GRAVE
,
0
,
lv3
,
lv3
,
nil
)
if
g
:
GetCount
()
>
0
then
--Duel.ConfirmCards(1-tp,g)
Duel
.
SendtoDeck
(
g
,
nil
,
0
,
REASON_EFFECT
)
Duel
.
DisableShuffleCheck
()
Duel
.
SendtoDeck
(
g
,
nil
,
SEQ_DECKTOP
,
REASON_EFFECT
)
local
og
=
Duel
.
GetOperatedGroup
()
local
ct
=
og
:
FilterCount
(
Card
.
IsLocation
,
nil
,
LOCATION_DECK
)
if
ct
==
0
then
return
end
...
...
@@ -91,4 +120,3 @@ function c67200406.thop(e,tp,eg,ep,ev,re,r,rp)
end
end
expansions/script/c67200408.lua
View file @
49b49e7f
...
...
@@ -57,15 +57,15 @@ function c67200408.activate(e,tp,eg,ep,ev,re,r,rp)
Duel
.
SendtoDeck
(
e
:
GetHandler
(),
nil
,
1
,
REASON_EFFECT
)
end
--
function
c67200408
.
thfilter
(
c
)
function
c67200408
.
thfilter
1
(
c
)
return
c
:
IsSetCard
(
0x5671
)
and
c
:
IsAbleToDeck
()
end
function
c67200408
.
thtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c67200408
.
thfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
)
and
Duel
.
IsCanRemoveCounter
(
tp
,
1
,
0
,
0x1
,
1
,
REASON_COST
)
end
local
g
=
Duel
.
GetMatchingGroup
(
c67200408
.
thfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c67200408
.
thfilter1
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
)
and
Duel
.
IsCanRemoveCounter
(
tp
,
1
,
0
,
0x1
,
1
,
REASON_COST
)
end
--
local
g
=
Duel
.
GetMatchingGroup
(
c67200408
.
thfilter1
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
local
count
=
g
:
GetCount
()
local
lvt
=
{}
local
tc
=
g
:
GetFirst
()
while
count
>
0
do
local
tlv
=
count
lvt
[
tlv
]
=
tlv
...
...
@@ -76,19 +76,48 @@ function c67200408.thtg(e,tp,eg,ep,ev,re,r,rp,chk)
if
lvt
[
i
]
then
lvt
[
i
]
=
nil
lvt
[
pc
]
=
i
pc
=
pc
+
1
end
end
lvt
[
pc
]
=
nil
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
67200408
,
2
))
local
lv
=
Duel
.
AnnounceNumber
(
tp
,
table.unpack
(
lvt
))
Duel
.
RemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv
,
REASON_COST
)
e
:
SetLabel
(
lv
)
--
local
dgc
=
Duel
.
GetCounter
(
tp
,
LOCATION_ONFIELD
,
0
,
0x1
)
local
lvt2
=
{}
while
dgc
>
0
do
local
tlv2
=
dgc
lvt2
[
tlv2
]
=
tlv2
dgc
=
dgc
-
1
end
local
pc2
=
1
for
i2
=
1
,
Duel
.
GetCounter
(
tp
,
LOCATION_ONFIELD
,
0
,
0x1
)
do
if
lvt2
[
i2
]
then
lvt2
[
i2
]
=
nil
lvt2
[
pc2
]
=
i2
pc2
=
pc2
+
1
end
end
lvt2
[
pc2
]
=
nil
--
if
g
:
GetCount
()
>
16
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
67200408
,
2
))
local
lv0
=
Duel
.
AnnounceNumber
(
tp
,
1
,
2
,
3
,
4
,
5
,
6
,
7
,
8
,
9
,
10
,
11
,
12
,
13
,
14
,
15
,
16
)
Duel
.
RemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv0
,
REASON_COST
)
e
:
SetLabel
(
lv0
)
else
if
g
:
GetCount
()
>
dgc
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
67200408
,
2
))
local
lv
=
Duel
.
AnnounceNumber
(
tp
,
table.unpack
(
lvt
))
Duel
.
RemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv
,
REASON_COST
)
e
:
SetLabel
(
lv
)
else
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
aux
.
Stringid
(
67200408
,
2
))
local
lv2
=
Duel
.
AnnounceNumber
(
tp
,
table.unpack
(
lvt2
))
Duel
.
RemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv2
,
REASON_COST
)
e
:
SetLabel
(
lv2
)
end
end
end
function
c67200408
.
thop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
lv
=
e
:
GetLabel
()
if
not
Duel
.
IsCanRemoveCounter
(
tp
,
1
,
0
,
0x1
,
lv
,
REASON_COST
)
then
return
end
local
lv
3
=
e
:
GetLabel
()
--if not Duel.IsCanRemoveCounter(tp,1,0,0x1,lv3
,REASON_COST) then return end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TODECK
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c67200408
.
thfilter
,
tp
,
LOCATION_GRAVE
,
0
,
lv
,
lv
,
nil
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c67200408
.
thfilter
1
,
tp
,
LOCATION_GRAVE
,
0
,
lv3
,
lv3
,
nil
)
if
g
:
GetCount
()
>
0
then
--Duel.ConfirmCards(1-tp,g)
Duel
.
SendtoDeck
(
g
,
nil
,
0
,
REASON_EFFECT
)
Duel
.
DisableShuffleCheck
()
Duel
.
SendtoDeck
(
g
,
nil
,
SEQ_DECKTOP
,
REASON_EFFECT
)
local
og
=
Duel
.
GetOperatedGroup
()
local
ct
=
og
:
FilterCount
(
Card
.
IsLocation
,
nil
,
LOCATION_DECK
)
if
ct
==
0
then
return
end
...
...
@@ -100,6 +129,3 @@ function c67200408.thop(e,tp,eg,ep,ev,re,r,rp)
end
end
expansions/script/c67200432.lua
View file @
49b49e7f
...
...
@@ -43,7 +43,7 @@ function c67200432.spcon(e,tp,eg,ep,ev,re,r,rp)
return
Duel
.
IsChainNegatable
(
ev
)
and
(
re
:
IsActiveType
(
TYPE_MONSTER
)
or
re
:
IsHasType
(
EFFECT_TYPE_ACTIVATE
))
end
function
c67200432
.
sptg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
if
chk
==
0
then
return
aux
.
nbcon
(
tp
,
re
)
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_NEGATE
,
eg
,
1
,
0
,
0
)
if
re
:
GetHandler
():
IsRelateToEffect
(
re
)
then
...
...
@@ -52,8 +52,10 @@ function c67200432.sptg(e,tp,eg,ep,ev,re,r,rp,chk)
end
function
c67200432
.
spop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
rc
=
re
:
GetHandler
()
if
Duel
.
NegateActivation
(
ev
)
and
re
:
GetHandler
():
IsRelateToEffect
(
re
)
then
Duel
.
SpecialSummon
(
c
,
0
,
tp
,
tp
,
false
,
false
,
POS_FACEUP
)
rc
:
CancelToGrave
()
Duel
.
Overlay
(
c
,
eg
)
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