aboutsummaryrefslogtreecommitdiff
path: root/games/minimal/mods/default/textures/default_steel_ingot.png
blob: ad133bc124e1c46e7e4aa398ad4bf5cdc475c869 (plain)
ofshex dumpascii
0000 89 50 4e 47 0d 0a 1a 0a 00 00 00 0d 49 48 44 52 00 00 00 10 00 00 00 11 08 03 00 00 00 e3 71 dc .PNG........IHDR..............q.
0020 f6 00 00 00 0c 50 4c 54 45 00 00 00 66 66 66 80 80 80 c0 c0 c0 67 4c 8e 94 00 00 00 01 74 52 4e .....PLTE...fff......gL......tRN
0040 53 00 40 e6 d8 66 00 00 00 32 49 44 41 54 78 da ad c8 41 0e 00 20 08 c4 40 17 fe ff 67 e3 06 6a S.@..f...2IDATx...A.....@...g..j
0060 b8 1a 7b 9b ae af 65 4e ba 4b 2a 92 a6 25 8f 88 26 e3 2c 61 8f 80 bd 9a 2c f8 d0 06 6f a6 00 c4 ..{...eN.K*..%..&.,a....,...o...
0080 17 42 c8 f4 00 00 00 00 49 45 4e 44 ae 42 60 82 .B......IEND.B`.
>73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138
/*
Minetest
Copyright (C) 2010-2013 celeron55, Perttu Ahola <celeron55@gmail.com>

This program is free software; you can redistribute it and/or modify
it under the terms of the GNU Lesser General Public License as published by
the Free Software Foundation; either version 2.1 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public License along
with this program; if not, write to the Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/

#pragma once

#include "irrlichttypes_extrabloated.h"
#include "map.h"
#include "camera.h"
#include <set>
#include <map>

struct MapDrawControl
{
	// Overrides limits by drawing everything
	bool range_all = false;
	// Wanted drawing range
	float wanted_range = 0.0f;
	// Maximum number of blocks to draw
	u32 wanted_max_blocks = 0;
	// show a wire frame for debugging
	bool show_wireframe = false;
};

class Client;
class ITextureSource;

/*
	ClientMap

	This is the only map class that is able to render itself on screen.
*/

class ClientMap : public Map, public scene::ISceneNode
{
public:
	ClientMap(
			Client *client,
			MapDrawControl &control,
			s32 id
	);

	virtual ~ClientMap() = default;

	s32 mapType() const
	{
		return MAPTYPE_CLIENT;
	}

	void drop()
	{
		ISceneNode::drop();
	}

	void updateCamera(const v3f &pos, const v3f &dir, f32 fov, const v3s16 &offset)
	{
		m_camera_position = pos;
		m_camera_direction = dir;
		m_camera_fov = fov;
		m_camera_offset = offset;
	}

	/*
		Forcefully get a sector from somewhere
	*/
	MapSector * emergeSector(v2s16 p);

	//void deSerializeSector(v2s16 p2d, std::istream &is);