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
5a50cd10
Commit
5a50cd10
authored
Jul 30, 2018
by
nanahira
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into server
parents
813dca76
6980d7aa
Changes
11
Show whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
86 additions
and
38 deletions
+86
-38
gframe/client_field.cpp
gframe/client_field.cpp
+1
-0
gframe/deck_con.cpp
gframe/deck_con.cpp
+15
-10
gframe/drawing.cpp
gframe/drawing.cpp
+0
-1
gframe/duelclient.cpp
gframe/duelclient.cpp
+4
-1
gframe/event_handler.cpp
gframe/event_handler.cpp
+20
-0
gframe/game.cpp
gframe/game.cpp
+26
-22
gframe/game.h
gframe/game.h
+11
-0
gframe/replay_mode.cpp
gframe/replay_mode.cpp
+1
-1
ocgcore
ocgcore
+1
-1
script
script
+1
-1
strings.conf
strings.conf
+6
-1
No files found.
gframe/client_field.cpp
View file @
5a50cd10
...
@@ -383,6 +383,7 @@ void ClientField::ClearChainSelect() {
...
@@ -383,6 +383,7 @@ void ClientField::ClearChainSelect() {
(
*
cit
)
->
is_selected
=
false
;
(
*
cit
)
->
is_selected
=
false
;
}
}
conti_cards
.
clear
();
conti_cards
.
clear
();
deck_act
=
false
;
grave_act
=
false
;
grave_act
=
false
;
remove_act
=
false
;
remove_act
=
false
;
extra_act
=
false
;
extra_act
=
false
;
...
...
gframe/deck_con.cpp
View file @
5a50cd10
...
@@ -817,15 +817,6 @@ void DeckBuilder::StartFilter() {
...
@@ -817,15 +817,6 @@ void DeckBuilder::StartFilter() {
void
DeckBuilder
::
FilterCards
()
{
void
DeckBuilder
::
FilterCards
()
{
results
.
clear
();
results
.
clear
();
const
wchar_t
*
pstr
=
mainGame
->
ebCardName
->
getText
();
const
wchar_t
*
pstr
=
mainGame
->
ebCardName
->
getText
();
int
trycode
=
BufferIO
::
GetVal
(
pstr
);
if
(
dataManager
.
GetData
(
trycode
,
0
))
{
auto
ptr
=
dataManager
.
GetCodePointer
(
trycode
);
// verified by GetData()
results
.
push_back
(
ptr
);
mainGame
->
scrFilter
->
setVisible
(
false
);
mainGame
->
scrFilter
->
setPos
(
0
);
myswprintf
(
result_string
,
L"%d"
,
results
.
size
());
return
;
}
std
::
wstring
str
=
std
::
wstring
(
pstr
);
std
::
wstring
str
=
std
::
wstring
(
pstr
);
std
::
vector
<
std
::
wstring
>
query_elements
;
std
::
vector
<
std
::
wstring
>
query_elements
;
std
::
vector
<
std
::
vector
<
std
::
wstring
>::
iterator
>
query_elements_track
;
std
::
vector
<
std
::
vector
<
std
::
wstring
>::
iterator
>
query_elements_track
;
...
@@ -854,6 +845,13 @@ void DeckBuilder::FilterCards() {
...
@@ -854,6 +845,13 @@ void DeckBuilder::FilterCards() {
}
}
for
(
auto
elements_track_iterator
=
query_elements_track
.
begin
();
elements_track_iterator
!=
query_elements_track
.
end
();
elements_track_iterator
++
)
for
(
auto
elements_track_iterator
=
query_elements_track
.
begin
();
elements_track_iterator
!=
query_elements_track
.
end
();
elements_track_iterator
++
)
query_elements
.
erase
(
*
elements_track_iterator
);
query_elements
.
erase
(
*
elements_track_iterator
);
unsigned
int
set_code
=
0
;
if
(
pstr
[
0
]
==
L'@'
)
set_code
=
dataManager
.
GetSetCode
(
&
pstr
[
1
]);
else
set_code
=
dataManager
.
GetSetCode
(
&
pstr
[
0
]);
if
(
pstr
[
0
]
==
0
||
(
pstr
[
0
]
==
L'$'
&&
pstr
[
1
]
==
0
)
||
(
pstr
[
0
]
==
L'@'
&&
pstr
[
1
]
==
0
))
pstr
=
0
;
auto
strpointer
=
dataManager
.
_strings
.
begin
();
auto
strpointer
=
dataManager
.
_strings
.
begin
();
for
(
code_pointer
ptr
=
dataManager
.
_datas
.
begin
();
ptr
!=
dataManager
.
_datas
.
end
();
++
ptr
,
++
strpointer
)
{
for
(
code_pointer
ptr
=
dataManager
.
_datas
.
begin
();
ptr
!=
dataManager
.
_datas
.
end
();
++
ptr
,
++
strpointer
)
{
const
CardDataC
&
data
=
ptr
->
second
;
const
CardDataC
&
data
=
ptr
->
second
;
...
@@ -942,11 +940,18 @@ void DeckBuilder::FilterCards() {
...
@@ -942,11 +940,18 @@ void DeckBuilder::FilterCards() {
break
;
break
;
}
}
}
else
{
}
else
{
if
(
!
CardNameContains
(
text
.
name
.
c_str
(),
elements_iterator
->
c_str
())
&&
text
.
text
.
find
(
elements_iterator
->
c_str
())
==
std
::
wstring
::
npos
int
trycode
=
BufferIO
::
GetVal
(
elements_iterator
->
c_str
());
bool
tryresult
=
dataManager
.
GetData
(
trycode
,
0
);
if
(
!
tryresult
&&
!
CardNameContains
(
text
.
name
.
c_str
(),
elements_iterator
->
c_str
())
&&
text
.
text
.
find
(
elements_iterator
->
c_str
())
==
std
::
wstring
::
npos
&&
(
!
set_code_map
[
*
elements_iterator
]
||
!
check_set_code
(
data
,
set_code_map
[
*
elements_iterator
])))
{
&&
(
!
set_code_map
[
*
elements_iterator
]
||
!
check_set_code
(
data
,
set_code_map
[
*
elements_iterator
])))
{
is_target
=
false
;
is_target
=
false
;
break
;
break
;
}
}
if
(
tryresult
&&
data
.
code
!=
trycode
&&
!
(
data
.
alias
==
trycode
&&
(
data
.
alias
-
data
.
code
<
CARD_ARTWORK_VERSIONS_OFFSET
||
data
.
code
-
data
.
alias
<
CARD_ARTWORK_VERSIONS_OFFSET
)))
{
is_target
=
false
;
break
;
}
}
}
}
}
if
(
is_target
)
if
(
is_target
)
...
...
gframe/drawing.cpp
View file @
5a50cd10
...
@@ -929,7 +929,6 @@ void Game::DrawSpec() {
...
@@ -929,7 +929,6 @@ void Game::DrawSpec() {
break
;
break
;
}
}
auto
pos
=
lpcFont
->
getDimension
(
lstr
);
auto
pos
=
lpcFont
->
getDimension
(
lstr
);
//int offset = pos.Width / 2;
if
(
showcardp
<
10
)
{
if
(
showcardp
<
10
)
{
int
alpha
=
(
showcardp
*
25
)
<<
24
;
int
alpha
=
(
showcardp
*
25
)
<<
24
;
DrawShadowText
(
lpcFont
,
lstr
,
ResizeElem
(
650
-
pos
.
Width
/
2
-
(
9
-
showcardp
)
*
40
,
290
,
950
,
370
),
Resize
(
-
1
,
-
1
,
0
,
0
),
alpha
|
0xffffff
,
alpha
);
DrawShadowText
(
lpcFont
,
lstr
,
ResizeElem
(
650
-
pos
.
Width
/
2
-
(
9
-
showcardp
)
*
40
,
290
,
950
,
370
),
Resize
(
-
1
,
-
1
,
0
,
0
),
alpha
|
0xffffff
,
alpha
);
...
...
gframe/duelclient.cpp
View file @
5a50cd10
...
@@ -1604,7 +1604,10 @@ int DuelClient::ClientAnalyze(char * msg, unsigned int len) {
...
@@ -1604,7 +1604,10 @@ int DuelClient::ClientAnalyze(char * msg, unsigned int len) {
pcard
->
cmdFlag
|=
COMMAND_RESET
;
pcard
->
cmdFlag
|=
COMMAND_RESET
;
else
else
pcard
->
cmdFlag
|=
COMMAND_ACTIVATE
;
pcard
->
cmdFlag
|=
COMMAND_ACTIVATE
;
if
(
l
==
LOCATION_GRAVE
)
if
(
pcard
->
location
==
LOCATION_DECK
)
{
pcard
->
SetCode
(
code
);
mainGame
->
dField
.
deck_act
=
true
;
}
else
if
(
l
==
LOCATION_GRAVE
)
mainGame
->
dField
.
grave_act
=
true
;
mainGame
->
dField
.
grave_act
=
true
;
else
if
(
l
==
LOCATION_REMOVED
)
else
if
(
l
==
LOCATION_REMOVED
)
mainGame
->
dField
.
remove_act
=
true
;
mainGame
->
dField
.
remove_act
=
true
;
...
...
gframe/event_handler.cpp
View file @
5a50cd10
...
@@ -1789,6 +1789,26 @@ bool ClientField::OnCommonEvent(const irr::SEvent& event) {
...
@@ -1789,6 +1789,26 @@ bool ClientField::OnCommonEvent(const irr::SEvent& event) {
return
true
;
return
true
;
break
;
break
;
}
}
case
BUTTON_WINDOW_RESIZE_S
:
{
mainGame
->
SetWindowsScale
(
0.8
);
return
true
;
break
;
}
case
BUTTON_WINDOW_RESIZE_M
:
{
mainGame
->
SetWindowsScale
(
1
);
return
true
;
break
;
}
case
BUTTON_WINDOW_RESIZE_L
:
{
mainGame
->
SetWindowsScale
(
1.25
);
return
true
;
break
;
}
case
BUTTON_WINDOW_RESIZE_XL
:
{
mainGame
->
SetWindowsScale
(
1.5
);
return
true
;
break
;
}
}
}
break
;
break
;
}
}
...
...
gframe/game.cpp
View file @
5a50cd10
...
@@ -177,12 +177,6 @@ bool Game::Initialize() {
...
@@ -177,12 +177,6 @@ bool Game::Initialize() {
hWnd
=
reinterpret_cast
<
HWND
>
(
exposedData
.
D3D9
.
HWnd
);
hWnd
=
reinterpret_cast
<
HWND
>
(
exposedData
.
D3D9
.
HWnd
);
else
else
hWnd
=
reinterpret_cast
<
HWND
>
(
exposedData
.
OpenGLWin32
.
HWnd
);
hWnd
=
reinterpret_cast
<
HWND
>
(
exposedData
.
OpenGLWin32
.
HWnd
);
/*if(hWnd) {
LONG style = GetWindowLong(hWnd, GWL_STYLE);
style |= WS_MINIMIZEBOX;
SetWindowLong(hWnd, GWL_STYLE, style);
SendMessage(hWnd, WM_NCPAINT, 1, 0);
}*/
#endif
#endif
SetWindowsIcon
();
SetWindowsIcon
();
//main menu
//main menu
...
@@ -386,6 +380,12 @@ bool Game::Initialize() {
...
@@ -386,6 +380,12 @@ bool Game::Initialize() {
chkAutoSearch
=
env
->
addCheckBox
(
false
,
rect
<
s32
>
(
posX
,
posY
,
posX
+
260
,
posY
+
25
),
tabSystem
,
CHECKBOX_AUTO_SEARCH
,
dataManager
.
GetSysString
(
1358
));
chkAutoSearch
=
env
->
addCheckBox
(
false
,
rect
<
s32
>
(
posX
,
posY
,
posX
+
260
,
posY
+
25
),
tabSystem
,
CHECKBOX_AUTO_SEARCH
,
dataManager
.
GetSysString
(
1358
));
chkAutoSearch
->
setChecked
(
gameConf
.
auto_search_limit
>=
0
);
chkAutoSearch
->
setChecked
(
gameConf
.
auto_search_limit
>=
0
);
posY
+=
30
;
posY
+=
30
;
env
->
addStaticText
(
dataManager
.
GetSysString
(
1282
),
rect
<
s32
>
(
posX
+
23
,
posY
+
3
,
posX
+
120
,
posY
+
28
),
false
,
false
,
tabSystem
);
btnWinResizeS
=
env
->
addButton
(
rect
<
s32
>
(
posX
+
125
,
posY
,
posX
+
155
,
posY
+
25
),
tabSystem
,
BUTTON_WINDOW_RESIZE_S
,
dataManager
.
GetSysString
(
1283
));
btnWinResizeM
=
env
->
addButton
(
rect
<
s32
>
(
posX
+
160
,
posY
,
posX
+
190
,
posY
+
25
),
tabSystem
,
BUTTON_WINDOW_RESIZE_M
,
dataManager
.
GetSysString
(
1284
));
btnWinResizeL
=
env
->
addButton
(
rect
<
s32
>
(
posX
+
195
,
posY
,
posX
+
225
,
posY
+
25
),
tabSystem
,
BUTTON_WINDOW_RESIZE_L
,
dataManager
.
GetSysString
(
1285
));
btnWinResizeXL
=
env
->
addButton
(
rect
<
s32
>
(
posX
+
230
,
posY
,
posX
+
260
,
posY
+
25
),
tabSystem
,
BUTTON_WINDOW_RESIZE_XL
,
dataManager
.
GetSysString
(
1286
));
posY
+=
30
;
chkEnableSound
=
env
->
addCheckBox
(
gameConf
.
enable_sound
,
rect
<
s32
>
(
posX
,
posY
,
posX
+
120
,
posY
+
25
),
tabSystem
,
CHECKBOX_ENABLE_SOUND
,
dataManager
.
GetSysString
(
1279
));
chkEnableSound
=
env
->
addCheckBox
(
gameConf
.
enable_sound
,
rect
<
s32
>
(
posX
,
posY
,
posX
+
120
,
posY
+
25
),
tabSystem
,
CHECKBOX_ENABLE_SOUND
,
dataManager
.
GetSysString
(
1279
));
chkEnableSound
->
setChecked
(
gameConf
.
enable_sound
);
chkEnableSound
->
setChecked
(
gameConf
.
enable_sound
);
scrSoundVolume
=
env
->
addScrollBar
(
true
,
rect
<
s32
>
(
posX
+
126
,
posY
+
4
,
posX
+
260
,
posY
+
21
),
tabSystem
,
SCROLL_VOLUME
);
scrSoundVolume
=
env
->
addScrollBar
(
true
,
rect
<
s32
>
(
posX
+
126
,
posY
+
4
,
posX
+
260
,
posY
+
21
),
tabSystem
,
SCROLL_VOLUME
);
...
@@ -407,7 +407,7 @@ bool Game::Initialize() {
...
@@ -407,7 +407,7 @@ bool Game::Initialize() {
chkMusicMode
=
env
->
addCheckBox
(
false
,
rect
<
s32
>
(
posX
,
posY
,
posX
+
260
,
posY
+
25
),
tabSystem
,
-
1
,
dataManager
.
GetSysString
(
1281
));
chkMusicMode
=
env
->
addCheckBox
(
false
,
rect
<
s32
>
(
posX
,
posY
,
posX
+
260
,
posY
+
25
),
tabSystem
,
-
1
,
dataManager
.
GetSysString
(
1281
));
chkMusicMode
->
setChecked
(
gameConf
.
music_mode
!=
0
);
chkMusicMode
->
setChecked
(
gameConf
.
music_mode
!=
0
);
posY
+=
30
;
posY
+=
30
;
chkEnablePScale
=
env
->
addCheckBox
(
false
,
rect
<
s32
>
(
posX
,
posY
,
posX
+
260
,
posY
+
25
),
tabSystem
,
-
1
,
dataManager
.
GetSysString
(
128
2
));
chkEnablePScale
=
env
->
addCheckBox
(
false
,
rect
<
s32
>
(
posX
,
posY
,
posX
+
260
,
posY
+
25
),
tabSystem
,
-
1
,
dataManager
.
GetSysString
(
128
7
));
chkEnablePScale
->
setChecked
(
gameConf
.
chkEnablePScale
!=
0
);
chkEnablePScale
->
setChecked
(
gameConf
.
chkEnablePScale
!=
0
);
//
//
wHand
=
env
->
addWindow
(
rect
<
s32
>
(
500
,
450
,
825
,
605
),
false
,
L""
);
wHand
=
env
->
addWindow
(
rect
<
s32
>
(
500
,
450
,
825
,
605
),
false
,
L""
);
...
@@ -829,7 +829,7 @@ void Game::MainLoop() {
...
@@ -829,7 +829,7 @@ void Game::MainLoop() {
atkdy
=
(
float
)
sin
(
atkframe
);
atkdy
=
(
float
)
sin
(
atkframe
);
driver
->
beginScene
(
true
,
true
,
SColor
(
0
,
0
,
0
,
0
));
driver
->
beginScene
(
true
,
true
,
SColor
(
0
,
0
,
0
,
0
));
gMutex
.
Lock
();
gMutex
.
Lock
();
if
(
dInfo
.
isStarted
||
dInfo
.
isReplaySkiping
)
{
if
(
dInfo
.
isStarted
)
{
if
(
dInfo
.
isFinished
&&
showcardcode
==
1
)
if
(
dInfo
.
isFinished
&&
showcardcode
==
1
)
soundManager
.
PlayBGM
(
BGM_WIN
);
soundManager
.
PlayBGM
(
BGM_WIN
);
else
if
(
dInfo
.
isFinished
&&
(
showcardcode
==
2
||
showcardcode
==
3
))
else
if
(
dInfo
.
isFinished
&&
(
showcardcode
==
2
||
showcardcode
==
3
))
...
@@ -1502,7 +1502,7 @@ void Game::ShowCardInfo(int code, bool resize) {
...
@@ -1502,7 +1502,7 @@ void Game::ShowCardInfo(int code, bool resize) {
memset
(
&
cd
,
0
,
sizeof
(
CardData
));
memset
(
&
cd
,
0
,
sizeof
(
CardData
));
imgCard
->
setImage
(
imageManager
.
GetTexture
(
code
,
true
));
imgCard
->
setImage
(
imageManager
.
GetTexture
(
code
,
true
));
imgCard
->
setScaleImage
(
true
);
imgCard
->
setScaleImage
(
true
);
if
(
cd
.
alias
!=
0
&&
(
cd
.
alias
-
code
<
10
||
code
-
cd
.
alias
<
10
))
if
(
cd
.
alias
!=
0
&&
(
cd
.
alias
-
code
<
CARD_ARTWORK_VERSIONS_OFFSET
||
code
-
cd
.
alias
<
CARD_ARTWORK_VERSIONS_OFFSET
))
myswprintf
(
formatBuffer
,
L"%ls[%08d]"
,
dataManager
.
GetName
(
cd
.
alias
),
cd
.
alias
);
myswprintf
(
formatBuffer
,
L"%ls[%08d]"
,
dataManager
.
GetName
(
cd
.
alias
),
cd
.
alias
);
else
myswprintf
(
formatBuffer
,
L"%ls[%08d]"
,
dataManager
.
GetName
(
code
),
code
);
else
myswprintf
(
formatBuffer
,
L"%ls[%08d]"
,
dataManager
.
GetName
(
code
),
code
);
stName
->
setText
(
formatBuffer
);
stName
->
setText
(
formatBuffer
);
...
@@ -1568,10 +1568,7 @@ void Game::ShowCardInfo(int code, bool resize) {
...
@@ -1568,10 +1568,7 @@ void Game::ShowCardInfo(int code, bool resize) {
}
else
{
}
else
{
myswprintf
(
formatBuffer
,
L"[%ls]"
,
dataManager
.
FormatType
(
cd
.
type
));
myswprintf
(
formatBuffer
,
L"[%ls]"
,
dataManager
.
FormatType
(
cd
.
type
));
stInfo
->
setText
(
formatBuffer
);
stInfo
->
setText
(
formatBuffer
);
stDataInfo
->
setRelativePosition
(
recti
(
15
,
60
,
300
*
xScale
-
13
,
83
));
stDataInfo
->
setText
(
L""
);
stDataInfo
->
setText
(
L""
);
//stSetName->setRelativePosition(rect<s32>(15, 60 * yScale, 296 * xScale, 60 * yScale + offset));
//stText->setRelativePosition(rect<s32>(15, 60 * yScale + offset, 287 * xScale, 324 * yScale));
stSetName
->
setRelativePosition
(
rect
<
s32
>
(
15
,
60
,
296
*
xScale
,
60
+
offset
));
stSetName
->
setRelativePosition
(
rect
<
s32
>
(
15
,
60
,
296
*
xScale
,
60
+
offset
));
stText
->
setRelativePosition
(
rect
<
s32
>
(
15
,
60
+
offset
,
287
*
xScale
,
324
*
yScale
));
stText
->
setRelativePosition
(
rect
<
s32
>
(
15
,
60
+
offset
,
287
*
xScale
,
324
*
yScale
));
scrCardText
->
setRelativePosition
(
rect
<
s32
>
(
287
*
xScale
-
20
,
60
+
offset
,
287
*
xScale
,
324
*
yScale
));
scrCardText
->
setRelativePosition
(
rect
<
s32
>
(
287
*
xScale
-
20
,
60
+
offset
,
287
*
xScale
,
324
*
yScale
));
...
@@ -1806,18 +1803,14 @@ void Game::OnResize() {
...
@@ -1806,18 +1803,14 @@ void Game::OnResize() {
irr
::
gui
::
CGUITTFont
*
old_numFont
=
numFont
;
irr
::
gui
::
CGUITTFont
*
old_numFont
=
numFont
;
irr
::
gui
::
CGUITTFont
*
old_adFont
=
adFont
;
irr
::
gui
::
CGUITTFont
*
old_adFont
=
adFont
;
irr
::
gui
::
CGUITTFont
*
old_lpcFont
=
lpcFont
;
irr
::
gui
::
CGUITTFont
*
old_lpcFont
=
lpcFont
;
//irr::gui::CGUITTFont* old_guiFont = guiFont;
irr
::
gui
::
CGUITTFont
*
old_textFont
=
textFont
;
irr
::
gui
::
CGUITTFont
*
old_textFont
=
textFont
;
numFont
=
irr
::
gui
::
CGUITTFont
::
createTTFont
(
env
,
gameConf
.
numfont
,
(
yScale
>
0.5
?
16
*
yScale
:
8
));
numFont
=
irr
::
gui
::
CGUITTFont
::
createTTFont
(
env
,
gameConf
.
numfont
,
(
yScale
>
0.5
?
16
*
yScale
:
8
));
adFont
=
irr
::
gui
::
CGUITTFont
::
createTTFont
(
env
,
gameConf
.
numfont
,
(
yScale
>
0.75
?
12
*
yScale
:
9
));
adFont
=
irr
::
gui
::
CGUITTFont
::
createTTFont
(
env
,
gameConf
.
numfont
,
(
yScale
>
0.75
?
12
*
yScale
:
9
));
lpcFont
=
irr
::
gui
::
CGUITTFont
::
createTTFont
(
env
,
gameConf
.
numfont
,
48
*
yScale
);
lpcFont
=
irr
::
gui
::
CGUITTFont
::
createTTFont
(
env
,
gameConf
.
numfont
,
48
*
yScale
);
//guiFont = irr::gui::CGUITTFont::createTTFont(env, gameConf.textfont, gameConf.textfontsize * yScale);
//env->getSkin()->setFont(guiFont);
textFont
=
irr
::
gui
::
CGUITTFont
::
createTTFont
(
env
,
gameConf
.
textfont
,
(
yScale
>
0.642
?
gameConf
.
textfontsize
*
yScale
:
9
));
textFont
=
irr
::
gui
::
CGUITTFont
::
createTTFont
(
env
,
gameConf
.
textfont
,
(
yScale
>
0.642
?
gameConf
.
textfontsize
*
yScale
:
9
));
old_numFont
->
drop
();
old_numFont
->
drop
();
old_adFont
->
drop
();
old_adFont
->
drop
();
old_lpcFont
->
drop
();
old_lpcFont
->
drop
();
//old_guiFont->drop();
old_textFont
->
drop
();
old_textFont
->
drop
();
imageManager
.
ClearTexture
();
imageManager
.
ClearTexture
();
...
@@ -1896,8 +1889,8 @@ void Game::OnResize() {
...
@@ -1896,8 +1889,8 @@ void Game::OnResize() {
stHintMsg
->
setRelativePosition
(
ResizeWin
(
500
,
60
,
820
,
90
));
stHintMsg
->
setRelativePosition
(
ResizeWin
(
500
,
60
,
820
,
90
));
//sound / music volume bar
//sound / music volume bar
scrSoundVolume
->
setRelativePosition
(
recti
(
20
+
126
,
2
00
+
4
,
20
+
(
300
*
xScale
)
-
40
,
20
0
+
21
));
scrSoundVolume
->
setRelativePosition
(
recti
(
20
+
126
,
2
30
+
4
,
20
+
(
300
*
xScale
)
-
40
,
23
0
+
21
));
scrMusicVolume
->
setRelativePosition
(
recti
(
20
+
126
,
2
30
+
4
,
20
+
(
300
*
xScale
)
-
40
,
23
0
+
21
));
scrMusicVolume
->
setRelativePosition
(
recti
(
20
+
126
,
2
60
+
4
,
20
+
(
300
*
xScale
)
-
40
,
26
0
+
21
));
if
(
gameConf
.
resize_popup_menu
)
{
if
(
gameConf
.
resize_popup_menu
)
{
int
width
=
100
*
mainGame
->
xScale
;
int
width
=
100
*
mainGame
->
xScale
;
...
@@ -1920,11 +1913,7 @@ void Game::OnResize() {
...
@@ -1920,11 +1913,7 @@ void Game::OnResize() {
imgCard
->
setRelativePosition
(
ResizeCard
(
10
,
9
,
0
,
0
));
imgCard
->
setRelativePosition
(
ResizeCard
(
10
,
9
,
0
,
0
));
wInfos
->
setRelativePosition
(
Resize
(
1
,
275
,
301
,
639
));
wInfos
->
setRelativePosition
(
Resize
(
1
,
275
,
301
,
639
));
stName
->
setRelativePosition
(
recti
(
10
,
10
,
300
*
xScale
-
13
,
10
+
22
));
stName
->
setRelativePosition
(
recti
(
10
,
10
,
300
*
xScale
-
13
,
10
+
22
));
//stName->setRelativePosition(recti(10, 10, 300 * xScale - 13, 10 + 22 * yScale));
//stInfo->setRelativePosition(recti(15, 37 * yScale, 300 * xScale - 13, 60 * yScale));
//stDataInfo->setRelativePosition(recti(15, 60 * yScale, 300 * xScale - 13, 83 * yScale));
lstLog
->
setRelativePosition
(
Resize
(
10
,
10
,
290
,
290
));
lstLog
->
setRelativePosition
(
Resize
(
10
,
10
,
290
,
290
));
//const auto& tsize = stText->getRelativePosition();
if
(
showingcode
)
if
(
showingcode
)
ShowCardInfo
(
showingcode
,
true
);
ShowCardInfo
(
showingcode
,
true
);
btnClearLog
->
setRelativePosition
(
Resize
(
160
,
300
,
260
,
325
));
btnClearLog
->
setRelativePosition
(
Resize
(
160
,
300
,
260
,
325
));
...
@@ -2061,6 +2050,21 @@ void Game::SetWindowsIcon() {
...
@@ -2061,6 +2050,21 @@ void Game::SetWindowsIcon() {
SendMessageW
(
hWnd
,
WM_SETICON
,
ICON_BIG
,
(
long
)
hBigIcon
);
SendMessageW
(
hWnd
,
WM_SETICON
,
ICON_BIG
,
(
long
)
hBigIcon
);
#endif
#endif
}
}
void
Game
::
SetWindowsScale
(
float
scale
)
{
#ifdef _WIN32
WINDOWPLACEMENT
plc
;
plc
.
length
=
sizeof
(
WINDOWPLACEMENT
);
if
(
GetWindowPlacement
(
hWnd
,
&
plc
)
&&
(
plc
.
showCmd
==
SW_SHOWMAXIMIZED
))
ShowWindow
(
hWnd
,
SW_RESTORE
);
RECT
rcWindow
,
rcClient
;
GetWindowRect
(
hWnd
,
&
rcWindow
);
GetClientRect
(
hWnd
,
&
rcClient
);
MoveWindow
(
hWnd
,
rcWindow
.
left
,
rcWindow
.
top
,
(
rcWindow
.
right
-
rcWindow
.
left
)
-
rcClient
.
right
+
1024
*
scale
,
(
rcWindow
.
bottom
-
rcWindow
.
top
)
-
rcClient
.
bottom
+
640
*
scale
,
true
);
#endif
}
void
Game
::
FlashWindow
()
{
void
Game
::
FlashWindow
()
{
#ifdef _WIN32
#ifdef _WIN32
FLASHWINFO
fi
;
FLASHWINFO
fi
;
...
...
gframe/game.h
View file @
5a50cd10
...
@@ -192,6 +192,7 @@ public:
...
@@ -192,6 +192,7 @@ public:
recti
ResizeFit
(
s32
x
,
s32
y
,
s32
x2
,
s32
y2
);
recti
ResizeFit
(
s32
x
,
s32
y
,
s32
x2
,
s32
y2
);
void
SetWindowsIcon
();
void
SetWindowsIcon
();
void
SetWindowsScale
(
float
scale
);
void
FlashWindow
();
void
FlashWindow
();
void
takeScreenshot
();
void
takeScreenshot
();
void
SetCursor
(
ECURSOR_ICON
icon
);
void
SetCursor
(
ECURSOR_ICON
icon
);
...
@@ -301,6 +302,10 @@ public:
...
@@ -301,6 +302,10 @@ public:
irr
::
gui
::
IGUIScrollBar
*
scrSoundVolume
;
irr
::
gui
::
IGUIScrollBar
*
scrSoundVolume
;
irr
::
gui
::
IGUIScrollBar
*
scrMusicVolume
;
irr
::
gui
::
IGUIScrollBar
*
scrMusicVolume
;
irr
::
gui
::
IGUICheckBox
*
chkMusicMode
;
irr
::
gui
::
IGUICheckBox
*
chkMusicMode
;
irr
::
gui
::
IGUIButton
*
btnWinResizeS
;
irr
::
gui
::
IGUIButton
*
btnWinResizeM
;
irr
::
gui
::
IGUIButton
*
btnWinResizeL
;
irr
::
gui
::
IGUIButton
*
btnWinResizeXL
;
irr
::
gui
::
IGUICheckBox
*
chkEnablePScale
;
irr
::
gui
::
IGUICheckBox
*
chkEnablePScale
;
//main menu
//main menu
irr
::
gui
::
IGUIWindow
*
wMainMenu
;
irr
::
gui
::
IGUIWindow
*
wMainMenu
;
...
@@ -694,6 +699,10 @@ extern HostInfo game_info;
...
@@ -694,6 +699,10 @@ extern HostInfo game_info;
#define CHECKBOX_ENABLE_MUSIC 362
#define CHECKBOX_ENABLE_MUSIC 362
#define SCROLL_VOLUME 363
#define SCROLL_VOLUME 363
#define CHECKBOX_DISABLE_CHAT 364
#define CHECKBOX_DISABLE_CHAT 364
#define BUTTON_WINDOW_RESIZE_S 365
#define BUTTON_WINDOW_RESIZE_M 366
#define BUTTON_WINDOW_RESIZE_L 367
#define BUTTON_WINDOW_RESIZE_XL 368
#define COMBOBOX_SORTTYPE 370
#define COMBOBOX_SORTTYPE 370
#define COMBOBOX_LIMIT 371
#define COMBOBOX_LIMIT 371
...
@@ -714,4 +723,6 @@ extern HostInfo game_info;
...
@@ -714,4 +723,6 @@ extern HostInfo game_info;
#define TEXTURE_ACTIVATE 6
#define TEXTURE_ACTIVATE 6
#define DEFAULT_DUEL_RULE 4
#define DEFAULT_DUEL_RULE 4
#define CARD_ARTWORK_VERSIONS_OFFSET 10
#endif // GAME_H
#endif // GAME_H
gframe/replay_mode.cpp
View file @
5a50cd10
...
@@ -106,6 +106,7 @@ int ReplayMode::ReplayThread(void* param) {
...
@@ -106,6 +106,7 @@ int ReplayMode::ReplayThread(void* param) {
get_message
(
pduel
,
(
byte
*
)
engineBuffer
);
get_message
(
pduel
,
(
byte
*
)
engineBuffer
);
is_continuing
=
ReplayAnalyze
(
engineBuffer
,
len
);
is_continuing
=
ReplayAnalyze
(
engineBuffer
,
len
);
if
(
is_restarting
)
{
if
(
is_restarting
)
{
mainGame
->
gMutex
.
Lock
();
is_restarting
=
false
;
is_restarting
=
false
;
int
step
=
current_step
-
1
;
int
step
=
current_step
-
1
;
if
(
step
<
0
)
if
(
step
<
0
)
...
@@ -282,7 +283,6 @@ void ReplayMode::Undo() {
...
@@ -282,7 +283,6 @@ void ReplayMode::Undo() {
return
;
return
;
mainGame
->
dInfo
.
isReplaySkiping
=
true
;
mainGame
->
dInfo
.
isReplaySkiping
=
true
;
Restart
(
false
);
Restart
(
false
);
mainGame
->
gMutex
.
Lock
();
Pause
(
false
,
false
);
Pause
(
false
,
false
);
}
}
bool
ReplayMode
::
ReplayAnalyze
(
char
*
msg
,
unsigned
int
len
)
{
bool
ReplayMode
::
ReplayAnalyze
(
char
*
msg
,
unsigned
int
len
)
{
...
...
ocgcore
@
18d7c0ab
Subproject commit
f542264303925cbef2054cb30932019c420eec1d
Subproject commit
18d7c0ab0c17afc0967993c1eabdbc9dcb3688db
script
@
a5facedc
Subproject commit
79825779c6a415b2a0c86a2af82532f03c21a34b
Subproject commit
a5facedc2c207e9cfaeacef6cb30a37c96d097f3
strings.conf
View file @
5a50cd10
...
@@ -308,7 +308,12 @@
...
@@ -308,7 +308,12 @@
!
system
1279
开启音效
!
system
1279
开启音效
!
system
1280
开启音乐
!
system
1280
开启音乐
!
system
1281
按场景切换音乐
!
system
1281
按场景切换音乐
!
system
1282
数字灵摆图片
!
system
1282
窗口大小
!
system
1283
小
!
system
1284
中
!
system
1285
大
!
system
1286
特大
!
system
1287
数字灵摆图片
!
system
1290
忽略对方发言
!
system
1290
忽略对方发言
!
system
1291
忽略观战者发言
!
system
1291
忽略观战者发言
!
system
1292
忽略时点
!
system
1292
忽略时点
...
...
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