summaryrefslogtreecommitdiff
path: root/src/game.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/game.cpp')
-rw-r--r--src/game.cpp15
1 files changed, 13 insertions, 2 deletions
diff --git a/src/game.cpp b/src/game.cpp
index a38ffa13c..1339afbf0 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -50,6 +50,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include "main.h" // For g_settings
#include "itemdef.h"
#include "tile.h" // For TextureSource
+#include "shader.h" // For ShaderSource
#include "logoutputbuffer.h"
#include "subgame.h"
#include "quicktune_shortcutter.h"
@@ -876,6 +877,9 @@ void the_game(
// Create texture source
IWritableTextureSource *tsrc = createTextureSource(device);
+ // Create shader source
+ IWritableShaderSource *shsrc = createShaderSource(device);
+
// These will be filled by data received from the server
// Create item definition manager
IWritableItemDefManager *itemdef = createItemDefManager();
@@ -943,7 +947,7 @@ void the_game(
MapDrawControl draw_control;
Client client(device, playername.c_str(), password, draw_control,
- tsrc, itemdef, nodedef, sound, &eventmgr);
+ tsrc, shsrc, itemdef, nodedef, sound, &eventmgr);
// Client acts as our GameDef
IGameDef *gamedef = &client;
@@ -1423,6 +1427,11 @@ void the_game(
itemdef->processQueue(gamedef);
/*
+ Process ShaderSource's queue
+ */
+ shsrc->processQueue();
+
+ /*
Random calculations
*/
last_screensize = screensize;
@@ -3002,9 +3011,11 @@ void the_game(
if(!sound_is_dummy)
delete sound;
+
+ delete tsrc;
+ delete shsrc;
delete nodedef;
delete itemdef;
- delete tsrc;
}