#file #bsp #quake #description #fs-file #mralligator #com-q3

quake3_loader

Crate for loading Quake 3 BSP files based on description given here http://www.mralligator.com/q3/

2 unstable releases

Uses old Rust 2015

0.2.0 Sep 27, 2017
0.1.0 Dec 20, 2016

#31 in #bsp

MIT license

17KB
450 lines

#Example usage

(Assuming that the pk3 file is unzipped locally)

extern crate quake3_loader;
use std::fs::{File};
use std::path::{Path};
use std::io::{Read};
fn main() {
    let path = Path::new("pak0/maps/q3dm1.bsp");
    let mut file = File::open(path).unwrap();
    let mut bytes = Vec::new();
    file.read_to_end(&mut bytes).unwrap();
    let bsp = quake3_loader::read_bsp(bytes);           
    println!("{:?}", bsp);
}

Dependencies

~165KB