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
e5feeae6
Commit
e5feeae6
authored
Nov 22, 2024
by
Chen Bill
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
const reference in card::xyz_overlay
parent
94dcb8a2
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
9 deletions
+7
-9
card.cpp
card.cpp
+3
-4
card.h
card.h
+1
-1
libduel.cpp
libduel.cpp
+3
-4
No files found.
card.cpp
View file @
e5feeae6
...
...
@@ -1569,12 +1569,11 @@ int32 card::get_old_union_count() {
}
return
count
;
}
void
card
::
xyz_overlay
(
c
ard_set
*
materials
)
{
if
(
materials
->
empty
())
void
card
::
xyz_overlay
(
c
onst
card_set
&
materials
)
{
if
(
materials
.
empty
())
return
;
card_set
des
,
leave_grave
,
leave_deck
;
card_vector
cv
;
cv
.
assign
(
materials
->
begin
(),
materials
->
end
());
card_vector
cv
(
materials
.
begin
(),
materials
.
end
());
std
::
sort
(
cv
.
begin
(),
cv
.
end
(),
card
::
card_operation_sort
);
if
(
pduel
->
game_field
->
core
.
global_flag
&
GLOBALFLAG_DECK_REVERSE_CHECK
)
{
int32
d0
=
(
int32
)
pduel
->
game_field
->
player
[
0
].
list_main
.
size
()
-
1
,
s0
=
d0
;
...
...
card.h
View file @
e5feeae6
...
...
@@ -285,7 +285,7 @@ public:
void
unequip
();
int32
get_union_count
();
int32
get_old_union_count
();
void
xyz_overlay
(
c
ard_set
*
materials
);
void
xyz_overlay
(
c
onst
card_set
&
materials
);
void
xyz_add
(
card
*
mat
);
void
xyz_remove
(
card
*
mat
);
void
apply_field_effect
();
...
...
libduel.cpp
View file @
e5feeae6
...
...
@@ -3631,11 +3631,10 @@ int32 scriptlib::duel_overlay(lua_State *L) {
}
else
return
luaL_error
(
L
,
"Parameter %d should be
\"
Card
\"
or
\"
Group
\"
."
,
2
);
if
(
pcard
)
{
card_set
cset
;
cset
.
insert
(
pcard
);
target
->
xyz_overlay
(
&
cset
);
card_set
cset
{
pcard
};
target
->
xyz_overlay
(
cset
);
}
else
target
->
xyz_overlay
(
&
pgroup
->
container
);
target
->
xyz_overlay
(
pgroup
->
container
);
uint32
adjust
=
TRUE
;
if
(
lua_gettop
(
L
)
>
2
)
{
adjust
=
lua_toboolean
(
L
,
3
);
...
...
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