SEGS  0.4.2
Super Entity Game Server
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
GameServer.h
Go to the documentation of this file.
1 /*
2  * SEGS - Super Entity Game Server
3  * http://www.segs.io/
4  * Copyright (c) 2006 - 2018 SEGS Team (see Authors.txt)
5  * This software is licensed! (See License.txt for details)
6  */
7 
8 #pragma once
9 
10 #include "GameLink.h"
12 
13 #include <memory>
14 
15 class CharacterDatabase;
16 class GameServerData;
17 
18 class GameServer : public EventProcessor
19 {
20  class PrivateData;
21 public:
22  ~GameServer() override;
23  GameServer(int id);
24  bool ReadConfigAndRestart();
25  bool ShutDown() ;
26  const ACE_INET_Addr & getAddress();
27 
28  QString getName();
29  uint8_t getId();
30  uint16_t getCurrentPlayers();
31  uint16_t getMaxPlayers();
32  int getMaxCharacterSlots() const;
33 protected:
34  int handle_close(ACE_HANDLE handle, ACE_Reactor_Mask close_mask) override;
35  void dispatch(SEGSEvent *ev) override;
36  std::unique_ptr<PrivateData> d;
37 };
~GameServer() override
Definition: GameServer.cpp:94
Definition: SEGSEvent.h:32
std::unique_ptr< PrivateData > d
Definition: GameServer.h:36
const ACE_INET_Addr & getAddress()
Definition: GameServer.cpp:160
int handle_close(ACE_HANDLE handle, ACE_Reactor_Mask close_mask) override
Definition: GameServer.cpp:190
QString getName()
Definition: GameServer.cpp:165
bool ShutDown()
Definition: GameServer.cpp:153
int getMaxCharacterSlots() const
Definition: GameServer.cpp:185
uint16_t getCurrentPlayers()
Definition: GameServer.cpp:175
void dispatch(SEGSEvent *ev) override
Definition: GameServer.cpp:71
bool ReadConfigAndRestart()
Definition: GameServer.cpp:100
GameServer(int id)
Definition: GameServer.cpp:84
Definition: EventProcessor.h:13
uint8_t getId()
Definition: GameServer.cpp:170
uint16_t getMaxPlayers()
Definition: GameServer.cpp:180
Definition: GameServer.h:18