1
0
mirror of https://codeberg.org/tenplus1/mobs_redo.git synced 2025-09-16 20:35:35 +02:00

Default pathfinding to A* to avoid older client crashes

This commit is contained in:
tenplus1
2025-09-16 18:12:45 +01:00
parent 8d1de7b08e
commit 10f6d8f2b0
2 changed files with 5 additions and 5 deletions

View File

@@ -18,7 +18,7 @@ end
-- global table
mobs = {
mod = "redo", version = "20250824",
mod = "redo", version = "20250916",
spawning_mobs = {}, translate = S,
node_snow = has(core.registered_aliases["mapgen_snow"])
or has("mcl_core:snow") or has("default:snow") or "air",
@@ -88,7 +88,7 @@ local pathfinding_stuck_timeout = tonumber(
settings:get("mob_pathfinding_stuck_timeout")) or 3.0
local pathfinding_stuck_path_timeout = tonumber(
settings:get("mob_pathfinding_stuck_path_timeout")) or 5.0
local pathfinding_algorithm = settings:get("mob_pathfinding_algorithm") or "Dijkstra"
local pathfinding_algorithm = settings:get("mob_pathfinding_algorithm") or "A*_noprefetch"
if pathfinding_algorithm == "AStar_noprefetch" then
pathfinding_algorithm = "A*_noprefetch"

View File

@@ -77,11 +77,11 @@ mob_pathfinding_stuck_timeout (How long before stuck mobs start searching) float
# How long will mob follow path before giving up (default 5.0)
mob_pathfinding_stuck_path_timeout (How long will mob follow path before giving up) float 5.0
# Which pathfinding algorithm to use
# - Dijkstra (default)
# - Dijkstra
# - A*_noprefetch (AStar_noprefetch)
# - A* (AStar)
# - A* (AStar) Default
# (A* names differ cause Minetest doesn´t allow "*" in settings)
mob_pathfinding_algorithm (pathfinding algorithm) enum Dijkstra Dijkstra,AStar_noprefetch,AStar
mob_pathfinding_algorithm (pathfinding algorithm) enum Astar Dijkstra,AStar_noprefetch,AStar
# max search distance from search positions (default 16)
mob_pathfinding_searchdistance (path search distance) int 16
# max jump height for pathfinding (default 4)