strafe-client/src/load_bsp.rs

25 lines
619 B
Rust
Raw Normal View History

2023-10-10 04:37:07 +00:00
pub fn generate_indexed_models<R:std::io::Read+std::io::Seek>(input:&mut R) -> crate::model::IndexedModelInstances{
2023-10-02 22:28:57 +00:00
let mut spawn_point=crate::integer::Planar64Vec3::ZERO;
let mut indexed_models=Vec::new();
2023-10-10 04:37:07 +00:00
let mut s=Vec::new();
match input.read_to_end(&mut s){
Ok(guac)=>println!("readed to string {:?}", guac),
Err(e)=>println!("faile {:?}",e),
}
match vbsp::Bsp::read(s.as_slice()){
2023-10-02 22:28:57 +00:00
Ok(guac)=>println!("we got the guac {:?}", guac),
Err(e)=>println!("rotten {:?}",e),
}
crate::model::IndexedModelInstances{
textures:Vec::new(),
models:indexed_models,
spawn_point,
2023-10-10 04:37:07 +00:00
modes:Vec::new(),
2023-10-02 22:28:57 +00:00
}
}