Skip to content

Files

This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Latest commit

3b3a658 · Apr 6, 2021

History

History
893 lines (653 loc) · 33.3 KB

File metadata and controls

893 lines (653 loc) · 33.3 KB

+++ title = "This Month in Rust GameDev #20 - March 2021" date = 2021-04-06 transparent = true draft = true +++

Welcome to the 20th issue of the Rust GameDev Workgroup's monthly newsletter. Rust is a systems language pursuing the trifecta: safety, concurrency, and speed. These goals are well-aligned with game development. We hope to build an inviting ecosystem for anyone wishing to use Rust in their development process! Want to get involved? Join the Rust GameDev working group!

You can follow the newsletter creation process by watching the coordination issues. Want something mentioned in the next newsletter? Send us a pull request. Feel free to send PRs about your own projects!

Game Updates

Super Mario 64 JavaScript

SM64JS (GitHub, Discord) is a rewrite of the decompilation project of Super Mario 64 in JavaScript with a strong focus on massive multiplayer online. The backend recently has been rewritten in Rust by @marior and is now live.

You can find more information about it in this recent blog post, where the developers of a similar mod called Net64 are talking about several decompilation projects.

Some of the most recent additions are:

  • Carts and gliders
  • Health bars
  • More visuals with butterflies and fishes

A stress test is scheduled for 2021-04-17 17:30 UTC and everyone is invited to join.

Improved text rendering

pGLOWrpg by @Roal_Yr is a Procedurally Generated Living Open World RPG, a long-term project in development, which aims to be a narrative text-based game with maximum portability and accessibility.

Recent updates include:

  • Reformatting a print interface, making it very easy to link text UI and code.
  • Switching to .ron file format for storing configs and strings.
  • Implementing individual strings coloring for better visual perception.

Discussions: Twitter

Orbital Decay Orbital Decay gameplay

Orbital Decay by @stevebob is an open-source turn-based tactical roguelike with a focus on ranged combat. Deal enough damage to enemies to get through their armour without breaching the hull of the station, or risk being pulled into the void. It was made for the 7 Day Roguelike 2021 game jam.

Traverse a procedurally-generated space station to reach the fuel bay on the 5th floor. Choose your weapons and upgrades wisely to make it past the station's former crew - now a horde of ravenous undead.

Read more about Orbital Decay on its development blog.

Stellary 2

Stellary 2 Anti-Missile Laser ▶️ Click to watch the full video

Stellary 2 by @CoffeJunkStudio is a 3D real-time space shooter in which the player has to control his spaceship to colonize each planet in the solar system.

In the last month, the game concept has been overhauled. Most importantly:

  • Planets become inhabitable over time, starting with the outermost one in order to bring head-to-head matches to an end eventually.
  • Full focus on multiplayer, including AIs
  • Players can’t die mid-game anymore. When defeated, they re-spawn and lose a colony for it (if they have one) instead of dying. This prevents long waiting times when playing against friends.

You can follow the development of Stellary 2 on Twitter.

Elevation data in A/B Street

A/B Street by @dabreegster is a traffic simulation game exploring how small changes to roads affect cyclists, transit users, pedestrians, and drivers, with support for any city with OpenStreetMap coverage.

In March, elevation data courtesy of Eldan was imported, letting cycling speeds uphill be adjusted. Importing any area from OpenStreetMap can now be done from the UI with no command-line experience, and custom travel demand models based on UK-wide census data can now be generated. Some important simulation fixes for roundabouts improve gridlock, and Michael and Yuwen helped adjust the UI panel layout for smaller screens.

Egregoria city at dawn

Egregoria (GitHub, Discord) by @Uriopass is a simulation oriented city builder that tries to replicate modern society as well as possible.

The 8th devlog was published. Updates include:

  • Multiplayer based on deterministic lockstep
  • Economy revamp inspired by Anno 1800
  • Infinite world using procedural generation
  • Many more QoL features

See also the YouTube summary video of the past 6 months of development.

Gargoyle's Quest

Gargoyle's Quest by @ShamylZakariya is an implementation of level one of the 1990 Gameboy platformer built using wgpu.

Airship Waiting for the airship to land

Veloren is an open world, open-source voxel RPG inspired by Dwarf Fortress and Cube World.

