lol idk #1

Open
Quaternions wants to merge 99 commits from StrafesNET/strafe-client:master into master
Showing only changes of commit b25bcc627d - Show all commits

View File

@ -42,7 +42,7 @@ impl std::fmt::Display for LoadError{
} }
impl std::error::Error for LoadError{} impl std::error::Error for LoadError{}
pub fn load(path:&std::path::Path)->Result<(strafesnet_common::map::CompleteMap,strafesnet_deferred_loader::texture::Textures),LoadError>{ pub fn load<P:AsRef<std::path::Path>>(path:P)->Result<(strafesnet_common::map::CompleteMap,strafesnet_deferred_loader::texture::Textures),LoadError>{
//blocking because it's simpler... //blocking because it's simpler...
let file=std::fs::File::open(path).map_err(LoadError::File)?; let file=std::fs::File::open(path).map_err(LoadError::File)?;
match read(file).map_err(LoadError::ReadError)?{ match read(file).map_err(LoadError::ReadError)?{