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
261de912
Commit
261de912
authored
Jun 09, 2017
by
VanillaSalt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
3e0f081b
Changes
7
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
192 additions
and
92 deletions
+192
-92
card.cpp
card.cpp
+59
-21
card.h
card.h
+3
-2
field.h
field.h
+2
-1
libcard.cpp
libcard.cpp
+5
-2
libduel.cpp
libduel.cpp
+7
-4
operations.cpp
operations.cpp
+114
-60
processor.cpp
processor.cpp
+2
-2
No files found.
card.cpp
View file @
261de912
...
@@ -2289,8 +2289,6 @@ int32 card::filter_summon_procedure(uint8 playerid, effect_set* peset, uint8 ign
...
@@ -2289,8 +2289,6 @@ int32 card::filter_summon_procedure(uint8 playerid, effect_set* peset, uint8 ign
min
=
min_tribute
;
min
=
min_tribute
;
if
(
max
<
min
)
if
(
max
<
min
)
return
FALSE
;
return
FALSE
;
eset
.
clear
();
filter_effect
(
EFFECT_SUMMON_PROC
,
&
eset
);
if
(
!
ignore_count
&&
!
pduel
->
game_field
->
core
.
extra_summon
[
playerid
]
if
(
!
ignore_count
&&
!
pduel
->
game_field
->
core
.
extra_summon
[
playerid
]
&&
pduel
->
game_field
->
core
.
summon_count
[
playerid
]
>=
pduel
->
game_field
->
get_summon_count_limit
(
playerid
))
{
&&
pduel
->
game_field
->
core
.
summon_count
[
playerid
]
>=
pduel
->
game_field
->
get_summon_count_limit
(
playerid
))
{
effect_set
eset
;
effect_set
eset
;
...
@@ -2347,13 +2345,12 @@ int32 card::check_summon_procedure(effect* peffect, uint8 playerid, uint8 ignore
...
@@ -2347,13 +2345,12 @@ int32 card::check_summon_procedure(effect* peffect, uint8 playerid, uint8 ignore
return
FALSE
;
return
FALSE
;
}
}
// put all set procedures except ordinay set in peset (see is_can_be_summoned())
// put all set procedures except ordinay set in peset (see is_can_be_summoned())
int32
card
::
filter_set_procedure
(
uint8
playerid
,
effect_set
*
peset
,
uint8
ignore_count
,
uint8
min_tribute
)
{
int32
card
::
filter_set_procedure
(
uint8
playerid
,
effect_set
*
peset
,
uint8
ignore_count
,
uint8
min_tribute
,
uint32
zone
)
{
effect_set
eset
;
effect_set
eset
;
filter_effect
(
EFFECT_LIMIT_SET_PROC
,
&
eset
);
filter_effect
(
EFFECT_LIMIT_SET_PROC
,
&
eset
);
if
(
eset
.
size
())
{
if
(
eset
.
size
())
{
for
(
int32
i
=
0
;
i
<
eset
.
size
();
++
i
)
{
for
(
int32
i
=
0
;
i
<
eset
.
size
();
++
i
)
{
if
(
eset
[
i
]
->
check_count_limit
(
playerid
)
&&
is_summonable
(
eset
[
i
],
min_tribute
)
if
(
check_set_procedure
(
eset
[
i
],
playerid
,
ignore_count
,
min_tribute
,
zone
))
&&
pduel
->
game_field
->
is_player_can_mset
(
eset
[
i
]
->
get_value
(
this
),
playerid
,
this
))
peset
->
add_item
(
eset
[
i
]);
peset
->
add_item
(
eset
[
i
]);
}
}
if
(
peset
->
size
())
if
(
peset
->
size
())
...
@@ -2363,21 +2360,71 @@ int32 card::filter_set_procedure(uint8 playerid, effect_set* peset, uint8 ignore
...
@@ -2363,21 +2360,71 @@ int32 card::filter_set_procedure(uint8 playerid, effect_set* peset, uint8 ignore
eset
.
clear
();
eset
.
clear
();
filter_effect
(
EFFECT_SET_PROC
,
&
eset
);
filter_effect
(
EFFECT_SET_PROC
,
&
eset
);
for
(
int32
i
=
0
;
i
<
eset
.
size
();
++
i
)
{
for
(
int32
i
=
0
;
i
<
eset
.
size
();
++
i
)
{
if
(
eset
[
i
]
->
check_count_limit
(
playerid
)
&&
is_summonable
(
eset
[
i
],
min_tribute
)
if
(
check_set_procedure
(
eset
[
i
],
playerid
,
ignore_count
,
min_tribute
,
zone
))
&&
pduel
->
game_field
->
is_player_can_mset
(
eset
[
i
]
->
get_value
(
this
),
playerid
,
this
))
peset
->
add_item
(
eset
[
i
]);
peset
->
add_item
(
eset
[
i
]);
}
}
if
(
!
pduel
->
game_field
->
is_player_can_mset
(
SUMMON_TYPE_NORMAL
,
playerid
,
this
))
if
(
!
pduel
->
game_field
->
is_player_can_mset
(
SUMMON_TYPE_NORMAL
,
playerid
,
this
))
return
FALSE
;
return
FALSE
;
int32
rcount
=
get_summon_tribute_count
();
int32
rcount
=
get_summon_tribute_count
();
int32
min
=
rcount
&
0xffff
,
max
=
(
rcount
>>
16
)
&
0xffff
;
int32
min
=
rcount
&
0xffff
;
int32
max
=
(
rcount
>>
16
)
&
0xffff
;
if
(
!
pduel
->
game_field
->
is_player_can_mset
(
SUMMON_TYPE_ADVANCE
,
playerid
,
this
))
if
(
!
pduel
->
game_field
->
is_player_can_mset
(
SUMMON_TYPE_ADVANCE
,
playerid
,
this
))
max
=
0
;
max
=
0
;
if
(
min
<
min_tribute
)
if
(
min
<
min_tribute
)
min
=
min_tribute
;
min
=
min_tribute
;
if
(
max
<
min
)
if
(
max
<
min
)
return
FALSE
;
return
FALSE
;
return
pduel
->
game_field
->
check_tribute
(
this
,
min
,
max
,
0
,
current
.
controler
);
if
(
!
ignore_count
&&
!
pduel
->
game_field
->
core
.
extra_summon
[
playerid
]
&&
pduel
->
game_field
->
core
.
summon_count
[
playerid
]
>=
pduel
->
game_field
->
get_summon_count_limit
(
playerid
))
{
effect_set
eset
;
filter_effect
(
EFFECT_EXTRA_SET_COUNT
,
&
eset
);
for
(
int32
i
=
0
;
i
<
eset
.
size
();
++
i
)
{
int32
val
=
eset
[
i
]
->
get_value
();
int32
new_min
=
val
&
0xff
;
int32
new_zone
=
(
val
>>
16
)
&
0x1f
;
if
(
new_min
<
min
)
new_min
=
min
;
if
(
new_zone
)
new_zone
&=
zone
;
else
new_zone
=
zone
;
if
(
pduel
->
game_field
->
check_tribute
(
this
,
new_min
,
max
,
0
,
current
.
controler
,
new_zone
))
return
TRUE
;
}
}
else
return
pduel
->
game_field
->
check_tribute
(
this
,
min
,
max
,
0
,
current
.
controler
,
zone
);
return
FALSE
;
}
int32
card
::
check_set_procedure
(
effect
*
peffect
,
uint8
playerid
,
uint8
ignore_count
,
uint8
min_tribute
,
uint32
zone
)
{
if
(
!
peffect
->
check_count_limit
(
playerid
))
return
FALSE
;
if
(
!
pduel
->
game_field
->
is_player_can_mset
(
peffect
->
get_value
(
this
),
playerid
,
this
))
return
FALSE
;
uint8
toplayer
=
playerid
;
if
(
peffect
->
is_flag
(
EFFECT_FLAG_SPSUM_PARAM
))
{
if
(
peffect
->
o_range
)
toplayer
=
1
-
playerid
;
}
if
(
!
ignore_count
&&
!
pduel
->
game_field
->
core
.
extra_summon
[
playerid
]
&&
pduel
->
game_field
->
core
.
summon_count
[
playerid
]
>=
pduel
->
game_field
->
get_summon_count_limit
(
playerid
))
{
effect_set
eset
;
filter_effect
(
EFFECT_EXTRA_SET_COUNT
,
&
eset
);
for
(
int32
i
=
0
;
i
<
eset
.
size
();
++
i
)
{
int32
val
=
eset
[
i
]
->
get_value
();
int32
new_min_tribute
=
val
&
0xff
;
int32
new_zone
=
(
val
>>
16
)
&
0x1f
;
if
(
new_min_tribute
<
(
int32
)
min_tribute
)
new_min_tribute
=
min_tribute
;
if
(
new_zone
)
new_zone
&=
zone
;
else
new_zone
=
zone
;
if
(
is_summonable
(
peffect
,
new_min_tribute
,
new_zone
))
return
TRUE
;
}
}
else
return
is_summonable
(
peffect
,
min_tribute
,
zone
);
return
FALSE
;
}
}
void
card
::
filter_spsummon_procedure
(
uint8
playerid
,
effect_set
*
peset
,
uint32
summon_type
)
{
void
card
::
filter_spsummon_procedure
(
uint8
playerid
,
effect_set
*
peset
,
uint32
summon_type
)
{
auto
pr
=
field_effect
.
equal_range
(
EFFECT_SPSUMMON_PROC
);
auto
pr
=
field_effect
.
equal_range
(
EFFECT_SPSUMMON_PROC
);
...
@@ -2917,7 +2964,7 @@ int32 card::is_can_be_special_summoned(effect* reason_effect, uint32 sumtype, ui
...
@@ -2917,7 +2964,7 @@ int32 card::is_can_be_special_summoned(effect* reason_effect, uint32 sumtype, ui
return
TRUE
;
return
TRUE
;
}
}
// if this does not have a set set procedure, it will check ordinary set (see is_can_be_summoned())
// if this does not have a set set procedure, it will check ordinary set (see is_can_be_summoned())
int32
card
::
is_setable_mzone
(
uint8
playerid
,
uint8
ignore_count
,
effect
*
peffect
,
uint8
min_tribute
)
{
int32
card
::
is_setable_mzone
(
uint8
playerid
,
uint8
ignore_count
,
effect
*
peffect
,
uint8
min_tribute
,
uint32
zone
)
{
if
(
!
is_summonable_card
())
if
(
!
is_summonable_card
())
return
FALSE
;
return
FALSE
;
if
(
current
.
location
!=
LOCATION_HAND
)
if
(
current
.
location
!=
LOCATION_HAND
)
...
@@ -2941,17 +2988,8 @@ int32 card::is_setable_mzone(uint8 playerid, uint8 ignore_count, effect* peffect
...
@@ -2941,17 +2988,8 @@ int32 card::is_setable_mzone(uint8 playerid, uint8 ignore_count, effect* peffect
return
FALSE
;
return
FALSE
;
}
}
}
}
if
(
!
ignore_count
&&
!
pduel
->
game_field
->
core
.
extra_summon
[
playerid
]
&&
pduel
->
game_field
->
core
.
summon_count
[
playerid
]
>=
pduel
->
game_field
->
get_summon_count_limit
(
playerid
))
{
effect
*
pextra
=
is_affected_by_effect
(
EFFECT_EXTRA_SET_COUNT
);
if
(
pextra
&&
!
pextra
->
is_flag
(
EFFECT_FLAG_FUNC_VALUE
))
{
int32
count
=
pextra
->
get_value
();
if
(
min_tribute
<
count
)
min_tribute
=
count
;
}
}
eset
.
clear
();
eset
.
clear
();
int32
res
=
filter_set_procedure
(
playerid
,
&
eset
,
ignore_count
,
min_tribute
);
int32
res
=
filter_set_procedure
(
playerid
,
&
eset
,
ignore_count
,
min_tribute
,
zone
);
if
(
peffect
)
{
if
(
peffect
)
{
if
(
res
<
0
||
!
pduel
->
game_field
->
is_player_can_mset
(
peffect
->
get_value
(),
playerid
,
this
))
{
if
(
res
<
0
||
!
pduel
->
game_field
->
is_player_can_mset
(
peffect
->
get_value
(),
playerid
,
this
))
{
pduel
->
game_field
->
restore_lp_cost
();
pduel
->
game_field
->
restore_lp_cost
();
...
...
card.h
View file @
261de912
...
@@ -252,7 +252,8 @@ public:
...
@@ -252,7 +252,8 @@ public:
void
filter_disable_related_cards
();
void
filter_disable_related_cards
();
int32
filter_summon_procedure
(
uint8
playerid
,
effect_set
*
eset
,
uint8
ignore_count
,
uint8
min_tribute
,
uint32
zone
);
int32
filter_summon_procedure
(
uint8
playerid
,
effect_set
*
eset
,
uint8
ignore_count
,
uint8
min_tribute
,
uint32
zone
);
int32
check_summon_procedure
(
effect
*
peffect
,
uint8
playerid
,
uint8
ignore_count
,
uint8
min_tribute
,
uint32
zone
);
int32
check_summon_procedure
(
effect
*
peffect
,
uint8
playerid
,
uint8
ignore_count
,
uint8
min_tribute
,
uint32
zone
);
int32
filter_set_procedure
(
uint8
playerid
,
effect_set
*
eset
,
uint8
ignore_count
,
uint8
min_tribute
);
int32
filter_set_procedure
(
uint8
playerid
,
effect_set
*
eset
,
uint8
ignore_count
,
uint8
min_tribute
,
uint32
zone
);
int32
check_set_procedure
(
effect
*
peffect
,
uint8
playerid
,
uint8
ignore_count
,
uint8
min_tribute
,
uint32
zone
);
void
filter_spsummon_procedure
(
uint8
playerid
,
effect_set
*
eset
,
uint32
summon_type
);
void
filter_spsummon_procedure
(
uint8
playerid
,
effect_set
*
eset
,
uint32
summon_type
);
void
filter_spsummon_procedure_g
(
uint8
playerid
,
effect_set
*
eset
);
void
filter_spsummon_procedure_g
(
uint8
playerid
,
effect_set
*
eset
);
effect
*
is_affected_by_effect
(
int32
code
);
effect
*
is_affected_by_effect
(
int32
code
);
...
@@ -274,7 +275,7 @@ public:
...
@@ -274,7 +275,7 @@ public:
int32
is_can_be_flip_summoned
(
uint8
playerid
);
int32
is_can_be_flip_summoned
(
uint8
playerid
);
int32
is_special_summonable
(
uint8
playerid
,
uint32
summon_type
);
int32
is_special_summonable
(
uint8
playerid
,
uint32
summon_type
);
int32
is_can_be_special_summoned
(
effect
*
reason_effect
,
uint32
sumtype
,
uint8
sumpos
,
uint8
sumplayer
,
uint8
toplayer
,
uint8
nocheck
,
uint8
nolimit
,
uint32
zone
);
int32
is_can_be_special_summoned
(
effect
*
reason_effect
,
uint32
sumtype
,
uint8
sumpos
,
uint8
sumplayer
,
uint8
toplayer
,
uint8
nocheck
,
uint8
nolimit
,
uint32
zone
);
int32
is_setable_mzone
(
uint8
playerid
,
uint8
ignore_count
,
effect
*
peffect
,
uint8
min_tribute
);
int32
is_setable_mzone
(
uint8
playerid
,
uint8
ignore_count
,
effect
*
peffect
,
uint8
min_tribute
,
uint32
zone
=
0x1f
);
int32
is_setable_szone
(
uint8
playerid
,
uint8
ignore_fd
=
0
);
int32
is_setable_szone
(
uint8
playerid
,
uint8
ignore_fd
=
0
);
int32
is_affect_by_effect
(
effect
*
peffect
);
int32
is_affect_by_effect
(
effect
*
peffect
);
int32
is_destructable
();
int32
is_destructable
();
...
...
field.h
View file @
261de912
...
@@ -499,6 +499,7 @@ public:
...
@@ -499,6 +499,7 @@ public:
void
damage
(
effect
*
reason_effect
,
uint32
reason
,
uint32
reason_player
,
card
*
reason_card
,
uint32
playerid
,
uint32
amount
,
uint32
is_step
=
FALSE
);
void
damage
(
effect
*
reason_effect
,
uint32
reason
,
uint32
reason_player
,
card
*
reason_card
,
uint32
playerid
,
uint32
amount
,
uint32
is_step
=
FALSE
);
void
recover
(
effect
*
reason_effect
,
uint32
reason
,
uint32
reason_player
,
uint32
playerid
,
uint32
amount
,
uint32
is_step
=
FALSE
);
void
recover
(
effect
*
reason_effect
,
uint32
reason
,
uint32
reason_player
,
uint32
playerid
,
uint32
amount
,
uint32
is_step
=
FALSE
);
void
summon
(
uint32
sumplayer
,
card
*
target
,
effect
*
proc
,
uint32
ignore_count
,
uint32
min_tribute
,
uint32
zone
=
0x1f
);
void
summon
(
uint32
sumplayer
,
card
*
target
,
effect
*
proc
,
uint32
ignore_count
,
uint32
min_tribute
,
uint32
zone
=
0x1f
);
void
mset
(
uint32
setplayer
,
card
*
target
,
effect
*
proc
,
uint32
ignore_count
,
uint32
min_tribute
,
uint32
zone
=
0x1f
);
void
special_summon_rule
(
uint32
sumplayer
,
card
*
target
,
uint32
summon_type
);
void
special_summon_rule
(
uint32
sumplayer
,
card
*
target
,
uint32
summon_type
);
void
special_summon
(
card_set
*
target
,
uint32
sumtype
,
uint32
sumplayer
,
uint32
playerid
,
uint32
nocheck
,
uint32
nolimit
,
uint32
positions
,
uint32
zone
);
void
special_summon
(
card_set
*
target
,
uint32
sumtype
,
uint32
sumplayer
,
uint32
playerid
,
uint32
nocheck
,
uint32
nolimit
,
uint32
positions
,
uint32
zone
);
void
special_summon_step
(
card
*
target
,
uint32
sumtype
,
uint32
sumplayer
,
uint32
playerid
,
uint32
nocheck
,
uint32
nolimit
,
uint32
positions
,
uint32
zone
);
void
special_summon_step
(
card
*
target
,
uint32
sumtype
,
uint32
sumplayer
,
uint32
playerid
,
uint32
nocheck
,
uint32
nolimit
,
uint32
positions
,
uint32
zone
);
...
@@ -525,7 +526,7 @@ public:
...
@@ -525,7 +526,7 @@ public:
int32
recover
(
uint16
step
,
effect
*
reason_effect
,
uint32
reason
,
uint8
reason_player
,
uint8
playerid
,
uint32
amount
,
uint32
is_step
);
int32
recover
(
uint16
step
,
effect
*
reason_effect
,
uint32
reason
,
uint8
reason_player
,
uint8
playerid
,
uint32
amount
,
uint32
is_step
);
int32
summon
(
uint16
step
,
uint8
sumplayer
,
card
*
target
,
effect
*
proc
,
uint8
ignore_count
,
uint8
min_tribute
,
uint32
zone
);
int32
summon
(
uint16
step
,
uint8
sumplayer
,
card
*
target
,
effect
*
proc
,
uint8
ignore_count
,
uint8
min_tribute
,
uint32
zone
);
int32
flip_summon
(
uint16
step
,
uint8
sumplayer
,
card
*
target
);
int32
flip_summon
(
uint16
step
,
uint8
sumplayer
,
card
*
target
);
int32
mset
(
uint16
step
,
uint8
setplayer
,
card
*
ptarget
,
effect
*
proc
,
uint8
ignore_count
,
uint8
min_tribute
);
int32
mset
(
uint16
step
,
uint8
setplayer
,
card
*
ptarget
,
effect
*
proc
,
uint8
ignore_count
,
uint8
min_tribute
,
uint32
zone
);
int32
sset
(
uint16
step
,
uint8
setplayer
,
uint8
toplayer
,
card
*
ptarget
);
int32
sset
(
uint16
step
,
uint8
setplayer
,
uint8
toplayer
,
card
*
ptarget
);
int32
sset_g
(
uint16
step
,
uint8
setplayer
,
uint8
toplayer
,
group
*
ptarget
);
int32
sset_g
(
uint16
step
,
uint8
setplayer
,
uint8
toplayer
,
group
*
ptarget
);
int32
special_summon_rule
(
uint16
step
,
uint8
sumplayer
,
card
*
target
,
uint32
summon_type
);
int32
special_summon_rule
(
uint16
step
,
uint8
sumplayer
,
card
*
target
,
uint32
summon_type
);
...
...
libcard.cpp
View file @
261de912
...
@@ -1435,9 +1435,12 @@ int32 scriptlib::card_is_msetable(lua_State *L) {
...
@@ -1435,9 +1435,12 @@ int32 scriptlib::card_is_msetable(lua_State *L) {
peffect
=
*
(
effect
**
)
lua_touserdata
(
L
,
3
);
peffect
=
*
(
effect
**
)
lua_touserdata
(
L
,
3
);
}
}
uint32
minc
=
0
;
uint32
minc
=
0
;
if
(
lua_gettop
(
L
)
>
3
)
if
(
lua_gettop
(
L
)
>
=
4
)
minc
=
lua_tointeger
(
L
,
4
);
minc
=
lua_tointeger
(
L
,
4
);
lua_pushboolean
(
L
,
pcard
->
is_setable_mzone
(
p
,
ign
,
peffect
,
minc
));
uint32
zone
=
0x1f
;
if
(
lua_gettop
(
L
)
>=
5
)
zone
=
lua_tointeger
(
L
,
5
);
lua_pushboolean
(
L
,
pcard
->
is_setable_mzone
(
p
,
ign
,
peffect
,
minc
,
zone
));
return
1
;
return
1
;
}
}
int32
scriptlib
::
card_is_ssetable
(
lua_State
*
L
)
{
int32
scriptlib
::
card_is_ssetable
(
lua_State
*
L
)
{
...
...
libduel.cpp
View file @
261de912
...
@@ -227,7 +227,7 @@ int32 scriptlib::duel_summon(lua_State *L) {
...
@@ -227,7 +227,7 @@ int32 scriptlib::duel_summon(lua_State *L) {
uint32
min_tribute
=
0
;
uint32
min_tribute
=
0
;
if
(
lua_gettop
(
L
)
>=
5
)
if
(
lua_gettop
(
L
)
>=
5
)
min_tribute
=
lua_tointeger
(
L
,
5
);
min_tribute
=
lua_tointeger
(
L
,
5
);
uint32
zone
=
0
;
uint32
zone
=
0
x1f
;
if
(
lua_gettop
(
L
)
>=
6
)
if
(
lua_gettop
(
L
)
>=
6
)
zone
=
lua_tointeger
(
L
,
6
);
zone
=
lua_tointeger
(
L
,
6
);
duel
*
pduel
=
pcard
->
pduel
;
duel
*
pduel
=
pcard
->
pduel
;
...
@@ -317,11 +317,14 @@ int32 scriptlib::duel_setm(lua_State *L) {
...
@@ -317,11 +317,14 @@ int32 scriptlib::duel_setm(lua_State *L) {
card
*
pcard
=
*
(
card
**
)
lua_touserdata
(
L
,
2
);
card
*
pcard
=
*
(
card
**
)
lua_touserdata
(
L
,
2
);
uint32
ignore_count
=
lua_toboolean
(
L
,
3
);
uint32
ignore_count
=
lua_toboolean
(
L
,
3
);
uint32
min_tribute
=
0
;
uint32
min_tribute
=
0
;
if
(
lua_gettop
(
L
)
>
4
)
if
(
lua_gettop
(
L
)
>
=
5
)
min_tribute
=
lua_tointeger
(
L
,
5
);
min_tribute
=
lua_tointeger
(
L
,
5
);
duel
*
pduel
=
pcard
->
pduel
;
uint32
zone
=
0x1f
;
if
(
lua_gettop
(
L
)
>=
6
)
zone
=
lua_tointeger
(
L
,
6
);
duel
*
pduel
=
pcard
->
pduel
;
pduel
->
game_field
->
core
.
summon_cancelable
=
FALSE
;
pduel
->
game_field
->
core
.
summon_cancelable
=
FALSE
;
pduel
->
game_field
->
add_process
(
PROCESSOR_MSET
,
0
,
peffect
,
(
group
*
)
pcard
,
playerid
+
(
ignore_count
<<
8
)
+
(
min_tribute
<<
16
),
0
);
pduel
->
game_field
->
mset
(
playerid
,
pcard
,
peffect
,
ignore_count
,
min_tribute
,
zone
);
return
lua_yield
(
L
,
0
);
return
lua_yield
(
L
,
0
);
}
}
int32
scriptlib
::
duel_sets
(
lua_State
*
L
)
{
int32
scriptlib
::
duel_sets
(
lua_State
*
L
)
{
...
...
operations.cpp
View file @
261de912
This diff is collapsed.
Click to expand it.
processor.cpp
View file @
261de912
...
@@ -380,7 +380,7 @@ int32 field::process() {
...
@@ -380,7 +380,7 @@ int32 field::process() {
return
pduel
->
bufferlen
;
return
pduel
->
bufferlen
;
}
}
case
PROCESSOR_MSET
:
{
case
PROCESSOR_MSET
:
{
if
(
mset
(
it
->
step
,
it
->
arg1
&
0xff
,
(
card
*
)
it
->
ptarget
,
it
->
peffect
,
(
it
->
arg1
>>
8
)
&
0xff
,
(
it
->
arg1
>>
16
)
&
0xff
))
if
(
mset
(
it
->
step
,
it
->
arg1
&
0xff
,
(
card
*
)
it
->
ptarget
,
it
->
peffect
,
(
it
->
arg1
>>
8
)
&
0xff
,
(
it
->
arg1
>>
16
)
&
0xff
,
(
it
->
arg1
>>
24
)
&
0xff
))
core
.
units
.
pop_front
();
core
.
units
.
pop_front
();
else
else
it
->
step
++
;
it
->
step
++
;
...
@@ -2717,7 +2717,7 @@ int32 field::process_idle_command(uint16 step) {
...
@@ -2717,7 +2717,7 @@ int32 field::process_idle_command(uint16 step) {
case
8
:
{
case
8
:
{
card
*
target
=
core
.
msetable_cards
[
returns
.
ivalue
[
0
]
>>
16
];
card
*
target
=
core
.
msetable_cards
[
returns
.
ivalue
[
0
]
>>
16
];
core
.
summon_cancelable
=
TRUE
;
core
.
summon_cancelable
=
TRUE
;
add_process
(
PROCESSOR_MSET
,
0
,
0
,
(
group
*
)
target
,
target
->
current
.
controler
,
0
);
mset
(
target
->
current
.
controler
,
target
,
0
,
FALSE
,
0
);
core
.
units
.
begin
()
->
step
=
-
1
;
core
.
units
.
begin
()
->
step
=
-
1
;
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