Skip to content

Commit fbdc336

Browse files
committed
Prepping to move more examples to another PR
1 parent bab7adc commit fbdc336

File tree

5 files changed

+3
-15
lines changed

5 files changed

+3
-15
lines changed

Makefile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ assets:
55
rm -r assets || true
66
blender -b test_scenes/Cube.blend --python export.py -- --output-file="assets/scenes/Cube.scn" --log-level=DEBUG
77
blender -b test_scenes/PhysicsTest.blend --python export.py -- --output-file="assets/scenes/PhysicsTest.scn" --log-level=DEBUG
8-
blender -b test_scenes/Heirarchy.blend --python export.py -- --output-file="assets/scenes/Heirarchy.scn" --log-level=DEBUG
98

109
run:
11-
cargo run --example scenes -- scenes/PhysicsTest.scn
10+
cargo run --example scenes

blender_bevy_toolkit/rapier_definitions/rigid_body_description.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,6 @@
3333
"type": "bool",
3434
"default": false,
3535
"description": "allow this body to sleep when velocity is low - this increases performance"
36-
},
36+
}
3737
]
3838
}

examples/scenes/main.rs

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,6 @@ use bevy_rapier3d::physics::{NoUserData, RapierPhysicsPlugin};
44
use bevy_rapier3d::prelude::*;
55
use blender_bevy_toolkit::BlendLoadPlugin;
66

7-
use std::env;
8-
97

108
fn spawn_scene(
119
mut commands: Commands,
@@ -27,16 +25,7 @@ fn spawn_scene(
2725
..Default::default()
2826
});
2927

30-
let args: Vec<String> = env::args().collect();
31-
32-
if args.len() != 2 {
33-
println!("Please specify a scene file to load. For example:\n cargo run --example scenes -- scenes/Heirarchy.scn");
34-
std::process::exit(1);
35-
}
36-
37-
println!("Running scene: {}", args[1]);
38-
39-
let scene_handle: Handle<DynamicScene> = asset_server.load(args[1].as_str());
28+
let scene_handle: Handle<DynamicScene> = asset_server.load("scenes/PhysicsTest.scn");
4029
scene_spawner.spawn_dynamic(scene_handle);
4130
}
4231

test_scenes/Cube.blend

46.8 KB
Binary file not shown.

test_scenes/Heirarchy.blend

-774 KB
Binary file not shown.

0 commit comments

Comments
 (0)