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
nanahira
ygopro-core
Commits
4bdb7361
Commit
4bdb7361
authored
Mar 17, 2022
by
salix5
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix warning C6011
parent
29ff1257
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
3 deletions
+6
-3
card.cpp
card.cpp
+3
-2
ocgapi.cpp
ocgapi.cpp
+3
-1
No files found.
card.cpp
View file @
4bdb7361
...
@@ -43,9 +43,10 @@ bool card::card_operation_sort(card* c1, card* c2) {
...
@@ -43,9 +43,10 @@ bool card::card_operation_sort(card* c1, card* c2) {
if
(
c1
->
current
.
location
!=
c2
->
current
.
location
)
if
(
c1
->
current
.
location
!=
c2
->
current
.
location
)
return
c1
->
current
.
location
<
c2
->
current
.
location
;
return
c1
->
current
.
location
<
c2
->
current
.
location
;
if
(
c1
->
current
.
location
&
LOCATION_OVERLAY
)
{
if
(
c1
->
current
.
location
&
LOCATION_OVERLAY
)
{
if(c1->overlay_target->current.sequence != c2->overlay_target->current.sequence)
if
(
c1
->
overlay_target
&&
c2
->
overlay_target
&&
c1
->
overlay_target
->
current
.
sequence
!=
c2
->
overlay_target
->
current
.
sequence
)
return
c1
->
overlay_target
->
current
.
sequence
<
c2
->
overlay_target
->
current
.
sequence
;
return
c1
->
overlay_target
->
current
.
sequence
<
c2
->
overlay_target
->
current
.
sequence
;
else return c1->current.sequence < c2->current.sequence;
else
return
c1
->
current
.
sequence
<
c2
->
current
.
sequence
;
}
else
{
}
else
{
if
(
c1
->
current
.
location
&
(
LOCATION_DECK
|
LOCATION_EXTRA
|
LOCATION_GRAVE
|
LOCATION_REMOVED
))
if
(
c1
->
current
.
location
&
(
LOCATION_DECK
|
LOCATION_EXTRA
|
LOCATION_GRAVE
|
LOCATION_REMOVED
))
return
c1
->
current
.
sequence
>
c2
->
current
.
sequence
;
return
c1
->
current
.
sequence
>
c2
->
current
.
sequence
;
...
...
ocgapi.cpp
View file @
4bdb7361
...
@@ -265,7 +265,7 @@ extern "C" DECL_DLLEXPORT int32 query_field_card(ptr pduel, uint8 playerid, uint
...
@@ -265,7 +265,7 @@ extern "C" DECL_DLLEXPORT int32 query_field_card(ptr pduel, uint8 playerid, uint
}
}
}
}
else
{
else
{
field
::
card_vector
*
lst
=
0
;
field
::
card_vector
*
lst
=
nullptr
;
if
(
location
==
LOCATION_HAND
)
if
(
location
==
LOCATION_HAND
)
lst
=
&
player
.
list_hand
;
lst
=
&
player
.
list_hand
;
else
if
(
location
==
LOCATION_GRAVE
)
else
if
(
location
==
LOCATION_GRAVE
)
...
@@ -276,6 +276,8 @@ extern "C" DECL_DLLEXPORT int32 query_field_card(ptr pduel, uint8 playerid, uint
...
@@ -276,6 +276,8 @@ extern "C" DECL_DLLEXPORT int32 query_field_card(ptr pduel, uint8 playerid, uint
lst
=
&
player
.
list_extra
;
lst
=
&
player
.
list_extra
;
else
if
(
location
==
LOCATION_DECK
)
else
if
(
location
==
LOCATION_DECK
)
lst
=
&
player
.
list_main
;
lst
=
&
player
.
list_main
;
else
return
0
;
for
(
auto
&
pcard
:
*
lst
)
{
for
(
auto
&
pcard
:
*
lst
)
{
uint32
clen
=
pcard
->
get_infos
(
p
,
query_flag
,
use_cache
);
uint32
clen
=
pcard
->
get_infos
(
p
,
query_flag
,
use_cache
);
p
+=
clen
;
p
+=
clen
;
...
...
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