summaryrefslogtreecommitdiff
path: root/src/drawscene.cpp
diff options
context:
space:
mode:
authorRealBadAngel <maciej.kasatkin@o2.pl>2015-06-22 04:34:56 +0200
committerest31 <MTest31@outlook.com>2015-06-27 03:42:01 +0200
commitffd16e3feca90c356c55898de2b9f3f5c6bc5c98 (patch)
tree8fb350ba1d2afaa39b9d333290e16a68168a4ddd /src/drawscene.cpp
parent3376d2e114767eef06b87645edefcd2d42696919 (diff)
downloadminetest-ffd16e3feca90c356c55898de2b9f3f5c6bc5c98.tar.gz
minetest-ffd16e3feca90c356c55898de2b9f3f5c6bc5c98.tar.bz2
minetest-ffd16e3feca90c356c55898de2b9f3f5c6bc5c98.zip
Add minimap feature
Diffstat (limited to 'src/drawscene.cpp')
-rw-r--r--src/drawscene.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/src/drawscene.cpp b/src/drawscene.cpp
index f7cfdd262..509f341d5 100644
--- a/src/drawscene.cpp
+++ b/src/drawscene.cpp
@@ -416,10 +416,11 @@ void draw_plain(Camera& camera, bool show_hud, Hud& hud,
camera.drawWieldedTool();
}
-void draw_scene(video::IVideoDriver* driver, scene::ISceneManager* smgr,
- Camera& camera, Client& client, LocalPlayer* player, Hud& hud,
- gui::IGUIEnvironment* guienv, std::vector<aabb3f> hilightboxes,
- const v2u32& screensize, video::SColor skycolor, bool show_hud)
+void draw_scene(video::IVideoDriver *driver, scene::ISceneManager *smgr,
+ Camera &camera, Client& client, LocalPlayer *player, Hud &hud,
+ Mapper &mapper, gui::IGUIEnvironment *guienv,
+ std::vector<aabb3f> hilightboxes, const v2u32 &screensize,
+ video::SColor skycolor, bool show_hud, bool show_minimap)
{
TimeTaker timer("smgr");
@@ -484,6 +485,8 @@ void draw_scene(video::IVideoDriver* driver, scene::ISceneManager* smgr,
hud.drawCrosshair();
hud.drawHotbar(client.getPlayerItem());
hud.drawLuaElements(camera.getOffset());
+ if (show_minimap)
+ mapper.drawMinimap();
}
guienv->drawAll();