Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro
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
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
Commits
f147b547
Commit
f147b547
authored
Feb 16, 2014
by
Fluorohydride
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
207333cf
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
68 additions
and
18 deletions
+68
-18
ocgcore/libduel.cpp
ocgcore/libduel.cpp
+3
-2
script/c67556500.lua
script/c67556500.lua
+9
-4
script/c93157004.lua
script/c93157004.lua
+28
-6
script/c97489701.lua
script/c97489701.lua
+28
-6
No files found.
ocgcore/libduel.cpp
View file @
f147b547
...
@@ -2648,11 +2648,12 @@ int32 scriptlib::duel_is_player_affected_by_effect(lua_State *L) {
...
@@ -2648,11 +2648,12 @@ int32 scriptlib::duel_is_player_affected_by_effect(lua_State *L) {
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
duel
*
pduel
=
interpreter
::
get_duel_info
(
L
);
int32
playerid
=
lua_tointeger
(
L
,
1
);
int32
playerid
=
lua_tointeger
(
L
,
1
);
if
(
playerid
!=
0
&&
playerid
!=
1
)
{
if
(
playerid
!=
0
&&
playerid
!=
1
)
{
lua_push
boolean
(
L
,
0
);
lua_push
nil
(
L
);
return
1
;
return
1
;
}
}
int32
code
=
lua_tointeger
(
L
,
2
);
int32
code
=
lua_tointeger
(
L
,
2
);
lua_pushboolean
(
L
,
pduel
->
game_field
->
is_player_affected_by_effect
(
playerid
,
code
)
?
1
:
0
);
effect
*
peffect
=
pduel
->
game_field
->
is_player_affected_by_effect
(
playerid
,
code
);
interpreter
::
effect2value
(
L
,
peffect
);
return
1
;
return
1
;
}
}
int32
scriptlib
::
duel_is_player_can_draw
(
lua_State
*
L
)
{
int32
scriptlib
::
duel_is_player_can_draw
(
lua_State
*
L
)
{
...
...
script/c67556500.lua
View file @
f147b547
...
@@ -31,6 +31,7 @@ function c67556500.lvtg(e,tp,eg,ep,ev,re,r,rp,chk)
...
@@ -31,6 +31,7 @@ function c67556500.lvtg(e,tp,eg,ep,ev,re,r,rp,chk)
end
end
function
c67556500
.
lvop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c67556500
.
lvop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
c
=
e
:
GetHandler
()
local
c
=
e
:
GetHandler
()
local
fid
=
0
if
c
:
IsFaceup
()
and
c
:
IsRelateToEffect
(
e
)
then
if
c
:
IsFaceup
()
and
c
:
IsRelateToEffect
(
e
)
then
local
e1
=
Effect
.
CreateEffect
(
c
)
local
e1
=
Effect
.
CreateEffect
(
c
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
e1
:
SetType
(
EFFECT_TYPE_SINGLE
)
...
@@ -38,6 +39,7 @@ function c67556500.lvop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -38,6 +39,7 @@ function c67556500.lvop(e,tp,eg,ep,ev,re,r,rp)
e1
:
SetValue
(
e
:
GetLabel
())
e1
:
SetValue
(
e
:
GetLabel
())
e1
:
SetReset
(
RESET_EVENT
+
0x1ff0000
)
e1
:
SetReset
(
RESET_EVENT
+
0x1ff0000
)
c
:
RegisterEffect
(
e1
)
c
:
RegisterEffect
(
e1
)
fid
=
c
:
GetRealFieldID
()
end
end
local
e2
=
Effect
.
CreateEffect
(
c
)
local
e2
=
Effect
.
CreateEffect
(
c
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
)
e2
:
SetType
(
EFFECT_TYPE_FIELD
)
...
@@ -46,16 +48,19 @@ function c67556500.lvop(e,tp,eg,ep,ev,re,r,rp)
...
@@ -46,16 +48,19 @@ function c67556500.lvop(e,tp,eg,ep,ev,re,r,rp)
e2
:
SetTargetRange
(
1
,
0
)
e2
:
SetTargetRange
(
1
,
0
)
e2
:
SetReset
(
RESET_PHASE
+
PHASE_END
)
e2
:
SetReset
(
RESET_PHASE
+
PHASE_END
)
e2
:
SetTarget
(
c67556500
.
splimit
)
e2
:
SetTarget
(
c67556500
.
splimit
)
e2
:
SetLabel
(
fid
)
Duel
.
RegisterEffect
(
e2
,
tp
)
Duel
.
RegisterEffect
(
e2
,
tp
)
local
e3
=
Effect
.
CreateEffect
(
c
)
local
e3
=
Effect
.
CreateEffect
(
c
)
e3
:
SetType
(
EFFECT_TYPE_SINGLE
)
e3
:
SetType
(
EFFECT_TYPE_FIELD
)
e3
:
SetRange
(
LOCATION_MZONE
)
e3
:
SetCode
(
EFFECT_MUST_BE_SMATERIAL
)
e3
:
SetCode
(
EFFECT_MUST_BE_SMATERIAL
)
e3
:
SetProperty
(
EFFECT_FLAG_CANNOT_DISABLE
)
e3
:
SetProperty
(
EFFECT_FLAG_PLAYER_TARGET
+
EFFECT_FLAG_CANNOT_DISABLE
)
e3
:
SetReset
(
RESET_EVENT
+
0x1fe0000
+
RESET_PHASE
+
PHASE_END
)
e3
:
SetTargetRange
(
1
,
0
)
e3
:
SetReset
(
RESET_EVENT
+
0x1fc0000
+
RESET_PHASE
+
PHASE_END
)
c
:
RegisterEffect
(
e3
)
c
:
RegisterEffect
(
e3
)
end
end
function
c67556500
.
splimit
(
e
,
c
,
sump
,
sumtype
,
sumpos
,
targetp
,
se
)
function
c67556500
.
splimit
(
e
,
c
,
sump
,
sumtype
,
sumpos
,
targetp
,
se
)
return
sumtype
~=
SUMMON_TYPE_SYNCHRO
return
sumtype
~=
SUMMON_TYPE_SYNCHRO
or
e
:
GetOwner
():
GetRealFieldID
()
~=
e
:
GetLabel
()
or
e
:
GetOwner
():
IsFacedown
()
end
end
function
c67556500
.
regop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
function
c67556500
.
regop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
)
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
local
e1
=
Effect
.
CreateEffect
(
e
:
GetHandler
())
...
...
script/c93157004.lua
View file @
f147b547
...
@@ -74,27 +74,43 @@ function c93157004.syncon(e,c,tuner)
...
@@ -74,27 +74,43 @@ function c93157004.syncon(e,c,tuner)
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<-
2
then
return
false
end
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<-
2
then
return
false
end
local
g1
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
g1
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
g2
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
g2
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
local
lv
=
c
:
GetLevel
()
if
tuner
then
if
tuner
then
local
tlv
=
tuner
:
GetLevel
()
local
tlv
=
tuner
:
GetLevel
()
if
lv
-
tlv
<=
0
then
return
false
end
if
lv
-
tlv
<=
0
then
return
false
end
local
f1
=
tuner
.
tuner_filter
local
f1
=
tuner
.
tuner_filter
if
not
pe
then
return
g1
:
IsExists
(
c93157004
.
synfilter2
,
1
,
tuner
,
lv
-
tlv
,
g2
,
f1
,
tuner
)
return
g1
:
IsExists
(
c93157004
.
synfilter2
,
1
,
tuner
,
lv
-
tlv
,
g2
,
f1
,
tuner
)
else
return
c93157004
.
synfilter2
(
pe
:
GetOwner
(),
lv
-
tlv
,
g2
,
f1
,
tuner
)
end
end
end
if
not
pe
then
return
g1
:
IsExists
(
c93157004
.
synfilter1
,
1
,
nil
,
lv
,
g1
,
g2
)
return
g1
:
IsExists
(
c93157004
.
synfilter1
,
1
,
nil
,
lv
,
g1
,
g2
)
else
return
c93157004
.
synfilter1
(
pe
:
GetOwner
(),
lv
,
g1
,
g2
)
end
end
end
function
c93157004
.
synop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
tuner
)
function
c93157004
.
synop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
tuner
)
local
g
=
Group
.
CreateGroup
()
local
g
=
Group
.
CreateGroup
()
local
g1
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
g1
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
g2
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
g2
=
Duel
.
GetMatchingGroup
(
c93157004
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
local
lv
=
c
:
GetLevel
()
if
tuner
then
if
tuner
then
g
:
AddCard
(
tuner
)
g
:
AddCard
(
tuner
)
local
lv1
=
tuner
:
GetLevel
()
local
lv1
=
tuner
:
GetLevel
()
local
f1
=
tuner
.
tuner_filter
local
f1
=
tuner
.
tuner_filter
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner2
=
nil
if
not
pe
then
local
t2
=
g1
:
FilterSelect
(
tp
,
c93157004
.
synfilter2
,
1
,
1
,
tuner
,
lv
-
lv1
,
g2
,
f1
,
tuner
)
local
t2
=
g1
:
FilterSelect
(
tp
,
c93157004
.
synfilter2
,
1
,
1
,
tuner
,
lv
-
lv1
,
g2
,
f1
,
tuner
)
local
tuner2
=
t2
:
GetFirst
()
tuner2
=
t2
:
GetFirst
()
else
tuner2
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner2
):
Select
(
tp
,
1
,
1
,
nil
)
end
g
:
AddCard
(
tuner2
)
g
:
AddCard
(
tuner2
)
local
lv2
=
tuner2
:
GetLevel
()
local
lv2
=
tuner2
:
GetLevel
()
local
f2
=
tuner2
.
tuner_filter
local
f2
=
tuner2
.
tuner_filter
...
@@ -103,8 +119,14 @@ function c93157004.synop(e,tp,eg,ep,ev,re,r,rp,c,tuner)
...
@@ -103,8 +119,14 @@ function c93157004.synop(e,tp,eg,ep,ev,re,r,rp,c,tuner)
g
:
Merge
(
m3
)
g
:
Merge
(
m3
)
else
else
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner1
=
nil
if
not
pe
then
local
t1
=
g1
:
FilterSelect
(
tp
,
c93157004
.
synfilter1
,
1
,
1
,
nil
,
lv
,
g1
,
g2
)
local
t1
=
g1
:
FilterSelect
(
tp
,
c93157004
.
synfilter1
,
1
,
1
,
nil
,
lv
,
g1
,
g2
)
local
tuner1
=
t1
:
GetFirst
()
tuner1
=
t1
:
GetFirst
()
else
tuner1
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner1
):
Select
(
tp
,
1
,
1
,
nil
)
end
g
:
AddCard
(
tuner1
)
g
:
AddCard
(
tuner1
)
local
lv1
=
tuner1
:
GetLevel
()
local
lv1
=
tuner1
:
GetLevel
()
local
f1
=
tuner1
.
tuner_filter
local
f1
=
tuner1
.
tuner_filter
...
...
script/c97489701.lua
View file @
f147b547
...
@@ -81,27 +81,43 @@ function c97489701.syncon(e,c,tuner)
...
@@ -81,27 +81,43 @@ function c97489701.syncon(e,c,tuner)
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<-
2
then
return
false
end
if
Duel
.
GetLocationCount
(
tp
,
LOCATION_MZONE
)
<-
2
then
return
false
end
local
g1
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
g1
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
g2
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
g2
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
local
lv
=
c
:
GetLevel
()
if
tuner
then
if
tuner
then
local
tlv
=
tuner
:
GetLevel
()
local
tlv
=
tuner
:
GetLevel
()
if
lv
-
tlv
<=
0
then
return
false
end
if
lv
-
tlv
<=
0
then
return
false
end
local
f1
=
tuner
.
tuner_filter
local
f1
=
tuner
.
tuner_filter
if
not
pe
then
return
g1
:
IsExists
(
c97489701
.
synfilter2
,
1
,
tuner
,
lv
-
tlv
,
g2
,
f1
,
tuner
)
return
g1
:
IsExists
(
c97489701
.
synfilter2
,
1
,
tuner
,
lv
-
tlv
,
g2
,
f1
,
tuner
)
else
return
c97489701
.
synfilter2
(
pe
:
GetOwner
(),
lv
-
tlv
,
g2
,
f1
,
tuner
)
end
end
end
if
not
pe
then
return
g1
:
IsExists
(
c97489701
.
synfilter1
,
1
,
nil
,
lv
,
g1
,
g2
)
return
g1
:
IsExists
(
c97489701
.
synfilter1
,
1
,
nil
,
lv
,
g1
,
g2
)
else
return
c97489701
.
synfilter1
(
pe
:
GetOwner
(),
lv
,
g1
,
g2
)
end
end
end
function
c97489701
.
synop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
tuner
)
function
c97489701
.
synop
(
e
,
tp
,
eg
,
ep
,
ev
,
re
,
r
,
rp
,
c
,
tuner
)
local
g
=
Group
.
CreateGroup
()
local
g
=
Group
.
CreateGroup
()
local
g1
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
g1
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter1
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
g2
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
g2
=
Duel
.
GetMatchingGroup
(
c97489701
.
matfilter2
,
tp
,
LOCATION_MZONE
,
LOCATION_MZONE
,
nil
,
c
)
local
pe
=
Duel
.
IsPlayerAffectedByEffect
(
tp
,
EFFECT_MUST_BE_SMATERIAL
)
local
lv
=
c
:
GetLevel
()
local
lv
=
c
:
GetLevel
()
if
tuner
then
if
tuner
then
g
:
AddCard
(
tuner
)
g
:
AddCard
(
tuner
)
local
lv1
=
tuner
:
GetLevel
()
local
lv1
=
tuner
:
GetLevel
()
local
f1
=
tuner
.
tuner_filter
local
f1
=
tuner
.
tuner_filter
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner2
=
nil
if
not
pe
then
local
t2
=
g1
:
FilterSelect
(
tp
,
c97489701
.
synfilter2
,
1
,
1
,
tuner
,
lv
-
lv1
,
g2
,
f1
,
tuner
)
local
t2
=
g1
:
FilterSelect
(
tp
,
c97489701
.
synfilter2
,
1
,
1
,
tuner
,
lv
-
lv1
,
g2
,
f1
,
tuner
)
local
tuner2
=
t2
:
GetFirst
()
tuner2
=
t2
:
GetFirst
()
else
tuner2
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner2
):
Select
(
tp
,
1
,
1
,
nil
)
end
g
:
AddCard
(
tuner2
)
g
:
AddCard
(
tuner2
)
local
lv2
=
tuner2
:
GetLevel
()
local
lv2
=
tuner2
:
GetLevel
()
local
f2
=
tuner2
.
tuner_filter
local
f2
=
tuner2
.
tuner_filter
...
@@ -110,8 +126,14 @@ function c97489701.synop(e,tp,eg,ep,ev,re,r,rp,c,tuner)
...
@@ -110,8 +126,14 @@ function c97489701.synop(e,tp,eg,ep,ev,re,r,rp,c,tuner)
g
:
Merge
(
m3
)
g
:
Merge
(
m3
)
else
else
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
Duel
.
Hint
(
HINT_SELECTMSG
,
tp
,
HINTMSG_SMATERIAL
)
local
tuner1
=
nil
if
not
pe
then
local
t1
=
g1
:
FilterSelect
(
tp
,
c97489701
.
synfilter1
,
1
,
1
,
nil
,
lv
,
g1
,
g2
)
local
t1
=
g1
:
FilterSelect
(
tp
,
c97489701
.
synfilter1
,
1
,
1
,
nil
,
lv
,
g1
,
g2
)
local
tuner1
=
t1
:
GetFirst
()
tuner1
=
t1
:
GetFirst
()
else
tuner1
=
pe
:
GetOwner
()
Group
.
FromCards
(
tuner1
):
Select
(
tp
,
1
,
1
,
nil
)
end
g
:
AddCard
(
tuner1
)
g
:
AddCard
(
tuner1
)
local
lv1
=
tuner1
:
GetLevel
()
local
lv1
=
tuner1
:
GetLevel
()
local
f1
=
tuner1
.
tuner_filter
local
f1
=
tuner1
.
tuner_filter
...
...
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