summaryrefslogtreecommitdiff
path: root/src/gui/char_select.h
diff options
context:
space:
mode:
authorBjørn Lindeijer <bjorn@lindeijer.nl>2005-01-08 16:51:00 +0000
committerBjørn Lindeijer <bjorn@lindeijer.nl>2005-01-08 16:51:00 +0000
commit9ab399906e9c6ba2d6e029b1d8be50bd1df70ed4 (patch)
tree325486399e3859098f20fbe83a47276fdf01a130 /src/gui/char_select.h
parentee416a5f3de03a689247a290077e7fdf451e1a23 (diff)
downloadMana-9ab399906e9c6ba2d6e029b1d8be50bd1df70ed4.tar.gz
Mana-9ab399906e9c6ba2d6e029b1d8be50bd1df70ed4.tar.bz2
Mana-9ab399906e9c6ba2d6e029b1d8be50bd1df70ed4.tar.xz
Mana-9ab399906e9c6ba2d6e029b1d8be50bd1df70ed4.zip
Some improvements to character creation and selection dialogs.
Diffstat (limited to 'src/gui/char_select.h')
-rw-r--r--src/gui/char_select.h38
1 files changed, 14 insertions, 24 deletions
diff --git a/src/gui/char_select.h b/src/gui/char_select.h
index 475deab0..5711fb2f 100644
--- a/src/gui/char_select.h
+++ b/src/gui/char_select.h
@@ -29,6 +29,7 @@
#include "../main.h"
#include "../net/network.h"
#include "gui.h"
+#include "playerbox.h"
#include <guichan/allegro.hpp>
/**
@@ -48,6 +49,8 @@ class CharSelectDialog : public Window, public gcn::ActionListener {
gcn::Label *jobLevelLabel;
gcn::Label *moneyLabel;
+ PlayerBox *playerBox;
+
public:
/**
* Constructor.
@@ -61,25 +64,7 @@ class CharSelectDialog : public Window, public gcn::ActionListener {
void action(const std::string& eventId);
- void setName(const std::string name)
- {
- nameLabel->setCaption(name);
- }
-
- void setLevel(const std::string level)
- {
- levelLabel->setCaption(level);
- }
-
- void setJobLevel(const std::string level)
- {
- jobLevelLabel->setCaption(level);
- }
-
- void setMoney(const std::string money)
- {
- moneyLabel->setCaption(money);
- }
+ void setPlayerInfo(PLAYER_INFO* pi);
};
/**
@@ -97,8 +82,16 @@ class CharCreateDialog : public Window, public gcn::ActionListener {
gcn::Button *nextHairStyleButton;
gcn::Button *prevHairStyleButton;
gcn::Label *hairStyleLabel;
-
gcn::Button *createButton;
+ gcn::Button *cancelButton;
+
+ PlayerBox *playerBox;
+
+ /**
+ * Communicate character creation to the server and receive new char
+ * info.
+ */
+ void serverCharCreate();
public:
/**
@@ -113,9 +106,7 @@ class CharCreateDialog : public Window, public gcn::ActionListener {
void action(const std::string& eventId);
- std::string getName() {
- return nameField->getText();
- }
+ std::string getName();
};
void charSelect();
@@ -123,6 +114,5 @@ void serverCharSelect();
void charCreate();
void serverCharDelete();
-void serverCharCreate();
#endif