1 src/config.cpp | 12 +++++++-----
2 src/config.h | 10 +++++-----
4 3 files changed, 13 insertions(+), 11 deletions(-)
6 diff --git a/src/config.cpp b/src/config.cpp
7 index 815414b..cb66599 100644
10 @@ -153,17 +153,19 @@ void config::save()
14 -const unsigned int config::get_feldbreite() const
15 +/* In this case a copy of an unsigned int is returned and not a reference or a pointer
16 + * so no side effect (so "const unsigned int" doesn't make sense) */
17 +unsigned int config::get_feldbreite() const
22 -const unsigned int config::get_feldhohe() const
23 +unsigned int config::get_feldhohe() const
28 -const unsigned int config::get_feldgrose() const
29 +unsigned int config::get_feldgrose() const
31 return feldbreite * feldhohe;
33 @@ -173,7 +175,7 @@ const std::string & config::get_datapath() const
37 -const unsigned int config::get_quadsize() const
38 +unsigned int config::get_quadsize() const
42 @@ -188,7 +190,7 @@ const std::string & config::get_version() const
46 -const unsigned int config::get_maxplayer() const
47 +unsigned int config::get_maxplayer() const
51 diff --git a/src/config.h b/src/config.h
52 index 71bb76e..4a93c83 100644
55 @@ -37,13 +37,13 @@ class config
59 - const unsigned int get_feldbreite() const; //const für den Rückgabetyp entfernen (gcc 4 ungrad warnt)
60 - const unsigned int get_feldhohe() const;
61 - const unsigned int get_feldgrose() const;
62 + unsigned int get_feldbreite() const; //const für den Rückgabetyp entfernen (gcc 4 ungrad warnt)
63 + unsigned int get_feldhohe() const;
64 + unsigned int get_feldgrose() const;
65 const std::string & get_datapath() const;
66 - const unsigned int get_quadsize() const;
67 + unsigned int get_quadsize() const;
68 const std::string & get_version() const;
69 - const unsigned int get_maxplayer() const;
70 + unsigned int get_maxplayer() const;
71 config_player *get_player(int); // Variablenname
72 std::string get_filepath(std::string);
73 void save(); // hier const
74 diff --git a/src/snake.cpp b/src/snake.cpp
75 index d7d3f91..d930a30 100644
78 @@ -174,7 +174,7 @@ int snake::step()
79 SDL_Surface *font_src = 0;
\r
81 sprintf(titel, "Punkte: %d", punkte);
\r
82 - SDL_Color color = {255,255,255};
\r
83 + SDL_Color color = {255,255,255, 255};
\r
84 font_src = TTF_RenderText_Solid(pFont, titel, color); // hat irgendwie ein bug
\r
85 // font_src = TTF_RenderText_Blended(pFont, titel, color); // drum den workaround
\r