]> git.localhorst.tv Git - gong.git/blob - src/app/Config.hpp
code, assets, and other stuff stolen from blank
[gong.git] / src / app / Config.hpp
1 #ifndef GONG_APP_CONFIG_HPP_
2 #define GONG_APP_CONFIG_HPP_
3
4 #include <cstdint>
5 #include <iosfwd>
6 #include <string>
7
8
9 namespace gong {
10 namespace app {
11
12 struct Config {
13
14         struct Audio {
15
16                 bool enabled = true;
17
18         } audio;
19
20         struct Input {
21
22                 bool keyboard = true;
23                 bool mouse = true;
24
25                 float pitch_sensitivity = -0.0025f;
26                 float yaw_sensitivity = -0.001f;
27
28         } input;
29
30         struct Network {
31
32                 std::string host = "localhost";
33                 std::uint16_t port = 12364;
34                 std::uint16_t cmd_port = 0;
35
36         } net;
37
38         struct Player {
39
40                 std::string name = "default";
41
42         } player;
43
44         struct Video {
45
46                 bool dblbuf = true;
47                 bool vsync = true;
48                 int msaa = 1;
49
50                 bool hud = true;
51                 bool world = true;
52                 bool debug = false;
53
54         } video;
55
56         void Load(std::istream &);
57         void Save(std::ostream &);
58
59 };
60
61 }
62 }
63
64 #endif