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
222bfbf2
Commit
222bfbf2
authored
Apr 20, 2016
by
DailyShana
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
revert & fix
parent
da337861
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
7 deletions
+8
-7
effect.cpp
effect.cpp
+8
-7
No files found.
effect.cpp
View file @
222bfbf2
...
@@ -235,12 +235,13 @@ int32 effect::is_activateable(uint8 playerid, const tevent& e, int32 neglect_con
...
@@ -235,12 +235,13 @@ int32 effect::is_activateable(uint8 playerid, const tevent& e, int32 neglect_con
if
((
handler
->
data
.
type
&
TYPE_MONSTER
)
&&
(
handler
->
current
.
location
&
LOCATION_SZONE
)
if
((
handler
->
data
.
type
&
TYPE_MONSTER
)
&&
(
handler
->
current
.
location
&
LOCATION_SZONE
)
&&
!
in_range
(
handler
->
current
.
location
,
handler
->
current
.
sequence
))
&&
!
in_range
(
handler
->
current
.
location
,
handler
->
current
.
sequence
))
return
FALSE
;
return
FALSE
;
// effects with EFFECT_FLAG_SET_AVAILABLE can be activated while face-down
if
((
handler
->
current
.
location
&
(
LOCATION_ONFIELD
|
LOCATION_REMOVED
)))
{
if
((
handler
->
current
.
location
&
(
LOCATION_ONFIELD
|
LOCATION_REMOVED
))
// effects with EFFECT_FLAG_SET_AVAILABLE can be activated while face-down
&&
!
is_flag
(
EFFECT_FLAG_SET_AVAILABLE
)
if
(
!
handler
->
is_position
(
POS_FACEUP
)
&&
!
is_flag
(
EFFECT_FLAG_SET_AVAILABLE
)
&&
(
code
!=
EVENT_FLIP
||
!
(
e
.
event_value
&
(
FLIP_SET_AVAILABLE
>>
16
))))
&&
(
code
!=
EVENT_FLIP
||
!
(
e
.
event_value
&
(
FLIP_SET_AVAILABLE
>>
16
)))
return
FALSE
;
&&
!
handler
->
is_status
(
STATUS_EFFECT_ENABLED
))
if
(
handler
->
is_position
(
POS_FACEUP
)
&&
!
handler
->
is_status
(
STATUS_EFFECT_ENABLED
))
return
FALSE
;
return
FALSE
;
}
if
(
!
(
type
&
(
EFFECT_TYPE_FLIP
|
EFFECT_TYPE_TRIGGER_F
))
if
(
!
(
type
&
(
EFFECT_TYPE_FLIP
|
EFFECT_TYPE_TRIGGER_F
))
&&
!
((
type
&
EFFECT_TYPE_SINGLE
)
&&
(
code
==
EVENT_TO_GRAVE
||
code
==
EVENT_DESTROYED
||
code
==
EVENT_SPSUMMON_SUCCESS
||
code
==
EVENT_TO_HAND
)))
{
&&
!
((
type
&
EFFECT_TYPE_SINGLE
)
&&
(
code
==
EVENT_TO_GRAVE
||
code
==
EVENT_DESTROYED
||
code
==
EVENT_SPSUMMON_SUCCESS
||
code
==
EVENT_TO_HAND
)))
{
if
((
code
<
1132
||
code
>
1149
)
&&
pduel
->
game_field
->
infos
.
phase
==
PHASE_DAMAGE
&&
!
is_flag
(
EFFECT_FLAG_DAMAGE_STEP
))
if
((
code
<
1132
||
code
>
1149
)
&&
pduel
->
game_field
->
infos
.
phase
==
PHASE_DAMAGE
&&
!
is_flag
(
EFFECT_FLAG_DAMAGE_STEP
))
...
@@ -260,7 +261,7 @@ int32 effect::is_activateable(uint8 playerid, const tevent& e, int32 neglect_con
...
@@ -260,7 +261,7 @@ int32 effect::is_activateable(uint8 playerid, const tevent& e, int32 neglect_con
if
(
!
is_flag
(
EFFECT_FLAG_AVAILABLE_BD
)
&&
(
type
&
EFFECT_TYPE_FIELD
)
&&
handler
->
is_status
(
STATUS_BATTLE_DESTROYED
))
if
(
!
is_flag
(
EFFECT_FLAG_AVAILABLE_BD
)
&&
(
type
&
EFFECT_TYPE_FIELD
)
&&
handler
->
is_status
(
STATUS_BATTLE_DESTROYED
))
return
FALSE
;
return
FALSE
;
if
(((
type
&
EFFECT_TYPE_FIELD
)
||
((
type
&
EFFECT_TYPE_SINGLE
)
&&
is_flag
(
EFFECT_FLAG_SINGLE_RANGE
)))
&&
(
handler
->
current
.
location
&
LOCATION_ONFIELD
)
if
(((
type
&
EFFECT_TYPE_FIELD
)
||
((
type
&
EFFECT_TYPE_SINGLE
)
&&
is_flag
(
EFFECT_FLAG_SINGLE_RANGE
)))
&&
(
handler
->
current
.
location
&
LOCATION_ONFIELD
)
&&
!
handler
->
is_status
(
STATUS_EFFECT_ENABLED
))
&&
(
!
handler
->
is_position
(
POS_FACEUP
)
||
!
handler
->
is_status
(
STATUS_EFFECT_ENABLED
)
))
return
FALSE
;
return
FALSE
;
if
((
type
&
EFFECT_TYPE_SINGLE
)
&&
is_flag
(
EFFECT_FLAG_SINGLE_RANGE
)
&&
!
in_range
(
handler
->
current
.
location
,
handler
->
current
.
sequence
))
if
((
type
&
EFFECT_TYPE_SINGLE
)
&&
is_flag
(
EFFECT_FLAG_SINGLE_RANGE
)
&&
!
in_range
(
handler
->
current
.
location
,
handler
->
current
.
sequence
))
return
FALSE
;
return
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