mirror of https://github.com/wayvr-org/wayvr.git
Use from_scale_rotation_translation
This commit is contained in:
parent
1815da2d2d
commit
cc7b3d8fae
|
|
@ -91,13 +91,13 @@ impl OverlayState {
|
|||
pub fn auto_movement(&mut self, app: &mut AppState) {
|
||||
if let Some(parent) = self.parent_transform(app) {
|
||||
self.transform = parent
|
||||
* Affine3A::from_translation(self.spawn_point.into())
|
||||
* Affine3A::from_quat(
|
||||
* Affine3A::from_scale_rotation_translation(
|
||||
Vec3::ONE * self.spawn_scale,
|
||||
self.spawn_rotation
|
||||
* Quat::from_rotation_x(f32::to_radians(-180.0))
|
||||
* Quat::from_rotation_z(f32::to_radians(180.0)),
|
||||
)
|
||||
* Affine3A::from_scale(Vec3::ONE * self.spawn_scale);
|
||||
self.spawn_point.into(),
|
||||
);
|
||||
|
||||
self.dirty = true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue