Tweak the settings.
This commit is contained in:
parent
8dc2f91fcf
commit
93d1db607a
3 changed files with 11 additions and 11 deletions
|
@ -34,8 +34,8 @@ fn setup_colliders(
|
||||||
let pcollide = ColliderBundle {
|
let pcollide = ColliderBundle {
|
||||||
shape: ColliderShape::ball(PLANET_RADIUS).into(),
|
shape: ColliderShape::ball(PLANET_RADIUS).into(),
|
||||||
material: ColliderMaterial {
|
material: ColliderMaterial {
|
||||||
friction: 0.0,
|
friction: 0.1,
|
||||||
restitution: 0.3,
|
restitution: 0.05,
|
||||||
..Default::default()
|
..Default::default()
|
||||||
}
|
}
|
||||||
.into(),
|
.into(),
|
||||||
|
@ -48,8 +48,8 @@ fn setup_colliders(
|
||||||
|
|
||||||
let (bike, xform) = bike_query.single();
|
let (bike, xform) = bike_query.single();
|
||||||
let mut bbody = RigidBodyBundle::default();
|
let mut bbody = RigidBodyBundle::default();
|
||||||
bbody.damping.angular_damping = 0.8;
|
bbody.damping.angular_damping = 0.7;
|
||||||
bbody.damping.linear_damping = 0.5;
|
bbody.damping.linear_damping = 0.4;
|
||||||
let isometry = Isometry::from_parts(xform.translation.into(), xform.rotation.into());
|
let isometry = Isometry::from_parts(xform.translation.into(), xform.rotation.into());
|
||||||
bbody.position = isometry.into();
|
bbody.position = isometry.into();
|
||||||
// collider
|
// collider
|
||||||
|
@ -63,7 +63,7 @@ fn setup_colliders(
|
||||||
mass_properties: ColliderMassProps::Density(0.3).into(),
|
mass_properties: ColliderMassProps::Density(0.3).into(),
|
||||||
material: ColliderMaterial {
|
material: ColliderMaterial {
|
||||||
friction: 0.0,
|
friction: 0.0,
|
||||||
restitution: 0.3,
|
restitution: 0.05,
|
||||||
..Default::default()
|
..Default::default()
|
||||||
}
|
}
|
||||||
.into(),
|
.into(),
|
||||||
|
|
|
@ -17,7 +17,7 @@ fn spawn_giant_sphere(
|
||||||
mut materials: ResMut<Assets<StandardMaterial>>,
|
mut materials: ResMut<Assets<StandardMaterial>>,
|
||||||
) {
|
) {
|
||||||
let mut color = Color::DARK_GRAY;
|
let mut color = Color::DARK_GRAY;
|
||||||
color.set_a(0.0);
|
color.set_a(0.8);
|
||||||
commands
|
commands
|
||||||
.spawn_bundle(PbrBundle {
|
.spawn_bundle(PbrBundle {
|
||||||
mesh: meshes.add(Mesh::from(shape::Icosphere {
|
mesh: meshes.add(Mesh::from(shape::Icosphere {
|
||||||
|
@ -26,9 +26,9 @@ fn spawn_giant_sphere(
|
||||||
})),
|
})),
|
||||||
material: materials.add(StandardMaterial {
|
material: materials.add(StandardMaterial {
|
||||||
base_color: color,
|
base_color: color,
|
||||||
metallic: 0.6,
|
metallic: 0.65,
|
||||||
perceptual_roughness: 0.4,
|
perceptual_roughness: 0.3,
|
||||||
alpha_mode: AlphaMode::Mask(0.5),
|
alpha_mode: AlphaMode::Blend,
|
||||||
..Default::default()
|
..Default::default()
|
||||||
}),
|
}),
|
||||||
|
|
||||||
|
|
|
@ -11,8 +11,8 @@ use cyber_rider::{
|
||||||
};
|
};
|
||||||
|
|
||||||
const MOVEMENT_SETTINGS: MovementSettings = MovementSettings {
|
const MOVEMENT_SETTINGS: MovementSettings = MovementSettings {
|
||||||
sensitivity: 4.0, // default: 1.0
|
sensitivity: 50.0, // default: 1.0
|
||||||
accel: 15.0, // default: 40.0
|
accel: 12.0, // default: 40.0
|
||||||
};
|
};
|
||||||
|
|
||||||
fn main() {
|
fn main() {
|
||||||
|
|
Loading…
Reference in a new issue