Update a couple of deprecated bits

This commit is contained in:
Patrick Dobbs 2024-10-24 23:22:58 +01:00
parent ac406eaad7
commit c7b1ad3145
3 changed files with 4 additions and 10 deletions

View File

@ -514,11 +514,8 @@ pub(crate) fn blueprints_assets_loaded(
//println!("ANIMATION INFOS: {:?}", animation_infos);
commands.entity(entity).insert((
SceneBundle {
scene: SceneRoot(scene.clone()),
transform: transforms,
..Default::default()
},
SceneRoot(scene.clone()),
transforms,
OriginalChildren(original_children),
BlueprintAnimations {
// TODO: perhaps swap this out with InstanceAnimations depending on whether we are spawning a level or a simple blueprint

View File

@ -83,10 +83,7 @@ pub(crate) fn load_game(
// let input = std::fs::read(&path)?;
let _dynamic_data = commands
.spawn((
DynamicSceneBundle {
scene: DynamicSceneRoot(asset_server.load(load_request.path.clone())),
..default()
},
DynamicSceneRoot(asset_server.load(load_request.path.clone())),
bevy::prelude::Name::from("World_dynamic"),
DynamicEntitiesRoot,
GameWorldTag,

View File

@ -86,7 +86,7 @@ pub(crate) fn save_game(world: &mut World) {
let mut save_path: String = "".into();
let mut events = world.resource_mut::<Events<SavingRequest>>();
for event in events.get_reader().read(&events) {
for event in events.get_cursor().read(&events) {
info!("SAVE EVENT !! {:?}", event);
save_path.clone_from(&event.path);
}