00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef EQUIPMENT_H
00023 #define EQUIPMENT_H
00024
00025 #ifdef TMWSERV_SUPPORT
00026 #define EQUIPMENT_SIZE 11
00027 #else
00028 #define EQUIPMENT_SIZE 10
00029 #endif
00030
00031 class Item;
00032
00033 class Equipment
00034 {
00035 public:
00039 Equipment();
00040
00041 #ifdef TMWSERV_SUPPORT
00042
00045 ~Equipment();
00046 #endif
00047
00051 #ifdef TMWSERV_SUPPORT
00052 Item *getEquipment(int index)
00053 #else
00054 int getEquipment(int index) const
00055 #endif
00056 { return mEquipment[index]; }
00057
00058 #ifdef TMWSERV_SUPPORT
00059
00062 void clear();
00063 #endif
00064
00068 #ifdef TMWSERV_SUPPORT
00069 void setEquipment(int index, int id);
00070 #else
00071 void setEquipment(int index, int inventoryIndex);
00072 #endif
00073
00074 #ifdef EATHENA_SUPPORT
00075
00078 void removeEquipment(int index);
00079
00083 int getArrows() const { return mArrows; }
00084
00088 void setArrows(int arrows) { mArrows = arrows; }
00089 #endif
00090
00091 private:
00092 #ifdef TMWSERV_SUPPORT
00093 Item *mEquipment[EQUIPMENT_SIZE];
00094 #else
00095 int mEquipment[EQUIPMENT_SIZE];
00096 int mArrows;
00097 #endif
00098 };
00099
00100 #endif