This commit is contained in:
aozhiwei 2023-03-09 15:05:20 +08:00
parent a1c661444d
commit 1be6e492c4

View File

@ -2915,7 +2915,7 @@ void Creature::ShortFindPath()
#if 1
auto try_move =
[this] (glm::vec3 start, glm::vec3 end,
bool& block, glm::vec3& new_point, float& distance)
glm::vec3& new_point, float& distance) -> bool
{
room->map_instance->Scale(start);
room->map_instance->Scale(end);
@ -2924,8 +2924,9 @@ void Creature::ShortFindPath()
bool hit_result = false;
bool ret = room->map_instance->Raycast(start, end, hit_point, hit_result);
if (ret) {
return true;
} else {
block = true;
return false;
}
};