2007-06-07 23:16:19 +03:00
|
|
|
#ifndef CARTHANDLER_H
|
|
|
|
#define CARTHANDLER_H
|
2008-06-13 11:16:51 +03:00
|
|
|
#include "../global.h"
|
2007-06-07 23:16:19 +03:00
|
|
|
#include <string>
|
|
|
|
#include <vector>
|
|
|
|
|
|
|
|
enum EartClass {SartClass=0, TartClass, NartClass, JartClass, RartClass}; //artifact class (relict, treasure, strong, weak etc.)
|
2008-01-19 15:19:58 +02:00
|
|
|
class CDefHandler;
|
2007-06-07 23:16:19 +03:00
|
|
|
|
2008-06-13 11:16:51 +03:00
|
|
|
class DLL_EXPORT CArtifact //container for artifacts
|
2007-06-07 23:16:19 +03:00
|
|
|
{
|
|
|
|
public:
|
2007-07-10 05:46:38 +03:00
|
|
|
bool isAllowed; //true if we can use this artifact (map information)
|
2007-06-07 23:16:19 +03:00
|
|
|
std::string name;
|
|
|
|
std::string description;
|
2007-08-04 22:01:22 +03:00
|
|
|
//std::string desc2;
|
2007-06-07 23:16:19 +03:00
|
|
|
unsigned int price;
|
2008-08-26 00:14:00 +03:00
|
|
|
std::vector<ui16> possibleSlots; //ids of slots where artifact can be placed
|
|
|
|
//bool spellBook, warMachine1, warMachine2, warMachine3, warMachine4, misc1, misc2, misc3, misc4, misc5, feet, lRing, rRing, torso, lHand, rHand, neck, shoulders, head;
|
2007-06-07 23:16:19 +03:00
|
|
|
EartClass aClass;
|
2007-08-04 22:01:22 +03:00
|
|
|
int id;
|
2008-08-26 00:14:00 +03:00
|
|
|
|
|
|
|
|
2007-06-07 23:16:19 +03:00
|
|
|
};
|
|
|
|
|
2008-06-13 11:16:51 +03:00
|
|
|
class DLL_EXPORT CArtHandler //handles artifacts
|
2007-06-07 23:16:19 +03:00
|
|
|
{
|
|
|
|
public:
|
2008-02-05 05:56:45 +02:00
|
|
|
std::vector<CArtifact*> treasures, minors, majors, relics;
|
2007-06-07 23:16:19 +03:00
|
|
|
std::vector<CArtifact> artifacts;
|
|
|
|
void loadArtifacts();
|
2008-08-30 00:41:32 +03:00
|
|
|
static int convertMachineID(int id, bool creToArt);
|
2008-06-17 20:48:32 +03:00
|
|
|
CArtHandler();
|
2007-06-07 23:16:19 +03:00
|
|
|
};
|
|
|
|
|
2008-08-02 18:08:03 +03:00
|
|
|
#endif // CARTHANDLER_H
|