⇠ More posts

Defold release 1.9.3

By Björn Ritzl on Sep 16, 2024

Tagged as: Release notes


Defold 1.9.3

Summary

  • NEW: (#9298) Bob.jar builds only files from the dependency tree
  • NEW: (#9300) Added engine.max_time_step config value
  • NEW: (#9315) Add documentation for report_progress in http.request
  • NEW: (#9367) Added b2d.get_angular_damping()/b2d.set_angular_damping()
  • NEW: (#9214) Add ‘types’ script module for checking Defold userdata types.
  • NEW: (#9307) Decorate editor build exceptions with error source
  • NEW: (#9353) Notify if a GameObject/Component Id or Collection Name contains a space at the beginning or end.
  • NEW: (#9355) Use naming for bundle folders based on the bundle architecture when bundling from the editor.
  • FIX: (#9269) Support render.enable_material with material(s) that use custom vertex attributes
  • FIX: (#9274) Support turning vsync off for Vulkan
  • FIX: (#9301) Added support for display.update_frequency for headless builds
  • FIX: (#9330) Detect circular dependencies during the build process in Bob
  • FIX: (#9347) Added fix for asynchronous raycast messages
  • FIX: (#9349) Optimized the sprite component size
  • FIX: (#9378) Make the atlas output *.a.texturesetc more deterministic
  • FIX: (#9368) Rebuilt spirv tools for macos 10.15
  • FIX: (#9293) Fix dialog behavior on Linux
  • FIX: (#9277) Fix various issues with slice9 and gui pivots
  • FIX: (#9317) Fix missing animation preview overlay in atlas views
  • FIX: (#9316) Ensure build resource paths for embedded resources always reflect their contents
  • FIX: (#9327) Correctly visualize trimmed sprites with flipped animations
  • FIX: (#9356) Remove the GUI scene itself from the GUI template picking dialog

Engine

NEW: (#9298) Bob.jar builds only files from the dependency tree This fix introduces the building of a dependency tree before the bundling step for Bob.jar—the building and bundling tool for Defold. This helps avoid building all the files in the project folder, as was previously the case. Instead, it builds only the files referenced in the tree that starts from game.project.

NEW: (#9300) Added engine.max_time_step config value In case the engine timestep grows too large, it will be capped against this max value (default is 0.5 seconds)

NEW: (#9315) Add documentation for report_progress in http.request

NEW: (#9367) Added b2d.get_angular_damping()/b2d.set_angular_damping() The two functions had accidentally been left out of the api.

NEW: (#9214) Add ‘types’ script module for checking Defold userdata types. Changes added new Lua module ‘types’ which contains utility function to check Defold userdata type like vector, vector3, matrix, quaternion, etc. Module can be excluded via AppManifest.

Usage example:

    local url = msg.url("main_collection", "/hero", "right_hand")
    print(types.is_url(url)) ----> true

    local long_vector = vmath.vector({ 10, 14, 19, -20, -11, -2, 132 })
    print(types.is_vector(long_vector)) --------> true

    local non_empty_vector3 = vmath.vector3(13, 14.5, -7)
    print(types.is_vector3(non_empty_vector3)) ------> true

    local non_empty_matrix = vmath.matrix4_translation(non_empty_vector3)
    print(types.is_matrix4(non_empty_matrix)) -----> true

    local non_empty_quat = vmath.quat(1, 2, 3, 4)
    print(types.is_quat(non_empty_quat)) ------> true

    local test_hash = hash("some_foo_text")
    print(types.is_hash(test_hash))  --- ---> true

    print(not types.is_vector(non_empty_vector3))   ------> false
    print(not types.is_vector(nil))   ------> false
    print(not types.is_vector3(non_empty_matrix))   ------> false
    print(not types.is_quat(non_empty_vector3))   ------> false
    print(not types.is_url(long_vector))   ------> false
    print(not types.is_matrix4(test_hash))   ------> false

FIX: (#9269) Support render.enable_material with material(s) that use custom vertex attributes Components didn’t produce custom vertex attributes when a “context material” is set using render.enable_material(..) together with a material that has custom vertex attributes.

FIX: (#9274) Support turning vsync off for Vulkan Vulkan can now turn vsync off by setting the swap interval of the game.project file to zero. Note that there is no actual concept of swap intervals built-in by Vulkan, hence this value simply turns vsync on or off. To fully support swap intervals other than these values, we need to manually wait for vblanks, which is currently not planned.

FIX: (#9301) Added support for display.update_frequency for headless builds This allows for control of the headless builds where no graphics backend is present. Can be turned off using the setting display.update_frequency = 0

Fixes: https://github.com/defold/defold/issues/8029

FIX: (#9330) Detect circular dependencies during the build process in Bob Before this fix, it was possible to bundle a project with circular dependencies, which would result in a runtime crash. Now, Bob detects such cases and reports them during the build process:

Circular dependency detected:
main.lua class com.dynamo.bob.pipeline.ScriptBuilders$LuaScriptBuilder
-> first.lua class com.dynamo.bob.pipeline.ScriptBuilders$LuaScriptBuilder (Circular Point)
second.lua class com.dynamo.bob.pipeline.ScriptBuilders$LuaScriptBuilder
third.lua class com.dynamo.bob.pipeline.ScriptBuilders$LuaScriptBuilder
-> first.lua class com.dynamo.bob.pipeline.ScriptBuilders$LuaScriptBuilder (Circular Point)'

FIX: (#9347) Added fix for asynchronous raycast messages This fixes a rare crash where lingering raycast messages were handled the exact frame when the collection was freed.

FIX: (#9349) Optimized the sprite component size The size is now 256 bytes (previously 272). Example with 896 sprites was 288kb and became 256kb.

FIX: (#9378) Make the atlas output *.a.texturec more deterministic Fixes the issue where changing the order of images in an atlas without altering any content results in a different *.a.texturesetc file.

FIX: (#9368) Rebuilt spirv tools for macos 10.15 This fixes an issue on macOS 10 or 11, where shaders weren’t built properly.

Editor

NEW: (#9307) Decorate editor build exceptions with error source Exceptions thrown from building the project in the editor will now contain information about the source of the error for diagnostic purposes.

NEW: (#9353) Notify if a GameObject/Component Id or Collection Name contains a space at the beginning or end. It may be hard to notice if a GameObject or component ID contains a space symbol at the beginning or end. With this fix, a warning will be shown in the editor.

NEW: (#9355) Use naming for bundle folders based on the bundle architecture when bundling from the editor. The editor will create a folder based on the architecture selected in the bundle dialog. For example, for macOS:

  • x86_64-macos
  • arm64-macos
  • universal-macos (if both architectures are selected)

FIX: (#9293) Fix dialog behavior on Linux

FIX: (#9277) Fix various issues with slice9 and gui pivots

  • The slice-9 setting will now be correctly visualized in the editor viewport in all scenarios.
  • Gui pivot offsets are now correctly visualized in the editor viewport in all scenarios.
  • You can no longer select “Polygons” as a Sprite Trim Mode for an atlas image, which would previously throw an exception.

FIX: (#9317) Fix missing animation preview overlay in atlas views The animation preview overlay is now visible again in atlas views.

FIX: (#9316) Ensure build resource paths for embedded resources always reflect their contents Referencing a .wav or .ogg file directly as a component from a game object embedded in a collection no longer throws an exception when building the project.

FIX: (#9327) Correctly visualize trimmed sprites with flipped animations The editor now correctly renders sprites and GUI nodes with flipped animations in the scene view.

FIX: (#9356) Remove the GUI scene itself from the GUI template picking dialog Picking the GUI as a template for itself results in the editor freezing. This fix hides the GUI scene from the GUI template picking dialog.