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
b28973f0
Commit
b28973f0
authored
Nov 22, 2024
by
salix5
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
const reference in field::change_position
parent
a46f29d6
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
8 deletions
+7
-8
field.h
field.h
+1
-1
libduel.cpp
libduel.cpp
+3
-4
operations.cpp
operations.cpp
+3
-3
No files found.
field.h
View file @
b28973f0
...
@@ -585,7 +585,7 @@ public:
...
@@ -585,7 +585,7 @@ public:
void
send_to
(
const
card_set
&
targets
,
effect
*
reason_effect
,
uint32
reason
,
uint32
reason_player
,
uint32
playerid
,
uint32
destination
,
uint32
sequence
,
uint32
position
,
uint8
send_activating
=
FALSE
);
void
send_to
(
const
card_set
&
targets
,
effect
*
reason_effect
,
uint32
reason
,
uint32
reason_player
,
uint32
playerid
,
uint32
destination
,
uint32
sequence
,
uint32
position
,
uint8
send_activating
=
FALSE
);
void
send_to
(
card
*
target
,
effect
*
reason_effect
,
uint32
reason
,
uint32
reason_player
,
uint32
playerid
,
uint32
destination
,
uint32
sequence
,
uint32
position
,
uint8
send_activating
=
FALSE
);
void
send_to
(
card
*
target
,
effect
*
reason_effect
,
uint32
reason
,
uint32
reason_player
,
uint32
playerid
,
uint32
destination
,
uint32
sequence
,
uint32
position
,
uint8
send_activating
=
FALSE
);
void
move_to_field
(
card
*
target
,
uint32
move_player
,
uint32
playerid
,
uint32
destination
,
uint32
positions
,
uint32
enable
=
FALSE
,
uint32
ret
=
0
,
uint32
pzone
=
FALSE
,
uint32
zone
=
0xff
);
void
move_to_field
(
card
*
target
,
uint32
move_player
,
uint32
playerid
,
uint32
destination
,
uint32
positions
,
uint32
enable
=
FALSE
,
uint32
ret
=
0
,
uint32
pzone
=
FALSE
,
uint32
zone
=
0xff
);
void
change_position
(
c
ard_set
*
targets
,
effect
*
reason_effect
,
uint32
reason_player
,
uint32
au
,
uint32
ad
,
uint32
du
,
uint32
dd
,
uint32
flag
,
uint32
enable
=
FALSE
);
void
change_position
(
c
onst
card_set
&
targets
,
effect
*
reason_effect
,
uint32
reason_player
,
uint32
au
,
uint32
ad
,
uint32
du
,
uint32
dd
,
uint32
flag
,
uint32
enable
=
FALSE
);
void
change_position
(
card
*
target
,
effect
*
reason_effect
,
uint32
reason_player
,
uint32
npos
,
uint32
flag
,
uint32
enable
=
FALSE
);
void
change_position
(
card
*
target
,
effect
*
reason_effect
,
uint32
reason_player
,
uint32
npos
,
uint32
flag
,
uint32
enable
=
FALSE
);
void
operation_replace
(
int32
type
,
int32
step
,
group
*
targets
);
void
operation_replace
(
int32
type
,
int32
step
,
group
*
targets
);
void
select_tribute_cards
(
card
*
target
,
uint8
playerid
,
uint8
cancelable
,
int32
min
,
int32
max
,
uint8
toplayer
,
uint32
zone
);
void
select_tribute_cards
(
card
*
target
,
uint8
playerid
,
uint8
cancelable
,
int32
min
,
int32
max
,
uint8
toplayer
,
uint32
zone
);
...
...
libduel.cpp
View file @
b28973f0
...
@@ -806,11 +806,10 @@ int32 scriptlib::duel_change_form(lua_State *L) {
...
@@ -806,11 +806,10 @@ int32 scriptlib::duel_change_form(lua_State *L) {
if
(
top
>
4
)
dd
=
(
uint32
)
lua_tointeger
(
L
,
5
);
if
(
top
>
4
)
dd
=
(
uint32
)
lua_tointeger
(
L
,
5
);
if
(
top
>
5
&&
lua_toboolean
(
L
,
6
))
flag
|=
NO_FLIP_EFFECT
;
if
(
top
>
5
&&
lua_toboolean
(
L
,
6
))
flag
|=
NO_FLIP_EFFECT
;
if
(
pcard
)
{
if
(
pcard
)
{
card_set
cset
;
card_set
cset
{
pcard
};
cset
.
insert
(
pcard
);
pduel
->
game_field
->
change_position
(
cset
,
pduel
->
game_field
->
core
.
reason_effect
,
pduel
->
game_field
->
core
.
reason_player
,
au
,
ad
,
du
,
dd
,
flag
,
TRUE
);
pduel
->
game_field
->
change_position
(
&
cset
,
pduel
->
game_field
->
core
.
reason_effect
,
pduel
->
game_field
->
core
.
reason_player
,
au
,
ad
,
du
,
dd
,
flag
,
TRUE
);
}
else
}
else
pduel
->
game_field
->
change_position
(
&
(
pgroup
->
container
)
,
pduel
->
game_field
->
core
.
reason_effect
,
pduel
->
game_field
->
core
.
reason_player
,
au
,
ad
,
du
,
dd
,
flag
,
TRUE
);
pduel
->
game_field
->
change_position
(
pgroup
->
container
,
pduel
->
game_field
->
core
.
reason_effect
,
pduel
->
game_field
->
core
.
reason_player
,
au
,
ad
,
du
,
dd
,
flag
,
TRUE
);
return
lua_yieldk
(
L
,
0
,
(
lua_KContext
)
pduel
,
[](
lua_State
*
L
,
int32
status
,
lua_KContext
ctx
)
{
return
lua_yieldk
(
L
,
0
,
(
lua_KContext
)
pduel
,
[](
lua_State
*
L
,
int32
status
,
lua_KContext
ctx
)
{
duel
*
pduel
=
(
duel
*
)
ctx
;
duel
*
pduel
=
(
duel
*
)
ctx
;
lua_pushinteger
(
L
,
pduel
->
game_field
->
returns
.
ivalue
[
0
]);
lua_pushinteger
(
L
,
pduel
->
game_field
->
returns
.
ivalue
[
0
]);
...
...
operations.cpp
View file @
b28973f0
...
@@ -294,10 +294,10 @@ void field::move_to_field(card* target, uint32 move_player, uint32 playerid, uin
...
@@ -294,10 +294,10 @@ void field::move_to_field(card* target, uint32 move_player, uint32 playerid, uin
target
->
to_field_param
=
(
move_player
<<
24
)
+
(
playerid
<<
16
)
+
(
destination
<<
8
)
+
positions
;
target
->
to_field_param
=
(
move_player
<<
24
)
+
(
playerid
<<
16
)
+
(
destination
<<
8
)
+
positions
;
add_process
(
PROCESSOR_MOVETOFIELD
,
0
,
0
,
(
group
*
)
target
,
enable
,
ret
+
(
pzone
<<
8
),
zone
);
add_process
(
PROCESSOR_MOVETOFIELD
,
0
,
0
,
(
group
*
)
target
,
enable
,
ret
+
(
pzone
<<
8
),
zone
);
}
}
void
field
::
change_position
(
c
ard_set
*
targets
,
effect
*
reason_effect
,
uint32
reason_player
,
uint32
au
,
uint32
ad
,
uint32
du
,
uint32
dd
,
uint32
flag
,
uint32
enable
)
{
void
field
::
change_position
(
c
onst
card_set
&
targets
,
effect
*
reason_effect
,
uint32
reason_player
,
uint32
au
,
uint32
ad
,
uint32
du
,
uint32
dd
,
uint32
flag
,
uint32
enable
)
{
group
*
ng
=
pduel
->
new_group
(
*
targets
);
group
*
ng
=
pduel
->
new_group
(
targets
);
ng
->
is_readonly
=
GTYPE_READ_ONLY
;
ng
->
is_readonly
=
GTYPE_READ_ONLY
;
for
(
auto
&
pcard
:
*
targets
)
{
for
(
auto
&
pcard
:
targets
)
{
if
(
pcard
->
current
.
position
==
POS_FACEUP_ATTACK
)
if
(
pcard
->
current
.
position
==
POS_FACEUP_ATTACK
)
pcard
->
position_param
=
au
;
pcard
->
position_param
=
au
;
else
if
(
pcard
->
current
.
position
==
POS_FACEDOWN_DEFENSE
)
else
if
(
pcard
->
current
.
position
==
POS_FACEDOWN_DEFENSE
)
...
...
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