try interpolating more transforms, no dice

This commit is contained in:
Joe Ardent 2023-01-26 22:28:28 -08:00
parent 4708eabdd9
commit 2436e27290
1 changed files with 12 additions and 3 deletions

View File

@ -76,7 +76,7 @@ fn spawn_cyberbike(
let mut xform = Transform::from_translation(Vec3::X * altitude)
.with_rotation(Quat::from_axis_angle(Vec3::Z, -89.0f32.to_radians()));
//.with_rotation(Quat::from_axis_angle(Vec3::X, -90.0f32.to_radians()));
//.with_rotation(Quat::from_axis_angle(Vec3::X, 140.0f32.to_radians()));
let right = xform.right() * 350.0;
xform.translation += right;
@ -253,7 +253,7 @@ fn spawn_tires(
};
let tire_spundle = SpatialBundle {
transform: wheel_pos_in_world,
transform: Transform::IDENTITY,
..Default::default()
};
@ -270,7 +270,16 @@ fn spawn_tires(
wheels_collision_group,
))
.with_children(|wheel| {
wheel.spawn(tire_spundle).insert(pbr_bundle.clone());
wheel.spawn(tire_spundle).insert(pbr_bundle.clone()).insert(
TransformInterpolation {
start: None,
end: None,
},
);
})
.insert(TransformInterpolation {
start: None,
end: None,
})
.insert(CyberWheel);
}