Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-scripts-888
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
5
Merge Requests
5
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
MyCard
ygopro-scripts-888
Commits
11f6d8d8
Commit
11f6d8d8
authored
Jun 03, 2024
by
八宫一月
Committed by
GitHub
Jun 03, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update c86852702.lua (#2298)
parent
b847eb44
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
67 additions
and
46 deletions
+67
-46
c86852702.lua
c86852702.lua
+67
-46
No files found.
c86852702.lua
View file @
11f6d8d8
...
...
@@ -7,63 +7,84 @@ function c86852702.initial_effect(c)
e1
:
SetType
(
EFFECT_TYPE_ACTIVATE
)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetCountLimit
(
1
,
86852702
+
EFFECT_COUNT_CODE_OATH
)
e1
:
SetCost
(
c86852702
.
cost
1
)
e1
:
SetTarget
(
c86852702
.
target
1
)
e1
:
SetOperation
(
c86852702
.
activate
1
)
e1
:
SetCost
(
c86852702
.
cost
)
e1
:
SetTarget
(
c86852702
.
target
)
e1
:
SetOperation
(
c86852702
.
activate
)
c
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetDescription
(
aux
.
Stringid
(
86852702
,
1
))
e2
:
SetCost
(
c86852702
.
cost2
)
e2
:
SetTarget
(
c86852702
.
target2
)
e2
:
SetOperation
(
c86852702
.
activate2
)
c
:
RegisterEffect
(
e2
)
end
function
c86852702
.
cost1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
Card
.
IsDiscardable
,
tp
,
LOCATION_HAND
,
0
,
1
,
c
)
end
Duel
.
DiscardHand
(
tp
,
Card
.
IsDiscardable
,
1
,
1
,
REASON_COST
+
REASON_DISCARD
,
nil
)
end
function
c86852702
.
thfilter1
(
c
)
return
c
:
IsSetCard
(
0x36
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
IsAbleToHand
()
end
function
c86852702
.
target1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
g
=
Duel
.
GetMatchingGroup
(
c86852702
.
thfilter1
,
tp
,
LOCATION_DECK
,
0
,
nil
)
if
chk
==
0
then
return
g
:
GetClassCount
(
Card
.
GetCode
)
>=
2
end
Duel
.
Hint
(
HINT_OPSELECTED
,
1
-
tp
,
e
:
GetDescription
())
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
2
,
tp
,
LOCATION_DECK
)
end
function
c86852702
.
activate1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
Duel
.
GetMatchingGroup
(
c86852702
.
thfilter1
,
tp
,
LOCATION_DECK
,
0
,
nil
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
hg
=
g
:
SelectSubGroup
(
tp
,
aux
.
dncheck
,
false
,
2
,
2
)
if
hg
then
Duel
.
SendtoHand
(
hg
,
nil
,
REASON_EFFECT
)
Duel
.
ConfirmCards
(
1
-
tp
,
hg
)
end
function
c86852702
.
cost
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
e
:
SetLabel
(
1
)
if
chk
==
0
then
return
true
end
end
function
c86852702
.
costfilter
(
c
)
return
c
:
IsSetCard
(
0x36
)
and
c
:
IsDiscardable
()
end
function
c86852702
.
cost2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
if
chk
==
0
then
return
Duel
.
IsExistingMatchingCard
(
c86852702
.
costfilter
,
tp
,
LOCATION_HAND
,
0
,
1
,
c
)
end
Duel
.
DiscardHand
(
tp
,
c86852702
.
costfilter
,
1
,
1
,
REASON_COST
+
REASON_DISCARD
,
nil
)
function
c86852702
.
thfilter1
(
c
)
return
c
:
IsSetCard
(
0x36
)
and
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
IsAbleToHand
()
end
function
c86852702
.
thfilter2
(
c
)
return
c
:
IsSetCard
(
0x36
)
and
not
c
:
IsCode
(
86852702
)
and
c
:
IsAbleToHand
()
end
function
c86852702
.
target2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
g
=
Duel
.
GetMatchingGroup
(
c86852702
.
thfilter2
,
tp
,
LOCATION_DECK
,
0
,
nil
)
if
chk
==
0
then
return
g
:
GetClassCount
(
Card
.
GetCode
)
>=
2
end
Duel
.
Hint
(
HINT_OPSELECTED
,
1
-
tp
,
e
:
GetDescription
())
function
c86852702
.
target
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
local
c
=
e
:
GetHandler
()
local
count1
=
Duel
.
GetMatchingGroup
(
c86852702
.
thfilter1
,
tp
,
LOCATION_DECK
,
0
,
nil
):
GetClassCount
(
Card
.
GetCode
)
local
count2
=
Duel
.
GetMatchingGroup
(
c86852702
.
thfilter2
,
tp
,
LOCATION_DECK
,
0
,
nil
):
GetClassCount
(
Card
.
GetCode
)
local
b1
=
Duel
.
IsExistingMatchingCard
(
Card
.
IsDiscardable
,
tp
,
LOCATION_HAND
,
0
,
1
,
c
)
and
count1
>=
2
local
b2
=
Duel
.
IsExistingMatchingCard
(
c86852702
.
costfilter
,
tp
,
LOCATION_HAND
,
0
,
1
,
c
)
and
count2
>=
2
if
chk
==
0
then
if
e
:
GetLabel
()
==
1
then
e
:
SetLabel
(
0
)
return
b1
or
b2
else
return
count1
>=
2
or
count2
>=
2
end
end
if
e
:
GetLabel
()
==
1
then
e
:
SetLabel
(
0
)
local
op
=
0
if
b1
and
b2
then
op
=
Duel
.
SelectOption
(
tp
,
aux
.
Stringid
(
86852702
,
0
),
aux
.
Stringid
(
86852702
,
1
))
elseif
b1
then
op
=
Duel
.
SelectOption
(
tp
,
aux
.
Stringid
(
86852702
,
0
))
else
op
=
Duel
.
SelectOption
(
tp
,
aux
.
Stringid
(
86852702
,
1
))
+
1
end
if
op
==
0
then
Duel
.
DiscardHand
(
tp
,
Card
.
IsDiscardable
,
1
,
1
,
REASON_COST
+
REASON_DISCARD
,
nil
)
else
Duel
.
DiscardHand
(
tp
,
c86852702
.
costfilter
,
1
,
1
,
REASON_COST
+
REASON_DISCARD
,
nil
)
end
e
:
SetLabel
(
0
,
op
)
else
local
op
=
0
if
count1
>=
2
and
count2
>=
2
then
op
=
Duel
.
SelectOption
(
tp
,
aux
.
Stringid
(
86852702
,
0
),
aux
.
Stringid
(
86852702
,
1
))
elseif
count1
>=
2
then
op
=
Duel
.
SelectOption
(
tp
,
aux
.
Stringid
(
86852702
,
0
))
else
op
=
Duel
.
SelectOption
(
tp
,
aux
.
Stringid
(
86852702
,
1
))
+
1
end
e
:
SetLabel
(
0
,
op
)
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_TOHAND
,
nil
,
2
,
tp
,
LOCATION_DECK
)
end
function
c86852702
.
activate2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
Duel
.
GetMatchingGroup
(
c86852702
.
thfilter2
,
tp
,
LOCATION_DECK
,
0
,
nil
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
hg
=
g
:
SelectSubGroup
(
tp
,
aux
.
dncheck
,
false
,
2
,
2
)
if
hg
then
Duel
.
SendtoHand
(
hg
,
nil
,
REASON_EFFECT
)
Duel
.
ConfirmCards
(
1
-
tp
,
hg
)
function
c86852702
.
activate
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
label
,
op
=
e
:
GetLabel
()
if
op
==
0
then
local
g
=
Duel
.
GetMatchingGroup
(
c86852702
.
thfilter1
,
tp
,
LOCATION_DECK
,
0
,
nil
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
hg
=
g
:
SelectSubGroup
(
tp
,
aux
.
dncheck
,
false
,
2
,
2
)
if
hg
then
Duel
.
SendtoHand
(
hg
,
nil
,
REASON_EFFECT
)
Duel
.
ConfirmCards
(
1
-
tp
,
hg
)
end
else
local
g
=
Duel
.
GetMatchingGroup
(
c86852702
.
thfilter2
,
tp
,
LOCATION_DECK
,
0
,
nil
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_ATOHAND
)
local
hg
=
g
:
SelectSubGroup
(
tp
,
aux
.
dncheck
,
false
,
2
,
2
)
if
hg
then
Duel
.
SendtoHand
(
hg
,
nil
,
REASON_EFFECT
)
Duel
.
ConfirmCards
(
1
-
tp
,
hg
)
end
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