In March, Veloren released 0.9. Lots of work throughout the month was put towards preparing for this. NPC merchants and trading was merged. Many changes were made to combat, including buffs and combat. Player-to-player trading was also implemented. Lots of work was done in optimizing Veloren. This included significantly improving how long physics was talking, and network improvements. Metrics tracking was also overhauled to better track the different systems in Veloren. Pathfinding is also working through an overhaul. A large feature implemented in March was Airships being merged into the game. This prompted a redo of how physics in the game is handled.

A survey was sent out in preparation for the release. A lot of information was gathered about how players experience Veloren, and the items they like or don't like. These can all be ready in devblog #112. This was followed up by the 0.9 release, which turned out to be the largest yet. At peak, 133 players joined the main server. There were problems throughout the release party relating to networking, as well as our tick performance.

March's full weekly devlogs: "This Week In Veloren...": #109, #110, #111, #112. #113.

Enemy Formations Enemies can now be easily spawned in formations

Theta Wave is an open-source space shooter game by developers @micah_tigley and @carlosupina. It is one of the showcase games for the Amethyst Engine. In the past month, the "Foundations" update was released which included numerous refactors that improved the accessibility of contributing to the game.

They are now working on the "Formations" update which will organize how waves of enemies are spawned into the game.

Notable changes:

  • Formations can be defined in a data file
  • New InvasionFormation phase where formations of enemies are spawned from a pool of formations

harvest_hero_level

Harvest Hero by @bombfuse is an arcade/roguelite where you whack Groobles.

Harvest Hero has undergone a large change, migrating from semi-randomly generated levels to handcrafted levels that are randomly selected throughout your playthrough.

This means using Ogmo to design levels, and using nano-ogmo to import them.

Built on top of Emerald.

Updates:

Discussions: Discord, Twitter

Station Iapetus Youtube Check gameplay video on YouTube

Station Iapetus by @mrDIMAS is a 3rd person shooter on the prison Iapetus near the Saturn.

  • Inventory fixes and improvements
  • Splash damage for grenades
  • Weapon recoil
  • More items
  • Bots now hear player
  • More assets
  • First level improvements
  • Procedural animation of impact for bots
  • More sounds
  • Separate scene for menu with music
  • Pause game when in menu
  • More switches in options menu
  • Turrets

Mars with a RdBu colormap Mars heightmap with a RdBu colormap rendered with Aladin Lite v3

Aladin Lite is a spatial image survey visualizer developed by the Astronomical Observatory of Strasbourg in France. Since its first release in 2013, Aladin Lite has been used by astronomers as well as amateurs that are curious about exploring the sky.

Originally developed using 2D Javascript canvas, its core has been fully rewritten in Rust and WebGL2 using wasm-bindgen. New features include:

  • The support of multiple allsky projections (mercator, aitoff, ...)
  • The blending of multiple surveys
  • The support of FITS file images

For more information, see a talk done at the ADASS 2020 conference. A web page is also available here for you to test. You are also very welcolme to contribute to the project by e.g. posting issues on our github.

"Portal in portal" scene "Portal in portal" scene

Portal Explorer by @optozorax is a web visualizator of mind-blowing portals.

In Portal Explorer you can view how interesting portals are constructed, and visually explore their properties by moving and rotating them. This program doesn't work well on mobile, better opened from PC. The most interesting scene is portal in portal.

Created using ray-tracing in shaders, engine is macroquad, interface is egui.

Engine Updates

Tetra is a simple 2D game framework, inspired by XNA, Love2D, and Raylib. This month, versions 0.6.1 and 0.6.2 were released, featuring:

  • Support for blend modes and premultiplied alpha
  • Scissor rectangles (useful for UI rendering)
  • Word wrapping for text
  • More events and methods for tracking/controlling the window's state
  • Bugfixes and docs improvements

For more details, see the changelog.

Additionally, a template repository has been created, demonstrating some useful patterns for structuring a Tetra project.

Current state of starframe graphics and physics

Starframe by @moletrooper is a work-in-progress game engine for physics-y sidescrolling 2D games.

This month, its physics engine was revamped once more (for the last time, hopefully), implementing a modern solver method called Extended Position-Based Dynamics. Also, a blog post was published, covering the development of the physics engine so far in a great deal of mathematical detail.

Discussions: twitter (physics update), twitter (blog post)

Emerald

emerald_logo

Emerald by @bombfuse is a 2D game engine focused on being as portable as possible.

The ultimate goal of Emerald is to be a fully featured engine that you can slap onto any device with relative ease. It's currently able to run on WASM, Raspberry Pi, Mac, Windows, and Linux thanks to miniquad.

Features:

New Updates:

rg3d Youtube

