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
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
MyCard
ygopro-core
Commits
7da0970a
Commit
7da0970a
authored
May 31, 2018
by
mercury233
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update ShuffleSetCard to support shuffle szone
parent
b1093e82
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
2 deletions
+9
-2
libduel.cpp
libduel.cpp
+9
-2
No files found.
libduel.cpp
View file @
7da0970a
...
@@ -1353,12 +1353,15 @@ int32 scriptlib::duel_shuffle_setcard(lua_State *L) {
...
@@ -1353,12 +1353,15 @@ int32 scriptlib::duel_shuffle_setcard(lua_State *L) {
card
*
ms
[
7
];
card
*
ms
[
7
];
uint8
seq
[
7
];
uint8
seq
[
7
];
uint8
tp
=
2
;
uint8
tp
=
2
;
uint8
loc
=
0
;
uint8
ct
=
0
;
uint8
ct
=
0
;
for
(
auto
cit
=
pgroup
->
container
.
begin
();
cit
!=
pgroup
->
container
.
end
();
++
cit
)
{
for
(
auto
cit
=
pgroup
->
container
.
begin
();
cit
!=
pgroup
->
container
.
end
();
++
cit
)
{
card
*
pcard
=
*
cit
;
card
*
pcard
=
*
cit
;
if
(
pcard
->
current
.
location
!=
LOCATION_MZONE
||
(
pcard
->
current
.
position
&
POS_FACEUP
)
||
(
tp
!=
2
&&
(
pcard
->
current
.
controler
!=
tp
)))
if
((
loc
!=
0
&&
(
pcard
->
current
.
location
!=
loc
))
||
(
pcard
->
current
.
location
!=
LOCATION_MZONE
&&
pcard
->
current
.
location
!=
LOCATION_SZONE
)
||
(
pcard
->
current
.
position
&
POS_FACEUP
)
||
(
pcard
->
current
.
location
==
LOCATION_SZONE
&&
pcard
->
current
.
sequence
>
4
)
||
(
tp
!=
2
&&
(
pcard
->
current
.
controler
!=
tp
)))
return
0
;
return
0
;
tp
=
pcard
->
current
.
controler
;
tp
=
pcard
->
current
.
controler
;
loc
=
pcard
->
current
.
location
;
ms
[
ct
]
=
pcard
;
ms
[
ct
]
=
pcard
;
seq
[
ct
]
=
pcard
->
current
.
sequence
;
seq
[
ct
]
=
pcard
->
current
.
sequence
;
ct
++
;
ct
++
;
...
@@ -1368,11 +1371,15 @@ int32 scriptlib::duel_shuffle_setcard(lua_State *L) {
...
@@ -1368,11 +1371,15 @@ int32 scriptlib::duel_shuffle_setcard(lua_State *L) {
std
::
swap
(
ms
[
i
],
ms
[
s
]);
std
::
swap
(
ms
[
i
],
ms
[
s
]);
}
}
pduel
->
write_buffer8
(
MSG_SHUFFLE_SET_CARD
);
pduel
->
write_buffer8
(
MSG_SHUFFLE_SET_CARD
);
pduel
->
write_buffer8
(
loc
);
pduel
->
write_buffer8
(
ct
);
pduel
->
write_buffer8
(
ct
);
for
(
uint32
i
=
0
;
i
<
ct
;
++
i
)
{
for
(
uint32
i
=
0
;
i
<
ct
;
++
i
)
{
card
*
pcard
=
ms
[
i
];
card
*
pcard
=
ms
[
i
];
pduel
->
write_buffer32
(
pcard
->
get_info_location
());
pduel
->
write_buffer32
(
pcard
->
get_info_location
());
if
(
loc
==
LOCATION_MZONE
)
pduel
->
game_field
->
player
[
tp
].
list_mzone
[
seq
[
i
]]
=
pcard
;
pduel
->
game_field
->
player
[
tp
].
list_mzone
[
seq
[
i
]]
=
pcard
;
else
pduel
->
game_field
->
player
[
tp
].
list_szone
[
seq
[
i
]]
=
pcard
;
pcard
->
current
.
sequence
=
seq
[
i
];
pcard
->
current
.
sequence
=
seq
[
i
];
pduel
->
game_field
->
raise_single_event
(
pcard
,
0
,
EVENT_MOVE
,
pcard
->
current
.
reason_effect
,
pcard
->
current
.
reason
,
pcard
->
current
.
reason_player
,
tp
,
0
);
pduel
->
game_field
->
raise_single_event
(
pcard
,
0
,
EVENT_MOVE
,
pcard
->
current
.
reason_effect
,
pcard
->
current
.
reason
,
pcard
->
current
.
reason_player
,
tp
,
0
);
}
}
...
...
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