DDraceNetwork Documentation
Loading...
Searching...
No Matches
motd.h
Go to the documentation of this file.
1
/* (c) Magnus Auvinen. See licence.txt in the root of the distribution for more information. */
2
/* If you are missing that file, acquire a complete release at teeworlds.com. */
3
#ifndef GAME_CLIENT_COMPONENTS_MOTD_H
4
#define GAME_CLIENT_COMPONENTS_MOTD_H
5
6
#include <
engine/shared/config.h
>
7
#include <
engine/textrender.h
>
8
9
#include <
game/client/component.h
>
10
11
class
CMotd
:
public
CComponent
12
{
13
char
m_aServerMotd
[std::size(
g_Config
.m_SvMotd)];
14
int64_t
m_ServerMotdTime
;
15
int64_t
m_ServerMotdUpdateTime
;
16
int
m_RectQuadContainer
= -1;
17
STextContainerIndex
m_TextContainerIndex
;
18
19
public
:
20
CMotd
();
21
int
Sizeof
()
const override
{
return
sizeof
(*this); }
22
23
const
char
*
ServerMotd
()
const
{
return
m_aServerMotd
; }
24
int64_t
ServerMotdUpdateTime
()
const
{
return
m_ServerMotdUpdateTime
; }
25
void
Clear
();
26
bool
IsActive
()
const
;
27
28
void
OnRender
()
override
;
29
void
OnStateChange
(
int
NewState
,
int
OldState
)
override
;
30
void
OnWindowResize
()
override
;
31
void
OnMessage
(
int
MsgType
,
void
*
pRawMsg
)
override
;
32
bool
OnInput
(
const
IInput::CEvent
&
Event
)
override
;
33
};
34
35
#endif
CComponent
Definition
component.h:165
CMotd
Definition
motd.h:12
CMotd::m_RectQuadContainer
int m_RectQuadContainer
Definition
motd.h:16
CMotd::m_aServerMotd
char m_aServerMotd[std::size(g_Config.m_SvMotd)]
Definition
motd.h:13
CMotd::Sizeof
int Sizeof() const override
Definition
motd.h:21
CMotd::OnWindowResize
void OnWindowResize() override
Definition
motd.cpp:39
CMotd::m_ServerMotdTime
int64_t m_ServerMotdTime
Definition
motd.h:14
CMotd::OnRender
void OnRender() override
Definition
motd.cpp:45
CMotd::OnMessage
void OnMessage(int MsgType, void *pRawMsg) override
Definition
motd.cpp:89
CMotd::IsActive
bool IsActive() const
Definition
motd.cpp:28
CMotd::m_TextContainerIndex
STextContainerIndex m_TextContainerIndex
Definition
motd.h:17
CMotd::ServerMotd
const char * ServerMotd() const
Definition
motd.h:23
CMotd::OnStateChange
void OnStateChange(int NewState, int OldState) override
Definition
motd.cpp:33
CMotd::ServerMotdUpdateTime
int64_t ServerMotdUpdateTime() const
Definition
motd.h:24
CMotd::Clear
void Clear()
Definition
motd.cpp:21
CMotd::CMotd
CMotd()
Definition
motd.cpp:14
CMotd::OnInput
bool OnInput(const IInput::CEvent &Event) override
Definition
motd.cpp:135
CMotd::m_ServerMotdUpdateTime
int64_t m_ServerMotdUpdateTime
Definition
motd.h:15
IInput::CEvent
Definition
input.h:22
vector2_base
Definition
vmath.h:15
component.h
g_Config
CConfig g_Config
Definition
config.cpp:13
config.h
STextContainerIndex
Definition
textrender.h:261
textrender.h
src
game
client
components
motd.h
Generated by
1.9.8