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
22e81ada
Commit
22e81ada
authored
Jan 09, 2024
by
Uytrewq
Committed by
GitHub
Jan 09, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add SUMMON_INFO_REASON_PLAYER (#530)
* add SUMMON_INFO_REASON_PLAYER * fix
parent
438d791f
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
0 deletions
+7
-0
card.cpp
card.cpp
+3
-0
card.h
card.h
+1
-0
libcard.cpp
libcard.cpp
+3
-0
No files found.
card.cpp
View file @
22e81ada
...
@@ -2578,6 +2578,7 @@ void card::set_special_summon_status(effect* peffect) {
...
@@ -2578,6 +2578,7 @@ void card::set_special_summon_status(effect* peffect) {
spsummon
.
defense
=
0
;
spsummon
.
defense
=
0
;
spsummon
.
setcode
.
clear
();
spsummon
.
setcode
.
clear
();
spsummon
.
reason_effect
=
nullptr
;
spsummon
.
reason_effect
=
nullptr
;
spsummon
.
reason_player
=
PLAYER_NONE
;
return
;
return
;
}
}
card
*
pcard
=
peffect
->
get_handler
();
card
*
pcard
=
peffect
->
get_handler
();
...
@@ -2600,6 +2601,7 @@ void card::set_special_summon_status(effect* peffect) {
...
@@ -2600,6 +2601,7 @@ void card::set_special_summon_status(effect* peffect) {
spsummon
.
setcode
.
push_back
((
uint32
)
eset
[
i
]
->
get_value
(
pcard
));
spsummon
.
setcode
.
push_back
((
uint32
)
eset
[
i
]
->
get_value
(
pcard
));
}
}
spsummon
.
reason_effect
=
peffect
;
spsummon
.
reason_effect
=
peffect
;
spsummon
.
reason_player
=
peffect
->
get_handler_player
();
}
else
{
}
else
{
pcard
=
cait
->
triggering_effect
->
get_handler
();
pcard
=
cait
->
triggering_effect
->
get_handler
();
spsummon
.
code
=
cait
->
triggering_state
.
code
;
spsummon
.
code
=
cait
->
triggering_state
.
code
;
...
@@ -2618,6 +2620,7 @@ void card::set_special_summon_status(effect* peffect) {
...
@@ -2618,6 +2620,7 @@ void card::set_special_summon_status(effect* peffect) {
spsummon
.
setcode
.
push_back
((
uint32
)
eset
[
i
]
->
get_value
(
pcard
));
spsummon
.
setcode
.
push_back
((
uint32
)
eset
[
i
]
->
get_value
(
pcard
));
}
}
spsummon
.
reason_effect
=
cait
->
triggering_effect
;
spsummon
.
reason_effect
=
cait
->
triggering_effect
;
spsummon
.
reason_player
=
cait
->
triggering_player
;
}
}
}
}
void
card
::
filter_effect
(
int32
code
,
effect_set
*
eset
,
uint8
sort
)
{
void
card
::
filter_effect
(
int32
code
,
effect_set
*
eset
,
uint8
sort
)
{
...
...
card.h
View file @
22e81ada
...
@@ -417,6 +417,7 @@ public:
...
@@ -417,6 +417,7 @@ public:
#define SUMMON_INFO_ATTACK 0x80
#define SUMMON_INFO_ATTACK 0x80
#define SUMMON_INFO_DEFENSE 0x100
#define SUMMON_INFO_DEFENSE 0x100
#define SUMMON_INFO_REASON_EFFECT 0x200
#define SUMMON_INFO_REASON_EFFECT 0x200
#define SUMMON_INFO_REASON_PLAYER 0x400
//double-name cards
//double-name cards
#define CARD_MARINE_DOLPHIN 78734254
#define CARD_MARINE_DOLPHIN 78734254
...
...
libcard.cpp
View file @
22e81ada
...
@@ -921,6 +921,9 @@ int32 scriptlib::card_get_special_summon_info(lua_State *L) {
...
@@ -921,6 +921,9 @@ int32 scriptlib::card_get_special_summon_info(lua_State *L) {
case
SUMMON_INFO_REASON_EFFECT
:
case
SUMMON_INFO_REASON_EFFECT
:
interpreter
::
effect2value
(
L
,
pcard
->
spsummon
.
reason_effect
);
interpreter
::
effect2value
(
L
,
pcard
->
spsummon
.
reason_effect
);
break
;
break
;
case
SUMMON_INFO_REASON_PLAYER
:
lua_pushinteger
(
L
,
pcard
->
spsummon
.
reason_player
);
break
;
default:
default:
lua_pushnil
(
L
);
lua_pushnil
(
L
);
break
;
break
;
...
...
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