extension-rive icon indicating copy to clipboard operation
extension-rive copied to clipboard

Bones game object mappings are lost when a state machine is running

Open totebo opened this issue 1 year ago • 2 comments

Using rive.get_go() works on a Rive model only when no state machine is running. Once the state machine is started, two things happen:

  1. Any game objects that were attached to bones lose their parent and are repositioned within the scene.
  2. Using rive.get_go() now crashes, or returns ERROR:SCRIPT: main/main.script:19: the bone 'left_hand' could not be found.

Minimal project (including .rev file so the scene can be opened in Rive): BoneToGameobject.zip

--

Rive extension 3.6.0 Defold 1.9.6 macOS 14.6.1 (Sonoma)

totebo avatar Dec 18 '24 11:12 totebo

Video below. Expected behaviour is that the food stays attached to the left hand bone.

Once the state machine starts, the fruit gets removed for some reason.

https://github.com/user-attachments/assets/385096a5-56ca-4378-91dd-5f5c8d54fb20

totebo avatar Dec 18 '24 11:12 totebo

After a bit of more digging, it looks like all bones move to 0,0 (top left) of the art board when the state machine starts.

totebo avatar Dec 20 '24 15:12 totebo