![]() |
DDNet documentation
|
#include <console.h>
Classes | |
| class | CInstance |
Public Types | |
| enum | { CONSOLETYPE_LOCAL = 0 , CONSOLETYPE_REMOTE , NUM_CONSOLETYPES } |
Public Member Functions | |
| CGameConsole () | |
| ~CGameConsole () override | |
| int | Sizeof () const override |
| void | PrintLine (int Type, const char *pLine) |
| void | RequireUsername (bool UsernameReq) |
| void | OnStateChange (int NewState, int OldState) override |
| void | OnConsoleInit () override |
| void | OnInit () override |
| void | OnReset () override |
| void | OnRender () override |
| void | OnMessage (int MsgType, void *pRawMsg) override |
| bool | OnInput (const IInput::CEvent &Event) override |
| void | Prompt (char(&aPrompt)[32]) |
| void | Toggle (int Type) |
| bool | IsActive () const |
| void | ForceUpdateRemoteCompletionSuggestions () |
| Public Member Functions inherited from CComponent | |
| virtual void | OnShutdown () |
| virtual void | OnWindowResize () |
| virtual void | OnUpdate () |
| virtual void | OnNewSnapshot () |
| virtual void | OnRelease () |
| virtual void | OnMapLoad () |
| virtual bool | OnCursorMove (float x, float y, IInput::ECursorType CursorType) |
| virtual bool | OnTouchState (std::vector< IInput::CTouchFingerState > &vTouchFingerStates) |
| Public Member Functions inherited from CComponentInterfaces | |
| virtual void | OnInterfacesInit (CGameClient *pClient) |
| virtual | ~CComponentInterfaces ()=default |
Private Member Functions | |
| CInstance * | ConsoleForType (int ConsoleType) |
| CInstance * | CurrentConsole () |
| int | PossibleMaps (const char *pStr, IConsole::FPossibleCallback pfnCallback=IConsole::EmptyPossibleCommandCallback, void *pUser=nullptr) |
Static Private Member Functions | |
| static void | PossibleCommandsRenderCallback (int Index, const char *pStr, void *pUser) |
| static void | ConToggleLocalConsole (IConsole::IResult *pResult, void *pUserData) |
| static void | ConToggleRemoteConsole (IConsole::IResult *pResult, void *pUserData) |
| static void | ConClearLocalConsole (IConsole::IResult *pResult, void *pUserData) |
| static void | ConClearRemoteConsole (IConsole::IResult *pResult, void *pUserData) |
| static void | ConDumpLocalConsole (IConsole::IResult *pResult, void *pUserData) |
| static void | ConDumpRemoteConsole (IConsole::IResult *pResult, void *pUserData) |
| static void | ConConsolePageUp (IConsole::IResult *pResult, void *pUserData) |
| static void | ConConsolePageDown (IConsole::IResult *pResult, void *pUserData) |
| static void | ConConsolePageTop (IConsole::IResult *pResult, void *pUserData) |
| static void | ConConsolePageBottom (IConsole::IResult *pResult, void *pUserData) |
| static void | ConchainConsoleOutputLevel (IConsole::IResult *pResult, void *pUserData, IConsole::FCommandCallback pfnCallback, void *pCallbackUserData) |
Private Attributes | |
| class IConsole * | m_pConsole |
| CConsoleLogger * | m_pConsoleLogger = nullptr |
| CInstance | m_LocalConsole |
| CInstance | m_RemoteConsole |
| int | m_ConsoleType |
| int | m_ConsoleState |
| float | m_StateChangeEnd |
| float | m_StateChangeDuration |
| bool | m_WantsSelectionCopy = false |
| CUi::CTouchState | m_TouchState |
Static Private Attributes | |
| static constexpr ColorRGBA | ms_SearchHighlightColor = ColorRGBA(1.0f, 0.0f, 0.0f, 1.0f) |
| static constexpr ColorRGBA | ms_SearchSelectedColor = ColorRGBA(1.0f, 1.0f, 0.0f, 1.0f) |
Friends | |
| class | CConsoleLogger |
Additional Inherited Members | |
| Protected Member Functions inherited from CComponentInterfaces | |
| class CGameClient * | GameClient () const |
| class IClient * | Client () const |
| class IKernel * | Kernel () const |
| class IEngine * | Engine () const |
| class IGraphics * | Graphics () const |
| class ITextRender * | TextRender () const |
| class IInput * | Input () const |
| class IStorage * | Storage () const |
| class CUi * | Ui () const |
| class ISound * | Sound () const |
| class CRenderTools * | RenderTools () const |
| class CRenderMap * | RenderMap () const |
| class IConfigManager * | ConfigManager () const |
| class CConfig * | Config () const |
| class IConsole * | Console () const |
| class IDemoPlayer * | DemoPlayer () const |
| class IDemoRecorder * | DemoRecorder (int Recorder) const |
| class IFavorites * | Favorites () const |
| class IServerBrowser * | ServerBrowser () const |
| class CLayers * | Layers () const |
| class CCollision * | Collision () const |
| int64_t | time () const |
| float | LocalTime () const |
| class IHttp * | Http () const |
| CGameConsole::CGameConsole | ( | ) |
|
override |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
staticprivate |
|
private |
|
staticprivate |
|
staticprivate |
|
private |
| void CGameConsole::ForceUpdateRemoteCompletionSuggestions | ( | ) |
|
inline |
|
overridevirtual |
Called to let the components register their console commands.
Reimplemented from CComponent.
|
overridevirtual |
Called to let the components run initialization code.
Reimplemented from CComponent.
|
overridevirtual |
|
overridevirtual |
Called when receiving a network message.
| Msg | The message type. |
| pRawMsg | The message data. |
Reimplemented from CComponent.
|
overridevirtual |
Called when the component should get rendered.
The render order depends on the component insertion order.
Reimplemented from CComponent.
|
overridevirtual |
Called to reset the component. This method is usually called on your component constructor to avoid code duplication.
Reimplemented from CComponent.
|
overridevirtual |
This method is called when the client changes state, e.g from offline to online.
Reimplemented from CComponent.
|
staticprivate |
|
private |
| void CGameConsole::PrintLine | ( | int | Type, |
| const char * | pLine ) |
| void CGameConsole::Prompt | ( | char(&) | aPrompt[32] | ) |
| void CGameConsole::RequireUsername | ( | bool | UsernameReq | ) |
|
inlineoverridevirtual |
Gets the size of the non-abstract component.
Implements CComponent.
| void CGameConsole::Toggle | ( | int | Type | ) |
|
friend |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
staticconstexprprivate |
|
staticconstexprprivate |