Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-core
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
ygopro-core
Commits
fdd4c634
Commit
fdd4c634
authored
Jun 17, 2019
by
nekrozar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update Card.IsSynchroSummonable, Duel.SynchroSummon
deal with 斬機超階乗
parent
8024cc58
Changes
6
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
43 additions
and
1 deletion
+43
-1
card.cpp
card.cpp
+9
-1
field.cpp
field.cpp
+2
-0
field.h
field.h
+2
-0
libcard.cpp
libcard.cpp
+8
-0
libduel.cpp
libduel.cpp
+8
-0
operations.cpp
operations.cpp
+14
-0
No files found.
card.cpp
View file @
fdd4c634
...
...
@@ -2923,7 +2923,13 @@ int32 card::is_spsummonable(effect* peffect) {
if
(
pduel
->
game_field
->
core
.
limit_tuner
||
pduel
->
game_field
->
core
.
limit_syn
)
{
pduel
->
lua
->
add_param
(
pduel
->
game_field
->
core
.
limit_tuner
,
PARAM_TYPE_CARD
);
pduel
->
lua
->
add_param
(
pduel
->
game_field
->
core
.
limit_syn
,
PARAM_TYPE_GROUP
);
if
(
pduel
->
lua
->
check_condition
(
peffect
->
condition
,
4
))
uint32
param_count
=
4
;
if
(
pduel
->
game_field
->
core
.
limit_syn_minc
)
{
pduel
->
lua
->
add_param
(
pduel
->
game_field
->
core
.
limit_syn_minc
,
PARAM_TYPE_INT
);
pduel
->
lua
->
add_param
(
pduel
->
game_field
->
core
.
limit_syn_maxc
,
PARAM_TYPE_INT
);
param_count
=
6
;
}
if
(
pduel
->
lua
->
check_condition
(
peffect
->
condition
,
param_count
))
result
=
TRUE
;
}
else
if
(
pduel
->
game_field
->
core
.
limit_xyz
)
{
pduel
->
lua
->
add_param
(
pduel
->
game_field
->
core
.
limit_xyz
,
PARAM_TYPE_GROUP
);
...
...
@@ -3119,6 +3125,8 @@ int32 card::is_special_summonable(uint8 playerid, uint32 summon_type) {
filter_spsummon_procedure
(
playerid
,
&
eset
,
summon_type
);
pduel
->
game_field
->
core
.
limit_tuner
=
0
;
pduel
->
game_field
->
core
.
limit_syn
=
0
;
pduel
->
game_field
->
core
.
limit_syn_minc
=
0
;
pduel
->
game_field
->
core
.
limit_syn_maxc
=
0
;
pduel
->
game_field
->
core
.
limit_xyz
=
0
;
pduel
->
game_field
->
core
.
limit_xyz_minc
=
0
;
pduel
->
game_field
->
core
.
limit_xyz_maxc
=
0
;
...
...
field.cpp
View file @
fdd4c634
...
...
@@ -93,6 +93,8 @@ field::field(duel* pduel) {
core
.
check_level
=
0
;
core
.
limit_tuner
=
0
;
core
.
limit_syn
=
0
;
core
.
limit_syn_minc
=
0
;
core
.
limit_syn_maxc
=
0
;
core
.
limit_xyz
=
0
;
core
.
limit_xyz_minc
=
0
;
core
.
limit_xyz_maxc
=
0
;
...
...
field.h
View file @
fdd4c634
...
...
@@ -262,6 +262,8 @@ struct processor {
card
*
attack_target
;
card
*
limit_tuner
;
group
*
limit_syn
;
int32
limit_syn_minc
;
int32
limit_syn_maxc
;
group
*
limit_xyz
;
int32
limit_xyz_minc
;
int32
limit_xyz_maxc
;
...
...
libcard.cpp
View file @
fdd4c634
...
...
@@ -2005,9 +2005,17 @@ int32 scriptlib::card_is_synchro_summonable(lua_State *L) {
mg
=
*
(
group
**
)
lua_touserdata
(
L
,
3
);
}
}
int32
minc
=
0
;
if
(
lua_gettop
(
L
)
>=
4
)
minc
=
lua_tointeger
(
L
,
4
);
int32
maxc
=
0
;
if
(
lua_gettop
(
L
)
>=
5
)
maxc
=
lua_tointeger
(
L
,
5
);
uint32
p
=
pcard
->
pduel
->
game_field
->
core
.
reason_player
;
pcard
->
pduel
->
game_field
->
core
.
limit_tuner
=
tuner
;
pcard
->
pduel
->
game_field
->
core
.
limit_syn
=
mg
;
pcard
->
pduel
->
game_field
->
core
.
limit_syn_minc
=
minc
;
pcard
->
pduel
->
game_field
->
core
.
limit_syn_maxc
=
maxc
;
lua_pushboolean
(
L
,
pcard
->
is_special_summonable
(
p
,
SUMMON_TYPE_SYNCHRO
));
return
1
;
}
...
...
libduel.cpp
View file @
fdd4c634
...
...
@@ -307,9 +307,17 @@ int32 scriptlib::duel_synchro_summon(lua_State *L) {
mg
=
*
(
group
**
)
lua_touserdata
(
L
,
4
);
}
}
int32
minc
=
0
;
if
(
lua_gettop
(
L
)
>=
5
)
minc
=
lua_tointeger
(
L
,
5
);
int32
maxc
=
0
;
if
(
lua_gettop
(
L
)
>=
6
)
maxc
=
lua_tointeger
(
L
,
6
);
duel
*
pduel
=
pcard
->
pduel
;
pduel
->
game_field
->
core
.
limit_tuner
=
tuner
;
pduel
->
game_field
->
core
.
limit_syn
=
mg
;
pduel
->
game_field
->
core
.
limit_syn_minc
=
minc
;
pduel
->
game_field
->
core
.
limit_syn_maxc
=
maxc
;
pduel
->
game_field
->
core
.
summon_cancelable
=
FALSE
;
pduel
->
game_field
->
special_summon_rule
(
playerid
,
pcard
,
SUMMON_TYPE_SYNCHRO
);
return
lua_yield
(
L
,
0
);
...
...
operations.cpp
View file @
fdd4c634
...
...
@@ -2508,6 +2508,8 @@ int32 field::special_summon_rule(uint16 step, uint8 sumplayer, card* target, uin
effect_set
eset
;
card
*
tuner
=
core
.
limit_tuner
;
group
*
syn
=
core
.
limit_syn
;
int32
sminc
=
core
.
limit_syn_minc
;
int32
smaxc
=
core
.
limit_syn_maxc
;
group
*
xmaterials
=
core
.
limit_xyz
;
int32
xminc
=
core
.
limit_xyz_minc
;
int32
xmaxc
=
core
.
limit_xyz_maxc
;
...
...
@@ -2518,6 +2520,8 @@ int32 field::special_summon_rule(uint16 step, uint8 sumplayer, card* target, uin
target
->
filter_spsummon_procedure_g
(
sumplayer
,
&
eset
);
core
.
limit_tuner
=
tuner
;
core
.
limit_syn
=
syn
;
core
.
limit_syn_minc
=
sminc
;
core
.
limit_syn_maxc
=
smaxc
;
core
.
limit_xyz
=
xmaterials
;
core
.
limit_xyz_minc
=
xminc
;
core
.
limit_xyz_maxc
=
xmaxc
;
...
...
@@ -2551,6 +2555,10 @@ int32 field::special_summon_rule(uint16 step, uint8 sumplayer, card* target, uin
if
(
core
.
limit_tuner
||
core
.
limit_syn
)
{
pduel
->
lua
->
add_param
(
core
.
limit_tuner
,
PARAM_TYPE_CARD
);
pduel
->
lua
->
add_param
(
core
.
limit_syn
,
PARAM_TYPE_GROUP
);
if
(
core
.
limit_syn_minc
)
{
pduel
->
lua
->
add_param
(
core
.
limit_syn_minc
,
PARAM_TYPE_INT
);
pduel
->
lua
->
add_param
(
core
.
limit_syn_maxc
,
PARAM_TYPE_INT
);
}
}
else
if
(
core
.
limit_xyz
)
{
pduel
->
lua
->
add_param
(
core
.
limit_xyz
,
PARAM_TYPE_GROUP
);
if
(
core
.
limit_xyz_minc
)
{
...
...
@@ -2592,6 +2600,12 @@ int32 field::special_summon_rule(uint16 step, uint8 sumplayer, card* target, uin
pduel
->
lua
->
add_param
(
core
.
limit_syn
,
PARAM_TYPE_GROUP
);
core
.
limit_tuner
=
0
;
core
.
limit_syn
=
0
;
if
(
core
.
limit_syn_minc
)
{
pduel
->
lua
->
add_param
(
core
.
limit_syn_minc
,
PARAM_TYPE_INT
);
pduel
->
lua
->
add_param
(
core
.
limit_syn_maxc
,
PARAM_TYPE_INT
);
core
.
limit_syn_minc
=
0
;
core
.
limit_syn_maxc
=
0
;
}
}
if
(
core
.
limit_xyz
)
{
pduel
->
lua
->
add_param
(
core
.
limit_xyz
,
PARAM_TYPE_GROUP
);
...
...
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