Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro
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
YGOPRO-520DIY
ygopro
Commits
c0ba3783
Commit
c0ba3783
authored
Jan 10, 2014
by
VanillaSalt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
cef3565d
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
11 additions
and
8 deletions
+11
-8
ocgcore/card.cpp
ocgcore/card.cpp
+3
-1
ocgcore/field.cpp
ocgcore/field.cpp
+3
-2
ocgcore/operations.cpp
ocgcore/operations.cpp
+3
-3
ocgcore/processor.cpp
ocgcore/processor.cpp
+2
-2
No files found.
ocgcore/card.cpp
View file @
c0ba3783
...
...
@@ -238,7 +238,7 @@ uint32 card::get_another_code() {
}
int32
card
::
is_set_card
(
uint32
set_code
)
{
uint32
code
=
get_code
();
uint
32
setcode
;
uint
64
setcode
;
if
(
code
==
data
.
code
)
{
setcode
=
data
.
setcode
;
}
else
{
...
...
@@ -252,6 +252,8 @@ int32 card::is_set_card(uint32 set_code) {
return
TRUE
;
if
(((
setcode
>>
16
)
&
0xfff
)
==
settype
&&
((
setcode
>>
16
)
&
0xf000
&
setsubtype
)
==
setsubtype
)
return
TRUE
;
if
(((
setcode
>>
24
)
&
0xfff
)
==
settype
&&
((
setcode
>>
24
)
&
0xf000
&
setsubtype
)
==
setsubtype
)
return
TRUE
;
return
FALSE
;
}
uint32
card
::
get_type
()
{
...
...
ocgcore/field.cpp
View file @
c0ba3783
...
...
@@ -704,9 +704,10 @@ void field::add_effect(effect* peffect, uint8 owner_player) {
}
}
void
field
::
remove_effect
(
effect
*
peffect
)
{
if
(
effects
.
indexer
.
find
(
peffect
)
==
effects
.
indexer
.
end
())
auto
eit
=
effects
.
indexer
.
find
(
peffect
);
if
(
eit
==
effects
.
indexer
.
end
())
return
;
auto
it
=
e
ffects
.
indexer
[
peffect
]
;
auto
it
=
e
it
->
second
;
if
(
!
(
peffect
->
type
&
EFFECT_TYPE_ACTIONS
))
effects
.
aura_effect
.
erase
(
it
);
else
{
...
...
ocgcore/operations.cpp
View file @
c0ba3783
...
...
@@ -2368,9 +2368,9 @@ int32 field::destroy(uint16 step, group * targets, effect * reason_effect, uint3
dest
=
((
*
cit
)
->
operation_param
>>
8
)
&
0xff
;
if
(
!
dest
)
dest
=
LOCATION_GRAVE
;
if
((
dest
==
LOCATION_HAND
&&
(
*
cit
)
->
is_affected_by_effect
(
EFFECT_CANNOT_TO_HAND
))
||
(
dest
==
LOCATION_DECK
&&
(
*
cit
)
->
is_affected_by_effect
(
EFFECT_CANNOT_TO_DECK
))
||
(
dest
==
LOCATION_REMOVED
&&
(
*
cit
)
->
is_affected_by_effect
(
EFFECT_CANNOT_REMOVE
)))
if
((
dest
==
LOCATION_HAND
&&
!
(
*
cit
)
->
is_capable_send_to_hand
(
reason_player
))
||
(
dest
==
LOCATION_DECK
&&
!
(
*
cit
)
->
is_capable_send_to_deck
(
reason_player
))
||
(
dest
==
LOCATION_REMOVED
&&
!
(
*
cit
)
->
is_removeable
(
reason_player
)))
dest
=
LOCATION_GRAVE
;
(
*
cit
)
->
operation_param
=
((
*
cit
)
->
operation_param
&
0xffff00ff
)
+
(
dest
<<
8
);
}
...
...
ocgcore/processor.cpp
View file @
c0ba3783
...
...
@@ -481,7 +481,7 @@ int32 field::process() {
if
(
!
attacker
||
(
attacker
->
fieldid_r
!=
core
.
pre_field
[
0
])
||
(
attacker
->
current
.
position
&
POS_FACEDOWN
)
||
(
attacker
->
current
.
position
&
POS_DEFENCE
&&
!
(
attacker
->
is_affected_by_effect
(
EFFECT_DEFENCE_ATTACK
)))
||
((
attacker
->
current
.
position
&
POS_DEFENCE
)
&&
!
(
attacker
->
is_affected_by_effect
(
EFFECT_DEFENCE_ATTACK
)))
||
attacker
->
is_affected_by_effect
(
EFFECT_ATTACK_DISABLED
)
||
!
attacker
->
is_affect_by_effect
(
core
.
reason_effect
))
{
returns
.
ivalue
[
0
]
=
0
;
...
...
@@ -3745,7 +3745,7 @@ int32 field::process_turn(uint16 step, uint8 turn_player) {
card
*
pcard
;
for
(
auto
elit
=
core
.
used_event
.
begin
();
elit
!=
core
.
used_event
.
end
();
++
elit
)
{
if
(
elit
->
event_cards
)
pduel
->
delete_group
(
(
group
*
)
elit
->
event_cards
);
pduel
->
delete_group
(
elit
->
event_cards
);
}
core
.
used_event
.
clear
();
for
(
auto
eit
=
core
.
reseted_effects
.
begin
();
eit
!=
core
.
reseted_effects
.
end
();
++
eit
)
{
...
...
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