Begin EOS for MT 0.4.

We actually haven't been testing in 0.4 at all for quite a while
now.  Since this is a standalone base game without complex
interdependency relationships, there isn't really any need to
maintain compat with old versions of the engine.  Players can
upgrade to play; keeping a separate copy just to play on old 0.4
servers is even still an option.

There is some internal cruft that has been building up to support
0.4, and this allows us to purge most of it.  The larger benefit
may come when we're able to remove line_of_sight in favor of the
more efficient raycast (still yet to be done).
This commit is contained in:
Aaron Suen 2019-04-06 11:21:34 -04:00
parent 63db0010fc
commit 68d996e1f3
6 changed files with 9 additions and 15 deletions

View File

@ -6,5 +6,6 @@ local dofile
return {
user = "Warr1024",
pkg = "nodecore",
min = "5.0.0",
version = dofile("./mods/nc_api/version.lua")
}

View File

@ -19,9 +19,6 @@ ISSUES: Bugs, Cleanup and Refinements
is actually necessary.
- MT 0.4 Support Sunsetting.
- Set min in .cdbrelease.lua
- Remove references to nodecore.mt_old
- remove nc_player_model_old.b3d
- Switch line_of_sight to raycast
- Redesign how falling_nodes pile up.

View File

@ -1,14 +1,10 @@
-- LUALOCALS < ---------------------------------------------------------
local ItemStack, ipairs, math, minetest, nodecore, pairs, string, type,
unpack
= ItemStack, ipairs, math, minetest, nodecore, pairs, string, type,
unpack
local ItemStack, ipairs, math, minetest, nodecore, pairs, type, unpack
= ItemStack, ipairs, math, minetest, nodecore, pairs, type, unpack
local math_random
= math.random
-- LUALOCALS > ---------------------------------------------------------
nodecore.mt_old = minetest.get_version().string:sub(1, 2) == "0."
for k, v in pairs(minetest) do
if type(v) == "function" then
-- Late-bind in case minetest methods overridden.

View File

@ -1,6 +1,6 @@
-- LUALOCALS < ---------------------------------------------------------
local math, minetest, nodecore, os, pairs, table
= math, minetest, nodecore, os, pairs, table
local math, minetest, os, pairs, table
= math, minetest, os, pairs, table
local math_floor, os_date, table_concat
= math.floor, os.date, table.concat
-- LUALOCALS > ---------------------------------------------------------
@ -139,7 +139,7 @@ minetest.register_on_joinplayer(function(player)
player:set_properties({
visual = "mesh",
visual_size = {x = 0.9, y = 0.9, z = 0.9},
mesh = modname .. (nodecore.mt_old and "_old" or "") .. ".b3d"
mesh = modname .. ".b3d"
})
setskin(player, "dummy")
setanim(player, "dummy")

View File

@ -1,6 +1,6 @@
-- LUALOCALS < ---------------------------------------------------------
local math, minetest, nodecore, table
= math, minetest, nodecore, table
local math, minetest, table
= math, minetest, table
local math_random, table_remove
= math.random, table.remove
-- LUALOCALS > ---------------------------------------------------------
@ -126,7 +126,7 @@ minetest.register_on_joinplayer(function(player)
--[[
local function cslot(n, x, z)
return addslot(n, nil, x * 1.6,
(nodecore.mt_old and -4 or 5.5) + x / 2,
5.5 + x / 2,
z * 2.1)
end