summaryrefslogtreecommitdiff
path: root/src/gui/skill.h
diff options
context:
space:
mode:
authorIra Rice <irarice@gmail.com>2008-11-02 00:33:31 +0000
committerIra Rice <irarice@gmail.com>2008-11-02 00:33:31 +0000
commit5cf18a062ffca03196b83fe6fda8ea3e54079c57 (patch)
tree00fa520012a6ed4a0fee66a1d65364bf81ccaeb5 /src/gui/skill.h
parent494e35cda96863f676409d304a916d9308040eab (diff)
downloadmana-5cf18a062ffca03196b83fe6fda8ea3e54079c57.tar.gz
mana-5cf18a062ffca03196b83fe6fda8ea3e54079c57.tar.bz2
mana-5cf18a062ffca03196b83fe6fda8ea3e54079c57.tar.xz
mana-5cf18a062ffca03196b83fe6fda8ea3e54079c57.zip
Ported a patch from TMW by fate which de-hardcodes skills, as well as removes the server sending out view id's for
gloves and boots (which weren't needed.) Here's the full log: * Updated GUI table and model to better handle NULL widgets during initialisation * On SMSG_MOVE et al., ignore boots and glove information-- that information is incorrect and we're guaranteed to already have the correct information anyway. * Properly decode `is dead' information for PCs, so that dead players, when encountered, will be lying on the ground, dead, rather than standing. * Use `skills.xml' file from client data to determine skill names * Report client version number (hereby bumped to 1) in unused charserver slot (ignored by vanilla eAthena)
Diffstat (limited to 'src/gui/skill.h')
-rw-r--r--src/gui/skill.h18
1 files changed, 12 insertions, 6 deletions
diff --git a/src/gui/skill.h b/src/gui/skill.h
index 6bd6c51b..92badc8a 100644
--- a/src/gui/skill.h
+++ b/src/gui/skill.h
@@ -18,7 +18,7 @@
* along with The Mana World; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
- * $Id: skill.h 3494 2007-08-20 05:29:12Z joshlangley $
+ * $Id$
*/
#ifndef _TMW_SKILL_H
@@ -26,9 +26,11 @@
#include <vector>
-#include <guichan/listmodel.hpp>
#include <guichan/actionlistener.hpp>
+#include <guichan/listmodel.hpp>
+#include "scrollarea.h"
+#include "table.h"
#include "window.h"
#include "../guichanfwd.h"
@@ -38,13 +40,14 @@ struct SKILL {
short lv, sp;
};
+class SkillGuiTableModel;
+
/**
* The skill dialog.
*
* \ingroup Interface
*/
-class SkillDialog : public Window, public gcn::ActionListener,
- public gcn::ListModel
+class SkillDialog : public Window, public gcn::ActionListener
{
public:
/**
@@ -62,15 +65,18 @@ class SkillDialog : public Window, public gcn::ActionListener,
void update();
int getNumberOfElements();
- std::string getElementAt(int);
bool hasSkill(int id);
void addSkill(int id, int lv, int sp);
void setSkill(int id, int lv, int sp);
void cleanList();
+ const std::vector<SKILL*>& getSkills(void) const { return mSkillList; }
+
private:
- gcn::ListBox *mSkillListBox;
+ GuiTable mTable;//gcn::ListBox *mSkillListBox;
+ ScrollArea *skillScrollArea;
+ SkillGuiTableModel *mTableModel;
gcn::Label *mPointsLabel;
gcn::Button *mIncButton;
gcn::Button *mUseButton;