summaryrefslogtreecommitdiff
path: root/src/clientmap.h
diff options
context:
space:
mode:
authorShadowNinja <shadowninja@minetest.net>2017-06-03 14:55:10 -0400
committerShadowNinja <shadowninja@minetest.net>2017-06-03 14:55:10 -0400
commitcaecdb681c428c1aab9c0f7eec2570c0460f995c (patch)
treee5115982ea59bbf2343ba9b35bc4a0cfbb56f407 /src/clientmap.h
parent81d56b94919dceb7b2e51d70b21a7ca22f852bd5 (diff)
parent80dc961d24e1964e25d57039ddb2ba639f9f4d22 (diff)
downloadminetest-caecdb681c428c1aab9c0f7eec2570c0460f995c.tar.gz
minetest-caecdb681c428c1aab9c0f7eec2570c0460f995c.tar.bz2
minetest-caecdb681c428c1aab9c0f7eec2570c0460f995c.zip
Merge 0.4.16 into stable-0.4
Diffstat (limited to 'src/clientmap.h')
-rw-r--r--src/clientmap.h21
1 files changed, 7 insertions, 14 deletions
diff --git a/src/clientmap.h b/src/clientmap.h
index cb686ff33..84228f4ca 100644
--- a/src/clientmap.h
+++ b/src/clientmap.h
@@ -59,7 +59,7 @@ class ITextureSource;
/*
ClientMap
-
+
This is the only map class that is able to render itself on screen.
*/
@@ -68,7 +68,6 @@ class ClientMap : public Map, public scene::ISceneNode
public:
ClientMap(
Client *client,
- IGameDef *gamedef,
MapDrawControl &control,
scene::ISceneNode* parent,
scene::ISceneManager* mgr,
@@ -114,13 +113,13 @@ public:
driver->setTransform(video::ETS_WORLD, AbsoluteTransformation);
renderMap(driver, SceneManager->getSceneNodeRenderPass());
}
-
+
virtual const aabb3f &getBoundingBox() const
{
return m_box;
}
-
- void getBlocksInViewRange(v3s16 cam_pos_nodes,
+
+ void getBlocksInViewRange(v3s16 cam_pos_nodes,
v3s16 *p_blocks_min, v3s16 *p_blocks_max);
void updateDrawList(video::IVideoDriver* driver);
void renderMap(video::IVideoDriver* driver, s32 pass);
@@ -132,20 +131,14 @@ public:
// For debug printing
virtual void PrintInfo(std::ostream &out);
-
- // Check if sector was drawn on last render()
- bool sectorWasDrawn(v2s16 p)
- {
- return (m_last_drawn_sectors.find(p) != m_last_drawn_sectors.end());
- }
const MapDrawControl & getControl() const { return m_control; }
f32 getCameraFov() const { return m_camera_fov; }
private:
Client *m_client;
-
+
aabb3f m_box;
-
+
MapDrawControl &m_control;
v3f m_camera_position;
@@ -154,7 +147,7 @@ private:
v3s16 m_camera_offset;
std::map<v3s16, MapBlock*> m_drawlist;
-
+
std::set<v2s16> m_last_drawn_sectors;
bool m_cache_trilinear_filter;