]> git.jsancho.org Git - lugaru.git/blob - Source/Globals.cpp
Removed unused globals
[lugaru.git] / Source / Globals.cpp
1 /*
2 Copyright (C) 2003, 2010 - Wolfire Games
3 Copyright (C) 2010-2016 - Lugaru contributors (see AUTHORS file)
4
5 This file is part of Lugaru.
6
7 Lugaru is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or
10 (at your option) any later version.
11
12 Lugaru is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15 GNU General Public License for more details.
16
17 You should have received a copy of the GNU General Public License
18 along with Lugaru.  If not, see <http://www.gnu.org/licenses/>.
19 */
20
21 #include "SDL.h"
22
23 #include "gamegl.h"
24 #include "Quaternions.h"
25 #include "Lights.h"
26 #include "Skeleton.h"
27 #include "Terrain.h"
28 #include "Sprite.h"
29 #include "Frustum.h"
30 #include "Objects.h"
31 #include "Weapons.h"
32 #include "Person.h"
33 #include "ImageIO.h"
34 #include "openal_wrapper.h"
35 #include "Stereo.h"
36
37 #include "Animation.h"
38
39 bool visibleloading = 0;
40
41 float volume = 0;
42 bool ismotionblur = false;
43 float usermousesensitivity = 0;
44 bool floatjump = false;
45 bool cellophane = false;
46 bool autoslomo = false;
47 bool decals = false;
48 bool invertmouse = false;
49 bool texttoggle = false;
50 float blurness = 0;
51 float targetblurness = 0;
52 float windvar = 0;
53 float precipdelay = 0;
54 float gamespeed = 0;
55 float oldgamespeed = 0;
56 int difficulty = 0;
57 float multiplier = 0;
58 float realmultiplier = 0;
59 float screenwidth = 0, screenheight = 0;
60 bool fullscreen = 0;
61 float viewdistance = 0;
62 XYZ viewer;
63 XYZ viewerfacing;
64 float fadestart = 0;
65 int environment = 0;
66 float texscale = 0;
67 float gravity = 0;
68 Light light;
69 Animation animation[animation_count];
70 Terrain terrain;
71
72 SDL_Window *sdlwindow;
73
74 int kTextureSize = 0;
75 int detail = 0;
76 FRUSTUM frustum;
77 float texdetail = 0;
78 float realtexdetail = 0;
79 float playerdist = 0;
80 Objects objects;
81 int slomo = 0;
82 float slomodelay = 0;
83 GLubyte bloodText[512 * 512 * 3] = {0};
84 GLubyte wolfbloodText[512 * 512 * 3] = {0};
85 int bloodtoggle = 0;
86 float camerashake = 0;
87 float woozy = 0;
88 float blackout = 0;
89 bool foliage = false;
90 bool musictoggle = false;
91 bool trilinear;
92 Weapons weapons;
93 bool damageeffects = false;
94 bool ambientsound = false;
95 bool mousejump = false;
96 bool freeze = false;
97 bool winfreeze = false;
98 float flashamount = 0, flashr = 0, flashg = 0, flashb = 0;
99 int flashdelay = 0;
100 float motionbluramount = 0;
101 bool stillloading = false;
102 bool showpoints = false;
103 bool showdamagebar = false;
104 bool alwaysblur = false;
105 bool immediate = false;
106 bool velocityblur = false;
107 XYZ windvector;
108 int mainmenu = 0;
109 int whichjointstartarray[26] = {0};
110 int whichjointendarray[26] = {0};
111
112 int numhotspots = 0;
113 XYZ hotspot[40];
114 int hotspottype[40] = {0};
115 float hotspotsize[40] = {0};
116 char hotspottext[40][256] = {0};
117 int currenthotspot = 0;
118 int killhotspot = 0;
119
120 float smoketex = 0;
121
122 float slomospeed = 0;
123 float slomofreq = 0;
124
125 int tutoriallevel = 0;
126 int tutorialstage = 0;
127 float tutorialstagetime = 0;
128 float tutorialmaxtime = 0;
129 float tutorialsuccess = 0;
130
131 bool againbonus = false;
132
133 float damagedealt = 0;
134
135 int maptype = 0;
136
137 int editoractive = 0;
138 int editorpathtype = 0;
139
140 bool reversaltrain = false;
141 bool cananger = false;
142 bool canattack = false;
143
144 bool skyboxtexture = false;
145 float skyboxr = 0;
146 float skyboxg = 0;
147 float skyboxb = 0;
148 float skyboxlightr = 0;
149 float skyboxlightg = 0;
150 float skyboxlightb = 0;
151
152 int hostile = 0;
153 float hostiletime = 0;
154
155 XYZ envsound[30];
156 float envsoundvol[30] = {0};
157 float envsoundlife[30] = {0};
158 int numenvsounds;
159
160 bool debugmode = false;
161
162 bool campaign = false;
163
164 bool gamestarted = false;
165
166 StereoMode stereomode =  stereoNone;
167 StereoMode newstereomode = stereoNone;
168 float stereoseparation = 0.05;
169 bool  stereoreverse = false;