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
e06381f5
Commit
e06381f5
authored
Feb 07, 2024
by
Chen Bill
Committed by
GitHub
Feb 07, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: change type in field::equip() (#553)
* edit comment * fix: change type in field::equip()
parent
7e19d953
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
7 deletions
+13
-7
field.h
field.h
+6
-6
operations.cpp
operations.cpp
+7
-1
No files found.
field.h
View file @
e06381f5
...
@@ -759,17 +759,17 @@ public:
...
@@ -759,17 +759,17 @@ public:
#define PROCESSOR_DESTROY_REPLACE 56
#define PROCESSOR_DESTROY_REPLACE 56
#define PROCESSOR_RELEASE_REPLACE 57
#define PROCESSOR_RELEASE_REPLACE 57
#define PROCESSOR_SENDTO_REPLACE 58
#define PROCESSOR_SENDTO_REPLACE 58
#define PROCESSOR_SUMMON_RULE 60
//arg1, arg2
#define PROCESSOR_SUMMON_RULE 60
#define PROCESSOR_SPSUMMON_RULE 61
//arg1, arg2, arg3
#define PROCESSOR_SPSUMMON_RULE 61
#define PROCESSOR_SPSUMMON 62
#define PROCESSOR_SPSUMMON 62
#define PROCESSOR_FLIP_SUMMON 63
//arg1, arg2
#define PROCESSOR_FLIP_SUMMON 63
#define PROCESSOR_MSET 64
//arg1, arg2
#define PROCESSOR_MSET 64
#define PROCESSOR_SSET 65
#define PROCESSOR_SSET 65
#define PROCESSOR_SPSUMMON_STEP 66
#define PROCESSOR_SPSUMMON_STEP 66
#define PROCESSOR_SSET_G 67
#define PROCESSOR_SSET_G 67
#define PROCESSOR_DRAW 70
#define PROCESSOR_DRAW 70
#define PROCESSOR_DAMAGE 71
//arg1, arg2, arg3
#define PROCESSOR_DAMAGE 71
#define PROCESSOR_RECOVER 72
//arg1, arg2, arg3
#define PROCESSOR_RECOVER 72
#define PROCESSOR_EQUIP 73
#define PROCESSOR_EQUIP 73
#define PROCESSOR_GET_CONTROL 74
#define PROCESSOR_GET_CONTROL 74
#define PROCESSOR_SWAP_CONTROL 75
#define PROCESSOR_SWAP_CONTROL 75
...
...
operations.cpp
View file @
e06381f5
...
@@ -1386,6 +1386,8 @@ int32 field::equip(uint16 step, uint8 equip_player, card * equip_card, card * ta
...
@@ -1386,6 +1386,8 @@ int32 field::equip(uint16 step, uint8 equip_player, card * equip_card, card * ta
core
.
units
.
begin
()
->
step
=
2
;
core
.
units
.
begin
()
->
step
=
2
;
return
FALSE
;
return
FALSE
;
}
}
if
(
!
(
equip_card
->
data
.
type
&
TYPE_EQUIP
))
core
.
units
.
begin
()
->
value1
=
equip_card
->
get_type
();
if
(
equip_card
->
equiping_target
)
{
if
(
equip_card
->
equiping_target
)
{
equip_card
->
effect_target_cards
.
erase
(
equip_card
->
equiping_target
);
equip_card
->
effect_target_cards
.
erase
(
equip_card
->
equiping_target
);
equip_card
->
equiping_target
->
effect_target_owner
.
erase
(
equip_card
);
equip_card
->
equiping_target
->
effect_target_owner
.
erase
(
equip_card
);
...
@@ -1405,11 +1407,15 @@ int32 field::equip(uint16 step, uint8 equip_player, card * equip_card, card * ta
...
@@ -1405,11 +1407,15 @@ int32 field::equip(uint16 step, uint8 equip_player, card * equip_card, card * ta
case
1
:
{
case
1
:
{
equip_card
->
equip
(
target
);
equip_card
->
equip
(
target
);
if
(
!
(
equip_card
->
data
.
type
&
TYPE_EQUIP
))
{
if
(
!
(
equip_card
->
data
.
type
&
TYPE_EQUIP
))
{
uint32
equip_card_type
=
core
.
units
.
begin
()
->
value1
;
effect
*
peffect
=
pduel
->
new_effect
();
effect
*
peffect
=
pduel
->
new_effect
();
peffect
->
owner
=
equip_card
;
peffect
->
owner
=
equip_card
;
peffect
->
handler
=
equip_card
;
peffect
->
handler
=
equip_card
;
peffect
->
type
=
EFFECT_TYPE_SINGLE
;
peffect
->
type
=
EFFECT_TYPE_SINGLE
;
if
(
equip_card
->
get_type
()
&
TYPE_TRAP
)
{
if
(
equip_card_type
&
TYPE_TOKEN
)
{
peffect
->
code
=
EFFECT_CHANGE_TYPE
;
peffect
->
value
=
TYPE_EQUIP
+
TYPE_SPELL
+
TYPE_TOKEN
;
}
else
if
(
equip_card_type
&
TYPE_TRAP
)
{
peffect
->
code
=
EFFECT_ADD_TYPE
;
peffect
->
code
=
EFFECT_ADD_TYPE
;
peffect
->
value
=
TYPE_EQUIP
;
peffect
->
value
=
TYPE_EQUIP
;
}
else
{
}
else
{
...
...
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