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
3
Merge Requests
3
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
0b1e497d
Commit
0b1e497d
authored
Jun 26, 2025
by
Vury Leo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
draft mono
parent
0844c2fe
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
48 additions
and
9 deletions
+48
-9
procedure.lua
procedure.lua
+48
-9
No files found.
procedure.lua
View file @
0b1e497d
...
@@ -3460,6 +3460,7 @@ function Synchro.AddSynchroProcedure(c,params)
...
@@ -3460,6 +3460,7 @@ function Synchro.AddSynchroProcedure(c,params)
local
tuner_max
=
params
.
tuner_max
or
1
local
tuner_max
=
params
.
tuner_max
or
1
local
non_tuner_min
=
params
.
non_tuner_min
or
1
local
non_tuner_min
=
params
.
non_tuner_min
or
1
local
non_tuner_max
=
params
.
non_tuner_max
or
Synchro
.
Infinite
local
non_tuner_max
=
params
.
non_tuner_max
or
Synchro
.
Infinite
local
base_mapper
=
params
.
base_mapper
or
Synchro
.
LevelMapper
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
1164
)
e1
:
SetDescription
(
1164
)
...
@@ -3467,8 +3468,8 @@ function Synchro.AddSynchroProcedure(c,params)
...
@@ -3467,8 +3468,8 @@ function Synchro.AddSynchroProcedure(c,params)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
e1
:
SetCode
(
EFFECT_SPSUMMON_PROC
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
+
EFFECT_FLAG_UNCOPYABLE
)
e1
:
SetRange
(
LOCATION_EXTRA
)
e1
:
SetRange
(
LOCATION_EXTRA
)
e1
:
SetCondition
(
Synchro
.
SynCondition
(
tuner_filter
,
non_tuner_filter
,
tuner_min
,
tuner_max
,
non_tuner_min
,
non_tuner_max
))
e1
:
SetCondition
(
Synchro
.
SynCondition
(
tuner_filter
,
non_tuner_filter
,
tuner_min
,
tuner_max
,
non_tuner_min
,
non_tuner_max
,
base_mapper
))
e1
:
SetTarget
(
Synchro
.
SynTarget
(
tuner_filter
,
non_tuner_filter
,
tuner_min
,
tuner_max
,
non_tuner_min
,
non_tuner_max
))
e1
:
SetTarget
(
Synchro
.
SynTarget
(
tuner_filter
,
non_tuner_filter
,
tuner_min
,
tuner_max
,
non_tuner_min
,
non_tuner_max
,
base_mapper
))
e1
:
SetOperation
(
Synchro
.
SynOperation
())
e1
:
SetOperation
(
Synchro
.
SynOperation
())
e1
:
SetValue
(
SUMMON_TYPE_SYNCHRO
)
e1
:
SetValue
(
SUMMON_TYPE_SYNCHRO
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
...
@@ -3505,9 +3506,10 @@ function Synchro.CanCompleteSelection(candidates,target_level,tuner_filter,non_t
...
@@ -3505,9 +3506,10 @@ function Synchro.CanCompleteSelection(candidates,target_level,tuner_filter,non_t
possible_sums
=
{[
0
]
=
true
},
possible_sums
=
{[
0
]
=
true
},
tuner_count
=
0
,
tuner_count
=
0
,
non_tuner_count
=
0
,
non_tuner_count
=
0
,
level_mapper
=
base_mapper
or
Synchro
.
LevelMapper
,
priority
=
0
,
level_mapper
=
base_mapper
,
}
}
--- Mono Synchron (priority=2) > Flower Cardian (1) > normal (0)
local
mapper
=
state
.
level_mapper
local
mapper
=
state
.
level_mapper
if
Synchro
.
ExceedsMax
(
state
.
tuner_count
,
tuner_max
)
then
return
false
end
if
Synchro
.
ExceedsMax
(
state
.
tuner_count
,
tuner_max
)
then
return
false
end
...
@@ -3530,6 +3532,43 @@ function Synchro.CanCompleteSelection(candidates,target_level,tuner_filter,non_t
...
@@ -3530,6 +3532,43 @@ function Synchro.CanCompleteSelection(candidates,target_level,tuner_filter,non_t
-- include branch
-- include branch
local
variants
=
{}
local
variants
=
{}
-- 1) MonoSynchron branch (priority<2 → first Mono; priority==2 → full Mono)
if
mc
:
IsCode
(
56897896
)
then
if
state
.
priority
<
2
then
-- first Mono: that one keeps its real level, others=1
local
firstMono
=
mc
local
mono_mapper
=
function
(
c
,
tc_arg
)
if
c
==
firstMono
then
return
{
c
:
GetLevel
()}
else
return
{
1
}
end
end
local
sums1
=
Synchro
.
Updatepossible_sums
(
state
.
possible_sums
,
mono_mapper
(
mc
,
tc
),
target_level
)
if
next
(
sums1
)
then
table.insert
(
variants
,{
sums
=
sums1
,
mapper
=
mono_mapper
,
priority
=
2
,
})
end
elseif
state
.
priority
==
2
then
-- second (or later) Mono: full override—all cards=Level 1
local
full_mapper
=
function
()
return
{
1
}
end
-- reset your sums_so_far into a single bucket of (#selected+1)*1
local
cnt
=#
selected
+
1
local
sums2
=
{[
cnt
]
=
true
}
table.insert
(
variants
,{
sums
=
sums2
,
mapper
=
full_mapper
,
priority
=
2
,
-- stays in Mono mode
})
end
end
-- 1) Normal include branch
-- 1) Normal include branch
local
lvls
=
mapper
(
mc
,
tc
)
local
lvls
=
mapper
(
mc
,
tc
)
local
sums_norm
=
Synchro
.
UpdatepossibleSums
(
state
.
possible_sums
,
lvls
,
target_level
)
local
sums_norm
=
Synchro
.
UpdatepossibleSums
(
state
.
possible_sums
,
lvls
,
target_level
)
...
@@ -3537,7 +3576,7 @@ function Synchro.CanCompleteSelection(candidates,target_level,tuner_filter,non_t
...
@@ -3537,7 +3576,7 @@ function Synchro.CanCompleteSelection(candidates,target_level,tuner_filter,non_t
table.insert
(
variants
,{
sums
=
sums_norm
,
mapper
=
mapper
})
table.insert
(
variants
,{
sums
=
sums_norm
,
mapper
=
mapper
})
end
end
-- 2) override if
Peony
-- 2) override if
Flower Cardian
if
mc
:
IsCode
(
57261568
,
33541430
,
89818984
)
then
if
mc
:
IsCode
(
57261568
,
33541430
,
89818984
)
then
local
cnt
=#
selected
+
1
local
cnt
=#
selected
+
1
local
sums_ovr
=
{[
2
*
cnt
]
=
true
}
local
sums_ovr
=
{[
2
*
cnt
]
=
true
}
...
@@ -3576,7 +3615,7 @@ function Synchro.CanCompleteSelection(candidates,target_level,tuner_filter,non_t
...
@@ -3576,7 +3615,7 @@ function Synchro.CanCompleteSelection(candidates,target_level,tuner_filter,non_t
end
end
--- Synchro condition generator using tuner/non-tuner min/max counts and filters
--- Synchro condition generator using tuner/non-tuner min/max counts and filters
function
Synchro
.
SynCondition
(
tuner_filter
,
non_tuner_filter
,
tuner_min
,
tuner_max
,
non_tuner_min
,
non_tuner_max
)
function
Synchro
.
SynCondition
(
tuner_filter
,
non_tuner_filter
,
tuner_min
,
tuner_max
,
non_tuner_min
,
non_tuner_max
,
base_mapper
)
return
function
(
e
,
c
,
smat
,
mg
,
min
,
max
)
return
function
(
e
,
c
,
smat
,
mg
,
min
,
max
)
if
c
==
nil
then
return
true
end
if
c
==
nil
then
return
true
end
if
c
:
IsType
(
TYPE_PENDULUM
)
and
c
:
IsFaceup
()
then
return
false
end
if
c
:
IsType
(
TYPE_PENDULUM
)
and
c
:
IsFaceup
()
then
return
false
end
...
@@ -3588,7 +3627,7 @@ function Synchro.SynCondition(tuner_filter,non_tuner_filter,tuner_min,tuner_max,
...
@@ -3588,7 +3627,7 @@ function Synchro.SynCondition(tuner_filter,non_tuner_filter,tuner_min,tuner_max,
table.insert
(
candidates
,
mc
)
table.insert
(
candidates
,
mc
)
end
end
return
Synchro
.
CanCompleteSelection
(
candidates
,
target_level
,
tuner_filter
,
non_tuner_filter
,
c
,
tuner_min
,
tuner_max
,
non_tuner_min
,
non_tuner_max
,
Synchro
.
LevelM
apper
)
return
Synchro
.
CanCompleteSelection
(
candidates
,
target_level
,
tuner_filter
,
non_tuner_filter
,
c
,
tuner_min
,
tuner_max
,
non_tuner_min
,
non_tuner_max
,
base_m
apper
)
end
end
end
end
...
@@ -3625,7 +3664,7 @@ function Synchro.SynTarget(tuner_filter,non_tuner_filter,tuner_min,tuner_max,non
...
@@ -3625,7 +3664,7 @@ function Synchro.SynTarget(tuner_filter,non_tuner_filter,tuner_min,tuner_max,non
local
base_states
=
Synchro
.
BuildStatesFromSelection
(
local
base_states
=
Synchro
.
BuildStatesFromSelection
(
test_selection
,
test_selection
,
tuner_filter
,
non_tuner_filter
,
tuner_filter
,
non_tuner_filter
,
base_mapper
or
Synchro
.
LevelMapper
,
base_mapper
,
tc
,
target_level
tc
,
target_level
)
)
...
@@ -3634,7 +3673,7 @@ function Synchro.SynTarget(tuner_filter,non_tuner_filter,tuner_min,tuner_max,non
...
@@ -3634,7 +3673,7 @@ function Synchro.SynTarget(tuner_filter,non_tuner_filter,tuner_min,tuner_max,non
rest_candidates
,
target_level
,
rest_candidates
,
target_level
,
tuner_filter
,
non_tuner_filter
,
tc
,
tuner_filter
,
non_tuner_filter
,
tc
,
tuner_min
,
tuner_max
,
non_tuner_min
,
non_tuner_max
,
tuner_min
,
tuner_max
,
non_tuner_min
,
non_tuner_max
,
nil
,
test_selection
,
1
,
init_state
base_mapper
,
test_selection
,
1
,
init_state
)
)
then
then
addable
:
AddCard
(
candidate
)
addable
:
AddCard
(
candidate
)
...
...
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