Advertisement
s1ay3r44

Undefined references

Nov 18th, 2011
244
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 1.31 KB | None | 0 0
  1. class Item
  2. {
  3.     public:
  4.         int Price, Value;
  5.         string Name, Description;
  6.         virtual void Effect() =0;
  7. };
  8.  
  9. class Medicine : public Item
  10. {
  11.     public:
  12.         void Effect();
  13.         Medicine();
  14.         ~Medicine(){};
  15. };
  16.  
  17. class DCD : public Item
  18. {
  19.     public:
  20.         void Effect();
  21.         DCD();
  22.         ~DCD(){};
  23. };
  24.  
  25. class BlueLobster : public Item
  26. {
  27.     public:
  28.         void Effect();//Turn player into lobster and summon a lobster army to damage all enemies
  29.         BlueLobster();
  30.         ~BlueLobster(){};
  31. };
  32.  
  33. class Inventory
  34. {
  35.     public:
  36.         void AddItem();
  37.         vector<Item*> InventoryList;
  38.         vector<int> InventoryPointer;
  39.         vector<int> InventoryNum;
  40.         Inventory();
  41.     private:
  42.         Medicine MedicineItem;
  43.         DCD DCDItem;
  44.         BlueLobster BlueLobsterItem;
  45. };
  46.  
  47. Inventory::Inventory()
  48. {
  49.     InventoryList.push_back(&MedicineItem);
  50.     InventoryList.push_back(&DCDItem);
  51.     InventoryList.push_back(&BlueLobsterItem);
  52. }
  53.  
  54. void Inventory::AddItem()
  55. {
  56.  
  57.  
  58.     return;
  59. }
  60.  
  61. Medicine::Medicine()
  62. {
  63.     Name = "Medicine";
  64.     Description = "Heals your Daemons by 50 HP";
  65.     Price = 100;
  66.     Value = 75;
  67. }
  68.  
  69. DCD::DCD()
  70. {
  71.     Name = "DCD";
  72.     Description = "Daemon Capture Device/nUsed to catch Daemons";
  73.     Price = 150;
  74.     Value = 100;
  75. }
  76.  
  77. BlueLobster::BlueLobster()
  78. {
  79.     Name = "Blue Lobster";
  80.     Description = "Summon Netham45's Army >:D";
  81.     Price = 500;
  82.     Value = 50;
  83. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement