chore(testing): removed dependency on rapier etc for testing project

This commit is contained in:
kaosat.dev 2024-06-17 11:55:09 +02:00
parent 2abdb7f64e
commit 1686aca655
5 changed files with 31 additions and 8 deletions

View File

@ -8,9 +8,10 @@ license = "MIT OR Apache-2.0"
bevy = { version = "0.13", features = ["dynamic_linking"] }
bevy_gltf_blueprints = { path = "../../crates/bevy_gltf_blueprints" }
bevy_registry_export = { path = "../../crates/bevy_registry_export" }
bevy_gltf_worlflow_examples_common_rapier = { path = "../../examples/common_rapier" }
# bevy_gltf_worlflow_examples_common_rapier = { path = "../../examples/common_rapier" }
bevy_gltf_worlflow_examples_common = { path = "../../examples/common" }
bevy_rapier3d = { version = "0.25.0", features = ["serde-serialize", "debug-render-3d", "enhanced-determinism"] }
#evy_rapier3d = { version = "0.25.0", features = ["serde-serialize", "debug-render-3d", "enhanced-determinism"] }
bevy_asset_loader = { version = "0.20", features = ["standard_dynamic_assets"] }
bevy_editor_pls = { version = "0.8" }
rand = "0.8.5"

View File

@ -1,8 +1,8 @@
use bevy::prelude::*;
use bevy_gltf_blueprints::{BluePrintBundle, BlueprintName, BlueprintPath, GameWorldTag};
use bevy_gltf_worlflow_examples_common_rapier::{GameState, InAppRunning};
use bevy_gltf_worlflow_examples_common::{GameState, InAppRunning};
use bevy_rapier3d::prelude::Velocity;
//use bevy_rapier3d::prelude::Velocity;
use rand::Rng;
pub fn setup_game(
@ -69,10 +69,10 @@ pub fn spawn_test(
// BlueprintName("Health_Pickup".to_string()),
// SpawnHere,
TransformBundle::from_transform(Transform::from_xyz(x, 2.0, y)),
Velocity {
/*Velocity {
linvel: Vec3::new(vel_x, vel_y, vel_z),
angvel: Vec3::new(0.0, 0.0, 0.0),
},
},*/
))
.id();
commands.entity(world).add_child(new_entity);

View File

@ -13,7 +13,7 @@ use bevy::{
prelude::*, render::view::screenshot::ScreenshotManager, time::common_conditions::on_timer,
window::PrimaryWindow,
};
use bevy_gltf_worlflow_examples_common_rapier::{AppState, GameState};
use bevy_gltf_worlflow_examples_common::{AppState, GameState};
use json_writer::to_json_string;

View File

@ -1,5 +1,5 @@
use bevy::prelude::*;
use bevy_gltf_worlflow_examples_common_rapier::CommonPlugin;
use bevy_gltf_worlflow_examples_common::CommonPlugin;
mod core;
use crate::core::*;

View File

@ -117,6 +117,10 @@ pub struct VecOfVec3s2(Vec<TupleVec3>);
#[reflect(Component)]
pub struct VecOfColors(Vec<Color>);
#[derive(Component, Reflect, Default, Debug)]
#[reflect(Component)]
pub struct VecOfUints(Vec<u32>);
#[derive(Component, Reflect, Default, Debug)]
#[reflect(Component)]
pub struct AAAAddedCOMPONENT;
@ -196,6 +200,18 @@ pub struct ComponentAToFilterOut;
#[reflect(Component)]
pub struct ComponentBToFilterOut;
#[derive(Component, Reflect, Default, Debug)]
#[reflect(Component)]
pub struct ComponentWithFieldsOfIdenticalType{
pub first: f32,
pub second: f32,
pub third: Vec<f32>,
pub fourth: Vec<f32>,
}
#[derive(Component, Reflect, Default, Debug)]
#[reflect(Component)]
pub struct ComponentWithFieldsOfIdenticalType2(f32, f32, f32);
pub struct ComponentsTestPlugin;
impl Plugin for ComponentsTestPlugin {
fn build(&self, app: &mut App) {
@ -227,6 +243,9 @@ impl Plugin for ComponentsTestPlugin {
.register_type::<Range<f32>>()
.register_type::<VecOfF32s>()
.register_type::<Vec<f32>>()
.register_type::<u32>()
.register_type::<Vec<u32>>()
.register_type::<VecOfUints>()
// .register_type::<AAAAddedCOMPONENT>()
.register_type::<AComponentWithAnExtremlyExageratedOrMaybeNotButCouldBeNameOrWut>()
.register_type::<HashMap<String, String>>()
@ -242,6 +261,9 @@ impl Plugin for ComponentsTestPlugin {
.register_type::<HashmapTestStringColorFlat>()
.register_type::<ComponentAToFilterOut>()
.register_type::<ComponentBToFilterOut>()
.register_type::<ComponentWithFieldsOfIdenticalType>()
.register_type::<ComponentWithFieldsOfIdenticalType2>()
.add_plugins(MaterialPlugin::<
ExtendedMaterial<StandardMaterial, MyExtension>,
>::default());