0
0
Fork 0

Remove some unsused settings from mcl_mobs

This commit is contained in:
cora 2022-09-13 13:15:57 +02:00
parent 186059ae13
commit 786cea122d
3 changed files with 3 additions and 15 deletions

View File

@ -1,4 +1,3 @@
-- API for Mobs Redo: MineClone 2 Edition (MRM)
mcl_mobs = {}
@ -14,12 +13,6 @@ local FLOP_HOR_SPEED = 1.5
local ENTITY_CRAMMING_MAX = 24
local CRAMMING_DAMAGE = 3
local MOB_CAP = {}
MOB_CAP.hostile = 70
MOB_CAP.passive = 10
MOB_CAP.ambient = 15
MOB_CAP.water = 15
-- Localize
local S = minetest.get_translator("mcl_mobs")
@ -55,8 +48,6 @@ local spawn_protected = minetest.settings:get_bool("mobs_spawn_protected") ~= fa
local remove_far = true
local difficulty = tonumber(minetest.settings:get("mob_difficulty")) or 1.0
local show_health = false
local max_per_block = tonumber(minetest.settings:get("max_objects_per_block") or 64)
local mobs_spawn_chance = tonumber(minetest.settings:get("mobs_spawn_chance") or 2.5)
-- Shows helpful debug info above each mob
local mobs_debug = minetest.settings:get_bool("mobs_debug", false)

View File

@ -38,7 +38,7 @@ local mob_cap = {
--do mobs spawn?
local mobs_spawn = minetest.settings:get_bool("mobs_spawn", true) ~= false
local spawn_protected = minetest.settings:get_bool("mobs_spawn_protected") ~= false
local noise_params = {
offset = 0,
@ -456,7 +456,8 @@ local function spawn_check(pos,spawn_def)
and (spawn_def.check_position and spawn_def.check_position(pos) or true)
and (not is_farm_animal(spawn_def.name) or is_grass)
and (spawn_def.type_of_spawning ~= "water" or is_water)
and not is_bedrock then
and not spawn_protected or not minetest.is_protected(s, "")
and not is_bedrock
--only need to poll for node light if everything else worked
local gotten_light = get_node_light(pos)
if gotten_light >= spawn_def.min_light and gotten_light <= spawn_def.max_light then

View File

@ -76,10 +76,6 @@ mcl_enable_skin_customization (Enable player skin customization) bool true
# This setting is only read at startup.
mobs_spawn (Spawn mobs naturally) bool true
# Controls the overall amount of mobs that spawn. The higher the number,
# the less often mobs will spawn. This does not affect mob spawners.
mobs_spawn_chance (Mob spawn chance) float 2.5 0.0
# If enabled, only peaceful mobs will appear naturally. This does not
# affect mob spawners.
# This setting is only read at startup.