Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Y
ygopro-2pick
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
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
MyCard
ygopro-2pick
Commits
0962bce7
Commit
0962bce7
authored
Jan 04, 2015
by
VanillaSalt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
29980b7f
Changes
12
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
19 additions
and
23 deletions
+19
-23
gframe/client_field.cpp
gframe/client_field.cpp
+2
-2
ocgcore/card.cpp
ocgcore/card.cpp
+2
-1
ocgcore/card.h
ocgcore/card.h
+1
-1
ocgcore/duel.cpp
ocgcore/duel.cpp
+2
-6
ocgcore/effect.h
ocgcore/effect.h
+1
-1
ocgcore/field.cpp
ocgcore/field.cpp
+1
-0
ocgcore/field.h
ocgcore/field.h
+1
-1
ocgcore/group.cpp
ocgcore/group.cpp
+1
-1
ocgcore/interpreter.h
ocgcore/interpreter.h
+2
-1
ocgcore/libduel.cpp
ocgcore/libduel.cpp
+0
-1
ocgcore/libgroup.cpp
ocgcore/libgroup.cpp
+3
-3
ocgcore/processor.cpp
ocgcore/processor.cpp
+3
-5
No files found.
gframe/client_field.cpp
View file @
0962bce7
...
...
@@ -1112,7 +1112,7 @@ bool ClientField::check_min(std::set<ClientCard*>& left, std::set<ClientCard*>::
int
m
=
(
op2
>
0
&&
op1
>
op2
)
?
op2
:
op1
;
if
(
m
>=
min
&&
m
<=
max
)
return
true
;
index
++
;
++
index
;
return
(
min
>
m
&&
check_min
(
left
,
index
,
min
-
m
,
max
-
m
))
||
check_min
(
left
,
index
,
min
,
max
);
}
...
...
@@ -1158,7 +1158,7 @@ bool ClientField::check_sum(std::set<ClientCard*>& testlist, std::set<ClientCard
int
l2
=
l
>>
16
;
if
((
l1
==
acc
||
(
l2
>
0
&&
l2
==
acc
))
&&
(
count
+
1
>=
select_min
)
&&
(
count
+
1
<=
select_max
))
return
true
;
index
++
;
++
index
;
return
(
acc
>
l1
&&
check_sum
(
testlist
,
index
,
acc
-
l1
,
count
+
1
))
||
(
l2
>
0
&&
acc
>
l2
&&
check_sum
(
testlist
,
index
,
acc
-
l2
,
count
+
1
))
||
check_sum
(
testlist
,
index
,
acc
,
count
);
...
...
ocgcore/card.cpp
View file @
0962bce7
...
...
@@ -46,9 +46,10 @@ bool card::card_operation_sort(card* c1, card* c2) {
return
c1
->
current
.
sequence
<
c2
->
current
.
sequence
;
}
}
card
::
card
()
{
card
::
card
(
duel
*
pd
)
{
scrtype
=
1
;
ref_handle
=
0
;
pduel
=
pd
;
owner
=
PLAYER_NONE
;
operation_param
=
0
;
status
=
0
;
...
...
ocgcore/card.h
View file @
0962bce7
...
...
@@ -134,7 +134,7 @@ public:
effect_relation
relate_effect
;
effect_set_v
immune_effect
;
card
(
);
explicit
card
(
duel
*
pd
);
~
card
();
static
bool
card_operation_sort
(
card
*
c1
,
card
*
c2
);
...
...
ocgcore/duel.cpp
View file @
0962bce7
...
...
@@ -17,9 +17,7 @@
duel
::
duel
()
{
lua
=
new
interpreter
(
this
);
game_field
=
new
field
(
this
);
game_field
->
temp_card
=
new_card
(
0
);
bufferlen
=
0
;
bufferp
=
buffer
;
clear_buffer
();
}
duel
::~
duel
()
{
for
(
std
::
set
<
card
*>::
iterator
cit
=
cards
.
begin
();
cit
!=
cards
.
end
();
++
cit
)
...
...
@@ -43,15 +41,13 @@ void duel::clear() {
groups
.
clear
();
effects
.
clear
();
game_field
=
new
field
(
this
);
game_field
->
temp_card
=
new_card
(
0
);
}
card
*
duel
::
new_card
(
uint32
code
)
{
card
*
pcard
=
new
card
();
card
*
pcard
=
new
card
(
this
);
cards
.
insert
(
pcard
);
if
(
code
)
::
read_card
(
code
,
&
(
pcard
->
data
));
pcard
->
data
.
code
=
code
;
pcard
->
pduel
=
this
;
lua
->
register_card
(
pcard
);
return
pcard
;
}
...
...
ocgcore/effect.h
View file @
0962bce7
...
...
@@ -59,7 +59,7 @@ public:
int32
value
;
int32
operation
;
effect
(
duel
*
pd
);
e
xplicit
e
ffect
(
duel
*
pd
);
~
effect
();
int32
is_disable_related
();
...
...
ocgcore/field.cpp
View file @
0962bce7
...
...
@@ -25,6 +25,7 @@ bool tevent::operator< (const tevent& v) const {
}
field
::
field
(
duel
*
pduel
)
{
this
->
pduel
=
pduel
;
temp_card
=
pduel
->
new_card
(
0
);
infos
.
copy_id
=
1
;
infos
.
turn_player
=
0
;
infos
.
turn_id
=
0
;
...
...
ocgcore/field.h
View file @
0962bce7
...
...
@@ -312,7 +312,7 @@ public:
tevent
nil_event
;
static
int32
field_used_count
[
32
];
field
(
duel
*
pduel
);
explicit
field
(
duel
*
pduel
);
~
field
();
void
reload_field_info
();
...
...
ocgcore/group.cpp
View file @
0962bce7
...
...
@@ -22,7 +22,7 @@ group::group(duel* pd, card* pcard) {
pduel
=
pd
;
is_readonly
=
FALSE
;
}
group
::
group
(
duel
*
pd
,
const
card_set
&
cset
)
:
container
(
cset
)
{
group
::
group
(
duel
*
pd
,
const
card_set
&
cset
)
:
container
(
cset
)
{
scrtype
=
2
;
ref_handle
=
0
;
pduel
=
pd
;
...
...
ocgcore/interpreter.h
View file @
0962bce7
...
...
@@ -42,7 +42,8 @@ public:
coroutine_map
coroutines
;
int32
no_action
;
int32
call_depth
;
interpreter
(
duel
*
pd
);
explicit
interpreter
(
duel
*
pd
);
~
interpreter
();
int32
register_card
(
card
*
pcard
);
...
...
ocgcore/libduel.cpp
View file @
0962bce7
...
...
@@ -2444,7 +2444,6 @@ int32 scriptlib::duel_select_xyz_material(lua_State *L) {
uint32
lv
=
lua_tointeger
(
L
,
4
);
uint32
minc
=
lua_tointeger
(
L
,
5
);
uint32
maxc
=
lua_tointeger
(
L
,
6
);
field
::
card_set
mat
,
cset
;
duel
*
pduel
=
scard
->
pduel
;
pduel
->
game_field
->
get_xyz_material
(
scard
,
findex
,
lv
,
maxc
);
scard
->
pduel
->
game_field
->
add_process
(
PROCESSOR_SELECT_XMATERIAL
,
0
,
0
,
(
group
*
)
scard
,
playerid
+
(
lv
<<
16
),
minc
+
(
maxc
<<
16
));
...
...
ocgcore/libgroup.cpp
View file @
0962bce7
...
...
@@ -101,7 +101,7 @@ int32 scriptlib::group_get_next(lua_State *L) {
if
(
pgroup
->
it
==
pgroup
->
container
.
end
())
lua_pushnil
(
L
);
else
{
pgroup
->
it
++
;
++
pgroup
->
it
;
if
(
pgroup
->
it
==
pgroup
->
container
.
end
())
lua_pushnil
(
L
);
else
...
...
@@ -386,7 +386,7 @@ int32 scriptlib::group_get_min_group(lua_State *L) {
field
::
card_set
::
iterator
cit
=
pgroup
->
container
.
begin
();
min
=
pduel
->
lua
->
get_operation_value
(
*
cit
,
2
,
extraargs
);
newgroup
->
container
.
insert
(
*
cit
);
cit
++
;
++
cit
;
for
(;
cit
!=
pgroup
->
container
.
end
();
++
cit
)
{
op
=
pduel
->
lua
->
get_operation_value
(
*
cit
,
2
,
extraargs
);
if
(
op
==
min
)
...
...
@@ -415,7 +415,7 @@ int32 scriptlib::group_get_max_group(lua_State *L) {
field
::
card_set
::
iterator
cit
=
pgroup
->
container
.
begin
();
max
=
pduel
->
lua
->
get_operation_value
(
*
cit
,
2
,
extraargs
);
newgroup
->
container
.
insert
(
*
cit
);
cit
++
;
++
cit
;
for
(;
cit
!=
pgroup
->
container
.
end
();
++
cit
)
{
op
=
pduel
->
lua
->
get_operation_value
(
*
cit
,
2
,
extraargs
);
if
(
op
==
max
)
...
...
ocgcore/processor.cpp
View file @
0962bce7
...
...
@@ -2174,7 +2174,7 @@ int32 field::process_quick_effect(int16 step, int32 special, uint8 priority) {
core
.
delayed_quick_break
.
erase
(
make_pair
(
peffect
,
*
evit
));
}
}
evit
++
;
++
evit
;
if
(
pev
&&
evit
==
core
.
point_event
.
end
())
{
evit
=
core
.
instant_event
.
begin
();
pev
=
false
;
...
...
@@ -4709,10 +4709,8 @@ int32 field::solve_chain(uint16 step, uint32 skip_new) {
if(cait->opinfos.count(0x200) && (core.units.begin()->arg2 != core.spsummon_state_count[cait->triggering_player]))
set_spsummon_counter(cait->triggering_player, false);
}*/
if
(
core
.
special_summoning
.
size
())
core
.
special_summoning
.
clear
();
if
(
core
.
equiping_cards
.
size
())
core
.
equiping_cards
.
clear
();
core
.
special_summoning
.
clear
();
core
.
equiping_cards
.
clear
();
return
FALSE
;
}
case
4
:
{
...
...
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