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
e3d59b7e
Commit
e3d59b7e
authored
Mar 04, 2025
by
xiaoye
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
b763072e
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
13 additions
and
26 deletions
+13
-26
c10402004.lua
c10402004.lua
+1
-1
c10501043.lua
c10501043.lua
+1
-1
c10501064.lua
c10501064.lua
+1
-1
c10501096.lua
c10501096.lua
+1
-1
vgfuncLib.lua
vgfuncLib.lua
+9
-22
No files found.
c10402004.lua
View file @
e3d59b7e
...
@@ -7,7 +7,7 @@ function cm.con(e,tp,eg,ep,ev,re,r,rp)
...
@@ -7,7 +7,7 @@ function cm.con(e,tp,eg,ep,ev,re,r,rp)
end
end
function
cm
.
op
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
cm
.
op
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
vgf
.
SelectMatchingCard
(
HINTMSG_CALL
,
e
,
tp
,
cm
.
filter
,
tp
,
LOCATION_SOUL
,
0
,
0
,
1
,
nil
,
e
,
tp
)
local
g
=
vgf
.
SelectMatchingCard
(
HINTMSG_CALL
,
e
,
tp
,
cm
.
filter
,
tp
,
LOCATION_SOUL
,
0
,
0
,
1
,
nil
,
e
,
tp
)
vgf
.
Sendto
(
LOCATION_CIRCLE
,
g
,
0
,
tp
,
"No
Monster
"
)
vgf
.
Sendto
(
LOCATION_CIRCLE
,
g
,
0
,
tp
,
"No
Unit
"
)
end
end
function
cm
.
filter
(
c
,
e
,
tp
)
function
cm
.
filter
(
c
,
e
,
tp
)
return
c
:
IsCanBeCalled
(
e
,
tp
)
end
return
c
:
IsCanBeCalled
(
e
,
tp
)
end
\ No newline at end of file
c10501043.lua
View file @
e3d59b7e
...
@@ -11,7 +11,7 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
...
@@ -11,7 +11,7 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
Duel
.
ConfirmCards
(
tp
,
g
)
Duel
.
ConfirmCards
(
tp
,
g
)
Duel
.
ConfirmCards
(
1
-
tp
,
g
)
Duel
.
ConfirmCards
(
1
-
tp
,
g
)
local
tc
=
g
:
GetFirst
()
local
tc
=
g
:
GetFirst
()
if
tc
:
IsType
(
TYPE_UNIT
)
and
tc
:
GetLevel
()
~=
2
and
tc
:
IsCanBeCalled
(
e
,
tp
)
and
vgf
.
Sendto
(
LOCATION_CIRCLE
,
tc
,
0
,
tp
,
"No
Monster
"
)
==
0
then
if
tc
:
IsType
(
TYPE_UNIT
)
and
tc
:
GetLevel
()
~=
2
and
tc
:
IsCanBeCalled
(
e
,
tp
)
and
vgf
.
Sendto
(
LOCATION_CIRCLE
,
tc
,
0
,
tp
,
"No
Unit
"
)
==
0
then
Duel
.
MoveSequence
(
tc
,
1
)
Duel
.
MoveSequence
(
tc
,
1
)
end
end
end
end
...
...
c10501064.lua
View file @
e3d59b7e
...
@@ -15,7 +15,7 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
...
@@ -15,7 +15,7 @@ function cm.op(e,tp,eg,ep,ev,re,r,rp)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_CALL
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_CALL
)
local
sg
=
g
:
FilterSelect
(
tp
,
cm
.
filter
,
0
,
2
,
nil
,
e
,
tp
)
local
sg
=
g
:
FilterSelect
(
tp
,
cm
.
filter
,
0
,
2
,
nil
,
e
,
tp
)
if
#
sg
>
0
then
if
#
sg
>
0
then
vgf
.
Sendto
(
LOCATION_CIRCLE
,
sg
,
0
,
tp
,
"No
Monster
"
)
vgf
.
Sendto
(
LOCATION_CIRCLE
,
sg
,
0
,
tp
,
"No
Unit
"
)
end
end
Duel
.
ShuffleDeck
(
tp
)
Duel
.
ShuffleDeck
(
tp
)
end
end
...
...
c10501096.lua
View file @
e3d59b7e
...
@@ -8,7 +8,7 @@ end
...
@@ -8,7 +8,7 @@ end
function
cm
.
op
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
cm
.
op
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
if
c
:
IsRelateToEffect
(
e
)
and
c
:
IsCanBeCalled
(
e
,
tp
)
then
if
c
:
IsRelateToEffect
(
e
)
and
c
:
IsCanBeCalled
(
e
,
tp
)
then
vgf
.
Sendto
(
LOCATION_CIRCLE
,
c
,
0
,
tp
,
"No
Monster
"
)
vgf
.
Sendto
(
LOCATION_CIRCLE
,
c
,
0
,
tp
,
"No
Unit
"
)
end
end
end
end
...
...
vgfuncLib.lua
View file @
e3d59b7e
...
@@ -542,19 +542,6 @@ function VgF.Cost.RetireGroup(g)
...
@@ -542,19 +542,6 @@ function VgF.Cost.RetireGroup(g)
VgF
.
Sendto
(
LOCATION_DROP
,
g
,
REASON_COST
)
VgF
.
Sendto
(
LOCATION_DROP
,
g
,
REASON_COST
)
end
end
end
end
function
VgF
.
IsCanBeCalled
(
c
,
e
,
tp
,
calltyp
,
pos
,
zone
)
local
z
=
0
if
VgF
.
GetValueType
(
zone
)
==
"number"
then
z
=
VgF
.
GetAvailableLocation
(
tp
,
zone
)
elseif
VgF
.
GetValueType
(
zone
)
==
"string"
and
zone
==
"NoMonster"
then
z
=
Duel
.
GetLocationCount
(
tp
,
LOCATION_CIRCLE
)
zone
=
0xff
else
z
=
VgF
.
GetAvailableLocation
(
tp
)
zone
=
0xff
end
if
VgF
.
GetValueType
(
calltyp
)
~=
"number"
then
calltyp
=
0
end
if
VgF
.
GetValueType
(
pos
)
~=
"number"
then
pos
=
POS_FACEUP_ATTACK
end
if
VgF
.
GetValueType
(
zone
)
==
"string"
and
zone
==
"FromSouloV"
then
local
_
,
code
=
c
:
GetOriginalCode
()
return
Duel
.
IsPlayerCanSpecialSummonMonster
(
tp
,
code
,
nil
,
TYPE_UNIT
+
TYPE_NORMAL
,
c
:
GetBaseAttack
(),
c
:
GetBaseDefense
(),
c
:
GetOriginalLevel
(),
c
:
GetOriginalRace
(),
c
:
GetOriginalAttribute
())
end
return
z
>
0
and
c
:
IsCanBeSpecialSummoned
(
e
,
calltyp
,
tp
,
false
,
false
,
pos
,
tp
,
zone
)
end
----catalogue:Cost和Operation均可使用的函数------------------------------------------------------
----catalogue:Cost和Operation均可使用的函数------------------------------------------------------
...
@@ -649,7 +636,7 @@ function VgF.Operation.CardsFromTo(reason ,loc_to, loc_from, f, int_max, int_min
...
@@ -649,7 +636,7 @@ function VgF.Operation.CardsFromTo(reason ,loc_to, loc_from, f, int_max, int_min
end
end
elseif
loc_to
==
LOCATION_V_CIRCLE
then
elseif
loc_to
==
LOCATION_V_CIRCLE
then
local
g
=
VgF
.
SelectMatchingCard
(
HINTMSG_CALL
,
e
,
tp
,
function
(
c
)
local
g
=
VgF
.
SelectMatchingCard
(
HINTMSG_CALL
,
e
,
tp
,
function
(
c
)
if
not
VgF
.
IsCanBeCalled
(
c
,
e
,
tp
)
then
return
false
end
if
not
c
:
IsCanBeCalled
(
e
,
tp
)
then
return
false
end
return
VgF
.
GetValueType
(
f
)
~=
"function"
or
f
(
c
,
table.unpack
(
ext_params
))
return
VgF
.
GetValueType
(
f
)
~=
"function"
or
f
(
c
,
table.unpack
(
ext_params
))
end
,
tp
,
loc_from
,
0
,
int_min
,
int_max
,
nil
)
end
,
tp
,
loc_from
,
0
,
int_min
,
int_max
,
nil
)
if
g
:
GetCount
()
>
0
then
if
g
:
GetCount
()
>
0
then
...
@@ -660,7 +647,7 @@ function VgF.Operation.CardsFromTo(reason ,loc_to, loc_from, f, int_max, int_min
...
@@ -660,7 +647,7 @@ function VgF.Operation.CardsFromTo(reason ,loc_to, loc_from, f, int_max, int_min
elseif
loc_to
==
LOCATION_CIRCLE
then
elseif
loc_to
==
LOCATION_CIRCLE
then
if
VgF
.
GetAvailableLocation
(
tp
)
<
int_min
then
return
0
end
if
VgF
.
GetAvailableLocation
(
tp
)
<
int_min
then
return
0
end
local
g
=
VgF
.
SelectMatchingCard
(
HINTMSG_CALL
,
e
,
tp
,
function
(
c
)
local
g
=
VgF
.
SelectMatchingCard
(
HINTMSG_CALL
,
e
,
tp
,
function
(
c
)
if
not
VgF
.
IsCanBeCalled
(
c
,
e
,
tp
)
then
return
false
end
if
not
c
:
IsCanBeCalled
(
e
,
tp
)
then
return
false
end
return
VgF
.
GetValueType
(
f
)
~=
"function"
or
f
(
c
,
table.unpack
(
ext_params
))
return
VgF
.
GetValueType
(
f
)
~=
"function"
or
f
(
c
,
table.unpack
(
ext_params
))
end
,
tp
,
loc_from
,
0
,
int_min
,
int_max
,
nil
)
end
,
tp
,
loc_from
,
0
,
int_min
,
int_max
,
nil
)
if
g
:
GetCount
()
>
0
then
if
g
:
GetCount
()
>
0
then
...
@@ -865,16 +852,16 @@ end
...
@@ -865,16 +852,16 @@ end
---@return boolean 返回卡片 c 是否可以被玩家 tp 用效果 e[以 calltyp 方式和 callpos 表示形式] Call 到玩家 tp [的区域 zone]
---@return boolean 返回卡片 c 是否可以被玩家 tp 用效果 e[以 calltyp 方式和 callpos 表示形式] Call 到玩家 tp [的区域 zone]
function
Card
.
IsCanBeCalled
(
c
,
e
,
tp
,
calltyp
,
callpos
,
zone
)
function
Card
.
IsCanBeCalled
(
c
,
e
,
tp
,
calltyp
,
callpos
,
zone
)
calltyp
=
calltyp
or
0
calltyp
=
calltyp
or
0
callpos
=
callpos
or
POS_FACEUP_ATTACK
callpos
=
callpos
or
POS_FACEUP_ATTACK
if
zone
==
"FromSoulToV"
then
if
zone
==
"FromSoulToV"
then
local
_
,
code
=
c
:
GetOriginalCode
()
local
_
,
code
=
c
:
GetOriginalCode
()
local
atk
,
def
,
lv
,
race
,
att
=
c
:
GetBaseAttack
(),
c
:
GetBaseDefense
(),
c
:
GetOriginalLevel
(),
c
:
GetOriginalRace
(),
c
:
GetOriginalAttribute
()
local
atk
,
def
,
lv
,
race
,
att
=
c
:
GetBaseAttack
(),
c
:
GetBaseDefense
(),
c
:
GetOriginalLevel
(),
c
:
GetOriginalRace
(),
c
:
GetOriginalAttribute
()
return
Duel
.
IsPlayerCanSpecialSummonMonster
(
tp
,
code
,
nil
,
TYPE_
MONSTER
+
TYPE_EFFECT
,
atk
,
def
,
lv
,
race
,
att
,
callpos
,
tp
,
calltyp
)
return
Duel
.
IsPlayerCanSpecialSummonMonster
(
tp
,
code
,
nil
,
TYPE_
UNIT
+
TYPE_NORMAL
,
atk
,
def
,
lv
,
race
,
att
,
callpos
,
tp
,
calltyp
)
end
end
if
zone
==
"No
Monster
"
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_CIRCLE
)
==
0
then
return
false
end
if
zone
==
"No
Unit
"
and
Duel
.
GetLocationCount
(
tp
,
LOCATION_CIRCLE
)
==
0
then
return
false
end
if
type
(
zone
)
~=
"number"
then
zone
=
0x1f
end
if
type
(
zone
)
~=
"number"
then
zone
=
0x1f
end
if
VgF
.
GetAvailableLocation
(
tp
,
zone
)
==
0
then
return
false
end
if
VgF
.
GetAvailableLocation
(
tp
,
zone
)
==
0
then
return
false
end
return
loccount
>
0
and
c
:
IsCanBeSpecialSummoned
(
e
,
calltyp
,
tp
,
false
,
false
,
callpos
,
tp
,
zone
)
return
c
:
IsCanBeSpecialSummoned
(
e
,
calltyp
,
tp
,
false
,
false
,
callpos
,
tp
,
zone
)
end
end
--catalogue:Group库自定义函数-----------------------------------------------------------------------
--catalogue:Group库自定义函数-----------------------------------------------------------------------
...
@@ -1142,11 +1129,11 @@ end
...
@@ -1142,11 +1129,11 @@ end
function
VgF
.
Call
(
g
,
calltyp
,
tp
,
zone
,
pos
)
function
VgF
.
Call
(
g
,
calltyp
,
tp
,
zone
,
pos
)
if
(
VgF
.
GetValueType
(
g
)
~=
"Card"
and
VgF
.
GetValueType
(
g
)
~=
"Group"
)
or
(
VgF
.
GetValueType
(
g
)
==
"Group"
and
g
:
GetCount
()
==
0
)
then
return
0
end
if
(
VgF
.
GetValueType
(
g
)
~=
"Card"
and
VgF
.
GetValueType
(
g
)
~=
"Group"
)
or
(
VgF
.
GetValueType
(
g
)
==
"Group"
and
g
:
GetCount
()
==
0
)
then
return
0
end
if
VgF
.
GetValueType
(
pos
)
~=
"number"
then
pos
=
POS_FACEUP_ATTACK
end
if
VgF
.
GetValueType
(
pos
)
~=
"number"
then
pos
=
POS_FACEUP_ATTACK
end
if
VgF
.
GetValueType
(
zone
)
==
"string"
and
zone
==
"No
Monster
"
then
if
VgF
.
GetValueType
(
zone
)
==
"string"
and
zone
==
"No
Unit
"
then
return
Duel
.
SpecialSummon
(
g
,
calltyp
,
tp
,
tp
,
false
,
false
,
pos
)
return
Duel
.
SpecialSummon
(
g
,
calltyp
,
tp
,
tp
,
false
,
false
,
pos
)
elseif
VgF
.
GetValueType
(
zone
)
==
"string"
and
zone
==
"FromSouloV"
then
elseif
VgF
.
GetValueType
(
zone
)
==
"string"
and
zone
==
"FromSouloV"
then
local
tc
=
VgF
.
ReturnCard
(
g
)
local
tc
=
VgF
.
ReturnCard
(
g
)
if
not
VgF
.
IsCanBeCalled
(
tc
,
nil
,
tp
,
calltyp
,
pos
,
"FromSouloV"
)
then
return
0
end
if
not
tc
:
IsCanBeCalled
(
nil
,
tp
,
calltyp
,
pos
,
"FromSouloV"
)
then
return
0
end
VgF
.
Sendto
(
0
,
tc
,
tp
,
POS_FACEUP
,
REASON_EFFECT
)
VgF
.
Sendto
(
0
,
tc
,
tp
,
POS_FACEUP
,
REASON_EFFECT
)
local
_
,
code
=
tc
:
GetOriginalCode
()
local
_
,
code
=
tc
:
GetOriginalCode
()
local
c
=
Duel
.
CreateToken
(
tp
,
code
)
local
c
=
Duel
.
CreateToken
(
tp
,
code
)
...
...
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