Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-scripts
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
nanahira
ygopro-scripts
Commits
56f27fbb
Commit
56f27fbb
authored
Nov 03, 2024
by
salix5
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add Auxiliary.EnableArcanaCoin
parent
a0f88331
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
35 additions
and
0 deletions
+35
-0
utility.lua
utility.lua
+35
-0
No files found.
utility.lua
View file @
56f27fbb
...
@@ -259,6 +259,41 @@ function Auxiliary.NeosReturnTargetOptional(set_category)
...
@@ -259,6 +259,41 @@ function Auxiliary.NeosReturnTargetOptional(set_category)
if
set_category
then
set_category
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
end
if
set_category
then
set_category
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
end
end
end
end
end
---
---@param c Card
---@param event1 integer
---@param ... integer
function
Auxiliary
.
EnableArcanaCoin
(
c
,
event1
,
...
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
1
)
e1
:
SetCategory
(
CATEGORY_COIN
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
+
EFFECT_TYPE_TRIGGER_F
)
e1
:
SetCode
(
event1
)
e1
:
SetTarget
(
Auxiliary
.
ArcanaCoinTarget
)
e1
:
SetOperation
(
Auxiliary
.
ArcanaCoinOperation
)
c
:
RegisterEffect
(
e1
)
for
_
,
event
in
ipairs
{
...
}
do
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
event
)
c
:
RegisterEffect
(
e2
)
end
end
function
Auxiliary
.
ArcanaCoinTarget
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
chk
)
if
chk
==
0
then
return
true
end
Duel
.
SetOperationInfo
(
0
,
CATEGORY_COIN
,
nil
,
0
,
tp
,
1
)
end
function
Auxiliary
.
ArcanaCoinOperation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
if
not
c
:
IsRelateToEffect
(
e
)
or
c
:
IsFacedown
()
then
return
end
local
res
=
0
if
Duel
.
IsPlayerAffectedByEffect
(
tp
,
73206827
)
then
res
=
1
-
Duel
.
SelectOption
(
tp
,
60
,
61
)
else
res
=
Duel
.
TossCoin
(
tp
,
1
)
c
:
RegisterFlagEffect
(
FLAG_ID_REVERSAL_OF_FATE
,
RESET_EVENT
+
RESETS_STANDARD
,
0
,
1
)
end
c
.
arcanareg
(
c
,
res
)
end
function
Auxiliary
.
IsUnionState
(
effect
)
function
Auxiliary
.
IsUnionState
(
effect
)
local
c
=
effect
:
GetHandler
()
local
c
=
effect
:
GetHandler
()
return
c
:
IsHasEffect
(
EFFECT_UNION_STATUS
)
and
c
:
GetEquipTarget
()
return
c
:
IsHasEffect
(
EFFECT_UNION_STATUS
)
and
c
:
GetEquipTarget
()
...
...
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