KarteAuswahl.h 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107
  1. #ifndef KarteAuswahl_H
  2. #define KarteAuswahl_H
  3. #include <Klient.h>
  4. #include <Bild.h>
  5. #include <Knopf.h>
  6. #include <Thread.h>
  7. #include <KSGScript.h>
  8. #include <Rahmen.h>
  9. using namespace Framework;
  10. using namespace KSGScript;
  11. class KarteDaten : public virtual ReferenceCounter
  12. {
  13. private:
  14. class Loader : public Thread
  15. {
  16. private:
  17. KarteDaten *kd;
  18. int aktion;
  19. public:
  20. Loader( KarteDaten *kd, int aktion );
  21. void thread() override;
  22. int getAction() const;
  23. };
  24. Loader *loader;
  25. int karteId;
  26. Bild *hintergrund;
  27. HINSTANCE ksgs;
  28. KSGScriptObj *beschreibung;
  29. LRahmen *rahmen;
  30. double tickVal;
  31. int animation;
  32. bool ausgewählt;
  33. Punkt pos;
  34. Punkt gr;
  35. int geladen;
  36. AlphaFeld *auswahl;
  37. unsigned char auswAlpha;
  38. bool erlaubt;
  39. bool rend;
  40. unsigned char tAlpha;
  41. unsigned char alpha;
  42. friend Loader;
  43. public:
  44. // Konstruktor
  45. KarteDaten( int id );
  46. // Destruktor
  47. ~KarteDaten();
  48. // nicht constant
  49. void updateErlaubt();
  50. void ksgsAktion( RCArray< KSGSVariable > *parameter, KSGSVariable **retVal );
  51. void setSichtbar( bool sichtbar );
  52. void setSichtbar();
  53. void setAuswahl( bool auswahl );
  54. void setPosition( int lPos );
  55. bool tick( double tickVal );
  56. void doPublicMausEreignis( MausEreignis &me );
  57. void render( Bild &zRObj );
  58. // constant
  59. int getKarteId() const;
  60. bool istausgewählt() const;
  61. };
  62. class KarteAuswahlFenster : public Thread
  63. {
  64. private:
  65. int anzahl;
  66. int auswahl;
  67. RCArray< KarteDaten > *members;
  68. LRahmen *rahmen;
  69. TextRenderer *tr;
  70. double tickVal;
  71. int animation;
  72. Punkt pos;
  73. Punkt gr;
  74. int spielId;
  75. int seite;
  76. bool rend;
  77. unsigned char alpha;
  78. public:
  79. // Konstruktor
  80. KarteAuswahlFenster();
  81. // Destruktor
  82. ~KarteAuswahlFenster();
  83. // nicht constant
  84. void setSpielId( int spielId );
  85. void setSichtbar( bool sichtbar );
  86. void blättern( bool oben );
  87. void updateListe();
  88. virtual void thread();
  89. bool tick( double tickVal );
  90. void doPublicMausEreignis( MausEreignis &me );
  91. void render( Bild &zrObj );
  92. // constant
  93. int getAnzahl() const;
  94. int getSeiteAnzahl() const;
  95. int getSeite() const;
  96. int getAnzahlAufSeite() const;
  97. bool hatAuswahl() const;
  98. KarteDaten *getAuswahl() const;
  99. };
  100. #endif