build path in engine

This commit is contained in:
hodasemi 2024-08-25 08:45:28 +02:00
parent 1517aa11d0
commit 6893b8d285

View file

@ -6,6 +6,7 @@ use super::engineobject::*;
use super::enginesettings::EngineSettings;
use anyhow::Result;
use assetpath::AssetPath;
use context::prelude::cgmath::vec3;
use loading_screen::LoadingScreen;
@ -423,6 +424,10 @@ impl Engine {
&self.graphical.context
}
pub fn build_path(&self, path: &str) -> AssetPath {
(self.graphical.resource_base_path.as_str(), path).into()
}
pub fn assets(&self) -> AssetHandler<'_> {
AssetHandler {
asset_manager: &self.graphical.asset_manager,