vrheights
diff src/game_var.h @ 12:cb97ea43709b
fixed line endings
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Fri, 03 Oct 2014 23:11:43 +0300 |
parents | 537db3079134 |
children |
line diff
1.1 --- a/src/game_var.h Fri Oct 03 23:11:23 2014 +0300 1.2 +++ b/src/game_var.h Fri Oct 03 23:11:43 2014 +0300 1.3 @@ -1,32 +1,32 @@ 1.4 -#ifndef GAME_VAR_H_ 1.5 -#define GAME_VAR_H_ 1.6 - 1.7 -#include <string> 1.8 -#include <list> 1.9 - 1.10 -struct GameVariable { 1.11 - enum { NUMBER, BOOL, STR } type; 1.12 - std::string name, val; 1.13 - float num_val; 1.14 - bool bool_val; 1.15 - 1.16 - GameVariable(); 1.17 - std::string to_str() const; 1.18 -}; 1.19 - 1.20 -void set_gvar(const GameVariable &var); 1.21 -void set_gvar_str(const char *name, const char *val); 1.22 -void set_gvar_num(const char *name, float val); 1.23 -void set_gvar_bool(const char *name, bool val); 1.24 -int set_gvar_parse(const char *name, const char *val); 1.25 - 1.26 -GameVariable &get_gvar(const char *name); 1.27 -const char *get_gvar_str(const char *name); 1.28 -float get_gvar_num(const char *name); 1.29 -bool get_gvar_bool(const char *name); 1.30 - 1.31 -bool have_gvar(const char *name); 1.32 - 1.33 -std::list<std::string> get_gvar_list(); 1.34 - 1.35 -#endif // GAME_VAR_H_ 1.36 +#ifndef GAME_VAR_H_ 1.37 +#define GAME_VAR_H_ 1.38 + 1.39 +#include <string> 1.40 +#include <list> 1.41 + 1.42 +struct GameVariable { 1.43 + enum { NUMBER, BOOL, STR } type; 1.44 + std::string name, val; 1.45 + float num_val; 1.46 + bool bool_val; 1.47 + 1.48 + GameVariable(); 1.49 + std::string to_str() const; 1.50 +}; 1.51 + 1.52 +void set_gvar(const GameVariable &var); 1.53 +void set_gvar_str(const char *name, const char *val); 1.54 +void set_gvar_num(const char *name, float val); 1.55 +void set_gvar_bool(const char *name, bool val); 1.56 +int set_gvar_parse(const char *name, const char *val); 1.57 + 1.58 +GameVariable &get_gvar(const char *name); 1.59 +const char *get_gvar_str(const char *name); 1.60 +float get_gvar_num(const char *name); 1.61 +bool get_gvar_bool(const char *name); 1.62 + 1.63 +bool have_gvar(const char *name); 1.64 + 1.65 +std::list<std::string> get_gvar_list(); 1.66 + 1.67 +#endif // GAME_VAR_H_