Guest User

Untitled

a guest
Mar 22nd, 2018
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.02 KB | None | 0 0
  1. #pragma once
  2. /* Klasa opisująca pojedyncze pole gry.
  3. * sluzy głownie jako magazyn danych o polu gry.
  4. */
  5.  
  6. #include<string>
  7.  
  8. class World
  9. {
  10. int beInside; // ilosc odwiedzin w pokoju
  11. bool exitCell[4]{ true }; //wyjscia z pokoju: | 0-Połnoc | 1-wschod | 2-poludnie | 3-zachod || (w-d-s-a) * true = otwarte *
  12. int eventType; //rodzaj wydarzenia lub jego brak.
  13. int hpCell; //wartosc o jaką zmienia sie zdrowie gracza na tym polu
  14. int timeCell; //wartosc o jaka zmienia sie czas pozostaly do konca rozgrywki
  15. std::string infoCell; //opis tekstowy obszaru
  16.  
  17. public:
  18. World(); //konstruktor
  19. ~World(); //destruktor
  20.  
  21.  
  22. //gettery - czyli metody pobierajace prywatne dane z obiektu
  23.  
  24. std::string get_infoCell();
  25. int get_hpCell();
  26. int get_timeCell();
  27. int get_beInside();
  28. int get_eventType();
  29. bool get_exitCell(int);
  30.  
  31. //settery - czyli metody zmieniajace prywatne dane w obiekcie
  32.  
  33. void set_beInside(int);
  34. void set_exitCell(int, bool);
  35. void set_eventType(int);
  36. void set_infoCell(std::string, int);
  37. };
Add Comment
Please, Sign In to add comment