Really really re-enable CCD.
This commit is contained in:
parent
79ddc3f951
commit
b101d8bc15
3 changed files with 20 additions and 13 deletions
16
Cargo.lock
generated
16
Cargo.lock
generated
|
@ -30,7 +30,7 @@ version = "0.7.6"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47"
|
||||
dependencies = [
|
||||
"getrandom 0.2.4",
|
||||
"getrandom 0.2.5",
|
||||
"once_cell",
|
||||
"version_check",
|
||||
]
|
||||
|
@ -668,7 +668,7 @@ checksum = "252f6674aa3ba68bacfec506b91570a3cc206ad09b7ef4b23661959ef0246396"
|
|||
dependencies = [
|
||||
"ahash",
|
||||
"bevy_derive",
|
||||
"getrandom 0.2.4",
|
||||
"getrandom 0.2.5",
|
||||
"instant",
|
||||
"tracing",
|
||||
"uuid",
|
||||
|
@ -1271,9 +1271,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "getrandom"
|
||||
version = "0.2.4"
|
||||
version = "0.2.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "418d37c8b1d42553c93648be529cb70f920d3baf8ef469b74b9638df426e0b4c"
|
||||
checksum = "d39cd93900197114fa1fcb7ae84ca742095eed9442088988ae74fa744e930e77"
|
||||
dependencies = [
|
||||
"cfg-if 1.0.0",
|
||||
"js-sys",
|
||||
|
@ -2140,9 +2140,9 @@ checksum = "eb9f9e6e233e5c4a35559a617bf40a4ec447db2e84c20b55a6f83167b7e57872"
|
|||
|
||||
[[package]]
|
||||
name = "proc-macro-crate"
|
||||
version = "1.1.2"
|
||||
version = "1.1.3"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9dada8c9981fcf32929c3c0f0cd796a9284aca335565227ed88c83babb1d43dc"
|
||||
checksum = "e17d47ce914bf4de440332250b0edd23ce48c005f59fab39d3335866b114f11a"
|
||||
dependencies = [
|
||||
"thiserror",
|
||||
"toml",
|
||||
|
@ -2231,7 +2231,7 @@ version = "0.6.3"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "d34f1408f55294453790c48b2f1ebbb1c5b4b7563eb1f418bcfcfdbb06ebb4e7"
|
||||
dependencies = [
|
||||
"getrandom 0.2.4",
|
||||
"getrandom 0.2.5",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
|
@ -2785,7 +2785,7 @@ version = "0.8.2"
|
|||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "bc5cf98d8186244414c848017f0e2676b3fcb46807f6668a97dfe67359a3c4b7"
|
||||
dependencies = [
|
||||
"getrandom 0.2.4",
|
||||
"getrandom 0.2.5",
|
||||
"serde",
|
||||
]
|
||||
|
||||
|
|
|
@ -6,7 +6,7 @@ use bevy::{
|
|||
use bevy_rapier3d::{na::Vector3, physics::PhysicsSystems::StepWorld, prelude::*};
|
||||
|
||||
use crate::{
|
||||
geometry::{CyberBike, CyberSphere, PLANET_RADIUS},
|
||||
geometry::{CyberBike, CyberSphere, PLANET_RADIUS, SPAWN_ALTITUDE},
|
||||
input::InputState,
|
||||
};
|
||||
|
||||
|
@ -55,6 +55,13 @@ fn setup_colliders(
|
|||
|
||||
let pbody = RigidBodyBundle {
|
||||
body_type: RigidBodyType::Static.into(),
|
||||
ccd: RigidBodyCcd {
|
||||
ccd_enabled: true,
|
||||
ccd_thickness: 2.0,
|
||||
ccd_max_dist: SPAWN_ALTITUDE,
|
||||
..Default::default()
|
||||
}
|
||||
.into(),
|
||||
..Default::default()
|
||||
};
|
||||
let pcollide = ColliderBundle {
|
||||
|
|
|
@ -3,7 +3,7 @@ use bevy::{
|
|||
render::mesh::Indices,
|
||||
};
|
||||
use hexasphere::shapes::IcoSphere;
|
||||
use noise::{HybridMulti, NoiseFn, Simplex};
|
||||
use noise::{HybridMulti, NoiseFn, SuperSimplex};
|
||||
use wgpu::PrimitiveTopology;
|
||||
|
||||
use crate::Label;
|
||||
|
@ -22,10 +22,10 @@ fn spawn_giant_sphere(
|
|||
mut meshes: ResMut<Assets<Mesh>>,
|
||||
mut materials: ResMut<Assets<StandardMaterial>>,
|
||||
) {
|
||||
let color = Color::DARK_GRAY;
|
||||
let color = Color::rgb(0.2, 0.17, 0.2);
|
||||
let isphere = shape::Icosphere {
|
||||
radius: PLANET_RADIUS,
|
||||
subdivisions: 64,
|
||||
subdivisions: 79,
|
||||
};
|
||||
|
||||
let pmesh = gen_planet(isphere);
|
||||
|
@ -89,7 +89,7 @@ fn gen_planet(sphere: Icosphere) -> Mesh {
|
|||
|
||||
// TODO: use displaced points for normals by replacing raw_points with
|
||||
// noise-displaced points.
|
||||
let noise = HybridMulti::<Simplex>::default();
|
||||
let noise = HybridMulti::<SuperSimplex>::default();
|
||||
|
||||
let raw_points = generated
|
||||
.raw_points()
|
||||
|
|
Loading…
Reference in a new issue