summary refs log tree commit diff stats
path: root/hs_state.h
blob: 64ecac0446f07390f56e1af86d267df65fa7d3b4 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
#ifndef HS_STATE_H_C824D037
#define HS_STATE_H_C824D037

#include <memory>

#include "hslist.h"
#include "mazeoflife.h"
#include "sdl.h"
#include "state.h"

class DisplayLocalHighscoreListState : public State {
 public:
  explicit DisplayLocalHighscoreListState(Game& game);

  std::unique_ptr<State> operator()(Game& game);

 private:
  texture_ptr list_;
  texture_ptr pointer_;
};

class DisplayAndReturnLocalHighscoreListState : public State {
 public:
  explicit DisplayAndReturnLocalHighscoreListState(Game& game);

  std::unique_ptr<State> operator()(Game& game);

 private:
  texture_ptr list_;
  texture_ptr pointer_;
  int selection_ = 0;
};

class EnterHighscoreState : public State {
 public:
  EnterHighscoreState(Game& game, int level);

  std::unique_ptr<State> operator()(Game& game);

 private:
  int level_;
  int lp_ = 0;
  std::string hsname_;
  texture_ptr newName_;
  texture_ptr pointer_;
  texture_ptr list_;
  SDL_Rect rntSpace_;
  int newpos_;
};

class NewHighscoreState : public State {
 public:
  NewHighscoreState(Game& game, Highscore h);

  std::unique_ptr<State> operator()(Game& game);

 private:
  Highscore h_;
  texture_ptr pointer_;
  texture_ptr list_;
  int selection_ = 0;
};

#endif /* end of include guard: HS_STATE_H_C824D037 */