diff options
author | kwolekr <kwolekr@minetest.net> | 2015-01-05 02:42:27 -0500 |
---|---|---|
committer | kwolekr <kwolekr@minetest.net> | 2015-01-05 02:42:27 -0500 |
commit | 2d849b0a19af03913e564e2b6dbc36eecdd5ae0c (patch) | |
tree | 4f1cfff6586c305c419562173b73c9ab9410c401 /src/script | |
parent | 7289d61e99625b46eb2c4d6b90a2a5de42f207e6 (diff) | |
download | minetest-2d849b0a19af03913e564e2b6dbc36eecdd5ae0c.tar.gz minetest-2d849b0a19af03913e564e2b6dbc36eecdd5ae0c.tar.bz2 minetest-2d849b0a19af03913e564e2b6dbc36eecdd5ae0c.zip |
Shorten ManualMapVoxelManipulator to MMVManip
Diffstat (limited to 'src/script')
-rw-r--r-- | src/script/lua_api/l_mapgen.cpp | 2 | ||||
-rw-r--r-- | src/script/lua_api/l_vmanip.cpp | 30 | ||||
-rw-r--r-- | src/script/lua_api/l_vmanip.h | 6 |
3 files changed, 19 insertions, 19 deletions
diff --git a/src/script/lua_api/l_mapgen.cpp b/src/script/lua_api/l_mapgen.cpp index bff8ccfe6..d470cef88 100644 --- a/src/script/lua_api/l_mapgen.cpp +++ b/src/script/lua_api/l_mapgen.cpp @@ -240,7 +240,7 @@ int ModApiMapgen::l_get_mapgen_object(lua_State *L) switch (mgobj) { case MGOBJ_VMANIP: { - ManualMapVoxelManipulator *vm = mg->vm; + MMVManip *vm = mg->vm; // VoxelManip object LuaVoxelManip *o = new LuaVoxelManip(vm, true); diff --git a/src/script/lua_api/l_vmanip.cpp b/src/script/lua_api/l_vmanip.cpp index 54689c84c..de7612115 100644 --- a/src/script/lua_api/l_vmanip.cpp +++ b/src/script/lua_api/l_vmanip.cpp @@ -44,7 +44,7 @@ int LuaVoxelManip::gc_object(lua_State *L) int LuaVoxelManip::l_read_from_map(lua_State *L) { LuaVoxelManip *o = checkobject(L, 1); - ManualMapVoxelManipulator *vm = o->vm; + MMVManip *vm = o->vm; v3s16 bp1 = getNodeBlockPos(read_v3s16(L, 2)); v3s16 bp2 = getNodeBlockPos(read_v3s16(L, 3)); @@ -63,7 +63,7 @@ int LuaVoxelManip::l_get_data(lua_State *L) NO_MAP_LOCK_REQUIRED; LuaVoxelManip *o = checkobject(L, 1); - ManualMapVoxelManipulator *vm = o->vm; + MMVManip *vm = o->vm; int volume = vm->m_area.getVolume(); @@ -82,7 +82,7 @@ int LuaVoxelManip::l_set_data(lua_State *L) NO_MAP_LOCK_REQUIRED; LuaVoxelManip *o = checkobject(L, 1); - ManualMapVoxelManipulator *vm = o->vm; + MMVManip *vm = o->vm; if (!lua_istable(L, 2)) return 0; @@ -103,7 +103,7 @@ int LuaVoxelManip::l_set_data(lua_State *L) int LuaVoxelManip::l_write_to_map(lua_State *L) { LuaVoxelManip *o = checkobject(L, 1); - ManualMapVoxelManipulator *vm = o->vm; + MMVManip *vm = o->vm; vm->blitBackAll(&o->modified_blocks); @@ -144,7 +144,7 @@ int LuaVoxelManip::l_update_liquids(lua_State *L) Map *map = &(env->getMap()); INodeDefManager *ndef = getServer(L)->getNodeDefManager(); - ManualMapVoxelManipulator *vm = o->vm; + MMVManip *vm = o->vm; Mapgen mg; mg.vm = vm; @@ -166,7 +166,7 @@ int LuaVoxelManip::l_calc_lighting(lua_State *L) INodeDefManager *ndef = getServer(L)->getNodeDefManager(); EmergeManager *emerge = getServer(L)->getEmergeManager(); - ManualMapVoxelManipulator *vm = o->vm; + MMVManip *vm = o->vm; v3s16 yblock = v3s16(0, 1, 0) * MAP_BLOCKSIZE; v3s16 fpmin = vm->m_area.MinEdge; @@ -203,7 +203,7 @@ int LuaVoxelManip::l_set_lighting(lua_State *L) light = (getintfield_default(L, 2, "day", 0) & 0x0F); light |= (getintfield_default(L, 2, "night", 0) & 0x0F) << 4; - ManualMapVoxelManipulator *vm = o->vm; + MMVManip *vm = o->vm; v3s16 yblock = v3s16(0, 1, 0) * MAP_BLOCKSIZE; v3s16 pmin = lua_istable(L, 3) ? read_v3s16(L, 3) : vm->m_area.MinEdge + yblock; @@ -226,7 +226,7 @@ int LuaVoxelManip::l_get_light_data(lua_State *L) NO_MAP_LOCK_REQUIRED; LuaVoxelManip *o = checkobject(L, 1); - ManualMapVoxelManipulator *vm = o->vm; + MMVManip *vm = o->vm; int volume = vm->m_area.getVolume(); @@ -245,7 +245,7 @@ int LuaVoxelManip::l_set_light_data(lua_State *L) NO_MAP_LOCK_REQUIRED; LuaVoxelManip *o = checkobject(L, 1); - ManualMapVoxelManipulator *vm = o->vm; + MMVManip *vm = o->vm; if (!lua_istable(L, 2)) return 0; @@ -268,7 +268,7 @@ int LuaVoxelManip::l_get_param2_data(lua_State *L) NO_MAP_LOCK_REQUIRED; LuaVoxelManip *o = checkobject(L, 1); - ManualMapVoxelManipulator *vm = o->vm; + MMVManip *vm = o->vm; int volume = vm->m_area.getVolume(); @@ -287,7 +287,7 @@ int LuaVoxelManip::l_set_param2_data(lua_State *L) NO_MAP_LOCK_REQUIRED; LuaVoxelManip *o = checkobject(L, 1); - ManualMapVoxelManipulator *vm = o->vm; + MMVManip *vm = o->vm; if (!lua_istable(L, 2)) return 0; @@ -344,7 +344,7 @@ int LuaVoxelManip::l_was_modified(lua_State *L) NO_MAP_LOCK_REQUIRED; LuaVoxelManip *o = checkobject(L, 1); - ManualMapVoxelManipulator *vm = o->vm; + MMVManip *vm = o->vm; lua_pushboolean(L, vm->m_is_dirty); @@ -361,7 +361,7 @@ int LuaVoxelManip::l_get_emerged_area(lua_State *L) return 2; } -LuaVoxelManip::LuaVoxelManip(ManualMapVoxelManipulator *mmvm, bool is_mg_vm) +LuaVoxelManip::LuaVoxelManip(MMVManip *mmvm, bool is_mg_vm) { this->vm = mmvm; this->is_mapgen_vm = is_mg_vm; @@ -369,13 +369,13 @@ LuaVoxelManip::LuaVoxelManip(ManualMapVoxelManipulator *mmvm, bool is_mg_vm) LuaVoxelManip::LuaVoxelManip(Map *map) { - this->vm = new ManualMapVoxelManipulator(map); + this->vm = new MMVManip(map); this->is_mapgen_vm = false; } LuaVoxelManip::LuaVoxelManip(Map *map, v3s16 p1, v3s16 p2) { - this->vm = new ManualMapVoxelManipulator(map); + this->vm = new MMVManip(map); this->is_mapgen_vm = false; v3s16 bp1 = getNodeBlockPos(p1); diff --git a/src/script/lua_api/l_vmanip.h b/src/script/lua_api/l_vmanip.h index 82c807240..1adb78c4e 100644 --- a/src/script/lua_api/l_vmanip.h +++ b/src/script/lua_api/l_vmanip.h @@ -26,7 +26,7 @@ with this program; if not, write to the Free Software Foundation, Inc., class Map; class MapBlock; -class ManualMapVoxelManipulator; +class MMVManip; /* VoxelManip @@ -64,9 +64,9 @@ private: static int l_get_emerged_area(lua_State *L); public: - ManualMapVoxelManipulator *vm; + MMVManip *vm; - LuaVoxelManip(ManualMapVoxelManipulator *mmvm, bool is_mapgen_vm); + LuaVoxelManip(MMVManip *mmvm, bool is_mapgen_vm); LuaVoxelManip(Map *map, v3s16 p1, v3s16 p2); LuaVoxelManip(Map *map); ~LuaVoxelManip(); |