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
2347a6ea
Commit
2347a6ea
authored
Jun 12, 2019
by
salix5
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
revert
revert the changes to effects.disable_check_list
parent
7646ecfa
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
7 deletions
+12
-7
card.cpp
card.cpp
+1
-1
field.cpp
field.cpp
+10
-6
field.h
field.h
+1
-0
No files found.
card.cpp
View file @
2347a6ea
...
...
@@ -2427,7 +2427,7 @@ void card::filter_immune_effect() {
immune_effect
.
sort
();
}
// for all disable-related peffect of this,
// 1. Insert all cards in the target of peffect into effects.disable_check_
se
t.
// 1. Insert all cards in the target of peffect into effects.disable_check_
lis
t.
// 2. Insert equiping_target of peffect into it.
// 3. Insert overlay_target of peffect into it.
// 4. Insert continuous target of this into it.
...
...
field.cpp
View file @
2347a6ea
...
...
@@ -1869,7 +1869,7 @@ int32 field::get_overlay_count(uint8 self, uint8 s, uint8 o) {
}
return
count
;
}
// put all cards in the target of peffect into effects.disable_check_
se
t
// put all cards in the target of peffect into effects.disable_check_
lis
t
void
field
::
update_disable_check_list
(
effect
*
peffect
)
{
card_set
cset
;
filter_affected_cards
(
peffect
,
&
cset
);
...
...
@@ -1877,18 +1877,22 @@ void field::update_disable_check_list(effect* peffect) {
add_to_disable_check_list
(
pcard
);
}
void
field
::
add_to_disable_check_list
(
card
*
pcard
)
{
effects
.
disable_check_set
.
insert
(
pcard
);
auto
result
=
effects
.
disable_check_set
.
insert
(
pcard
);
if
(
!
result
.
second
)
return
effects
.
disable_check_list
.
push_back
(
pcard
);
}
void
field
::
adjust_disable_check_list
()
{
card
*
checking
;
int32
pre_disable
,
new_disable
;
if
(
!
effects
.
disable_check_
se
t
.
size
())
if
(
!
effects
.
disable_check_
lis
t
.
size
())
return
;
card_set
checked
;
do
{
checked
.
clear
();
while
(
effects
.
disable_check_set
.
size
())
{
checking
=
*
(
effects
.
disable_check_set
.
begin
());
while
(
effects
.
disable_check_list
.
size
())
{
checking
=
effects
.
disable_check_list
.
front
();
effects
.
disable_check_list
.
pop_front
();
effects
.
disable_check_set
.
erase
(
checking
);
checked
.
insert
(
checking
);
if
(
checking
->
is_status
(
STATUS_TO_ENABLE
|
STATUS_TO_DISABLE
))
...
...
@@ -1909,7 +1913,7 @@ void field::adjust_disable_check_list() {
pcard
->
reset
(
RESET_DISABLE
,
RESET_EVENT
);
pcard
->
set_status
(
STATUS_TO_ENABLE
|
STATUS_TO_DISABLE
,
FALSE
);
}
}
while
(
effects
.
disable_check_
se
t
.
size
());
}
while
(
effects
.
disable_check_
lis
t
.
size
());
}
// adjust SetUniqueOnField(), EFFECT_SELF_DESTROY, EFFECT_SELF_TOGRAVE
void
field
::
adjust_self_destroy_set
()
{
...
...
field.h
View file @
2347a6ea
...
...
@@ -110,6 +110,7 @@ struct field_effect {
effect_collection
rechargeable
;
effect_collection
spsummon_count_eff
;
std
::
list
<
card
*>
disable_check_list
;
std
::
unordered_set
<
card
*>
disable_check_set
;
grant_effect_container
grant_effect
;
...
...
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