Rustia Development Blog

First Post

2020-06-11

I decided to quit my job to create a game engine in Rust. I'm a newbie at Rust and only started learning a few weeks ago. This blog is a way to track my own progress while showing it off.

Rustia is the name for the game engine. No one had used the name for software that I can find, and it sounds kinda like a gaming term even though it's a type of cicada and plant.

The current iteration of the engine is using a few libraries to help my sanity.

At the core, Rustia is using a wgpu which is a WebGPU implementation in Rust. WebGPU itself is a relatively new standard, aiming to be a cross-platform graphics API, replacing OpenGL. The name is a bit unfortunate, as far as I understand it is able to target desktop and mobile applications as well as web. At the time of writing, no browsers support it in their stable builds.

WebGPU availability

Rustia is driven by an entity component system (ECS) called shipyard. My goal is to have as much as possible living in ECS, including rendering and the user interface. Many components and systems are inbuilt into Rustia to make live easier for the developer.

Shipyard makes this super easy where you declare a function with a certain set of arguments, and you have a system:

fn add_velocities(mut positions: ViewMut<Position>, velocities: View<Velocity>) {
    for (position, velocity) in (&mut positions, &velocities).iter() {
        position += velocity;
    }
}

A Shipyard system that simply adds entity velocities to their position.

I plan on open sourcing Rustia at some stage, but keeping my horrible Rust code away from the Internet for now.

gak