]> git.lizzy.rs Git - minetest.git/blobdiff - src/content_mapnode.cpp
Works for debian and a few other distributions but fails for even more so back to...
[minetest.git] / src / content_mapnode.cpp
index 4701736cfd79849f8ada6eca4b039547967241b8..44d0b8e386685f72ec3000a4fcce5120608b32f1 100644 (file)
@@ -1,28 +1,27 @@
 /*
-Minetest-c55
-Copyright (C) 2010-2011 celeron55, Perttu Ahola <celeron55@gmail.com>
+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 General Public License as published by
-the Free Software Foundation; either version 2 of the License, or
+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 General Public License for more details.
+GNU Lesser General Public License for more details.
 
-You should have received a copy of the GNU General Public License along
+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.
 */
 
 #include "content_mapnode.h"
 
-#include "irrlichttypes.h"
+#include "irrlichttypes_bloated.h"
 #include "mapnode.h"
 #include "nodedef.h"
-#include "utility.h"
 #include "nameidmapping.h"
 #include <map>
 
@@ -31,7 +30,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
        Ranges:
        0x000...0x07f (0...127): param2 is fully usable
        126 and 127 are reserved (CONTENT_AIR and CONTENT_IGNORE).
-       0x800...0xfff (2048...4095): higher 4 bytes of param2 are not usable
+       0x800...0xfff (2048...4095): higher 4 bits of param2 are not usable
 */
 #define CONTENT_STONE 0
 #define CONTENT_WATER 2
@@ -103,23 +102,6 @@ content_t trans_table_19[21][2] = {
        {CONTENT_BOOKSHELF, 29},
 };
 
-MapNode mapnode_translate_from_internal(MapNode n_from, u8 version)
-{
-       MapNode result = n_from;
-       if(version <= 19)
-       {
-               content_t c_from = n_from.getContent();
-               for(u32 i=0; i<sizeof(trans_table_19)/sizeof(trans_table_19[0]); i++)
-               {
-                       if(trans_table_19[i][0] == c_from)
-                       {
-                               result.setContent(trans_table_19[i][1]);
-                               break;
-                       }
-               }
-       }
-       return result;
-}
 MapNode mapnode_translate_to_internal(MapNode n_from, u8 version)
 {
        MapNode result = n_from;