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
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
nanahira
ygopro
Commits
10a78ee3
Commit
10a78ee3
authored
Sep 12, 2015
by
salix5
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shuffle
1 in each main_phase
parent
90e82de4
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
8 additions
and
6 deletions
+8
-6
ocgcore/field.cpp
ocgcore/field.cpp
+1
-1
ocgcore/field.h
ocgcore/field.h
+1
-1
ocgcore/playerop.cpp
ocgcore/playerop.cpp
+2
-2
ocgcore/processor.cpp
ocgcore/processor.cpp
+4
-2
No files found.
ocgcore/field.cpp
View file @
10a78ee3
...
...
@@ -27,7 +27,7 @@ field::field(duel* pduel) {
this
->
pduel
=
pduel
;
infos
.
field_id
=
1
;
infos
.
copy_id
=
1
;
infos
.
shuffle_count
=
0
;
infos
.
can_shuffle
=
TRUE
;
infos
.
turn_id
=
0
;
infos
.
card_id
=
1
;
infos
.
phase
=
0
;
...
...
ocgcore/field.h
View file @
10a78ee3
...
...
@@ -115,7 +115,7 @@ struct field_info {
uint8
phase
;
uint8
turn_player
;
uint8
priorities
[
2
];
uint8
shuffle_count
;
uint8
can_shuffle
;
};
struct
lpcost
{
int32
count
;
...
...
ocgcore/playerop.cpp
View file @
10a78ee3
...
...
@@ -139,7 +139,7 @@ int32 field::select_idle_command(uint16 step, uint8 playerid) {
pduel
->
write_buffer8
(
1
);
else
pduel
->
write_buffer8
(
0
);
if
(
infos
.
shuffle_count
<
2
&&
player
[
playerid
].
list_hand
.
size
()
>
1
)
if
(
infos
.
can_shuffle
&&
player
[
playerid
].
list_hand
.
size
()
>
1
)
pduel
->
write_buffer8
(
1
);
else
pduel
->
write_buffer8
(
0
);
...
...
@@ -156,7 +156,7 @@ int32 field::select_idle_command(uint16 step, uint8 playerid) {
||
(
t
==
5
&&
s
>=
core
.
select_chains
.
size
())
||
(
t
==
6
&&
(
infos
.
phase
!=
PHASE_MAIN1
||
!
core
.
to_bp
))
||
(
t
==
7
&&
!
core
.
to_ep
)
||
(
t
==
8
&&
!
(
infos
.
shuffle_count
<
1
&&
player
[
playerid
].
list_hand
.
size
()
>
1
)))
{
||
(
t
==
8
&&
!
(
infos
.
can_shuffle
&&
player
[
playerid
].
list_hand
.
size
()
>
1
)))
{
pduel
->
write_buffer8
(
MSG_RETRY
);
return
FALSE
;
}
...
...
ocgcore/processor.cpp
View file @
10a78ee3
...
...
@@ -2575,7 +2575,7 @@ int32 field::process_idle_command(uint16 step) {
}
else
if
(
ctype
==
8
)
{
core
.
units
.
begin
()
->
step
=
-
1
;
shuffle
(
infos
.
turn_player
,
LOCATION_HAND
);
infos
.
shuffle_count
++
;
infos
.
can_shuffle
=
FALSE
;
return
FALSE
;
}
else
{
core
.
units
.
begin
()
->
step
=
9
;
...
...
@@ -2679,7 +2679,7 @@ int32 field::process_idle_command(uint16 step) {
}
case
11
:
{
returns
.
ivalue
[
0
]
=
core
.
units
.
begin
()
->
arg1
;
infos
.
shuffle_count
=
0
;
infos
.
can_shuffle
=
TRUE
;
return
TRUE
;
}
case
12
:
{
...
...
@@ -4045,6 +4045,7 @@ int32 field::process_turn(uint16 step, uint8 turn_player) {
core
.
delayed_quick_tmp
.
clear
();
pduel
->
write_buffer8
(
MSG_NEW_PHASE
);
pduel
->
write_buffer8
(
infos
.
phase
);
add_process
(
PROCESSOR_IDLE_COMMAND
,
0
,
0
,
0
,
0
,
0
);
return
FALSE
;
}
...
...
@@ -4128,6 +4129,7 @@ int32 field::process_turn(uint16 step, uint8 turn_player) {
core
.
delayed_quick_tmp
.
clear
();
pduel
->
write_buffer8
(
MSG_NEW_PHASE
);
pduel
->
write_buffer8
(
infos
.
phase
);
infos
.
can_shuffle
=
TRUE
;
add_process
(
PROCESSOR_IDLE_COMMAND
,
0
,
0
,
0
,
0
,
0
);
return
FALSE
;
}
...
...
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