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
e164f5ae
Commit
e164f5ae
authored
Apr 09, 2024
by
jwyxym
Committed by
GitHub
Apr 09, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add files via upload
parent
db2f76c1
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
56 additions
and
14 deletions
+56
-14
VgD.Lua
VgD.Lua
+11
-7
VgFuncLib.lua
VgFuncLib.lua
+43
-3
c10101001.lua
c10101001.lua
+2
-4
No files found.
VgD.Lua
View file @
e164f5ae
...
...
@@ -561,9 +561,7 @@ function VgD.CardTriggerOperation(chkop,f)
VgF
.
AtkUp
(
c
,
g
,
10000
,
nil
)
elseif
c
:
IsRace
(
TRRIGGER_ADVANCE
)
then
local
g
=
Duel
.
GetMatchingGroup
(
VgF
.
IsSequence
,
tp
,
LOCATION_MZONE
,
0
,
nil
,
0
,
4
,
5
)
for
tc
in
VgF
.
Next
(
g
)
do
VgF
.
AtkUp
(
c
,
tc
,
10000
,
nil
)
end
VgF
.
AtkUp
(
c
,
tc
,
10000
,
nil
)
end
if
chkop
==
0
then
if
c
:
IsRace
(
TRRIGGER_SUPER
)
then
...
...
@@ -707,7 +705,7 @@ function VgD.SpellActivate(c,m,op,con,specialchk,num1,num2,num3,num4,num5)
e1
:
SetCode
(
EVENT_FREE_CHAIN
)
e1
:
SetCountLimit
(
1
,
VgID
+
EFFECT_COUNT_CODE_OATH
)
e1
:
SetCost
(
VgD
.
SpellCost
(
num1
,
num2
,
num3
,
num4
,
num5
))
if
VgF
.
GetValueType
(
con
)
==
"function"
then
e1
:
SetCondition
(
con
)
end
e1
:
SetCondition
(
VgD
.
SpellCondtion
(
con
))
e1
:
SetOperation
(
VgD
.
SpellOperation
(
op
))
c
:
RegisterEffect
(
e1
)
end
...
...
@@ -830,6 +828,12 @@ function VgD.SpellCostOp(e,tp,eg,ep,ev,re,r,rp,chk,c,mc,num1,num2,num3,num4,num5
Duel
.
ChangePosition
(
g
,
POS_FACEDOWN
)
end
end
function
VgD
.
SpellCondtion
(
con
)
return
function
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
if
VgF
.
GetValueType
(
con
)
==
"function"
and
not
con
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
then
return
false
end
return
VgF
.
LvCondition
(
e
)
end
end
function
VgD
.
SpellOperation
(
op
)
return
function
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
bool
)
if
op
then
op
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
end
...
...
@@ -880,14 +884,14 @@ function VgD.BeRidedByCardOpCondtion(e,tp,eg,ep,ev,re,r,rp)
return
eg
:
GetFirst
()
==
e
:
GetHandler
()
end
function
VgD
.
EffectTypeTrigger
(
c
,
m
,
loc
,
typ
e
,
code
,
op
,
cost
,
con
,
tg
,
count
,
property
)
function
VgD
.
EffectTypeTrigger
(
c
,
m
,
loc
,
typ
,
code
,
op
,
cost
,
con
,
tg
,
count
,
property
)
local
type2
=
EFFECT_TYPE_TRIGGER_F
if
VgF
.
GetValueType
(
cost
)
==
"function"
then
type2
=
EFFECT_TYPE_TRIGGER_O
end
if
not
typ
e
then
type
=
EFFECT_TYPE_SINGLE
end
if
not
typ
then
typ
=
EFFECT_TYPE_SINGLE
end
if
not
loc
then
loc
=
LOCATION_MZONE
end
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetDescription
(
VgF
.
Stringid
(
m
,
0
))
e1
:
SetType
(
typ
e
+
type2
)
e1
:
SetType
(
typ
+
type2
)
e1
:
SetRange
(
loc
)
e1
:
SetCode
(
code
)
if
property
and
property
>
0
then
e1
:
SetProperty
(
property
)
end
...
...
VgFuncLib.lua
View file @
e164f5ae
...
...
@@ -3,6 +3,7 @@ vgf=VgF
function
VgF
.
VgCard
(
c
)
VgD
.
Rule
(
c
)
VgF
.
DefineArguments
()
if
c
:
IsType
(
TYPE_MONSTER
)
then
VgD
.
RideUp
(
c
)
VgD
.
CallToR
(
c
)
...
...
@@ -19,6 +20,18 @@ end
function
VgF
.
Stringid
(
code
,
id
)
return
code
*
16
+
id
end
function
VgF
.
DefineArguments
()
if
not
loc
then
loc
=
nil
end
if
not
typ
then
typ
=
nil
end
if
not
count
then
count
=
nil
end
if
not
property
then
property
=
nil
end
if
not
reset
then
reset
=
nil
end
if
not
op
then
op
=
nil
end
if
not
cost
then
cost
=
nil
end
if
not
con
then
con
=
nil
end
if
not
tg
then
tg
=
nil
end
if
not
f
then
f
=
nil
end
end
function
VgF
.
SequenceToGlobal
(
p
,
loc
,
seq
)
if
p
~=
0
and
p
~=
1
then
return
0
...
...
@@ -109,10 +122,10 @@ end
function
VgF
.
RMonsterFilter
(
c
)
return
c
:
GetSequence
()
<
5
end
function
VgF
.
RMonsterCondition
(
e
,
c
)
function
VgF
.
RMonsterCondition
(
e
)
return
VgF
.
RMonsterFilter
(
e
:
GetHandler
())
end
function
VgF
.
VMonsterCondition
(
e
,
c
)
function
VgF
.
VMonsterCondition
(
e
)
return
VgF
.
VMonsterFilter
(
e
:
GetHandler
())
end
function
VgF
.
IsLevel
(
c
,
...
)
...
...
@@ -191,7 +204,7 @@ function VgF.tgoval(e,re,rp)
return
rp
==
1
-
e
:
GetHandlerPlayer
()
end
function
VgF
.
Call
(
g
,
sumtype
,
sp
,
zone
)
if
not
zone
then
zone
=
0x
3
f
end
if
not
zone
then
zone
=
0x
1
f
end
return
Duel
.
SpecialSummon
(
g
,
sumtype
,
sp
,
sp
,
true
,
true
,
POS_FACEUP_ATTACK
,
zone
)
end
function
VgF
.
LvCondition
(
e
)
...
...
@@ -207,6 +220,17 @@ function VgF.AtkUp(c,g,val,reset)
if
not
c
or
not
g
then
return
end
if
not
reset
then
reset
=
RESET_PHASE
+
PHASE_END
end
if
not
val
or
val
==
0
then
return
end
if
VgF
.
GetValueType
(
g
)
==
"Group"
and
g
:
GetCount
()
>
0
then
for
tc
in
VgF
.
Next
(
g
)
do
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_UPDATE_ATTACK
)
e1
:
SetValue
(
val
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
reset
)
tc
:
RegisterEffect
(
e1
)
end
return
end
local
tc
=
VgF
.
ReturnCard
(
g
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
...
...
@@ -219,6 +243,22 @@ function VgF.StarUp(c,g,val,reset)
if
not
c
or
not
g
then
return
end
if
not
reset
then
reset
=
RESET_PHASE
+
PHASE_END
end
if
not
val
or
val
==
0
then
return
end
if
VgF
.
GetValueType
(
g
)
==
"Group"
and
g
:
GetCount
()
>
0
then
for
tc
in
VgF
.
Next
(
g
)
do
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetCode
(
EFFECT_UPDATE_LSCALE
)
e1
:
SetProperty
(
EFFECT_FLAG_SINGLE_RANGE
)
e1
:
SetRange
(
LOCATION_MZONE
)
e1
:
SetValue
(
val
)
e1
:
SetReset
(
RESET_EVENT
+
RESETS_STANDARD
+
reset
)
tc
:
RegisterEffect
(
e1
)
local
e2
=
e1
:
Clone
()
e2
:
SetCode
(
EFFECT_UPDATE_RSCALE
)
tc
:
RegisterEffect
(
e2
)
end
return
end
local
tc
=
VgF
.
ReturnCard
(
g
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
...
...
c10101001.lua
View file @
e164f5ae
...
...
@@ -13,13 +13,11 @@ function cm.operation(e,tp,eg,ep,ev,re,r,rp)
local
g
=
Group
.
FromCards
(
c
)
local
sg
=
Duel
.
GetMatchingGroup
(
Card
.
IsSetCard
,
tp
,
LOCATION_MZONE
,
0
,
nil
,
0x201
)
if
sg
then
g
:
Merge
(
sg
)
end
for
tc
in
VgF
.
Next
(
g
)
do
VgF
.
AtkUp
(
c
,
tc
,
10000
,
nil
)
end
vgf
.
AtkUp
(
c
,
g
,
10000
)
end
function
cm
.
op
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
g
=
Duel
.
GetMatchingGroup
(
nil
,
tp
,
LOCATION_DAMAGE
,
0
,
nil
)
for
tc
in
VgF
.
Next
(
g
)
do
for
tc
in
vgf
.
Next
(
g
)
do
Duel
.
ChangePosition
(
tc
,
POS_FACEDOWN
)
end
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