1
This commit is contained in:
parent
0a93092c23
commit
ad9b5de45c
@ -164,6 +164,14 @@ void Player::InternalUpdate(int delta_time)
|
|||||||
moving = true;
|
moving = true;
|
||||||
moved_frames = 0;
|
moved_frames = 0;
|
||||||
}
|
}
|
||||||
|
if (room->GetGasData().GetGasMode() == GasInactive &&
|
||||||
|
room->IsSandTableRoom()
|
||||||
|
) {
|
||||||
|
if (sand_table_target_pos) {
|
||||||
|
} else {
|
||||||
|
moving = false;
|
||||||
|
}
|
||||||
|
}
|
||||||
if (moving) {
|
if (moving) {
|
||||||
UpdateMoving();
|
UpdateMoving();
|
||||||
}
|
}
|
||||||
@ -1031,6 +1039,11 @@ void Player::_CMMove(f8::MsgHdr& hdr, const cs::CMMove& msg)
|
|||||||
sand_table_target_pos = std::make_shared<glm::vec3>();
|
sand_table_target_pos = std::make_shared<glm::vec3>();
|
||||||
}
|
}
|
||||||
TypeConvert::FromPb(*sand_table_target_pos, &msg.sand_table_target_pos());
|
TypeConvert::FromPb(*sand_table_target_pos, &msg.sand_table_target_pos());
|
||||||
|
if (GlmHelper::IsEqual2D(*sand_table_target_pos, GetPos().ToGlmVec3())) {
|
||||||
|
sand_table_target_pos = nullptr;
|
||||||
|
} else {
|
||||||
|
glm::vec3 dir = *sand_table_target_pos - GetPos().ToGlmVec3();
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
sand_table_target_pos = nullptr;
|
sand_table_target_pos = nullptr;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user