Geschoss.h 772 B

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. #pragma once
  2. #include "GameObject.h"
  3. #include "Spieler.h"
  4. enum GeschossTyp
  5. {
  6. GESCHOSS_PFEIL,
  7. GESCHOSS_KUGEL,
  8. GESCHOSS_DRACHENAUGE,
  9. GESCHOSS_FEUERBALL
  10. };
  11. class Geschoss : public GameObject
  12. {
  13. private:
  14. float speed;
  15. Richtung richtung;
  16. Spieler *besitzer;
  17. GeschossTyp typ;
  18. int tunnelBenutzt;
  19. bool alive;
  20. int umgelenkt;
  21. int geschosseGetroffen;
  22. public:
  23. Geschoss( float speed, GeschossTyp typ, Richtung r, int x, int y, Spieler *besitzer );
  24. ~Geschoss();
  25. void tick( double zeit );
  26. };
  27. class FeuerballTreffer : public GameObject
  28. {
  29. private:
  30. Spieler *besitzer;
  31. float timeLeft;
  32. public:
  33. FeuerballTreffer( int x, int y, Spieler *besitzer, int maxZeit );
  34. ~FeuerballTreffer();
  35. void tick( double zeit );
  36. };