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
eb81f081
Commit
eb81f081
authored
Nov 20, 2017
by
mercury233
Committed by
GitHub
Nov 20, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add side reload/shuffle/sort deck (#2055)
parent
f3b42b46
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
24 additions
and
1 deletion
+24
-1
gframe/deck_con.cpp
gframe/deck_con.cpp
+7
-0
gframe/duelclient.cpp
gframe/duelclient.cpp
+6
-0
gframe/game.cpp
gframe/game.cpp
+6
-0
gframe/game.h
gframe/game.h
+4
-1
strings.conf
strings.conf
+1
-0
No files found.
gframe/deck_con.cpp
View file @
eb81f081
...
...
@@ -69,6 +69,9 @@ void DeckBuilder::Initialize() {
mainGame
->
btnLeaveGame
->
setVisible
(
true
);
mainGame
->
btnLeaveGame
->
setText
(
dataManager
.
GetSysString
(
1306
));
mainGame
->
btnSideOK
->
setVisible
(
false
);
mainGame
->
btnSideShuffle
->
setVisible
(
false
);
mainGame
->
btnSideSort
->
setVisible
(
false
);
mainGame
->
btnSideReload
->
setVisible
(
false
);
filterList
=
deckManager
.
_lfList
[
0
].
content
;
mainGame
->
cbDBLFList
->
setSelected
(
0
);
ClearSearch
();
...
...
@@ -239,6 +242,10 @@ bool DeckBuilder::OnEvent(const irr::SEvent& event) {
DuelClient
::
SendBufferToServer
(
CTOS_UPDATE_DECK
,
deckbuf
,
pdeck
-
deckbuf
);
break
;
}
case
BUTTON_SIDE_RELOAD
:
{
deckManager
.
LoadDeck
(
mainGame
->
cbDeckSelect
->
getItem
(
mainGame
->
cbDeckSelect
->
getSelected
()));
break
;
}
case
BUTTON_MSG_OK
:
{
mainGame
->
HideElement
(
mainGame
->
wMessage
);
mainGame
->
actionSignal
.
Set
();
...
...
gframe/duelclient.cpp
View file @
eb81f081
...
...
@@ -284,6 +284,9 @@ void DuelClient::HandleSTOCPacketLan(char* data, unsigned int len) {
mainGame
->
wSort
->
setVisible
(
false
);
mainGame
->
stTip
->
setVisible
(
false
);
mainGame
->
btnSideOK
->
setVisible
(
true
);
mainGame
->
btnSideShuffle
->
setVisible
(
true
);
mainGame
->
btnSideSort
->
setVisible
(
true
);
mainGame
->
btnSideReload
->
setVisible
(
true
);
if
(
mainGame
->
dInfo
.
player_type
<
7
)
mainGame
->
btnLeaveGame
->
setVisible
(
false
);
mainGame
->
btnSpectatorSwap
->
setVisible
(
false
);
...
...
@@ -485,6 +488,9 @@ void DuelClient::HandleSTOCPacketLan(char* data, unsigned int len) {
mainGame
->
wInfos
->
setVisible
(
true
);
mainGame
->
wPhase
->
setVisible
(
true
);
mainGame
->
btnSideOK
->
setVisible
(
false
);
mainGame
->
btnSideShuffle
->
setVisible
(
false
);
mainGame
->
btnSideSort
->
setVisible
(
false
);
mainGame
->
btnSideReload
->
setVisible
(
false
);
mainGame
->
btnPhaseStatus
->
setVisible
(
false
);
mainGame
->
btnBP
->
setVisible
(
false
);
mainGame
->
btnM2
->
setVisible
(
false
);
...
...
gframe/game.cpp
View file @
eb81f081
...
...
@@ -438,6 +438,12 @@ bool Game::Initialize() {
btnClearDeck
=
env
->
addButton
(
rect
<
s32
>
(
115
,
99
,
165
,
120
),
wDeckEdit
,
BUTTON_CLEAR_DECK
,
dataManager
.
GetSysString
(
1304
));
btnSideOK
=
env
->
addButton
(
rect
<
s32
>
(
510
,
40
,
820
,
80
),
0
,
BUTTON_SIDE_OK
,
dataManager
.
GetSysString
(
1334
));
btnSideOK
->
setVisible
(
false
);
btnSideShuffle
=
env
->
addButton
(
rect
<
s32
>
(
310
,
100
,
370
,
130
),
0
,
BUTTON_SHUFFLE_DECK
,
dataManager
.
GetSysString
(
1307
));
btnSideShuffle
->
setVisible
(
false
);
btnSideSort
=
env
->
addButton
(
rect
<
s32
>
(
375
,
100
,
435
,
130
),
0
,
BUTTON_SORT_DECK
,
dataManager
.
GetSysString
(
1305
));
btnSideSort
->
setVisible
(
false
);
btnSideReload
=
env
->
addButton
(
rect
<
s32
>
(
440
,
100
,
500
,
130
),
0
,
BUTTON_SIDE_RELOAD
,
dataManager
.
GetSysString
(
1309
));
btnSideReload
->
setVisible
(
false
);
//
scrFilter
=
env
->
addScrollBar
(
false
,
recti
(
999
,
161
,
1019
,
629
),
0
,
SCROLL_FILTER
);
scrFilter
->
setLargeStep
(
10
);
...
...
gframe/game.h
View file @
eb81f081
...
...
@@ -374,6 +374,9 @@ public:
irr
::
gui
::
IGUIButton
*
btnDeleteDeck
;
irr
::
gui
::
IGUIButton
*
btnSaveDeckAs
;
irr
::
gui
::
IGUIButton
*
btnSideOK
;
irr
::
gui
::
IGUIButton
*
btnSideShuffle
;
irr
::
gui
::
IGUIButton
*
btnSideSort
;
irr
::
gui
::
IGUIButton
*
btnSideReload
;
irr
::
gui
::
IGUIEditBox
*
ebDeckname
;
//filter
irr
::
gui
::
IGUIStaticText
*
wFilter
;
...
...
@@ -540,7 +543,7 @@ extern Game* mainGame;
#define BUTTON_SAVE_DECK 304
#define BUTTON_SAVE_DECK_AS 305
#define BUTTON_DELETE_DECK 306
//#define BUTTON_DBEXIT
307
#define BUTTON_SIDE_RELOAD
307
#define BUTTON_SORT_DECK 308
#define BUTTON_SIDE_OK 309
#define BUTTON_SHUFFLE_DECK 310
...
...
strings.conf
View file @
eb81f081
...
...
@@ -319,6 +319,7 @@
!
system
1306
退出编辑
!
system
1307
打乱
!
system
1308
删除
!
system
1309
重置
!
system
1310
(无)
!
system
1311
种类:
!
system
1312
怪兽
...
...
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