diff options
author | Stanislaw Halik <sthalik@misaki.pl> | 2023-09-26 07:52:51 +0200 |
---|---|---|
committer | Stanislaw Halik <sthalik@misaki.pl> | 2023-09-26 07:52:51 +0200 |
commit | 4c668acd91bdb9b7bb216d3ee45e4d2a1e2f50f5 (patch) | |
tree | c80f303ffaaf5f345ea0584270d89d9a675ff2e5 /src/path-search.hpp | |
parent | 25a494edf3790f7c6b923948e748b8a5b035277f (diff) |
a
Diffstat (limited to 'src/path-search.hpp')
-rw-r--r-- | src/path-search.hpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/path-search.hpp b/src/path-search.hpp index 2541a7ea..f3601a26 100644 --- a/src/path-search.hpp +++ b/src/path-search.hpp @@ -77,11 +77,13 @@ class path_search final // todo bucketize by array length path_search_result* pool = nullptr; - void ensure_allocated(chunk_coords a, chunk_coords b); - public: struct bbox { Vector2 min, max; }; + void ensure_allocated(chunk_coords a, chunk_coords b); + void fill_cache(world& w, Vector2i cmin, Vector2i cmax, int8_t z, Vector2ub own_size, object_id own_id); + void fill_cache_(world& w, chunk_coords_ coord, Vector2ub own_size, object_id own_id); + // todo remember to check from.z() == to.z() // todo add simple bresenham short-circuit Optional<path_search_result> operator()(world& w, Vector2ub own_size, object_id own_id, global_coords from, Vector2b from_offset, global_coords to, Vector2b to_offset); |