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
nanahira
ygopro
Commits
0e259c14
Commit
0e259c14
authored
Oct 01, 2018
by
nanahira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add detect language
parent
f2a0bbe4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
27 additions
and
2 deletions
+27
-2
gframe/game.cpp
gframe/game.cpp
+27
-2
No files found.
gframe/game.cpp
View file @
0e259c14
...
...
@@ -1409,7 +1409,32 @@ void Game::LoadConfig() {
}
fclose
(
fp_user
);
}
else
{
SaveConfig
();
#ifdef _WIN32
unsigned
int
lcid
=
((
unsigned
int
)
GetSystemDefaultLangID
())
&
0xff
;
switch
(
lcid
)
{
case
0x04
:
{
myswprintf
(
mainGame
->
gameConf
.
locale
,
L"%ls"
,
L"zh-CN"
);
break
;
}
case
0x09
:
{
myswprintf
(
mainGame
->
gameConf
.
locale
,
L"%ls"
,
L"en-US"
);
break
;
}
case
0x0a
:
{
myswprintf
(
mainGame
->
gameConf
.
locale
,
L"%ls"
,
L"es-ES"
);
break
;
}
case
0x11
:
{
myswprintf
(
mainGame
->
gameConf
.
locale
,
L"%ls"
,
L"ja-JP"
);
break
;
}
case
0x12
:
{
myswprintf
(
mainGame
->
gameConf
.
locale
,
L"%ls"
,
L"ko-KR"
);
break
;
}
}
#endif
//SaveConfig();
}
#endif //YGOPRO_COMPAT_MYCARD
}
...
...
@@ -1420,7 +1445,7 @@ void Game::SaveConfig() {
FILE
*
fp
=
fopen
(
"system_user.conf"
,
"w"
);
#endif //YGOPRO_COMPAT_MYCARD
fprintf
(
fp
,
"#config file
\n
#nickname & gamename should be less than 20 characters
\n
"
);
char
linebuf
[
256
];
char
linebuf
[
512
];
fprintf
(
fp
,
"use_d3d = %d
\n
"
,
gameConf
.
use_d3d
?
1
:
0
);
fprintf
(
fp
,
"use_image_scale = %d
\n
"
,
gameConf
.
use_image_scale
?
1
:
0
);
fprintf
(
fp
,
"pro_version = %d
\n
"
,
PRO_VERSION
);
...
...
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