1
This commit is contained in:
parent
eb6800f64c
commit
ca0834d091
@ -99,5 +99,5 @@ glm::vec3 GlmHelper::Vec2ToVec3(const glm::vec2& v2)
|
||||
|
||||
bool GlmHelper::IsValidVec3(const glm::vec3& v)
|
||||
{
|
||||
return !(isnan(v.x));
|
||||
return !(isnan(v.x) || isnan(v.y) || isnan(v.z));
|
||||
}
|
||||
|
@ -973,7 +973,7 @@ void Player::_CMMove(f8::MsgHdr* hdr, const cs::CMMove& msg)
|
||||
a8::XPrintf("has_move_dir1\n", {});
|
||||
#endif
|
||||
if (!(HasBuffEffect(kBET_Jump) && follow_target.Get())) {
|
||||
if (GetDisableMoveDirTimes() <= 0) {
|
||||
if (GetDisableMoveDirTimes() <= 0 && GlmHelper::IsValidVec3(new_move_dir)) {
|
||||
GlmHelper::Normalize(new_move_dir);
|
||||
if (std::fabs(new_move_dir.x - GetMoveDir().x) > 0.00001f ||
|
||||
std::fabs(new_move_dir.y - GetMoveDir().y) > 0.00001f ||
|
||||
|
Loading…
x
Reference in New Issue
Block a user