This Week In Veloren 123

4 minute read07 June 2021

Authored by AngelOnFira

This week, everything is wrapping up before the code freeze for 0.10. We hear about some physics changes, and other technical stuff.

- AngelOnFira, TWiV Editor

Contributor Work

Thanks to this week's contributors, @xMAC94x, @aweinstock, @Christof, @imbris, @Slipped, @Pfau, @Snowram, @Sam, @hqurve, @backyard_tourist, @XVar, @tygyh, @Capucho, @juliancoffee, @Yusdacra, @Sharp, @Synis, @zesterer!

This week, lots of work was done in preparation for the 0.10 code freeze. This is the last stretch before the full release on the 12th at 18:00 GMT. Make sure to join the release party, as we're super excited to celebrate what we've been working on! We recently hit 2000 merged MRs on GitLab, which is made up of 8500+ commits and 280k+ lines of code.

@Sam reworked the tidal warrior and yeti, the bosses in tier 1 and 2 dungeons. @Capucho fixed a VRAM leak and some other graphics-related panics from after wgpu was merged. @Vechro worked on a slight website redesign, which is going to be pretty hard to miss if the MR gets merged before the next blog post. @Slipped has continued to work on the armor/meat branch merged and after working out initial bugs people seem to mostly like it.

Hot-reloading by @juliancoffee

I created asset_tweak module in common/assets to allow developers to tweak values while running the game which don't yet have RON files. To use it you need to compile game with asset_tweak feature (it's not a default feature because we don't want it used it production code) by adding --features asset_tweak to any command you use to compile game. For example (cargo run --features asset_tweak).

Example of usage:

Consider this code in Body::dimensions():

Body::BipedSmall(_) => Vec3::new(1.0, 0.75, 1.4)

To start hot-reload it, you need to rewrite code above like following:

Body::BipedSmall(_) => {
  let (x, y, z) = assets::asset_tweak::tweak_expect_or_create("biped_small_dim", (1.0, 0.75, 1.4));
  Vec3::new(x, y, z)
}

This will create a file "assets/tweak/biped_small_dim.ron" with following content:

((1.0, 0.75, 1.4))

Note the parentheses around, it's important because it's a tuple. From now you can edit this file and each time game will call Body::dimensions() method, it will use your values.

Voxel minimaps and tornados by @aweinstock

I did more work on the voxel minimaps (which I've blogged about previously) and they're now merged. They can be enabled by setting map_show_voxel_map: true in voxygen's settings.ron.

I also got tornados working again on Snowram's branch once wgpu was merged (which were an edge case since tornados use entities with no meshes, only particles).

Physics changes by @sudoreboot

I've made good progress on the glider controls rework. The character now rotates based on the change in the relative velocity of the glider, which in conjunction with the reworked control logic enables you to perform manoeuvres such as loops and gliding upside-down. The strafe keys are repurposed to affect only roll rather than direction.

The glider now also generates forces even in glider wield state, and you can pitch it up and down before even taking off. This allows you to take the glider out while riding an airship and -- provided it's going fast enough -- start hovering (or get blown off of it if you angle it the right/wrong way).

To implement this I had to do a fair amount of refactoring, which requires more careful code review. For this reason (and the fact that we're past feature freeze) it won't be merged before 0.10. If it ends up getting approved, we may expect this to appear on the live server sometime after this coming release.

A ride through the clouds. See you next week!