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
7dce06cb
Commit
7dce06cb
authored
Dec 07, 2023
by
Chen Bill
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update field::get_control(uint16 step, ...
parent
232566b7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
9 deletions
+12
-9
operations.cpp
operations.cpp
+12
-9
No files found.
operations.cpp
View file @
7dce06cb
...
...
@@ -875,25 +875,28 @@ int32 field::get_control(uint16 step, effect* reason_effect, uint8 reason_player
card_set
*
destroy_set
=
new
card_set
;
core
.
units
.
begin
()
->
ptr1
=
destroy_set
;
for
(
auto
cit
=
targets
->
container
.
begin
();
cit
!=
targets
->
container
.
end
();)
{
card
*
pcard
=
*
cit
++
;
card
*
pcard
=
*
cit
;
pcard
->
filter_disable_related_cards
();
bool
change
=
true
;
if
(
pcard
->
overlay_target
)
change
=
false
;
if
(
pcard
->
current
.
controler
==
playerid
)
else
if
(
pcard
->
current
.
controler
==
playerid
)
change
=
false
;
if
(
pcard
->
current
.
controler
==
PLAYER_NONE
)
else
if
(
pcard
->
current
.
controler
==
PLAYER_NONE
)
change
=
false
;
if
(
pcard
->
current
.
location
!=
LOCATION_MZONE
)
else
if
(
pcard
->
current
.
location
!=
LOCATION_MZONE
)
change
=
false
;
if
(
!
pcard
->
is_capable_change_control
())
else
if
(
!
pcard
->
is_capable_change_control
())
change
=
false
;
if
(
!
pcard
->
is_affect_by_effect
(
reason_effect
))
else
if
(
!
pcard
->
is_affect_by_effect
(
reason_effect
))
change
=
false
;
if
(
core
.
duel_rule
<=
4
&&
(
pcard
->
get_type
()
&
TYPE_TRAPMONSTER
)
&&
get_useable_count
(
pcard
,
playerid
,
LOCATION_SZONE
,
reason_player
,
LOCATION_REASON_CONTROL
)
<=
0
)
else
if
(
core
.
duel_rule
<=
4
&&
(
pcard
->
get_type
()
&
TYPE_TRAPMONSTER
)
&&
get_useable_count
(
pcard
,
playerid
,
LOCATION_SZONE
,
reason_player
,
LOCATION_REASON_CONTROL
)
<=
0
)
change
=
false
;
if
(
!
change
)
targets
->
container
.
erase
(
pcard
);
if
(
!
change
)
cit
=
targets
->
container
.
erase
(
cit
);
else
++
cit
;
}
int32
fcount
=
get_useable_count
(
NULL
,
playerid
,
LOCATION_MZONE
,
reason_player
,
LOCATION_REASON_CONTROL
,
zone
);
if
(
fcount
<=
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