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
baichixing
ygopro
Commits
988e5916
Commit
988e5916
authored
Nov 20, 2017
by
mercury233
Committed by
GitHub
Nov 20, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update mark for OCG/TCG cards (#2048)
parent
59001686
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
17 additions
and
1 deletion
+17
-1
gframe/drawing.cpp
gframe/drawing.cpp
+10
-1
gframe/game.cpp
gframe/game.cpp
+5
-0
gframe/game.h
gframe/game.h
+1
-0
system.conf
system.conf
+1
-0
textures/ot.png
textures/ot.png
+0
-0
No files found.
gframe/drawing.cpp
View file @
988e5916
...
...
@@ -1045,7 +1045,16 @@ void Game::DrawThumb(code_pointer cp, position2di pos, std::unordered_map<int, i
break
;
}
}
if
(
mainGame
->
cbLimit
->
getSelected
()
>=
4
)
{
if
(
mainGame
->
cbLimit
->
getSelected
()
>=
4
&&
(
cp
->
second
.
ot
&
mainGame
->
gameConf
.
defaultOT
))
{
switch
(
cp
->
second
.
ot
)
{
case
1
:
driver
->
draw2DImage
(
imageManager
.
tOT
,
recti
(
pos
.
X
+
7
,
pos
.
Y
+
50
,
pos
.
X
+
37
,
pos
.
Y
+
65
),
recti
(
0
,
128
,
128
,
192
),
0
,
0
,
true
);
break
;
case
2
:
driver
->
draw2DImage
(
imageManager
.
tOT
,
recti
(
pos
.
X
+
7
,
pos
.
Y
+
50
,
pos
.
X
+
37
,
pos
.
Y
+
65
),
recti
(
0
,
192
,
128
,
256
),
0
,
0
,
true
);
break
;
}
}
else
if
(
mainGame
->
cbLimit
->
getSelected
()
>=
4
||
!
(
cp
->
second
.
ot
&
mainGame
->
gameConf
.
defaultOT
))
{
switch
(
cp
->
second
.
ot
)
{
case
1
:
driver
->
draw2DImage
(
imageManager
.
tOT
,
recti
(
pos
.
X
+
7
,
pos
.
Y
+
50
,
pos
.
X
+
37
,
pos
.
Y
+
65
),
recti
(
0
,
0
,
128
,
64
),
0
,
0
,
true
);
...
...
gframe/game.cpp
View file @
988e5916
...
...
@@ -128,6 +128,7 @@ bool Game::Initialize() {
cbRule
->
addItem
(
dataManager
.
GetSysString
(
1241
));
cbRule
->
addItem
(
dataManager
.
GetSysString
(
1242
));
cbRule
->
addItem
(
dataManager
.
GetSysString
(
1243
));
cbRule
->
setSelected
(
gameConf
.
defaultOT
-
1
);
env
->
addStaticText
(
dataManager
.
GetSysString
(
1227
),
rect
<
s32
>
(
20
,
90
,
220
,
110
),
false
,
false
,
wCreateHost
);
cbMatchMode
=
env
->
addComboBox
(
rect
<
s32
>
(
140
,
85
,
300
,
110
),
wCreateHost
);
cbMatchMode
->
addItem
(
dataManager
.
GetSysString
(
1244
));
...
...
@@ -935,6 +936,7 @@ void Game::LoadConfig() {
gameConf
.
separate_clear_button
=
1
;
gameConf
.
auto_search_limit
=
-
1
;
gameConf
.
chkIgnoreDeckChanges
=
0
;
gameConf
.
defaultOT
=
1
;
while
(
fgets
(
linebuf
,
256
,
fp
))
{
sscanf
(
linebuf
,
"%s = %s"
,
strbuf
,
valbuf
);
if
(
!
strcmp
(
strbuf
,
"antialias"
))
{
...
...
@@ -993,6 +995,8 @@ void Game::LoadConfig() {
gameConf
.
auto_search_limit
=
atoi
(
valbuf
);
}
else
if
(
!
strcmp
(
strbuf
,
"ignore_deck_changes"
))
{
gameConf
.
chkIgnoreDeckChanges
=
atoi
(
valbuf
);
}
else
if
(
!
strcmp
(
strbuf
,
"default_ot"
))
{
gameConf
.
defaultOT
=
atoi
(
valbuf
);
}
else
{
// options allowing multiple words
sscanf
(
linebuf
,
"%s = %240[^
\n
]"
,
strbuf
,
valbuf
);
...
...
@@ -1051,6 +1055,7 @@ void Game::SaveConfig() {
fprintf
(
fp
,
"#auto_search_limit >= 0: Start search automatically when the user enters N chars
\n
"
);
fprintf
(
fp
,
"auto_search_limit = %d
\n
"
,
gameConf
.
auto_search_limit
);
fprintf
(
fp
,
"ignore_deck_changes = %d
\n
"
,
((
mainGame
->
chkIgnoreDeckChanges
->
isChecked
())
?
1
:
0
));
fprintf
(
fp
,
"default_ot = %d
\n
"
,
gameConf
.
defaultOT
);
fclose
(
fp
);
}
void
Game
::
ShowCardInfo
(
int
code
)
{
...
...
gframe/game.h
View file @
988e5916
...
...
@@ -40,6 +40,7 @@ struct Config {
int
separate_clear_button
;
int
auto_search_limit
;
int
chkIgnoreDeckChanges
;
int
defaultOT
;
};
struct
DuelInfo
{
...
...
system.conf
View file @
988e5916
...
...
@@ -27,3 +27,4 @@ separate_clear_button = 1
#auto_search_limit >= 0: Start search automatically when the user enters N chars.
auto_search_limit
= -
1
ignore_deck_changes
=
0
default_ot
=
1
textures/ot.png
View replaced file @
59001686
View file @
988e5916
18.2 KB
|
W:
|
H:
8.26 KB
|
W:
|
H:
2-up
Swipe
Onion skin
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