rg3d (Discord, Twitter) is a game engine that aims to be easy to use and provide a large set of out-of-box features. Some of the recent updates:

  • Context menus and tooltips (huge thanks to MinusGix)
  • Performance improvements for UI
  • Parallax Mapping
  • Ability to enable/disable scenes
  • Expansion strategies for TreeView
  • LOD system fixes
  • Graphical fixes
  • First version of engine's architecture overview
  • Various bug fixes and small improvements

Editor updates:

  • Ability to edit collision groups and mask for colliders
  • Ability to clear command stack
  • Ability to change render path for meshes
  • LOD editor
  • "Collapse All", "Expand All", "Locate Selection" buttons for world outliner
  • "Fit Collider" feature fixes
  • Picking fixes
  • Change selection when paste from clipboard
  • "Slow" and "Fast" camera movement modifiers
  • Navmesh selection fixes
  • Simple TBN visualizer
  • Parallax mapping switch in settings

Learning Material Updates

The Unofficial Bevy Cheatbook by @jamadazi is a practical reference book for the Bevy Game Engine. It teaches programming patterns, features, and solutions to common problems. Written to be concise and easy to learn from.

The book recently got a major overhaul for the big new Bevy 0.5 release. Many pages were expanded or rewritten, new content added, and community feedback addressed.

If you are interested in Bevy, this book is now one of the most detailed learning resources. Have fun making cool things with Bevy!

NES Tetris with Hard Drop and Ghost Piece NES Tetris with Hard Drop and Ghost Piece

A blog post describing the process of reverse-engineering the rendering and input-handling logic in the NES version of Tetris, and using a rust embedded domain-specific language to make a patching tool that generates code (6502 machine code) to add hard drop (instantly dropping the current piece) and to render a ghost piece (the dotted outline showing where the current piece will land).

The patching tool uses the crate mos6502_assembler to specify 6502 assembly in rust and generate machine code. Many of the reverse-engineering experiments were done using this rust NES emulator. The result is available as an IPS Patch.

Discussions: Hacker News, /r/rust

Bevy game template by @nikl_me is a template repository for a Bevy game.

The goal is to present a possible structure for Bevy games and at the same time reduce the amount of copy paste when starting a new project. The repository includes a GitHub workflow for Linux, MacOS, and Windows builds (WASM will be supported soon) and comes with a small, opinionated example game.

@kettlecorn wrote a beginner-friendly tutorial that dives into the inner workings of the Entity-Component-System pattern. The tutorial walks through a minimalist ECS implementatation to illustrate how the pattern works, and why it's useful.

Discussion: /r/rust

Library & Tooling Updates

kira by @tesselode is a game audio library tailored to composers and other people who need expressive audio.

v0.5.0 was released with mixer send tracks, new effects, and playback position tracking for instances, as well as a variety of smaller improvements.

Discussions: /r/rust, Twitter

pixel-perfect-collision-demo Pixel-perfect collision example

Bevy Retro is a new Bevy plugin designed for making pixel-perfect games.

This project was released under the Katharos License. This license has moral and ethical implications that you may or may not agree with, so please read it before making use of this project.

Bevy Retro features:

  • Web and desktop support out of the box
    • It even runs in Safari on iOS!
  • Integer pixel coordinates
    • No need to round floats to keep pixels aligned!
  • Support for sprites, sprite sheets and animations
  • A super simple hierarchy system
  • A custom, scaled, pixel-perfect renderer with three camera modes: fixed width, fixed height, and letter-boxed
  • An LDtk map loading plugin
  • Pixel-perfect collision detection
  • Support for post-processing effects using custom shaders or the built-in CRT filter
  • Support for custom pixel aspect ratios

Discussions: GitHub

planck logo

Planck ECS (GitHub, Blog, Patreon) by @jojolepro is a brand new minimalist and safe ECS library.

The 1.0 release happened in the past month, featuring: various fixes, quality of life improvements, removal of unsafe code and completion of tests and documentation.

The library is currently considered completed, which means that all planned features are implemented, tested and benchmarked. Future updates will focus on performance improvements and usability improvements.

Planck ECS is also used in Shotcaller which is featured in this newsletter too.

You can read more about the library on the Blog and on GitHub.

Discussions: /r/rust, Discord: jojolepro#8057

voxel bunny on wgpu Voxel Bunny rendering with conservative rasterization

wgpu is a WebGPU implementation in Rust. It is safe, efficient, and portable: can target both native (Vulkan/D3D/Metal) and the Web.

