gamevecs

Crates.iogamevecs
lib.rsgamevecs
version1.0.0
sourcesrc
created_at2024-04-21 13:53:13.008694
updated_at2024-04-21 13:53:13.008694
descriptionA library that provides 2d and 3d vectors specifically for game developement
homepage
repositoryhttps://github.com/nobschulth/gamevecs
max_upload_size
id1215407
size26,085
nobschulth (nobschulth)

documentation

README

Gamevecs

Gamevecs is a library that provides 2d and 3d vectors for game developement in rust. The vectors have common functionality like cross/dot product, lerping, etc. .

Examples

use gamevecs::Vec2;

fn main() {
	//create 2 2D vectors
	let vec1 = Vec2::new(0.0, 10.0);
	let vec2 = Vec2::new(10.0, 0.0);
	
	//add them together
	let result = vec1 + vec2;
	
	//print the result (10.0, 10.0)
	println!(result);
}
Commit count: 10

cargo fmt