Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
V
Vgdpro 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
xiaoye
Vgdpro Scripts
Commits
a366c3e2
Commit
a366c3e2
authored
Feb 27, 2025
by
xiaoye
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update vgfuncLib.lua
parent
ce4fba61
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
43 deletions
+16
-43
vgfuncLib.lua
vgfuncLib.lua
+16
-43
No files found.
vgfuncLib.lua
View file @
a366c3e2
...
@@ -229,28 +229,18 @@ end
...
@@ -229,28 +229,18 @@ end
VgF
.
Effect
.
Damage
=
nil
VgF
.
Effect
.
Damage
=
nil
function
VgF
.
Effect
.
Reset
(
c
,
e
,
code
,
con
)
function
VgF
.
Effect
.
Reset
(
c
,
e
,
code
,
con
)
if
VgF
.
GetValueType
(
e
)
==
"Effect"
then
e
=
VgF
.
GetValueType
(
e
)
==
"Effect"
and
{
e
}
or
(
type
(
e
)
==
"table"
and
e
or
nil
)
if
not
e
then
return
end
for
i
,
v
in
ipairs
(
e
)
do
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetCode
(
code
)
e1
:
SetCode
(
code
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e1
:
SetRange
(
LOCATION_ALL
)
e1
:
SetRange
(
LOCATION_ALL
)
e1
:
SetLabelObject
(
e
)
e1
:
SetLabelObject
(
v
)
if
VgF
.
GetValueType
(
con
)
==
"function"
then
e1
:
SetCondition
(
con
)
end
if
VgF
.
GetValueType
(
con
)
==
"function"
then
e1
:
SetCondition
(
con
)
end
e1
:
SetOperation
(
VgF
.
Effect
.
ResetOperation
)
e1
:
SetOperation
(
VgF
.
Effect
.
ResetOperation
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
elseif
VgF
.
GetValueType
(
e
)
==
"table"
then
for
i
,
v
in
ipairs
(
e
)
do
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
+
EFFECT_TYPE_CONTINUOUS
)
e1
:
SetCode
(
code
)
e1
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e1
:
SetRange
(
LOCATION_ALL
)
e1
:
SetLabelObject
(
v
)
if
VgF
.
GetValueType
(
con
)
==
"function"
then
e1
:
SetCondition
(
con
)
end
e1
:
SetOperation
(
VgF
.
Effect
.
ResetOperation
)
c
:
RegisterEffect
(
e1
)
end
end
end
end
end
function
VgF
.
Effect
.
ResetOperation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
VgF
.
Effect
.
ResetOperation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
...
@@ -708,42 +698,25 @@ end
...
@@ -708,42 +698,25 @@ end
function
Card
.
GetColumnGroup
(
c
)
function
Card
.
GetColumnGroup
(
c
)
local
tp
=
c
:
GetControler
()
local
tp
=
c
:
GetControler
()
local
g
=
Group
.
CreateGroup
()
local
g
=
Group
.
CreateGroup
()
if
c
:
GetSequence
()
==
0
then
if
c
:
IsSequence
(
0
,
1
)
then
local
sg1
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
LOCATION_CIRCLE
,
0
,
nil
,
1
)
-- 左列
local
sg1
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
LOCATION_CIRCLE
,
0
,
nil
,
0
,
1
)
local
sg2
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
0
,
LOCATION_CIRCLE
,
nil
,
3
,
4
)
local
sg2
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
0
,
LOCATION_CIRCLE
,
nil
,
3
,
4
)
if
sg1
:
GetCount
()
>
0
then
g
:
Merge
(
sg1
)
end
if
sg1
:
GetCount
()
>
0
then
g
:
Merge
(
sg1
)
end
if
sg2
:
GetCount
()
>
0
then
g
:
Merge
(
sg2
)
end
if
sg2
:
GetCount
()
>
0
then
g
:
Merge
(
sg2
)
end
end
elseif
c
:
IsSequence
(
2
,
5
)
then
if
c
:
GetSequence
()
==
1
then
-- 中列
local
sg1
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
LOCATION_CIRCLE
,
0
,
nil
,
0
)
local
sg
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
LOCATION_CIRCLE
,
LOCATION_CIRCLE
,
nil
,
2
,
5
)
local
sg2
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
0
,
LOCATION_CIRCLE
,
nil
,
3
,
4
)
if
sg
:
GetCount
()
>
0
then
g
:
Merge
(
sg
)
end
if
sg1
:
GetCount
()
>
0
then
g
:
Merge
(
sg1
)
end
elseif
c
:
IsSequence
(
3
,
4
)
then
if
sg2
:
GetCount
()
>
0
then
g
:
Merge
(
sg2
)
end
-- 右列
end
local
sg1
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
LOCATION_CIRCLE
,
0
,
nil
,
3
,
4
)
if
c
:
GetSequence
()
==
2
then
local
sg1
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
LOCATION_CIRCLE
,
0
,
nil
,
5
)
local
sg2
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
0
,
LOCATION_CIRCLE
,
nil
,
2
,
5
)
if
sg1
:
GetCount
()
>
0
then
g
:
Merge
(
sg1
)
end
if
sg2
:
GetCount
()
>
0
then
g
:
Merge
(
sg2
)
end
end
if
c
:
GetSequence
()
==
3
then
local
sg1
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
LOCATION_CIRCLE
,
0
,
nil
,
4
)
local
sg2
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
0
,
LOCATION_CIRCLE
,
nil
,
0
,
1
)
if
sg1
:
GetCount
()
>
0
then
g
:
Merge
(
sg1
)
end
if
sg2
:
GetCount
()
>
0
then
g
:
Merge
(
sg2
)
end
end
if
c
:
GetSequence
()
==
4
then
local
sg1
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
LOCATION_CIRCLE
,
0
,
nil
,
3
)
local
sg2
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
0
,
LOCATION_CIRCLE
,
nil
,
0
,
1
)
local
sg2
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
0
,
LOCATION_CIRCLE
,
nil
,
0
,
1
)
if
sg1
:
GetCount
()
>
0
then
g
:
Merge
(
sg1
)
end
if
sg1
:
GetCount
()
>
0
then
g
:
Merge
(
sg1
)
end
if
sg2
:
GetCount
()
>
0
then
g
:
Merge
(
sg2
)
end
if
sg2
:
GetCount
()
>
0
then
g
:
Merge
(
sg2
)
end
end
end
if
c
:
GetSequence
()
==
5
then
-- 排除自身
local
sg1
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
LOCATION_CIRCLE
,
0
,
nil
,
2
)
g
:
RemoveCard
(
c
)
local
sg2
=
VgF
.
GetMatchingGroup
(
Card
.
IsSequence
,
tp
,
0
,
LOCATION_CIRCLE
,
nil
,
2
,
5
)
if
sg1
:
GetCount
()
>
0
then
g
:
Merge
(
sg1
)
end
if
sg2
:
GetCount
()
>
0
then
g
:
Merge
(
sg2
)
end
end
return
g
return
g
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