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
55d99c07
Commit
55d99c07
authored
Aug 29, 2024
by
xiaoye
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update deepnight
parent
6622dadb
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
32 additions
and
43 deletions
+32
-43
VgD.Lua
VgD.Lua
+29
-0
VgFuncLib.lua
VgFuncLib.lua
+1
-19
c10401043.lua
c10401043.lua
+2
-24
No files found.
VgD.Lua
View file @
55d99c07
...
...
@@ -1318,4 +1318,33 @@ function VgD.CannotBeTarget(c,con,val,loc)
end
)
end
c
:
RegisterEffect
(
e1
)
end
function
VgD
.
NightEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e1
:
SetCode
(
AFFECT_CODE_NIGHT
)
e1
:
SetRange
(
LOCATION_ORDER
)
e1
:
SetTargetRange
(
1
,
0
)
e1
:
SetCondition
(
function
(
e
)
local
tp
=
e
:
GetHandlerPlayer
()
return
not
vgf
.
IsExistingMatchingCard
(
VgD
.
NightFilter
,
tp
,
LOCATION_ORDER
,
0
,
1
,
nil
)
and
vgf
.
GetMatchingGroupCount
(
nil
,
tp
,
LOCATION_ORDER
,
0
,
nil
)
==
1
end
)
c
:
RegisterEffect
(
e1
)
end
function
VgD
.
DeepNightEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e1
:
SetCode
(
AFFECT_CODE_DEEP_NIGHT
)
e1
:
SetRange
(
LOCATION_ORDER
)
e1
:
SetTargetRange
(
1
,
0
)
e1
:
SetCondition
(
function
(
e
)
local
tp
=
e
:
GetHandlerPlayer
()
return
not
vgf
.
IsExistingMatchingCard
(
VgD
.
NightFilter
,
tp
,
LOCATION_ORDER
,
0
,
1
,
nil
)
and
vgf
.
GetMatchingGroupCount
(
nil
,
tp
,
LOCATION_ORDER
,
0
,
nil
)
>=
2
end
)
c
:
RegisterEffect
(
e1
)
end
function
VgD
.
NightFilter
(
c
)
return
not
c
:
IsSetCard
(
0x5040
)
and
c
:
IsType
(
TYPE_CONTINUOUS
)
end
\ No newline at end of file
VgFuncLib.lua
View file @
55d99c07
...
...
@@ -1076,25 +1076,7 @@ function VgF.Sendto(loc,sg,...)
end
if
loc
==
LOCATION_DROP
then
AddOverlayGroup
(
g
,
LOCATION_DROP
)
local
function
repfilter
(
c
,
tp
)
return
c
:
IsControler
(
tp
)
and
(
c
:
IsLocation
(
LOCATION_GZONE
)
or
VgF
.
RMonsterFilter
(
c
))
and
c
:
IsType
(
TYPE_MONSTER
)
and
c
:
GetLevel
()
%
2
==
1
end
local
print
=
0
for
tp
=
0
,
1
do
local
replace_to_overlay_group
=
g
:
Filter
(
repfilter
,
nil
,
tp
)
local
ct
=
replace_to_overlay_group
:
GetCount
()
if
Duel
.
IsPlayerAffectedByEffect
(
tp
,
10501118
)
and
ct
>
0
and
Duel
.
SelectYesNo
(
tp
,
VgF
.
Stringid
(
10501118
,
0
))
then
if
ct
>
1
then
replace_to_overlay_group
=
replace_to_overlay_group
:
Select
(
tp
,
1
,
ct
,
nil
)
end
local
ct1
=
VgF
.
Sendto
(
LOCATION_OVERLAY
,
replace_to_overlay_group
,
VgF
.
GetVMonster
(
tp
))
print
=
print
+
ct1
g
:
Sub
(
replace_to_overlay_group
)
end
end
if
g
:
GetCount
()
>
0
then
local
ct
=
Duel
.
SendtoGrave
(
g
,
...
)
print
=
print
+
ct
end
return
print
return
Duel
.
SendtoGrave
(
g
,
...
)
elseif
loc
==
LOCATION_DECK
then
return
Duel
.
SendtoDeck
(
g
,
...
)
elseif
loc
==
LOCATION_HAND
then
...
...
c10401043.lua
View file @
55d99c07
...
...
@@ -3,34 +3,12 @@ function cm.initial_effect(c)
vgf
.
VgCard
(
c
)
vgd
.
ContinuousSpell
(
c
,
vgf
.
OverlayCost
(
1
))
vgd
.
EffectTypeTrigger
(
c
,
m
,
nil
,
EFFECT_TYPE_SINGLE
,
EVENT_MOVE
,
cm
.
operation
,
nil
,
cm
.
condition
)
--黑夜
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_FIELD
)
e1
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
)
e1
:
SetCode
(
AFFECT_CODE_NIGHT
)
e1
:
SetRange
(
LOCATION_ORDER
)
e1
:
SetTargetRange
(
1
,
0
)
e1
:
SetCondition
(
cm
.
con1
)
c
:
RegisterEffect
(
e1
)
--深渊黑夜
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
AFFECT_CODE_DEEP_NIGHT
)
e2
:
SetCondition
(
cm
.
con2
)
c
:
RegisterEffect
(
e2
)
vgd
.
NightEffect
(
c
)
--黑夜
vgd
.
DeepNightEffect
(
c
)
--深渊黑夜
end
function
cm
.
operation
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
Duel
.
Draw
(
tp
,
1
,
REASON_EFFECT
)
end
function
cm
.
condition
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
e
:
GetHandler
():
IsLocation
(
LOCATION_ORDER
)
end
function
cm
.
con1
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
not
vgf
.
IsExistingMatchingCard
(
cm
.
filter
,
tp
,
LOCATION_ORDER
,
0
,
1
,
nil
)
and
vgf
.
IsExistingMatchingCard
(
Card
.
IsSetCard
,
tp
,
LOCATION_ORDER
,
0
,
1
,
nil
,
0x5040
)
and
not
vgf
.
IsExistingMatchingCard
(
Card
.
IsSetCard
,
tp
,
LOCATION_ORDER
,
0
,
2
,
nil
,
0x5040
)
end
function
cm
.
con2
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
return
not
vgf
.
IsExistingMatchingCard
(
cm
.
filter
,
tp
,
LOCATION_ORDER
,
0
,
1
,
nil
)
and
vgf
.
IsExistingMatchingCard
(
Card
.
IsSetCard
,
tp
,
LOCATION_ORDER
,
0
,
2
,
nil
,
0x5040
)
end
function
cm
.
filter
(
c
)
return
not
c
:
IsSetCard
(
0x5040
)
and
c
:
IsType
(
TYPE_CONTINUOUS
)
end
\ No newline at end of file
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