Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-222DIY-cards
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
Soulgamer
ygopro-222DIY-cards
Commits
3124b512
Commit
3124b512
authored
Jan 11, 2020
by
TanakaKotoha
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix 2
parent
c6285d14
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
104 additions
and
101 deletions
+104
-101
expansions/script/c22600109.lua
expansions/script/c22600109.lua
+103
-100
expansions/script/c26809023.lua
expansions/script/c26809023.lua
+1
-1
No files found.
expansions/script/c22600109.lua
View file @
3124b512
...
...
@@ -2,134 +2,137 @@
local
m
=
22600109
local
cm
=
_G
[
"c"
..
m
]
function
cm
.
initial_effect
(
c
)
--link summon
aux
.
AddLinkProcedure
(
c
,
cm
.
matfilter
,
1
,
1
)
c
:
EnableReviveLimit
()
--search
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetCategory
(
CATEGORY_HANDES
+
CATEGORY_SEARCH
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_O
)
e1
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetCondition
(
cm
.
scon1
)
e1
:
SetCost
(
cm
.
stg1
)
e1
:
SetOperation
(
cm
.
sop1
)
c
:
RegisterEffect
(
e1
)
--search
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetCategory
(
CATEGORY_SEARCH
)
e2
:
SetType
(
EFFECT_TYPE_IGNITION
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetCountLimit
(
1
)
e2
:
SetCondition
(
cm
.
scon2
)
e2
:
SetCost
(
cm
.
stg2
)
e2
:
SetOperation
(
cm
.
sop2
)
c
:
RegisterEffect
(
e2
)
--return
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e3
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e3
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e3
:
SetCondition
(
cm
.
retcon
)
e3
:
SetOperation
(
cm
.
retreg
)
c
:
RegisterEffect
(
e3
)
--
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetCode
(
EFFECT_CANNOT_BE_LINK_MATERIAL
)
e4
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e4
:
SetValue
(
cm
.
linklimit
)
c
:
RegisterEffect
(
e4
)
--link summon
aux
.
AddLinkProcedure
(
c
,
cm
.
matfilter
,
1
,
1
)
c
:
EnableReviveLimit
()
--search
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetCategory
(
CATEGORY_HANDES
+
CATEGORY_SEARCH
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_O
)
e1
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetCondition
(
cm
.
scon1
)
e1
:
SetCost
(
cm
.
stg1
)
e1
:
SetOperation
(
cm
.
sop1
)
c
:
RegisterEffect
(
e1
)
--search
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetCategory
(
CATEGORY_SEARCH
)
e2
:
SetType
(
EFFECT_TYPE_IGNITION
)
e2
:
SetRange
(
LOCATION_MZONE
)
e2
:
SetCountLimit
(
1
)
e2
:
SetCondition
(
cm
.
scon2
)
e2
:
SetCost
(
cm
.
stg2
)
e2
:
SetOperation
(
cm
.
sop2
)
c
:
RegisterEffect
(
e2
)
--return
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_CONTINUOUS
)
e3
:
SetCode
(
EVENT_SPSUMMON_SUCCESS
)
e3
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e3
:
SetCondition
(
cm
.
retcon
)
e3
:
SetOperation
(
cm
.
retreg
)
c
:
RegisterEffect
(
e3
)
--
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetType
(
EFFECT_TYPE_SINGLE
)
e4
:
SetCode
(
EFFECT_CANNOT_BE_LINK_MATERIAL
)
e4
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e4
:
SetValue
(
cm
.
linklimit
)
c
:
RegisterEffect
(
e4
)
end
function
cm
.
linklimit
(
e
,
c
)
if
not
c
then
return
false
end
return
not
c
:
IsSetCard
(
0x261
)
if
not
c
then
return
false
end
return
not
c
:
IsSetCard
(
0x261
)
end
function
cm
.
matfilter
(
c
)
return
c
:
IsLinkSetCard
(
0x261
)
and
not
c
:
IsType
(
TYPE_LINK
)
return
c
:
IsLinkSetCard
(
0x261
)
and
not
c
:
IsType
(
TYPE_LINK
)
end
function
cm
.
scon1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_LINK
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_LINK
)
end
function
cm
.
filter1
(
c
)
return
c
:
IsSetCard
(
0x261
)
and
c
:
IsAbleToHand
()
return
c
:
IsSetCard
(
0x261
)
and
c
:
IsAbleToHand
()
end
function
cm
.
stg1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
cm
.
filter1
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
1
,
tp
,
LOCATION_DECK
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
cm
.
filter1
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
1
,
tp
,
LOCATION_DECK
)
end
function
cm
.
sop1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
filter1
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
if
g
:
GetCount
()
>
0
then
Duel
.
SendtoHand
(
g
,
nil
,
REASON_EFFECT
)
Duel
.
ConfirmCards
(
1
-
tp
,
g
)
local
g
=
Duel
.
GetFieldGroup
(
tp
,
LOCATION_HAND
,
0
)
if
g
:
GetCount
()
==
0
then
return
end
Duel
.
BreakEffect
()
local
sg
=
g
:
RandomSelect
(
tp
,
1
)
Duel
.
SendtoGrave
(
sg
,
REASON_DISCARD
+
REASON_EFFECT
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
filter1
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
if
g
:
GetCount
()
>
0
then
Duel
.
SendtoHand
(
g
,
nil
,
REASON_EFFECT
)
Duel
.
ConfirmCards
(
1
-
tp
,
g
)
local
g
=
Duel
.
GetFieldGroup
(
tp
,
LOCATION_HAND
,
0
)
if
g
:
GetCount
()
==
0
then
return
end
Duel
.
BreakEffect
()
local
sg
=
g
:
RandomSelect
(
tp
,
1
)
Duel
.
SendtoGrave
(
sg
,
REASON_DISCARD
+
REASON_EFFECT
)
end
end
function
cm
.
scon2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
Duel
.
GetMatchingGroupCount
(
Card
.
IsType
,
tp
,
LOCATION_GRAVE
,
0
,
nil
,
TYPE_SPIRIT
)
>=
5
return
Duel
.
GetMatchingGroupCount
(
Card
.
IsType
,
tp
,
LOCATION_GRAVE
,
0
,
nil
,
TYPE_SPIRIT
)
>=
5
end
function
cm
.
sfilter
(
c
,
att
)
return
c
:
IsAttribute
(
att
)
and
c
:
IsType
(
TYPE_SPIRIT
)
end
function
cm
.
filter2
(
c
,
tp
)
return
c
:
IsType
(
TYPE_SPIRIT
)
and
c
:
IsAbleToHand
()
and
not
Duel
.
IsExistingMatchingCard
(
Card
.
IsAttribute
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
,
c
:
GetAttribute
())
return
c
:
IsType
(
TYPE_SPIRIT
)
and
c
:
IsAbleToHand
()
and
not
Duel
.
IsExistingMatchingCard
(
cm
.
sfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
nil
,
c
:
GetAttribute
())
end
function
cm
.
stg2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
,
chkc
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
cm
.
filter2
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
,
tp
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
1
,
tp
,
LOCATION_DECK
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
cm
.
filter2
,
tp
,
LOCATION_DECK
,
0
,
1
,
nil
,
tp
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
1
,
tp
,
LOCATION_DECK
)
end
function
cm
.
sop2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
filter2
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
,
tp
)
if
g
:
GetCount
()
>
0
then
Duel
.
SendtoHand
(
g
,
nil
,
REASON_EFFECT
)
Duel
.
ConfirmCards
(
1
-
tp
,
g
)
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
filter2
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
,
tp
)
if
g
:
GetCount
()
>
0
then
Duel
.
SendtoHand
(
g
,
nil
,
REASON_EFFECT
)
Duel
.
ConfirmCards
(
1
-
tp
,
g
)
end
end
function
cm
.
retcon
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_LINK
)
return
e
:
GetHandler
():
IsSummonType
(
SUMMON_TYPE_LINK
)
end
function
cm
.
retreg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e1
:
SetDescription
(
1104
)
e1
:
SetCategory
(
CATEGORY_TODECK
+
CATEGORY_TOHAND
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetCountLimit
(
1
)
e1
:
SetReset
(
RESET_EVENT
+
0x1ee0000
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetCondition
(
aux
.
SpiritReturnCondition
)
e1
:
SetTarget
(
cm
.
rettg
)
e1
:
SetOperation
(
cm
.
retop
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_O
)
c
:
RegisterEffect
(
e2
)
local
c
=
e
:
GetHandler
()
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_F
)
e1
:
SetDescription
(
1104
)
e1
:
SetCategory
(
CATEGORY_TODECK
+
CATEGORY_TOHAND
)
e1
:
SetCode
(
EVENT_PHASE
+
PHASE_END
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetCountLimit
(
1
)
e1
:
SetReset
(
RESET_EVENT
+
0x1ee0000
+
RESET_PHASE
+
PHASE_END
)
e1
:
SetCondition
(
aux
.
SpiritReturnCondition
)
e1
:
SetTarget
(
cm
.
rettg
)
e1
:
SetOperation
(
cm
.
retop
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_TRIGGER_O
)
c
:
RegisterEffect
(
e2
)
end
function
cm
.
retfilter
(
c
)
return
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
IsSetCard
(
0x261
)
and
c
:
IsAbleToHand
()
return
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
IsSetCard
(
0x261
)
and
c
:
IsAbleToHand
()
end
function
cm
.
rettg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
if
e
:
IsHasType
(
EFFECT_TYPE_TRIGGER_F
)
then
return
true
else
return
Duel
.
GetMatchingGroupCount
(
cm
.
retfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
>
0
end
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TODECK
,
e
:
GetHandler
(),
1
,
0
,
0
)
if
chk
==
0
then
if
e
:
IsHasType
(
EFFECT_TYPE_TRIGGER_F
)
then
return
true
else
return
Duel
.
GetMatchingGroupCount
(
cm
.
retfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
>
0
end
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TODECK
,
e
:
GetHandler
(),
1
,
0
,
0
)
end
function
cm
.
retop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
and
c
:
IsFaceup
()
and
Duel
.
SendtoDeck
(
c
,
nil
,
2
,
REASON_EFFECT
)
~=
0
and
Duel
.
GetMatchingGroupCount
(
cm
.
retfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
>
0
then
local
g
=
Duel
.
GetMatchingGroup
(
cm
.
retfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
tg
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
retfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
)
Duel
.
SendtoHand
(
tg
,
nil
,
REASON_EFFECT
)
end
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
and
c
:
IsFaceup
()
and
Duel
.
SendtoDeck
(
c
,
nil
,
2
,
REASON_EFFECT
)
~=
0
and
Duel
.
GetMatchingGroupCount
(
cm
.
retfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
>
0
then
local
g
=
Duel
.
GetMatchingGroup
(
cm
.
retfilter
,
tp
,
LOCATION_GRAVE
,
0
,
nil
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
tg
=
Duel
.
SelectMatchingCard
(
tp
,
cm
.
retfilter
,
tp
,
LOCATION_GRAVE
,
0
,
1
,
1
,
nil
)
Duel
.
SendtoHand
(
tg
,
nil
,
REASON_EFFECT
)
end
end
\ No newline at end of file
expansions/script/c26809023.lua
View file @
3124b512
...
...
@@ -71,7 +71,7 @@ function c26809023.spop(e,tp,eg,ep,ev,re,r,rp)
end
end
function
c26809023
.
cfilter
(
c
)
return
c
:
IsType
(
TYPE_EFFECT
)
return
c
:
IsType
(
TYPE_EFFECT
)
and
c
:
IsFaceup
()
end
function
c26809023
.
handcon
(
e
)
local
tp
=
e
:
GetHandlerPlayer
()
...
...
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