ManaPlus
Functions | Variables
Ea::GameRecv Namespace Reference

Functions

void processWhoAnswer (Net::MessageIn &msg)
 
void processCharSwitchResponse (Net::MessageIn &msg)
 
void processMapQuitResponse (Net::MessageIn &msg)
 

Variables

std::string mMap
 
BeingId mCharID = BeingId_zero
 

Function Documentation

◆ processCharSwitchResponse()

void Ea::GameRecv::processCharSwitchResponse ( Net::MessageIn msg)

Definition at line 55 of file gamerecv.cpp.

56 {
57  if (msg.readUInt8("response") != 0U)
59 }

References client, Actions::msg(), Client::setState(), and State::SWITCH_CHARACTER.

◆ processMapQuitResponse()

void Ea::GameRecv::processMapQuitResponse ( Net::MessageIn msg)

Definition at line 61 of file gamerecv.cpp.

62 {
63  if (msg.readInt16("response") != 0)
64  {
66  // TRANSLATORS: error header
67  _("Game"),
68  // TRANSLATORS: error message
69  _("Request to quit denied!"),
70  // TRANSLATORS: ok dialog button
71  _("OK"),
73  Modal_true,
75  nullptr,
76  260);
77  }
78 }

References _, CREATEWIDGET, DialogType::ERROR, Modal_true, Actions::msg(), and ShowCenter_true.

◆ processWhoAnswer()

void Ea::GameRecv::processWhoAnswer ( Net::MessageIn msg)

Definition at line 49 of file gamerecv.cpp.

50 {
52  msg.readInt32("users count"));
53 }

References Actions::msg(), NotifyManager::notify(), and NotifyTypes::ONLINE_USERS.

Variable Documentation

◆ mCharID

BeingId Ea::GameRecv::mCharID = BeingId_zero

◆ mMap

std::string Ea::GameRecv::mMap
DialogType::ERROR
@ ERROR
Definition: dialogtype.h:33
Actions::msg
bool msg(InputEvent &event)
Definition: chat.cpp:38
OkDialog
Definition: okdialog.h:43
NotifyManager::notify
void notify(const unsigned int message)
Definition: notifymanager.cpp:81
Client::setState
void setState(const StateT state)
Definition: client.h:65
ShowCenter_true
const bool ShowCenter_true
Definition: showcenter.h:29
client
Client * client
Definition: client.cpp:117
Modal_true
const bool Modal_true
Definition: modal.h:29
_
#define _(s)
Definition: gettext.h:34
NotifyTypes::ONLINE_USERS
@ ONLINE_USERS
Definition: notifytypes.h:41
State::SWITCH_CHARACTER
@ SWITCH_CHARACTER
Definition: state.h:63
CREATEWIDGET
#define CREATEWIDGET(type,...)
Definition: createwidget.h:28