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
REIKAI
ygopro
Commits
78772f2d
Commit
78772f2d
authored
Apr 20, 2018
by
mercury233
Committed by
GitHub
Apr 20, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add disable chat (#2107)
parent
a3c68478
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
21 additions
and
4 deletions
+21
-4
gframe/duelclient.cpp
gframe/duelclient.cpp
+4
-2
gframe/event_handler.cpp
gframe/event_handler.cpp
+8
-0
gframe/game.cpp
gframe/game.cpp
+6
-1
gframe/game.h
gframe/game.h
+2
-0
strings.conf
strings.conf
+1
-1
No files found.
gframe/duelclient.cpp
View file @
78772f2d
...
...
@@ -479,7 +479,8 @@ void DuelClient::HandleSTOCPacketLan(char* data, unsigned int len) {
else
if
(
mainGame
->
wSinglePlay
->
isVisible
())
mainGame
->
HideElement
(
mainGame
->
wSinglePlay
);
mainGame
->
ShowElement
(
mainGame
->
wHostPrepare
);
mainGame
->
wChat
->
setVisible
(
true
);
if
(
!
mainGame
->
chkIgnore1
->
isChecked
())
mainGame
->
wChat
->
setVisible
(
true
);
mainGame
->
gMutex
.
Unlock
();
mainGame
->
dInfo
.
duel_rule
=
pkt
->
info
.
duel_rule
;
watching
=
0
;
...
...
@@ -588,7 +589,8 @@ void DuelClient::HandleSTOCPacketLan(char* data, unsigned int len) {
mainGame
->
btnM2
->
setVisible
(
false
);
mainGame
->
btnEP
->
setVisible
(
false
);
mainGame
->
btnShuffle
->
setVisible
(
false
);
mainGame
->
wChat
->
setVisible
(
true
);
if
(
!
mainGame
->
chkIgnore1
->
isChecked
())
mainGame
->
wChat
->
setVisible
(
true
);
mainGame
->
device
->
setEventReceiver
(
&
mainGame
->
dField
);
if
(
!
mainGame
->
dInfo
.
isTag
)
{
if
(
selftype
>
1
)
{
...
...
gframe/event_handler.cpp
View file @
78772f2d
...
...
@@ -1785,6 +1785,14 @@ bool ClientField::OnCommonEvent(const irr::SEvent& event) {
return
true
;
break
;
}
case
CHECKBOX_DISABLE_CHAT
:
{
bool
show
=
mainGame
->
is_building
?
false
:
!
mainGame
->
chkIgnore1
->
isChecked
();
mainGame
->
wChat
->
setVisible
(
show
);
if
(
!
show
)
mainGame
->
ClearChatMsg
();
return
true
;
break
;
}
}
break
;
}
...
...
gframe/game.cpp
View file @
78772f2d
...
...
@@ -266,7 +266,7 @@ bool Game::Initialize() {
//system
irr
::
gui
::
IGUITab
*
tabSystem
=
wInfos
->
addTab
(
dataManager
.
GetSysString
(
1273
));
posY
=
20
;
chkIgnore1
=
env
->
addCheckBox
(
false
,
rect
<
s32
>
(
posX
,
posY
,
posX
+
260
,
posY
+
25
),
tabSystem
,
-
1
,
dataManager
.
GetSysString
(
1290
));
chkIgnore1
=
env
->
addCheckBox
(
false
,
rect
<
s32
>
(
posX
,
posY
,
posX
+
260
,
posY
+
25
),
tabSystem
,
CHECKBOX_DISABLE_CHAT
,
dataManager
.
GetSysString
(
1290
));
chkIgnore1
->
setChecked
(
gameConf
.
chkIgnore1
!=
0
);
posY
+=
30
;
chkIgnore2
=
env
->
addCheckBox
(
false
,
rect
<
s32
>
(
posX
,
posY
,
posX
+
260
,
posY
+
25
),
tabSystem
,
-
1
,
dataManager
.
GetSysString
(
1291
));
...
...
@@ -1320,6 +1320,11 @@ void Game::AddChatMsg(wchar_t* msg, int player) {
}
chatMsg
[
0
].
append
(
msg
);
}
void
Game
::
ClearChatMsg
()
{
for
(
int
i
=
7
;
i
>=
0
;
--
i
)
{
chatTiming
[
i
]
=
0
;
}
}
void
Game
::
AddDebugMsg
(
char
*
msg
)
{
if
(
enable_log
&
0x1
)
{
...
...
gframe/game.h
View file @
78772f2d
...
...
@@ -131,6 +131,7 @@ public:
void
SaveConfig
();
void
ShowCardInfo
(
int
code
);
void
AddChatMsg
(
wchar_t
*
msg
,
int
player
);
void
ClearChatMsg
();
void
AddDebugMsg
(
char
*
msgbuf
);
void
ClearTextures
();
void
CloseDuelWindow
();
...
...
@@ -613,6 +614,7 @@ extern Game* mainGame;
#define CHECKBOX_ENABLE_SOUND 361
#define CHECKBOX_ENABLE_MUSIC 362
#define SCROLL_VOLUME 363
#define CHECKBOX_DISABLE_CHAT 364
#define COMBOBOX_SORTTYPE 370
#define COMBOBOX_LIMIT 371
...
...
strings.conf
View file @
78772f2d
...
...
@@ -305,7 +305,7 @@
!
system
1279
开启音效
!
system
1280
开启音乐
!
system
1281
按场景切换音乐
!
system
1290
忽略对方发言
!
system
1290
禁用聊天功能
!
system
1291
忽略观战者发言
!
system
1292
忽略时点
!
system
1293
显示时点
...
...
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