Ir para o conteúdo principal

2023 Jun: VehicleWater, Smooth Net Sync!

· Leitura de 5 minutos
Gabriel T. Nardy
nanos world developer (SyedMuhammad)

VehicleWater, Smooth Network Sync, CEF Updated, Assets.toml Generator and more!

Tune in for a roundup of the latest updates from June!

New Class: VehicleWater

We are proud to introduce our new Class: VehicleWater! this is still a bare minimum concept class, but with the main feature working: Driving over Water with all the usual Vehicle capabilities!

This new VehicleWater class works like the Vehicle class, supporting adding custom doors, tweaking it's power and having Characters entering doors and attaching to a specific position for each door. All Vehicle events of characters entering/leaving work as well!

VehicleWater concept class piloting

It procedurally generates the physics pontoons needed to float properly over the Water!

VehicleWater concept class piloting interacting with waves

I still want to keep improving this new Class, as well add new animations to the Character. I also did some tests integrating Unreal's Water foaming but it required a lot of hacky solutions that weren't scalable, this is something I will keep working on to try to bring the best visuals as possible!

Please provide us feedback and suggestions so we can keep improving and adding new features to this new class!

tip

Wast3d, enjoy 🙏

Renamed Vehicle Class

With the addition of the new VehicleWater Class, we are renaming the old Vehicle class to VehicleWheeled, this way we will open the doors for having multiple types of Vehicles (in the future being able to have Air, Plane, Helicopter vehicles types too).

The scripts using Vehicle just got warnings when using the old Vehicle name.

ADK Assets.toml Generator

With the latest month update of Assets Metadata, we are now able to include custom data for each asset in our Asset Pack.

So we improved our ADK's Assets.toml Generator to also optionally include the Bounds information for all Static Meshes:

[assets.static_meshes]
SM_Cube = { path = "Meshes/SM_Cube", bounds = { origin = "Vector(0.000, 0.000, 0.000)", box_extent = "Vector(50.000, 50.000, 50.000)", sphere_radius = 86.602539 } }

This can be accessed through scripting like (on server side!!):

for _, asset in pairs(Assets.GetStaticMeshes("nanos-world")) do
local bounds = asset.bounds
Console.Log(bounds.origin) -- Vector(0.000, 0.000, 0.000)
Console.Log(bounds.box_extent) -- Vector(50.000, 50.000, 50.000)
Console.Log(bounds.sphere_radius) -- 86.602539
end

Default Assets Category

Also our Default Asset Pack got categorized! A new metadata category was added to most of the built-in assets, and can be get like this:

for _, asset in pairs(Assets.GetStaticMeshes("nanos-world")) do
Console.Log(asset.category) -- e.g. "furniture"
end

This replaces the old way Sandbox was doing to categorize the assets, before having a hardcoded Lua file with all assets in a table pointing to a category, now it supports you creating your custom Asset Pack and add the category MetaData to it to be integrated with the Sandbox convention!

Attached Mesh Bounds

We got some changes on Attached Mesh methods, now they allow defining if it will use parent bounds or not when being attached. They got a new last parameter:

character:AddStaticMeshAttached("hair", "nanos-world::SM_Hair_Long", "hair_male", true)
character:AddSkeletalMeshAttached("tie", "nanos-world::SK_Tie", false)

This fixes some cases when an attached mesh keeps flickering when it is attached to an entity with a smaller/tiny base mesh.

Smoother Network Sync

We got a huge improvement in our netcode related to synchronizing location/rotation snapshots of dynamic actors.

You can notice Props, Pickables and Vehicles are now way more fluid when other players are driving or physically interacting with them!

Updated CEF

We finally managed to update our CEF version to the latest CEF build (114) successfully, we weren't able to do so as it was not working on linux builds due some unknown reason, but finally after almost 1 year without updating, the latest CEF version worked again for Linux users. We are now up to date with the latest optimizations and security builds!

Lots of Bug Fixes

But besides the news, we also had more than 10 significant bugs fixes and small improvements that have been made.

Just to mention a few:

  • Server side Pickables not returning the real location if are being handled.
  • Server side crashes.
  • Random High Ticks on server due heavy load.
  • JSON parser not converting keys properly
  • CEF JSON parser not converting to lua arrays properly.
  • Multiple Player Spawn event.
  • Character Physical animation not resetting.
  • And more...

Check the complete list on our Discord's Changelog channel!

Conclusion

This was a shorter news blog than the usual as last month I've moved to a new apartment and that resulted in less time focused, but now things are getting back to normal again! 😎

This VehicleWater Update was something I had been working already for some time at a slow pace, some months ago I've refactored all the systems internally related to Vehicles and Characters interaction to allow more vehicle child types and leave the interaction of "Character" entities with all "Vehicles" more generically and this allowed us to create a new Vehicle class just for Water in a modular way!

Also I will try to dedicate some time to upgrade our Unreal version to the latest UE 5.2, now that Epic released the first hotfix we may be more stable to do that!

Thank you for your time for this another month, your support is immensely important as always!