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
572aba05
Commit
572aba05
authored
Jul 25, 2019
by
Nemo Ma
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix tama cards
parent
d648d13c
Changes
23
Hide whitespace changes
Inline
Side-by-side
Showing
23 changed files
with
236 additions
and
105 deletions
+236
-105
expansions/script/c13254032.lua
expansions/script/c13254032.lua
+3
-3
expansions/script/c13254038.lua
expansions/script/c13254038.lua
+8
-8
expansions/script/c13254042.lua
expansions/script/c13254042.lua
+0
-1
expansions/script/c13254045.lua
expansions/script/c13254045.lua
+3
-3
expansions/script/c13257301.lua
expansions/script/c13257301.lua
+9
-9
expansions/script/c13257302.lua
expansions/script/c13257302.lua
+8
-8
expansions/script/c13257303.lua
expansions/script/c13257303.lua
+8
-8
expansions/script/c13257304.lua
expansions/script/c13257304.lua
+8
-8
expansions/script/c13257305.lua
expansions/script/c13257305.lua
+9
-9
expansions/script/c13257306.lua
expansions/script/c13257306.lua
+8
-8
expansions/script/c13257307.lua
expansions/script/c13257307.lua
+1
-1
expansions/script/c13257308.lua
expansions/script/c13257308.lua
+1
-1
expansions/script/c13257309.lua
expansions/script/c13257309.lua
+2
-2
expansions/script/c13257325.lua
expansions/script/c13257325.lua
+8
-8
expansions/script/c13257326.lua
expansions/script/c13257326.lua
+8
-8
expansions/script/c13257327.lua
expansions/script/c13257327.lua
+7
-7
expansions/script/c13257328.lua
expansions/script/c13257328.lua
+116
-0
expansions/script/c13257329.lua
expansions/script/c13257329.lua
+2
-2
expansions/script/c13257330.lua
expansions/script/c13257330.lua
+1
-1
expansions/script/c13257331.lua
expansions/script/c13257331.lua
+1
-1
expansions/script/c13257332.lua
expansions/script/c13257332.lua
+1
-1
expansions/script/c9981016.lua
expansions/script/c9981016.lua
+1
-2
expansions/script/tama.lua
expansions/script/tama.lua
+23
-6
No files found.
expansions/script/c13254032.lua
View file @
572aba05
...
...
@@ -46,7 +46,7 @@ function cm.filter(c,ft)
end
function
cm
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
ft1
=
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
if
ft1
<-
1
then
return
false
end
if
ft1
<-
1
then
return
end
local
ft
=
ft1
if
ft1
<=
1
then
ft1
=
Duel
.
GetFieldGroupCount
(
tp
,
LOCATION_MZONE
,
0
)
...
...
@@ -57,9 +57,9 @@ function cm.operation(e,tp,eg,ep,ev,re,r,rp)
if
Duel
.
IsPlayerAffectedByEffect
(
tp
,
59822133
)
then
ft1
=
1
end
local
i
=
1
local
sg
=
Group
.
CreateGroup
()
while
i
<=
ft1
do
while
i
<=
ft1
and
Duel
.
GetMatchingGroupCount
(
cm
.
filter
,
tp
,
LOCATION_ONFIELD
,
0
,
sg
,
ft
)
do
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_TOGRAVE
)
local
g1
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
filter
,
tp
,
LOCATION_ONFIELD
,
0
,
1
,
1
,
nil
,
ft
)
local
g1
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
filter
,
tp
,
LOCATION_ONFIELD
,
0
,
1
,
1
,
sg
,
ft
)
if
g1
:
GetFirst
():
IsLocation
(
LOCATION_ONFIELD
)
then
ft
=
ft
-
1
end
...
...
expansions/script/c13254038.lua
View file @
572aba05
...
...
@@ -33,9 +33,9 @@ function cm.filter2(c)
return
c
:
IsSetCard
(
0x356
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
IsAbleToDeck
()
end
function
cm
.
disop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
not
Duel
.
IsPlayerCanDiscardDeck
(
tp
,
3
)
then
return
end
Duel
.
ConfirmDecktop
(
tp
,
3
)
local
g
=
Duel
.
GetDecktopGroup
(
tp
,
3
)
if
not
Duel
.
IsPlayerCanDiscardDeck
(
tp
,
5
)
then
return
end
Duel
.
ConfirmDecktop
(
tp
,
5
)
local
g
=
Duel
.
GetDecktopGroup
(
tp
,
5
)
local
sg
=
g
:
Filter
(
cm
.
filter
,
nil
)
if
sg
:
GetCount
()
<=
0
then
return
end
Duel
.
DisableShuffleCheck
()
...
...
@@ -43,17 +43,17 @@ function cm.disop(e,tp,eg,ep,ev,re,r,rp)
local
sg1
=
Duel
.
GetOperatedGroup
()
local
sg2
=
sg1
:
Clone
()
if
sg1
:
GetCount
()
>
0
then
if
sg1
:
GetSum
(
tama
.
tamas_getElementCount
,
13254033
)
>
0
and
Duel
.
IsPlayerCanDiscardDeck
(
tp
,
2
)
then
if
sg1
:
GetSum
(
tama
.
tamas_getElementCount
,
13254033
)
>
0
and
Duel
.
IsPlayerCanDiscardDeck
(
tp
,
3
)
then
Duel
.
BreakEffect
()
Duel
.
ShuffleDeck
(
tp
)
Duel
.
DiscardDeck
(
tp
,
2
,
REASON_EFFECT
)
Duel
.
DiscardDeck
(
tp
,
3
,
REASON_EFFECT
)
sg2
:
Merge
(
Duel
.
GetOperatedGroup
())
end
if
sg1
:
GetSum
(
tama
.
tamas_getElementCount
,
13254031
)
>
0
and
Duel
.
IsPlayerCanDraw
(
tp
,
1
)
then
if
sg1
:
GetSum
(
tama
.
tamas_getElementCount
,
13254031
)
>
0
and
Duel
.
IsPlayerCanDraw
(
tp
,
2
)
then
Duel
.
BreakEffect
()
Duel
.
Draw
(
tp
,
1
,
REASON_EFFECT
)
Duel
.
Draw
(
tp
,
2
,
REASON_EFFECT
)
Duel
.
ShuffleHand
(
tp
)
Duel
.
DiscardHand
(
tp
,
aux
.
TRUE
,
1
,
1
,
REASON_EFFECT
+
REASON_DISCARD
)
Duel
.
DiscardHand
(
tp
,
aux
.
TRUE
,
2
,
2
,
REASON_EFFECT
+
REASON_DISCARD
)
sg2
:
Merge
(
Duel
.
GetOperatedGroup
())
end
if
sg1
:
GetSum
(
tama
.
tamas_getElementCount
,
13254036
)
>
0
and
sg2
:
IsExists
(
cm
.
filter2
,
1
,
nil
)
then
...
...
expansions/script/c13254042.lua
View file @
572aba05
...
...
@@ -31,7 +31,6 @@ function cm.initial_effect(c)
e3
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e3
:
SetCode
(
EVENT_FREE_CHAIN
)
e3
:
SetCost
(
cm
.
cost2
)
e3
:
SetTarget
(
cm
.
target2
)
e3
:
SetOperation
(
cm
.
operation2
)
c
:
RegisterEffect
(
e3
)
...
...
expansions/script/c13254045.lua
View file @
572aba05
...
...
@@ -31,10 +31,10 @@ function cm.initial_effect(c)
end
function
cm
.
tdfilter
(
c
)
return
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
IsAbleToDeckAsCost
()
and
Duel
.
IsExistingMatchingCard
(
cm
.
thfilter
,
tp
,
0
,
LOCATION_DECK
,
1
,
nil
,
c
)
return
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
IsAbleToDeckAsCost
()
and
Duel
.
IsExistingMatchingCard
(
cm
.
thfilter
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
,
c
)
end
function
cm
.
thfilter
(
c
,
tc
)
return
c
:
IsSetCard
(
0x3356
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
tama
.
tamas_checkElementsEmpty
(
tama
.
tamas_getElements
(
c
))
and
tama
.
tamas_checkCardElementsGreater
(
tc
,
c
)
and
c
:
IsAbleToHand
()
return
c
:
IsSetCard
(
0x3356
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
not
tama
.
tamas_checkElementsEmpty
(
tama
.
tamas_getElements
(
c
))
and
tama
.
tamas_checkCardElementsGreater
(
tc
,
c
)
and
c
:
IsAbleToHand
()
end
function
cm
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
cm
.
tdfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
)
end
...
...
@@ -53,7 +53,7 @@ function cm.operation(e,tp,eg,ep,ev,re,r,rp)
if
g
:
GetCount
()
>
0
then
Duel
.
SendtoHand
(
g
,
nil
,
REASON_EFFECT
)
Duel
.
ConfirmCards
(
1
-
tp
,
g
)
if
Duel
.
SelectYesNo
(
aux
.
Stringid
(
m
,
2
))
then
if
Duel
.
SelectYesNo
(
tp
,
aux
.
Stringid
(
m
,
2
))
then
Duel
.
BreakEffect
()
Duel
.
Summon
(
tp
,
g
:
GetFirst
(),
true
,
nil
)
end
...
...
expansions/script/c13257301.lua
View file @
572aba05
...
...
@@ -49,14 +49,14 @@ function cm.pctg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
t1
or
t2
or
t3
end
local
op
=
0
if
t1
or
t2
or
t3
then
local
m
=
{}
local
n
=
{}
local
m
1
=
{}
local
n
1
=
{}
local
ct
=
1
if
t1
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n
[
ct
]
=
2
ct
=
ct
+
1
end
if
t3
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
4
)
n
[
ct
]
=
3
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
))
op
=
n
[
sp
+
1
]
if
t1
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n1
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n1
[
ct
]
=
2
ct
=
ct
+
1
end
if
t3
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
4
)
n1
[
ct
]
=
3
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
1
))
op
=
n
1
[
sp
+
1
]
end
e
:
SetLabel
(
op
)
if
op
==
1
then
...
...
@@ -128,8 +128,8 @@ function cm.pcop(e,tp,eg,ep,ev,re,r,rp)
e6
:
SetCondition
(
cm
.
tokendes
)
e6
:
SetReset
(
RESET_EVENT
+
0xfe0000
)
token
:
RegisterEffect
(
e6
,
true
)
Duel
.
SpecialSummonComplete
()
c
:
SetCardTarget
(
token
)
Duel
.
SpecialSummonComplete
()
else
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
thfilter
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
...
...
@@ -155,7 +155,7 @@ function cm.tokenatt(e,c)
return
e
:
GetOwner
():
GetAttribute
()
end
function
cm
.
tokendes
(
e
)
return
not
e
:
GetOwner
():
IsHasCardTarget
(
e
:
GetHandler
())
return
not
e
:
GetOwner
():
GetCardTarget
():
IsContains
(
e
:
GetHandler
())
end
function
cm
.
spfilter
(
c
,
e
,
tp
)
return
c
:
IsSetCard
(
0x351
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
IsCanBeSpecialSummoned
(
e
,
0
,
tp
,
false
,
false
)
...
...
expansions/script/c13257302.lua
View file @
572aba05
...
...
@@ -72,13 +72,13 @@ function cm.pctg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
t1
or
t2
end
local
op
=
0
if
t1
or
t2
then
local
m
=
{}
local
n
=
{}
local
m
1
=
{}
local
n
1
=
{}
local
ct
=
1
if
t1
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
))
op
=
n
[
sp
+
1
]
if
t1
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n1
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n1
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
1
))
op
=
n
1
[
sp
+
1
]
end
e
:
SetLabel
(
op
)
if
op
==
1
then
...
...
@@ -147,8 +147,8 @@ function cm.pcop(e,tp,eg,ep,ev,re,r,rp)
e6
:
SetCondition
(
cm
.
tokendes
)
e6
:
SetReset
(
RESET_EVENT
+
0xfe0000
)
token
:
RegisterEffect
(
e6
,
true
)
Duel
.
SpecialSummonComplete
()
c
:
SetCardTarget
(
token
)
Duel
.
SpecialSummonComplete
()
end
end
function
cm
.
tokenatk
(
e
,
c
)
...
...
@@ -167,7 +167,7 @@ function cm.tokenatt(e,c)
return
e
:
GetOwner
():
GetAttribute
()
end
function
cm
.
tokendes
(
e
)
return
not
e
:
GetOwner
():
IsHasCardTarget
(
e
:
GetHandler
())
return
not
e
:
GetOwner
():
GetCardTarget
():
IsContains
(
e
:
GetHandler
())
end
function
cm
.
regop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
...
...
expansions/script/c13257303.lua
View file @
572aba05
...
...
@@ -115,13 +115,13 @@ function cm.pctg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
t1
or
t2
end
local
op
=
0
if
t1
or
t2
then
local
m
=
{}
local
n
=
{}
local
m
1
=
{}
local
n
1
=
{}
local
ct
=
1
if
t1
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
))
op
=
n
[
sp
+
1
]
if
t1
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n1
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n1
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
1
))
op
=
n
1
[
sp
+
1
]
end
e
:
SetLabel
(
op
)
if
op
==
1
then
...
...
@@ -190,8 +190,8 @@ function cm.pcop(e,tp,eg,ep,ev,re,r,rp)
e6
:
SetCondition
(
cm
.
tokendes
)
e6
:
SetReset
(
RESET_EVENT
+
0xfe0000
)
token
:
RegisterEffect
(
e6
,
true
)
Duel
.
SpecialSummonComplete
()
c
:
SetCardTarget
(
token
)
Duel
.
SpecialSummonComplete
()
end
end
function
cm
.
tokenatk
(
e
,
c
)
...
...
@@ -210,7 +210,7 @@ function cm.tokenatt(e,c)
return
e
:
GetOwner
():
GetAttribute
()
end
function
cm
.
tokendes
(
e
)
return
not
e
:
GetOwner
():
IsHasCardTarget
(
e
:
GetHandler
())
return
not
e
:
GetOwner
():
GetCardTarget
():
IsContains
(
e
:
GetHandler
())
end
function
cm
.
bgmop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Hint
(
11
,
0
,
aux
.
Stringid
(
m
,
7
))
...
...
expansions/script/c13257304.lua
View file @
572aba05
...
...
@@ -97,13 +97,13 @@ function cm.pctg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
t1
or
t2
end
local
op
=
0
if
t1
or
t2
then
local
m
=
{}
local
n
=
{}
local
m
1
=
{}
local
n
1
=
{}
local
ct
=
1
if
t1
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
))
op
=
n
[
sp
+
1
]
if
t1
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n1
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n1
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
1
))
op
=
n
1
[
sp
+
1
]
end
e
:
SetLabel
(
op
)
if
op
==
1
then
...
...
@@ -172,8 +172,8 @@ function cm.pcop(e,tp,eg,ep,ev,re,r,rp)
e6
:
SetCondition
(
cm
.
tokendes
)
e6
:
SetReset
(
RESET_EVENT
+
0xfe0000
)
token
:
RegisterEffect
(
e6
,
true
)
Duel
.
SpecialSummonComplete
()
c
:
SetCardTarget
(
token
)
Duel
.
SpecialSummonComplete
()
end
end
function
cm
.
tokenatk
(
e
,
c
)
...
...
@@ -192,7 +192,7 @@ function cm.tokenatt(e,c)
return
e
:
GetOwner
():
GetAttribute
()
end
function
cm
.
tokendes
(
e
)
return
not
e
:
GetOwner
():
IsHasCardTarget
(
e
:
GetHandler
())
return
not
e
:
GetOwner
():
GetCardTarget
():
IsContains
(
e
:
GetHandler
())
end
function
cm
.
tgfilter
(
c
,
tp
)
return
c
:
IsLocation
(
LOCATION_MZONE
)
and
c
:
IsControler
(
tp
)
and
c
:
IsSetCard
(
0x351
)
...
...
expansions/script/c13257305.lua
View file @
572aba05
...
...
@@ -77,14 +77,14 @@ function cm.pctg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
t1
or
t2
end
local
op
=
0
if
t1
or
t2
or
t3
then
local
m
=
{}
local
n
=
{}
local
m
1
=
{}
local
n
1
=
{}
local
ct
=
1
if
t1
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n
[
ct
]
=
2
ct
=
ct
+
1
end
if
t3
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
4
)
n
[
ct
]
=
3
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
))
op
=
n
[
sp
+
1
]
if
t1
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n1
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n1
[
ct
]
=
2
ct
=
ct
+
1
end
if
t3
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
4
)
n1
[
ct
]
=
3
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
1
))
op
=
n
1
[
sp
+
1
]
end
e
:
SetLabel
(
op
)
if
op
==
1
then
...
...
@@ -153,8 +153,8 @@ function cm.pcop(e,tp,eg,ep,ev,re,r,rp)
e6
:
SetCondition
(
cm
.
tokendes
)
e6
:
SetReset
(
RESET_EVENT
+
0xfe0000
)
token
:
RegisterEffect
(
e6
,
true
)
Duel
.
SpecialSummonComplete
()
c
:
SetCardTarget
(
token
)
Duel
.
SpecialSummonComplete
()
elseif
e
:
GetLabel
()
==
3
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_EQUIP
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
eqfilter
,
tp
,
LOCATION_EXTRA
,
0
,
1
,
1
,
nil
,
c
)
...
...
@@ -186,7 +186,7 @@ function cm.tokenatt(e,c)
return
e
:
GetOwner
():
GetAttribute
()
end
function
cm
.
tokendes
(
e
)
return
not
e
:
GetOwner
():
IsHasCardTarget
(
e
:
GetHandler
())
return
not
e
:
GetOwner
():
GetCardTarget
():
IsContains
(
e
:
GetHandler
())
end
function
cm
.
tdfilter
(
c
,
ec
,
tp
)
return
c
:
IsSetCard
(
0x352
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
IsFaceup
()
and
((
c
:
CheckEquipTarget
(
ec
)
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_SZONE
)
>
0
)
or
c
:
IsAbleToExtra
())
...
...
expansions/script/c13257306.lua
View file @
572aba05
...
...
@@ -81,13 +81,13 @@ function cm.pctg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
t1
or
t2
end
local
op
=
0
if
t1
or
t2
then
local
m
=
{}
local
n
=
{}
local
m
1
=
{}
local
n
1
=
{}
local
ct
=
1
if
t1
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
))
op
=
n
[
sp
+
1
]
if
t1
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n1
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n1
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
1
))
op
=
n
1
[
sp
+
1
]
end
e
:
SetLabel
(
op
)
if
op
==
1
then
...
...
@@ -156,8 +156,8 @@ function cm.pcop(e,tp,eg,ep,ev,re,r,rp)
e6
:
SetCondition
(
cm
.
tokendes
)
e6
:
SetReset
(
RESET_EVENT
+
0xfe0000
)
token
:
RegisterEffect
(
e6
,
true
)
Duel
.
SpecialSummonComplete
()
c
:
SetCardTarget
(
token
)
Duel
.
SpecialSummonComplete
()
end
end
function
cm
.
tokenatk
(
e
,
c
)
...
...
@@ -176,7 +176,7 @@ function cm.tokenatt(e,c)
return
e
:
GetOwner
():
GetAttribute
()
end
function
cm
.
tokendes
(
e
)
return
not
e
:
GetOwner
():
IsHasCardTarget
(
e
:
GetHandler
())
return
not
e
:
GetOwner
():
GetCardTarget
():
IsContains
(
e
:
GetHandler
())
end
function
cm
.
tdfilter
(
c
,
ec
,
tp
)
return
c
:
IsSetCard
(
0x352
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
IsFaceup
()
and
((
c
:
CheckEquipTarget
(
ec
)
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_SZONE
)
>
0
)
or
c
:
IsAbleToExtra
())
...
...
expansions/script/c13257307.lua
View file @
572aba05
...
...
@@ -45,7 +45,7 @@ function cm.aclimit(e,re,tp)
end
function
cm
.
actcon
(
e
)
local
f
=
tama
.
cosmicFighters_equipGetFormation
(
e
:
GetHandler
())
return
f
and
f
:
IsContains
(
Duel
.
GetAttacker
())
or
f
:
IsContains
(
Duel
.
GetAttackTarget
(
))
return
f
and
((
Duel
.
GetAttacker
()
and
f
:
IsContains
(
Duel
.
GetAttacker
()))
or
(
Duel
.
GetAttackTarget
()
and
f
:
IsContains
(
Duel
.
GetAttackTarget
())
))
end
function
cm
.
target
(
e
,
c
)
local
f
=
tama
.
cosmicFighters_equipGetFormation
(
e
:
GetHandler
())
...
...
expansions/script/c13257308.lua
View file @
572aba05
...
...
@@ -29,7 +29,7 @@ function cm.initial_effect(c)
e3
:
SetCode
(
EVENT_BATTLE_DESTROYING
)
e3
:
SetRange
(
LOCATION_SZONE
)
e3
:
SetCountLimit
(
1
)
e3
:
Set
Condition
(
cm
.
cacon
)
e3
:
Set
Target
(
cm
.
catg
)
e3
:
SetOperation
(
cm
.
caop
)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
...
...
expansions/script/c13257309.lua
View file @
572aba05
...
...
@@ -54,7 +54,7 @@ function cm.descon(e,tp,eg,ep,ev,re,r,rp)
return
ep
~=
tp
end
function
cm
.
destg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
if
chk
==
0
then
local
f
=
tama
.
cosmicFighters_equipGetFormation
(
e
:
GetHandler
())
return
f
and
tama
.
tamas_groupHasGroupCard
(
eg
,
f
)
end
...
...
@@ -106,7 +106,7 @@ function cm.aclimit(e,re,tp)
end
function
cm
.
actcon
(
e
)
local
f
=
tama
.
cosmicFighters_equipGetFormation
(
e
:
GetHandler
())
return
f
and
f
:
IsContains
(
Duel
.
GetAttacker
())
or
f
:
IsContains
(
Duel
.
GetAttackTarget
(
))
return
f
and
((
Duel
.
GetAttacker
()
and
f
:
IsContains
(
Duel
.
GetAttacker
()))
or
(
Duel
.
GetAttackTarget
()
and
f
:
IsContains
(
Duel
.
GetAttackTarget
())
))
end
function
cm
.
target
(
e
,
c
)
local
f
=
tama
.
cosmicFighters_equipGetFormation
(
e
:
GetHandler
())
...
...
expansions/script/c13257325.lua
View file @
572aba05
...
...
@@ -64,13 +64,13 @@ function cm.pctg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
t1
or
t2
end
local
op
=
0
if
t1
or
t2
then
local
m
=
{}
local
n
=
{}
local
m
1
=
{}
local
n
1
=
{}
local
ct
=
1
if
t1
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
))
op
=
n
[
sp
+
1
]
if
t1
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n1
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n1
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
1
))
op
=
n
1
[
sp
+
1
]
end
e
:
SetLabel
(
op
)
if
op
==
1
then
...
...
@@ -140,8 +140,8 @@ function cm.pcop(e,tp,eg,ep,ev,re,r,rp)
e6
:
SetCondition
(
cm
.
tokendes
)
e6
:
SetReset
(
RESET_EVENT
+
0xfe0000
)
token
:
RegisterEffect
(
e6
,
true
)
Duel
.
SpecialSummonComplete
()
c
:
SetCardTarget
(
token
)
Duel
.
SpecialSummonComplete
()
end
end
function
cm
.
tokenatk
(
e
,
c
)
...
...
@@ -157,7 +157,7 @@ function cm.tokenatt(e,c)
return
e
:
GetOwner
():
GetAttribute
()
end
function
cm
.
tokendes
(
e
)
return
not
e
:
GetOwner
():
IsHasCardTarget
(
e
:
GetHandler
())
return
not
e
:
GetOwner
():
GetCardTarget
():
IsContains
(
e
:
GetHandler
())
end
function
cm
.
upcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
a
=
Duel
.
GetAttacker
()
...
...
expansions/script/c13257326.lua
View file @
572aba05
...
...
@@ -65,13 +65,13 @@ function cm.pctg(e,tp,eg,ep,ev,re,r,rp,chk)
if
chk
==
0
then
return
t1
or
t2
end
local
op
=
0
if
t1
or
t2
then
local
m
=
{}
local
n
=
{}
local
m
1
=
{}
local
n
1
=
{}
local
ct
=
1
if
t1
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
))
op
=
n
[
sp
+
1
]
if
t1
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n1
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n1
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
1
))
op
=
n
1
[
sp
+
1
]
end
e
:
SetLabel
(
op
)
if
op
==
1
then
...
...
@@ -141,8 +141,8 @@ function cm.pcop(e,tp,eg,ep,ev,re,r,rp)
e6
:
SetCondition
(
cm
.
tokendes
)
e6
:
SetReset
(
RESET_EVENT
+
0xfe0000
)
token
:
RegisterEffect
(
e6
,
true
)
Duel
.
SpecialSummonComplete
()
c
:
SetCardTarget
(
token
)
Duel
.
SpecialSummonComplete
()
end
end
function
cm
.
tokenatk
(
e
,
c
)
...
...
@@ -158,7 +158,7 @@ function cm.tokenatt(e,c)
return
e
:
GetOwner
():
GetAttribute
()
end
function
cm
.
tokendes
(
e
)
return
not
e
:
GetOwner
():
IsHasCardTarget
(
e
:
GetHandler
())
return
not
e
:
GetOwner
():
GetCardTarget
():
IsContains
(
e
:
GetHandler
())
end
function
cm
.
upcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
a
=
Duel
.
GetAttacker
()
...
...
expansions/script/c13257327.lua
View file @
572aba05
--超时空战斗机-银银河战机
local
m
=
1325
40
27
local
m
=
1325
73
27
local
cm
=
_G
[
"c"
..
m
]
xpcall
(
function
()
require
(
"expansions/script/tama"
)
end
,
function
()
require
(
"script/tama"
)
end
)
function
cm
.
initial_effect
(
c
)
...
...
@@ -207,13 +207,13 @@ function cm.pcop(e,tp,eg,ep,ev,re,r,rp)
if
not
(
t1
or
t2
)
then
return
end
local
op
=
0
if
t1
or
t2
then
local
m
=
{}
local
n
=
{}
local
m
1
=
{}
local
n
1
=
{}
local
ct
=
1
if
t1
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
))
op
=
n
[
sp
+
1
]
if
t1
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
2
)
n1
[
ct
]
=
1
ct
=
ct
+
1
end
if
t2
then
m
1
[
ct
]
=
aux
.
Stringid
(
m
,
3
)
n1
[
ct
]
=
2
ct
=
ct
+
1
end
local
sp
=
Duel
.
SelectOption
(
tp
,
table.unpack
(
m
1
))
op
=
n
1
[
sp
+
1
]
end
if
op
==
1
then
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_EQUIP
)
...
...
expansions/script/c13257328.lua
0 → 100644
View file @
572aba05
--超时空战斗机-火石战机
local
m
=
13257328
local
cm
=
_G
[
"c"
..
m
]
xpcall
(
function
()
require
(
"expansions/script/tama"
)
end
,
function
()
require
(
"script/tama"
)
end
)
function
cm
.
initial_effect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
m
,
3
))
e1
:
SetCategory
(
CATEGORY_EQUIP
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_O
)
e1
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e1
:
SetProperty
(
EFFECT_FLAG_DAMAGE_STEP
+
EFFECT_FLAG_DELAY
)
e1
:
SetTarget
(
cm
.
eqtg
)
e1
:
SetOperation
(
cm
.
eqop
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
c
:
RegisterEffect
(
e2
)
--Power Capsule
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetDescription
(
aux
.
Stringid
(
m
,
0
))
e3
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_O
)
e3
:
SetCode
(
EVENT_DESTROYED
)
e3
:
SetRange
(
LOCATION_MZONE
)
e3
:
SetProperty
(
EFFECT_FLAG_DAMAGE_STEP
+
EFFECT_FLAG_DELAY
)
e3
:
SetCondition
(
cm
.
pccon
)
e3
:
SetTarget
(
cm
.
pctg
)
e3
:
SetOperation
(
cm
.
pcop
)
c
:
RegisterEffect
(
e3
)
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetDescription
(
aux
.
Stringid
(
m
,
4
))
e4
:
SetCategory
(
CATEGORY_DESTROY
+
CATEGORY_DRAW
)
e4
:
SetType
(
EFFECT_TYPE_IGNITION
)
e4
:
SetRange
(
LOCATION_MZONE
)
e4
:
SetCountLimit
(
1
)
e4
:
SetTarget
(
cm
.
destg
)
e4
:
SetOperation
(
cm
.
desop
)
c
:
RegisterEffect
(
e4
)
local
e11
=
Effect
.
CreateEffect
(
c
)
e11
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e11
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e11
:
SetOperation
(
cm
.
bgmop
)
c
:
RegisterEffect
(
e11
)
eflist
=
{
"power_capsule"
,
e3
}
cm
[
c
]
=
eflist
end
function
cm
.
feqfilter
(
c
,
ec
)
return
c
:
IsCode
(
13257319
)
and
c
:
CheckEquipTarget
(
ec
)
end
function
cm
.
eqtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
GetLocationCount
(
tp
,
LOCATION_SZONE
)
>
0
and
Duel
.
IsExistingMatchingCard
(
cm
.
feqfilter
,
tp
,
LOCATION_EXTRA
,
0
,
1
,
nil
,
e
:
GetHandler
())
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_EQUIP
,
nil
,
1
,
tp
,
LOCATION_EXTRA
)
end
function
cm
.
eqop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_SZONE
)
<=
0
or
c
:
IsFacedown
()
or
not
c
:
IsRelateToEffect
(
e
)
then
return
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_EQUIP
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
feqfilter
,
tp
,
LOCATION_EXTRA
,
0
,
1
,
1
,
nil
,
c
)
local
tc
=
g
:
GetFirst
()
if
tc
then
Duel
.
Equip
(
tp
,
tc
,
c
)
end
end
function
cm
.
desfilter
(
c
)
return
c
:
IsFaceup
()
and
c
:
GetEquipGroup
():
IsExists
(
Card
.
IsCode
,
1
,
nil
,
13257319
)
end
function
cm
.
destg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
cm
.
desfilter
,
tp
,
0
,
LOCATION_MZONE
,
1
,
nil
)
and
Duel
.
IsPlayerCanDraw
(
tp
,
1
)
end
local
g
=
Duel
.
GetMatchingGroup
(
cm
.
desfilter
,
tp
,
0
,
LOCATION_MZONE
,
nil
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DESTROY
,
g
,
g
:
GetCount
(),
0
,
0
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_DRAW
,
nil
,
0
,
tp
,
g
:
GetCount
())
end
function
cm
.
desop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
Duel
.
GetMatchingGroup
(
cm
.
desfilter
,
tp
,
0
,
LOCATION_MZONE
,
nil
)
local
ct
=
Duel
.
Destroy
(
g
,
REASON_EFFECT
)
if
ct
>
0
then
Duel
.
BreakEffect
()
Duel
.
Draw
(
tp
,
ct
,
REASON_EFFECT
)
end
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e1
:
SetCode
(
EFFECT_CANNOT_SPECIAL_SUMMON
)
e1
:
SetReset
(
RESET_PHASE
+
PHASE_END
)
e1
:
SetTargetRange
(
1
,
0
)
Duel
.
RegisterEffect
(
e1
,
tp
)
end
function
cm
.
pcfilter
(
c
,
tp
)
return
c
:
IsReason
(
REASON_BATTLE
+
REASON_EFFECT
)
and
c
:
IsPreviousLocation
(
LOCATION_MZONE
)
and
c
:
GetPreviousControler
()
==
tp
end
function
cm
.
pccon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
eg
:
IsExists
(
cm
.
pcfilter
,
1
,
nil
,
1
-
tp
)
end
function
cm
.
eqfilter
(
c
,
ec
)
return
c
:
IsSetCard
(
0x352
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
CheckEquipTarget
(
ec
)
end
function
cm
.
pctg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
GetLocationCount
(
tp
,
LOCATION_SZONE
)
>
0
and
Duel
.
IsExistingMatchingCard
(
cm
.
eqfilter
,
tp
,
LOCATION_EXTRA
,
0
,
1
,
nil
,
e
:
GetHandler
())
end
e
:
SetCategory
(
CATEGORY_EQUIP
)
Duel
.
SetOperationInfo
(
0
,
CATEGORY_EQUIP
,
nil
,
1
,
tp
,
LOCATION_EXTRA
)
end
function
cm
.
pcop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_SZONE
)
<=
0
or
c
:
IsFacedown
()
or
not
c
:
IsRelateToEffect
(
e
)
then
return
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_EQUIP
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
eqfilter
,
tp
,
LOCATION_EXTRA
,
0
,
1
,
1
,
nil
,
c
)
local
tc
=
g
:
GetFirst
()
if
tc
then
Duel
.
Equip
(
tp
,
tc
,
c
)
end
end
function
cm
.
bgmop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Hint
(
11
,
0
,
aux
.
Stringid
(
m
,
7
))
end
expansions/script/c13257329.lua
View file @
572aba05
--超时空能量胶囊
local
m
=
1325
40
29
local
m
=
1325
73
29
local
cm
=
_G
[
"c"
..
m
]
xpcall
(
function
()
require
(
"expansions/script/tama"
)
end
,
function
()
require
(
"script/tama"
)
end
)
function
cm
.
initial_effect
(
c
)
...
...
@@ -38,7 +38,7 @@ function cm.activate(e,tp,eg,ep,ev,re,r,rp)
if
tc
:
IsRelateToEffect
(
e
)
then
Duel
.
Hint
(
12
,
0
,
aux
.
Stringid
(
m
,
7
))
local
tep
=
tc
:
GetControler
()
local
PCe
=
tama
.
tamas_getTargetTable
(
c
,
"power_capsule"
)
local
PCe
=
tama
.
tamas_getTargetTable
(
t
c
,
"power_capsule"
)
if
PCe
then
local
cost
=
PCe
:
GetCost
()
local
target
=
PCe
:
GetTarget
()
...
...
expansions/script/c13257330.lua
View file @
572aba05
--超时空破坏胶囊
local
m
=
1325
40
30
local
m
=
1325
73
30
local
cm
=
_G
[
"c"
..
m
]
xpcall
(
function
()
require
(
"expansions/script/tama"
)
end
,
function
()
require
(
"script/tama"
)
end
)
function
cm
.
initial_effect
(
c
)
...
...
expansions/script/c13257331.lua
View file @
572aba05
--超时空修复胶囊
local
m
=
1325
40
31
local
m
=
1325
73
31
local
cm
=
_G
[
"c"
..
m
]
xpcall
(
function
()
require
(
"expansions/script/tama"
)
end
,
function
()
require
(
"script/tama"
)
end
)
function
cm
.
initial_effect
(
c
)
...
...
expansions/script/c13257332.lua
View file @
572aba05
--超时空填充胶囊
local
m
=
1325
40
32
local
m
=
1325
73
32
local
cm
=
_G
[
"c"
..
m
]
xpcall
(
function
()
require
(
"expansions/script/tama"
)
end
,
function
()
require
(
"script/tama"
)
end
)
function
cm
.
initial_effect
(
c
)
...
...
expansions/script/c9981016.lua
View file @
572aba05
...
...
@@ -14,7 +14,6 @@ function c9981016.initial_effect(c)
e2
:
SetCategory
(
CATEGORY_SPECIAL_SUMMON
)
e2
:
SetType
(
EFFECT_TYPE_IGNITION
)
e2
:
SetRange
(
LOCATION_HAND
)
e2
:
SetCountLimit
(
1
,
9981016
)
e2
:
SetCost
(
c9981016
.
cost
)
e2
:
SetTarget
(
c9981016
.
sptg
)
e2
:
SetOperation
(
c9981016
.
spop
)
...
...
@@ -26,7 +25,7 @@ function c9981016.initial_effect(c)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_O
)
e3
:
SetProperty
(
EFFECT_FLAG_CARD_TARGET
+
EFFECT_FLAG_DELAY
)
e3
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e3
:
SetCountLimit
(
1
,
1142881
)
e3
:
SetCountLimit
(
1
,
9981016
)
e3
:
SetTarget
(
c9981016
.
sptg2
)
e3
:
SetOperation
(
c9981016
.
spop2
)
c
:
RegisterEffect
(
e3
)
...
...
expansions/script/tama.lua
View file @
572aba05
...
...
@@ -60,7 +60,7 @@ function tama.cosmicFighters_optionFilter(c)
end
function
tama
.
cosmicFighters_getOptions
(
c
)
local
og
=
c
:
GetCardTarget
()
local
g
=
og
:
Filter
(
tama
.
optionFilter
,
nil
)
local
g
=
og
:
Filter
(
tama
.
cosmicFighters_
optionFilter
,
nil
)
return
g
end
function
tama
.
cosmicFighters_getFormation
(
c
)
...
...
@@ -223,19 +223,23 @@ end
function
tama
.
tamas_increaseElements
(
codes
,
add
)
local
toAdd
=
tama
.
DeepCopy
(
codes
)
if
#
toAdd
>
0
then
if
not
tama
.
tamas_checkContainElements
(
toAdd
,
add
)
then
local
i
=
1
while
add
[
i
]
do
if
not
tama
.
tamas_checkElementsHasElement
(
toAdd
,
add
[
i
])
then
table.insert
(
toAdd
,{
add
[
i
][
1
],
0
})
end
end
end
local
i
=
1
while
toAdd
[
i
]
do
local
j
=
1
local
h
=
true
while
add
[
j
]
do
if
toAdd
[
i
][
1
]
==
add
[
j
][
1
]
then
toAdd
[
i
][
2
]
=
toAdd
[
i
][
2
]
+
add
[
j
][
2
]
end
j
=
j
+
1
end
if
not
h
then
table.insert
(
toAdd
,
add
[
j
])
end
i
=
i
+
1
end
else
...
...
@@ -307,6 +311,7 @@ function tama.tamas_checkContainElements(codes,check)
end
return
contain
end
--some elements are equal or lower than 0
function
tama
.
tamas_checkElementsEmpty
(
codes
)
local
i
=
1
local
empty
=
true
...
...
@@ -318,6 +323,18 @@ function tama.tamas_checkElementsEmpty(codes)
end
return
empty
end
--some elements are lower than 0
function
tama
.
tamas_checkElementsLowerEmpty
(
codes
)
local
i
=
1
local
empty
=
true
while
codes
[
i
]
do
if
codes
[
i
][
2
]
>=
0
then
empty
=
false
end
i
=
i
+
1
end
return
empty
end
function
tama
.
tamas_checkGroupElementsForLess
(
g
,
codes
)
local
sg
=
Group
.
CreateGroup
()
local
tc
=
g
:
GetFirst
()
...
...
@@ -657,7 +674,7 @@ function tama.tamas_checkElementsGreater(codes,subCodes,targetCodes)
elements
=
tama
.
tamas_increaseElements
(
elements
,{
subCodes
[
i
]})
end
elements
=
tama
.
tamas_decreaseElements
(
elements
,
targetCodes
)
if
tama
.
tamas_checkContainElements
(
elements
,
targetCodes
)
and
not
tama
.
tamas_checkElementsEmpty
(
elements
)
then
if
tama
.
tamas_checkContainElements
(
elements
,
targetCodes
)
and
not
tama
.
tamas_checkElements
Lower
Empty
(
elements
)
then
greater
=
true
end
until
(
not
subCodes
[
i
]
or
greater
)
...
...
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