From 9e8c41c6c31849c748638e3e4358414ccfde697b Mon Sep 17 00:00:00 2001 From: MoNTE48 Date: Tue, 4 Jun 2019 14:08:08 +0200 Subject: [PATCH] Change drop and liftimer settings (boats, carts, mobs), change defultsettings --- files/boats/init.lua | 7 +++++-- files/boost_cart/cart_entity.lua | 7 +++++-- files/mobs_redo/api.lua | 16 ++++++++++------ files/vessels/textures/vessels_shelf.png | Bin 1408 -> 1384 bytes 4 files changed, 20 insertions(+), 10 deletions(-) diff --git a/files/boats/init.lua b/files/boats/init.lua index 88150ce..d240cd0 100644 --- a/files/boats/init.lua +++ b/files/boats/init.lua @@ -152,11 +152,14 @@ end function boat.on_step(self, dtime) - + local drop_timer = 300 -- 5 min + if not minetest.is_singleplayer() then + drop_timer = 60 -- 1 min + end self.count = (self.count or 0) + dtime -- Drop boat if the player is not on board - if self.count > 120 then + if self.count > drop_timer then minetest.add_item(self.object:get_pos(), "boats:boat") self.object:remove() return diff --git a/files/boost_cart/cart_entity.lua b/files/boost_cart/cart_entity.lua index efe00e0..fec0f6f 100644 --- a/files/boost_cart/cart_entity.lua +++ b/files/boost_cart/cart_entity.lua @@ -189,15 +189,18 @@ local function rail_sound(self, dtime) end end - local v3_len = vector.length function cart_entity:on_step(dtime) -- Drop cart if there is no player or items inside. if not self.driver and #self.attached_items == 0 then + local drop_timer = 300 -- 5 min + if not minetest.is_singleplayer() then + drop_timer = 60 -- 1 min + end self.count = (self.count or 0) + dtime - if self.count > 120 then + if self.count > drop_timer then minetest.add_item(self.object:get_pos(), "carts:cart") if self.sound_handle then minetest.sound_stop(self.sound_handle) diff --git a/files/mobs_redo/api.lua b/files/mobs_redo/api.lua index 4aace17..368b3f0 100644 --- a/files/mobs_redo/api.lua +++ b/files/mobs_redo/api.lua @@ -75,6 +75,10 @@ local node_ice = "default:ice" local node_snowblock = "default:snowblock" local node_snow = "default:snow" mobs.fallback_node = minetest.registered_aliases["mapgen_dirt"] or "default:dirt" +local lifetime = 1200 -- 20 min +if not minetest.is_singleplayer() then + lifetime = 300 -- 5 min +end local mob_class = { stepheight = 1.1, -- was 0.6 @@ -82,7 +86,7 @@ local mob_class = { owner = "", order = "", jump_height = 4, - lifetimer = 600, -- was 10 minutes + lifetimer = lifetime, physical = true, collisionbox = {-0.25, -0.25, -0.25, 0.25, 0.25, 0.25}, visual_size = {x = 1, y = 1}, @@ -2760,7 +2764,7 @@ if damage >= 1 then self.object:settexturemod("") end) end) - + end -- END if damage -- knock back effect (only on full punch) @@ -2930,7 +2934,7 @@ function mob_class:mob_activate(staticdata, def, dtime) self[_] = stat end end - + -- force current model into mob self.mesh = def.mesh self.base_mesh = def.mesh @@ -3240,7 +3244,7 @@ function mob_class:on_step(dtime) self:do_jump() self:do_runaway_from(self) - + self:do_stay_near() end @@ -3754,7 +3758,7 @@ end -- Register spawn eggs --- Note: This also introduces the “spawn_egg” group: +-- Note: This also introduces the "spawn_egg" group: -- * spawn_egg=1: Spawn egg (generic mob, no metadata) -- * spawn_egg=2: Spawn egg (captured/tamed mob, metadata) function mobs:register_egg(mob, desc, background, addegg, no_creative) @@ -4126,7 +4130,7 @@ function mobs:feed_tame(self, clicker, feed_count, breed, tame) -- feed and tame self.food = (self.food or 0) + 1 - + if self.food >= feed_count then self.food = 0 diff --git a/files/vessels/textures/vessels_shelf.png b/files/vessels/textures/vessels_shelf.png index 141f275d872f05f4dc12d66cb471ae9643bb0600..e903067e70fcf3457e9a2716c8ee7accd0a42bfe 100644 GIT binary patch delta 952 zcmV;p14sOT3+M{4zX5-gNkl_Dp$BFAEe5aO1Ts%VasM+HwH*afRuj-M4zfz_X(Q~=u@$K zd;5O?b>05!OF#pNeF>gte-oR{X02Rqwcl%%xzPc-J>3NGJO#|X0Bi*79zeg&7`!$G zh_YekUI0rl_d|@v{$$ECm`wm81@t}uY(efZ_ZL`V)#24zHU(Vw1?as1D(L-YyMxpn z?780$H~lHZ0EvGsz#jnc7Yht<;8_$P`T{r^s56d7ptHsZyikDXZvilNr}Gep3mUxs z3!oVX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