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
Nguyễn Anh Kiệt
ygopro-222DIY-cards
Commits
7be98033
Commit
7be98033
authored
Sep 16, 2021
by
Tachibana
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ndyd
parent
498381d4
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
400 additions
and
399 deletions
+400
-399
expansions/script/c47510239.lua
expansions/script/c47510239.lua
+82
-85
expansions/script/c47530026.lua
expansions/script/c47530026.lua
+160
-158
expansions/script/c47530027.lua
expansions/script/c47530027.lua
+158
-156
No files found.
expansions/script/c47510239.lua
View file @
7be98033
...
...
@@ -4,113 +4,110 @@ local cm=_G["c"..m]
cm
.
dfc_front_side
=
m
cm
.
dfc_back_side
=
m
+
2
function
c47510239
.
initial_effect
(
c
)
aux
.
EnablePendulumAttribute
(
c
)
--summon with 1 tribute
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
47510239
,
0
))
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SUMMON_PROC
)
e1
:
SetCondition
(
c47510239
.
otcon
)
e1
:
SetOperation
(
c47510239
.
otop
)
e1
:
SetValue
(
SUMMON_TYPE_ADVANCE
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EFFECT_SET_PROC
)
c
:
RegisterEffect
(
e2
)
--
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetCategory
(
CATEGORY_TOHAND
+
CATEGORY_SEARCH
)
e4
:
SetType
(
EFFECT_TYPE_CONTINUOUS
+
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_DELAY
)
e4
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e4
:
SetOperation
(
c47510239
.
thop
)
c
:
RegisterEffect
(
e4
)
local
e5
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
47510239
,
2
))
e5
:
SetType
(
EFFECT_TYPE_QUICK_O
)
e5
:
SetRange
(
LOCATION_PZONE
)
e5
:
SetCode
(
EVENT_FREE_CHAIN
)
e5
:
SetCountLimit
(
1
,
47510240
)
e5
:
SetTarget
(
c47510239
.
sumtg
)
e5
:
SetOperation
(
c47510239
.
sumop
)
c
:
RegisterEffect
(
e5
)
--Change
local
e6
=
Effect
.
CreateEffect
(
c
)
e6
:
SetDescription
(
aux
.
Stringid
(
47510239
,
3
))
e6
:
SetType
(
EFFECT_TYPE_IGNITION
)
e6
:
SetRange
(
LOCATION_MZONE
)
e6
:
SetCountLimit
(
1
,
47510239
)
e6
:
SetCost
(
c47510239
.
chcost
)
e6
:
SetTarget
(
c47510239
.
changetg
)
e6
:
SetOperation
(
c47510239
.
changeop
)
c
:
RegisterEffect
(
e6
)
aux
.
EnablePendulumAttribute
(
c
)
--summon with 1 tribute
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
47510239
,
0
))
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_SUMMON_PROC
)
e1
:
SetCondition
(
c47510239
.
otcon
)
e1
:
SetOperation
(
c47510239
.
otop
)
e1
:
SetValue
(
SUMMON_TYPE_ADVANCE
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EFFECT_SET_PROC
)
c
:
RegisterEffect
(
e2
)
--
local
e4
=
Effect
.
CreateEffect
(
c
)
e4
:
SetCategory
(
CATEGORY_TOHAND
+
CATEGORY_SEARCH
)
e4
:
SetType
(
EFFECT_TYPE_CONTINUOUS
+
EFFECT_TYPE_SINGLE
)
e4
:
SetProperty
(
EFFECT_FLAG_DELAY
)
e4
:
SetCode
(
EVENT_SUMMON_SUCCESS
)
e4
:
SetOperation
(
c47510239
.
thop
)
c
:
RegisterEffect
(
e4
)
local
e5
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
aux
.
Stringid
(
47510239
,
2
))
e5
:
SetType
(
EFFECT_TYPE_QUICK_O
)
e5
:
SetRange
(
LOCATION_PZONE
)
e5
:
SetCode
(
EVENT_FREE_CHAIN
)
e5
:
SetCountLimit
(
1
,
47510240
)
e5
:
SetTarget
(
c47510239
.
sumtg
)
e5
:
SetOperation
(
c47510239
.
sumop
)
c
:
RegisterEffect
(
e5
)
--Change
local
e6
=
Effect
.
CreateEffect
(
c
)
e6
:
SetDescription
(
aux
.
Stringid
(
47510239
,
3
))
e6
:
SetType
(
EFFECT_TYPE_IGNITION
)
e6
:
SetRange
(
LOCATION_MZONE
)
e6
:
SetCountLimit
(
1
,
47510239
)
e6
:
SetCost
(
c47510239
.
chcost
)
e6
:
SetTarget
(
c47510239
.
changetg
)
e6
:
SetOperation
(
c47510239
.
changeop
)
c
:
RegisterEffect
(
e6
)
end
function
c47510239
.
otfilter
(
c
)
return
c
:
IsType
(
TYPE_PENDULUM
)
return
c
:
IsType
(
TYPE_PENDULUM
)
end
function
c47510239
.
otcon
(
e
,
c
,
minc
)
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
return
c
:
GetLevel
()
>
4
and
minc
<=
1
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
Duel
.
IsExistingMatchingCard
(
c47510239
.
otfilter
,
tp
,
LOCATION_PZONE
,
0
,
1
,
c
,
tp
)
if
c
==
nil
then
return
true
end
local
tp
=
c
:
GetControler
()
return
c
:
GetLevel
()
>
4
and
minc
<=
1
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
>
0
and
Duel
.
IsExistingMatchingCard
(
c47510239
.
otfilter
,
tp
,
LOCATION_PZONE
,
0
,
1
,
c
,
tp
)
end
function
c47510239
.
otop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_RELEASE
)
local
sg
=
Duel
.
SelectMatchingCard
(
tp
,
c47510239
.
otfilter
,
tp
,
LOCATION_PZONE
,
0
,
1
,
1
,
c
,
tp
)
c
:
SetMaterial
(
sg
)
Duel
.
Release
(
sg
,
REASON_SUMMON
+
REASON_MATERIAL
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_RELEASE
)
local
sg
=
Duel
.
SelectMatchingCard
(
tp
,
c47510239
.
otfilter
,
tp
,
LOCATION_PZONE
,
0
,
1
,
1
,
c
,
tp
)
c
:
SetMaterial
(
sg
)
Duel
.
Release
(
sg
,
REASON_SUMMON
+
REASON_MATERIAL
)
end
function
c47510239
.
thfilter
(
c
,
e
,
tp
,
zone
)
return
c
:
IsType
(
TYPE_PENDULUM
)
and
c
:
IsLevelAbove
(
7
)
and
c
:
IsRace
(
RACE_FAIRY
)
and
c
:
IsAttribute
(
ATTRIBUTE_LIGHT
)
return
c
:
IsType
(
TYPE_PENDULUM
)
and
c
:
IsLevelAbove
(
7
)
and
c
:
IsRace
(
RACE_FAIRY
)
and
c
:
IsAttribute
(
ATTRIBUTE_LIGHT
)
end
function
c47510239
.
thop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SELF
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c47510239
.
thfilter
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
if
g
:
GetCount
()
>
0
then
local
tc
=
g
:
GetFirst
()
if
tc
then
Duel
.
MoveToField
(
tc
,
tp
,
tp
,
LOCATION_PZONE
,
POS_FACEUP
,
true
)
end
end
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SELF
)
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c47510239
.
thfilter
,
tp
,
LOCATION_DECK
,
0
,
1
,
1
,
nil
)
if
g
:
GetCount
()
>
0
then
local
tc
=
g
:
GetFirst
()
if
tc
then
Duel
.
MoveToField
(
tc
,
tp
,
tp
,
LOCATION_PZONE
,
POS_FACEUP
,
true
)
end
end
end
function
c47510239
.
sumfilter
(
c
)
return
c
:
IsFacedown
()
or
not
c
:
IsRace
(
RACE_FAIRY
)
return
c
:
IsFacedown
()
or
not
c
:
IsRace
(
RACE_FAIRY
)
end
function
c47510239
.
sumtg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
if
chk
==
0
then
return
c
:
IsSummonable
(
true
,
nil
,
1
)
or
c
:
IsMSetable
(
true
,
nil
,
1
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SUMMON
,
c
,
1
,
0
,
0
)
local
c
=
e
:
GetHandler
()
local
minc
,
maxc
=
c
:
GetTributeRequirement
()
if
chk
==
0
then
return
Duel
.
IsPlayerCanSummon
(
tp
,
SUMMON_TYPE_ADVANCE
,
c
)
and
Duel
.
CheckTribute
(
c
,
minc
,
maxc
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_SUMMON
,
c
,
1
,
tp
,
LOCATION_PZONE
)
end
function
c47510239
.
sumop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
not
c
:
IsRelateToEffect
(
e
)
then
return
end
local
pos
=
0
if
c
:
IsSummonable
(
true
,
nil
,
1
)
then
pos
=
pos
+
POS_FACEUP_ATTACK
end
if
c
:
IsMSetable
(
true
,
nil
,
1
)
then
pos
=
pos
+
POS_FACEDOWN_DEFENSE
end
if
pos
==
0
then
return
end
if
Duel
.
SelectPosition
(
tp
,
c
,
pos
)
==
POS_FACEUP_ATTACK
then
Duel
.
Summon
(
tp
,
c
,
true
,
nil
,
1
)
else
Duel
.
MSet
(
tp
,
c
,
true
,
nil
,
1
)
end
local
c
=
e
:
GetHandler
()
local
minc
,
maxc
=
c
:
GetTributeRequirement
()
if
not
c
:
IsRelateToEffect
(
e
)
or
not
Duel
.
CheckTribute
(
c
,
minc
,
maxc
)
or
not
Duel
.
IsPlayerCanSummon
(
tp
,
SUMMON_TYPE_ADVANCE
,
c
)
then
return
end
local
SummonCheck
=
Duel
.
CheckTribute
(
c
,
minc
,
maxc
)
if
SummonCheck
then
Duel
.
Summon
(
tp
,
c
,
true
,
nil
,
1
)
end
end
function
c47510239
.
chfilter
(
c
)
return
c
:
IsRace
(
RACE_FAIRY
)
and
c
:
IsLevelAbove
(
7
)
and
c
:
IsAbleToGraveAsCost
()
return
c
:
IsRace
(
RACE_FAIRY
)
and
c
:
IsLevelAbove
(
7
)
and
c
:
IsAbleToGraveAsCost
()
end
function
c47510239
.
chcost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c47510239
.
chfilter
,
tp
,
LOCATION_HAND
+
LOCATION_EXTRA
,
0
,
2
,
nil
)
end
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c47510239
.
chfilter
,
tp
,
LOCATION_HAND
+
LOCATION_EXTRA
,
0
,
2
,
2
,
nil
)
Duel
.
SendtoGrave
(
g
,
REASON_COST
)
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c47510239
.
chfilter
,
tp
,
LOCATION_HAND
+
LOCATION_EXTRA
,
0
,
2
,
nil
)
end
local
g
=
Duel
.
SelectMatchingCard
(
tp
,
c47510239
.
chfilter
,
tp
,
LOCATION_HAND
+
LOCATION_EXTRA
,
0
,
2
,
2
,
nil
)
Duel
.
SendtoGrave
(
g
,
REASON_COST
)
end
function
c47510239
.
changetg
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
if
chk
==
0
then
return
c
.
dfc_back_side
and
c
.
dfc_front_side
==
c
:
GetOriginalCode
()
end
Duel
.
Hint
(
HINT_OPSELECTED
,
1
-
tp
,
e
:
GetDescription
())
local
c
=
e
:
GetHandler
()
if
chk
==
0
then
return
c
.
dfc_back_side
and
c
.
dfc_front_side
==
c
:
GetOriginalCode
()
end
Duel
.
Hint
(
HINT_OPSELECTED
,
1
-
tp
,
e
:
GetDescription
())
end
function
c47510239
.
changeop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
if
not
c
:
IsRelateToEffect
(
e
)
or
c
:
IsFacedown
()
or
c
:
IsImmuneToEffect
(
e
)
then
return
end
local
tcode
=
c
.
dfc_back_side
c
:
SetEntityCode
(
tcode
,
true
)
c
:
ReplaceEffect
(
tcode
,
0
,
0
)
local
c
=
e
:
GetHandler
()
if
not
c
:
IsRelateToEffect
(
e
)
or
c
:
IsFacedown
()
or
c
:
IsImmuneToEffect
(
e
)
then
return
end
local
tcode
=
c
.
dfc_back_side
c
:
SetEntityCode
(
tcode
,
true
)
c
:
ReplaceEffect
(
tcode
,
0
,
0
)
end
\ No newline at end of file
expansions/script/c47530026.lua
View file @
7be98033
This diff is collapsed.
Click to expand it.
expansions/script/c47530027.lua
View file @
7be98033
This diff is collapsed.
Click to expand it.
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