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
4f740bf2
You need to sign in or sign up before continuing.
Commit
4f740bf2
authored
Apr 14, 2020
by
nanahira
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of github.com:Fluorohydride/ygopro-core
parents
3b89b5b5
dae92637
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
1 addition
and
13 deletions
+1
-13
card.cpp
card.cpp
+1
-1
field.cpp
field.cpp
+0
-10
operations.cpp
operations.cpp
+0
-2
No files found.
card.cpp
View file @
4f740bf2
...
@@ -1557,7 +1557,7 @@ void card::xyz_overlay(card_set* materials) {
...
@@ -1557,7 +1557,7 @@ void card::xyz_overlay(card_set* materials) {
pduel
->
game_field
->
adjust_instant
();
pduel
->
game_field
->
adjust_instant
();
}
}
void
card
::
xyz_add
(
card
*
mat
)
{
void
card
::
xyz_add
(
card
*
mat
)
{
if
(
mat
->
current
.
controler
!=
PLAYER_NONE
||
mat
->
overlay_target
)
if
(
mat
->
current
.
location
!=
0
)
return
;
return
;
xyz_materials
.
push_back
(
mat
);
xyz_materials
.
push_back
(
mat
);
mat
->
overlay_target
=
this
;
mat
->
overlay_target
=
this
;
...
...
field.cpp
View file @
4f740bf2
...
@@ -164,8 +164,6 @@ void field::reload_field_info() {
...
@@ -164,8 +164,6 @@ void field::reload_field_info() {
pduel
->
write_buffer32
(
peffect
->
description
);
pduel
->
write_buffer32
(
peffect
->
description
);
}
}
}
}
// The core of moving cards, and Debug.AddCard() will call this function directly.
// check Fusion/S/X monster redirection by the rule, set fieldid_r
void
field
::
add_card
(
uint8
playerid
,
card
*
pcard
,
uint8
location
,
uint8
sequence
,
uint8
pzone
)
{
void
field
::
add_card
(
uint8
playerid
,
card
*
pcard
,
uint8
location
,
uint8
sequence
,
uint8
pzone
)
{
if
(
pcard
->
current
.
location
!=
0
)
if
(
pcard
->
current
.
location
!=
0
)
return
;
return
;
...
@@ -297,13 +295,6 @@ void field::remove_card(card* pcard) {
...
@@ -297,13 +295,6 @@ void field::remove_card(card* pcard) {
pcard
->
current
.
location
=
0
;
pcard
->
current
.
location
=
0
;
pcard
->
current
.
sequence
=
0
;
pcard
->
current
.
sequence
=
0
;
}
}
// moving cards:
// 1. draw()
// 2. discard_deck()
// 3. swap_control()
// 4. control_adjust()
// 5. move_card()
// check Fusion/S/X monster redirection by the rule
void
field
::
move_card
(
uint8
playerid
,
card
*
pcard
,
uint8
location
,
uint8
sequence
,
uint8
pzone
)
{
void
field
::
move_card
(
uint8
playerid
,
card
*
pcard
,
uint8
location
,
uint8
sequence
,
uint8
pzone
)
{
if
(
!
is_location_useable
(
playerid
,
location
,
sequence
))
if
(
!
is_location_useable
(
playerid
,
location
,
sequence
))
return
;
return
;
...
@@ -624,7 +615,6 @@ card* field::get_field_card(uint32 playerid, uint32 location, uint32 sequence) {
...
@@ -624,7 +615,6 @@ card* field::get_field_card(uint32 playerid, uint32 location, uint32 sequence) {
}
}
return
0
;
return
0
;
}
}
// return: the given slot in LOCATION_MZONE or all LOCATION_SZONE is available or not
int32
field
::
is_location_useable
(
uint32
playerid
,
uint32
location
,
uint32
sequence
)
{
int32
field
::
is_location_useable
(
uint32
playerid
,
uint32
location
,
uint32
sequence
)
{
uint32
flag
=
player
[
playerid
].
disabled_location
|
player
[
playerid
].
used_location
;
uint32
flag
=
player
[
playerid
].
disabled_location
|
player
[
playerid
].
used_location
;
if
(
location
==
LOCATION_MZONE
)
{
if
(
location
==
LOCATION_MZONE
)
{
...
...
operations.cpp
View file @
4f740bf2
...
@@ -4036,7 +4036,6 @@ int32 field::send_to(uint16 step, group * targets, effect * reason_effect, uint3
...
@@ -4036,7 +4036,6 @@ int32 field::send_to(uint16 step, group * targets, effect * reason_effect, uint3
}
else
if
(
dest
==
LOCATION_REMOVED
)
{
}
else
if
(
dest
==
LOCATION_REMOVED
)
{
core
.
hint_timing
[
control_player
]
|=
TIMING_REMOVE
;
core
.
hint_timing
[
control_player
]
|=
TIMING_REMOVE
;
}
}
//call move_card()
if
(
pcard
->
current
.
controler
!=
playerid
||
pcard
->
current
.
location
!=
dest
)
{
if
(
pcard
->
current
.
controler
!=
playerid
||
pcard
->
current
.
location
!=
dest
)
{
pduel
->
write_buffer8
(
MSG_MOVE
);
pduel
->
write_buffer8
(
MSG_MOVE
);
pduel
->
write_buffer32
(
pcard
->
data
.
code
);
pduel
->
write_buffer32
(
pcard
->
data
.
code
);
...
@@ -4564,7 +4563,6 @@ int32 field::move_to_field(uint16 step, card* target, uint32 enable, uint32 ret,
...
@@ -4564,7 +4563,6 @@ int32 field::move_to_field(uint16 step, card* target, uint32 enable, uint32 ret,
pduel
->
write_buffer32
(
target
->
get_info_location
());
pduel
->
write_buffer32
(
target
->
get_info_location
());
if
(
target
->
overlay_target
)
if
(
target
->
overlay_target
)
target
->
overlay_target
->
xyz_remove
(
target
);
target
->
overlay_target
->
xyz_remove
(
target
);
// call move_card()
move_card
(
playerid
,
target
,
location
,
target
->
temp
.
sequence
,
pzone
);
move_card
(
playerid
,
target
,
location
,
target
->
temp
.
sequence
,
pzone
);
target
->
current
.
position
=
returns
.
ivalue
[
0
];
target
->
current
.
position
=
returns
.
ivalue
[
0
];
target
->
set_status
(
STATUS_LEAVE_CONFIRMED
,
FALSE
);
target
->
set_status
(
STATUS_LEAVE_CONFIRMED
,
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