Most progress in April was focused around WGSL shaders and validation. naga has seen a lot of improvements in the SPIR-V and WGSL parsing, as well as backend code generation. Most importantly, it now fully validates both statements and expressions. No more accidental foot shots from adding vec2 and vec3 in the shaders!

The last and the biggest (in terms of shader complexity) example - "water" has been successfully ported to WGSL 🎉.

A small addition to our native-only features - conservative rasterization feature - was added by @wumpf and demonstrated on a voxel bunny 🐇

Finally, there is a blog post on Mozilla graphics team blog about the progress using wgpu in Gecko.

Discussions: /r/rust_gamedev

rafx tilemap rendering Rafx rendering an example tilemap from LDTK level editor

Rafx is a multi-backend renderer that optionally integrates with the distill asset pipeline. This month, we introduced a fourth layer to the library, rafx-renderer. It provides a plugin system, simplifying framework setup in a project.

The demo now includes a tilemap renderer that integrates with the LDTK level editor. The distill integration processes the level files offline for very efficient loading/rendering at runtime.

Sprite rendering in general is also much faster now. Scenes with 40k-100k sprites can render at 60fps (measured on M1 mini) depending on transparency/distinct Z values in the scene. New examples demonstrate tilemap and sprite rendering.

Early work was also done to reuse descriptor sets across frames and reduce dynamic memory allocation when working with descriptor sets. Rafx also includes more options for HDR tonemapping.

rkyv is a zero-copy deserialization framework for Rust. It's similar to FlatBuffers and Cap'n Proto and can be used for data storage and messaging.

A benchmark was put together to compare rkyv against other leading serialization solutions and gather feedback and use cases for development. A summary and analysis of the results is also available.

Version 0.5 is hot off the presses and rolls up features from the 0.4 development cycle:

  • Derive macros can now implement PartialEq and PartialOrd between archived and unarchived types
  • Custom type bounds for serialization and deserialization can be added with derive attributes
  • Helper types like AlignedVec and Infallible were introduced to improve ergonomics
  • const_generics are now enabled by default
  • Helper functions have been added to make getting root objects easier
  • Several bugfixes and performance improvements

A feedback issue is still open for providing feedback on further development.

whattheframe gui

WhatTheFrame by @JMS55 is a frame-based cpu profiler crate along with a GTK (gtk4-rs) based GUI.

This project aims to answer the question: Which frames of my game are slow, and why?

It aims to be simple to use, consisting of only 3 functions: Call let _r = Profiler::new_frame() at the start of each frame, let _r = Profiler::new_task("task_name") whenever you want to profile a task, and finally Profiler::end_profiling() once at the end.

You can then open the resulting .wtf profile in the GUI and analyze the results.

This month was spent designing and implementing both the GUI and profiler crate. The core functionality of both programs are complete, and all that remains is cleanup, tweaks, optimization, and finally packaging the GUI up.

Bitmapflow interpolating a walking mech animation Bitmapflow interpolating a walking mech animation

Bitmapflow (GitHub) by @bauxitedev is a tool to help you generate inbetweens for animated sprites. In other words, it makes your animations smoother. It uses optical flow to try to guess how the pixels move between frames, and blends them accordingly. The results are far from perfect, and probably require some editing by hand afterwards, but it can produce decent results.

It supports loading and saving animated gifs, spritesheets and individual frames.

The tool is written using godot-rust and executables are available for Windows, although Linux support will be coming soon. (If you compile the program from source, it already works on Linux.)

A full demonstration and walkthrough of the program is available on YouTube.

You can try it out yourself on itch.io.

Discussions: /r/rust_gamedev

femtovg

FemtoVG is a 2D canvas like vector graphics library based on nanovg that has been previously featured in this newsletter.

This month, the FemtoVG team has implemented a new rendering backend based on the wgpu framework. This work is being done in this fork of FemtoVG and will be merged into the main repo soon. The team is currently looking for users to try out the new backend and provide feedback.

Join the FemtoVG Discord channel.

Code example of usage of this library. Code example of usage of this library.

egui-macroquad is a small library to use egui inside of macroquad. It consists only of two functions.

Popular Workgroup Issues in Github

Meeting Minutes

See all meeting issues including full text notes or join the next meeting.

Requests for Contribution

Jobs

Bonus


That's all news for today, thanks for reading!

Want something mentioned in the next newsletter? Send us a pull request.

Also, subscribe to @rust_gamedev on Twitter or /r/rust_gamedev subreddit if you want to receive fresh news!