add docs to remaining public blocks_agent functions
This commit is contained in:
parent
6ed0bc3e7e
commit
7ca91020e3
@ -107,6 +107,13 @@ inline bool is_replaceable_at(const Storage& chunks, int32_t x, int32_t y, int32
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// @brief Set block at specified position if voxel exists.
|
||||||
|
/// @param chunks chunks matrix
|
||||||
|
/// @param x block position X
|
||||||
|
/// @param y block position Y
|
||||||
|
/// @param z block position Z
|
||||||
|
/// @param id new block id
|
||||||
|
/// @param state new block state
|
||||||
void set(
|
void set(
|
||||||
Chunks& chunks,
|
Chunks& chunks,
|
||||||
int32_t x,
|
int32_t x,
|
||||||
@ -116,6 +123,13 @@ void set(
|
|||||||
blockstate state
|
blockstate state
|
||||||
);
|
);
|
||||||
|
|
||||||
|
/// @brief Set block at specified position if voxel exists.
|
||||||
|
/// @param chunks chunks storage
|
||||||
|
/// @param x block position X
|
||||||
|
/// @param y block position Y
|
||||||
|
/// @param z block position Z
|
||||||
|
/// @param id new block id
|
||||||
|
/// @param state new block state
|
||||||
void set(
|
void set(
|
||||||
GlobalChunks& chunks,
|
GlobalChunks& chunks,
|
||||||
int32_t x,
|
int32_t x,
|
||||||
@ -376,6 +390,16 @@ inline void set_rotation(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// @brief Cast ray to a selectable block with filter based on id.
|
||||||
|
/// @param chunks chunks matrix
|
||||||
|
/// @param start ray start position
|
||||||
|
/// @param dir normalized ray direction vector
|
||||||
|
/// @param maxDist maximum ray length
|
||||||
|
/// @param end [out] ray end position
|
||||||
|
/// @param norm [out] surface normal vector
|
||||||
|
/// @param iend [out] ray end integer position (voxel position + normal)
|
||||||
|
/// @param filter filtered ids
|
||||||
|
/// @return voxel pointer or nullptr
|
||||||
voxel* raycast(
|
voxel* raycast(
|
||||||
const Chunks& chunks,
|
const Chunks& chunks,
|
||||||
const glm::vec3& start,
|
const glm::vec3& start,
|
||||||
@ -387,6 +411,16 @@ voxel* raycast(
|
|||||||
std::set<blockid_t> filter
|
std::set<blockid_t> filter
|
||||||
);
|
);
|
||||||
|
|
||||||
|
/// @brief Cast ray to a selectable block with filter based on id.
|
||||||
|
/// @param chunks chunks storage
|
||||||
|
/// @param start ray start position
|
||||||
|
/// @param dir normalized ray direction vector
|
||||||
|
/// @param maxDist maximum ray length
|
||||||
|
/// @param end [out] ray end position
|
||||||
|
/// @param norm [out] surface normal vector
|
||||||
|
/// @param iend [out] ray end integer position (voxel position + normal)
|
||||||
|
/// @param filter filtered ids
|
||||||
|
/// @return voxel pointer or nullptr
|
||||||
voxel* raycast(
|
voxel* raycast(
|
||||||
const GlobalChunks& chunks,
|
const GlobalChunks& chunks,
|
||||||
const glm::vec3& start,
|
const glm::vec3& start,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user