cleanup
Some checks failed
Build legacy Nix package on Ubuntu / build (push) Failing after 9m39s
Some checks failed
Build legacy Nix package on Ubuntu / build (push) Failing after 9m39s
This commit is contained in:
parent
2c169548b9
commit
bc42892d39
5 changed files with 12 additions and 32 deletions
|
@ -42,16 +42,9 @@ impl SceneManager {
|
|||
}
|
||||
|
||||
pub fn current_scene_mut(&mut self) -> Option<&mut Box<dyn Scene>> {
|
||||
log::debug!(
|
||||
"current_scene_mut called - index: {:?}, scenes len: {}",
|
||||
self.current_scene_index,
|
||||
self.scenes.len()
|
||||
);
|
||||
if let Some(index) = self.current_scene_index {
|
||||
log::debug!("Getting scene at index {}", index);
|
||||
self.scenes.get_mut(index)
|
||||
} else {
|
||||
log::debug!("No current scene index set");
|
||||
None
|
||||
}
|
||||
}
|
||||
|
@ -60,21 +53,9 @@ impl SceneManager {
|
|||
&mut self,
|
||||
app_context: &mut ApplicationContext,
|
||||
) -> Result<(), Box<dyn Error>> {
|
||||
log::debug!("SceneManager::load_scene_if_not_loaded called");
|
||||
log::debug!(
|
||||
"Current scene index: {:?}, scenes count: {}",
|
||||
self.current_scene_index,
|
||||
self.scenes.len()
|
||||
);
|
||||
|
||||
if let Some(scene) = self.current_scene_mut() {
|
||||
log::debug!("Scene found, checking if loaded: {}", scene.loaded());
|
||||
if !scene.loaded() {
|
||||
log::debug!("Scene not loaded, loading...");
|
||||
scene.load(app_context)?;
|
||||
log::debug!("Scene loaded successfully");
|
||||
} else {
|
||||
log::debug!("Scene already loaded");
|
||||
}
|
||||
} else {
|
||||
log::warn!("No scene found in SceneManager!");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue