1
0
Fork 0

Merge pull request 'Disable zombie siege raid until we stop zombies pathing through door' (#3329) from disable_zombie_siege into master

Reviewed-on: https://git.minetest.land/MineClone2/MineClone2/pulls/3329
Reviewed-by: PrairieWind <prairie.astronomer1@gmail.com>
hardcore_mode_test
PrairieWind 2023-01-18 20:51:04 +00:00
commit c49aef3251
2 changed files with 11 additions and 1 deletions

View File

@ -1,3 +1,4 @@
local zombie_siege_enabled = minetest.settings:get_bool("mcl_raids_zombie_siege", false)
local function check_spawn_pos(pos)
return minetest.get_natural_light(pos) < 7
@ -33,6 +34,13 @@ mcl_events.register_event("zombie_siege",{
--minetest.log("Cond start zs")
local r = {}
if not zombie_siege_enabled then
--minetest.log("action", "Zombie siege disabled")
return r
else
--minetest.log("action", "Zombie siege start check")
end
local t = minetest.get_timeofday()
local pr = PseudoRandom(minetest.get_day_count())
local rnd = pr:next(1,10)
@ -42,7 +50,7 @@ mcl_events.register_event("zombie_siege",{
for _,p in pairs(minetest.get_connected_players()) do
local village = mcl_raids.find_village(p:get_pos())
if village then
--minetest.log("Found village")
minetest.log("action", "Zombie siege is starting")
table.insert(r,{ player = p:get_player_name(), pos = village})
end
end

View File

@ -134,6 +134,8 @@ mcl_old_spawn_icons (Old spawn icons instead of eggs) bool false
# Larger values will have a larger performance impact (default:48)
mcl_mob_active_range (Active mob range) int 48 0 256
# Zombie siege raid (default:false)
mcl_raids_zombie_siege (Zombie siege raid) bool false
[Audio]
# Enable flame sound.