Luanti 5.11.0-dev
 
Loading...
Searching...
No Matches
pathfinder.h
Go to the documentation of this file.
1// Luanti
2// SPDX-License-Identifier: LGPL-2.1-or-later
3// Copyright (C) 2013 sapier, sapier at gmx dot net
4
5#pragma once
6
7/******************************************************************************/
8/* Includes */
9/******************************************************************************/
10#include <vector>
11#include "irr_v3d.h"
12
13/******************************************************************************/
14/* Forward declarations */
15/******************************************************************************/
16
17class NodeDefManager;
18class Map;
19
20/******************************************************************************/
21/* Typedefs and macros */
22/******************************************************************************/
23
30
37
38/******************************************************************************/
39/* declarations */
40/******************************************************************************/
41
43std::vector<v3s16> get_path(Map *map, const NodeDefManager *ndef,
44 v3s16 source,
45 v3s16 destination,
46 unsigned int searchdistance,
47 unsigned int max_jump,
48 unsigned int max_drop,
49 PathAlgorithm algo);
Definition map.h:101
This class is for getting the actual properties of nodes from their content ID.
Definition nodedef.h:540
core::vector3d< s16 > v3s16
Definition irr_v3d.h:13
PathAlgorithm
List of supported algorithms.
Definition pathfinder.h:32
@ PA_PLAIN
A* algorithm using heuristics to find a path.
Definition pathfinder.h:34
@ PA_DIJKSTRA
Dijkstra shortest path algorithm
Definition pathfinder.h:33
@ PA_PLAIN_NP
A* algorithm without prefetching of map data.
Definition pathfinder.h:35
std::vector< v3s16 > get_path(Map *map, const NodeDefManager *ndef, v3s16 source, v3s16 destination, unsigned int searchdistance, unsigned int max_jump, unsigned int max_drop, PathAlgorithm algo)
c wrapper function to use from scriptapi
Definition pathfinder.cpp:396
PathDirections
Definition pathfinder.h:24
@ DIR_XM
Definition pathfinder.h:26
@ DIR_ZM
Definition pathfinder.h:28
@ DIR_ZP
Definition pathfinder.h:27
@ DIR_XP
Definition pathfinder.h:25