Rive support - Alpha testing

Hi everyone!

It’s finally time to share our progress with the support for Rive app animation files.

We’d be happy to receive some feedback from our users regarding usability and performance etc.

Note that this is an alpha version, and there are features left to implement.
Also note that sometimes the stability might suffer a bit as well.

Scripting api:

There really isn’t much of an api yet. Currently, there is

  • rive.play_anim()
  • rive.play_state_machine() (added 2021-09-07)
  • rive.cancel()
  • rive.get_go() (added 2021-09-01)

The api is decsribed in in more detail by our auto complete docs. (added 2021-09-07)

Since the full documentation isn’t done yet, the best place to learn about the api is here
and in the actual implementation here script_rive.cpp

How to use it:

  • Download the alpha version of the editor here
    (Note that using an alpha version may exhibit unstable behavior. Always back up your work files!)

  • Use the beta build server: https://build-stage.defold.com (it’s going live on monday)

  • Download the extension-rive

  • Start a build with “Build and Run” in the editor

Notes and known issues:

  • No GUI support (yet)

  • No good editor preview of the rive scenes. They only display a white bounding box.

(We have an experimental branch rive-vertices that shows a slightly better preview, but it’s also currently a bit unstable)

  • Gradients aren’t implemented yet (currently being worked on)

  • Path strokes aren’t implemented yet

  • Missing documentation. Not only for the rive extension, but also for all the new api’s we’ve added during the last couple of months.

  • Long build times. We will add prebuilt libraries later on (should also fix the iOS build)

  • Rive features: Bones support, events, state machines etc (the Rive team add lots of new features fast!)

Engine support/performance:

  • macOS: Builds. Good performance
  • Win32: Builds. Good performance.
  • HTML5: Builds. Performance: Safari - Good, Firefox - Poor, Chrome - Poor
  • Android: Builds. Good performance
  • iOS: Builds. Good performance.
  • Linux: Builds. Runs (performance?). Editor preview seems to fail on my VM.

With that said, we hope to get some good feedback and also see some fun screenshots from our users!

Have a good weekend!

(Here’s what the extension-rive test app looks like:


Opening the extension on Linux causes the editor to crash with this error:

./packages/jdk11.0.1-p1/bin/java: symbol lookup error: /home/potota/Downloads/extension-rive-main/build/plugins/defold-rive/plugins/lib/x86_64-linux/libRiveExt.so: undefined symbol: _ZN11dmArrayUtil11SetCapacityEjjPmS0_S0_

I really need to fix so that the editor doesn’t shut down on exceptions from the plugin.

I’ll look into the missing symbol tomorrow!


Performance is good for me on Windows 10.

Are anti-aliasing options planned?

When trying to build HTML5 from the editor this happens every time.

	<head><title>504 Gateway Time-out</title></head>
	<center><h1>504 Gateway Time-out</h1></center>

Thanks for testing! I’ve updated the status table.

I’ll have to refer to @jhonny.goransson for more info about what type of anti aliasing we’ll implement.

Yeah, the html5 builds took a looong time for me, and I’m slightly closer to the server in Ireland. I’ll make sure to start the task of having precompiled rive libraries added instead of source code.


I’ve updated the main branch of the extension, and it now uses prebuilt rive-cpp libraries (which will save a lot of time for everyone). E.g. it will avoid a timeout when building for HTML5.

Also, the iOS version now builds and runs as expected.

I’m looking into the Linux issues right now.



Well, I had to check this alpha build :slight_smile: I don’t have much time, so I just tried to replace the Rive asset in the example project with my own one, and it works (Windows 10)!

Soon I’ll start building my next game with Defold and Rive, awesome :slight_smile:


Hi @Dawid_Wnukowski !
Thanks for testing!


I’ve updated the Linux plugins for the extension.
So I can now open the extension, and press “Build and run”, and the example runs.

It’s quite slow on my VM, but I suspect that’s the same issue I had on the Windows VM.

The editor preview however doesn’t currently preview the scene (not even a white bounding box) due to a shader error. I’m currently looking into that. EDIT: It might be an unrelated shader error that shows up on my VM.

@Potota would you mind testing the performance on your machine?


It actually runs too fast on my 144hz monitor (known issue), but other than that it looks good!


Thanks for testing!
What if you open e.g. test.rivemodel, will it draw a white box for you?


Yep, all scenes and models show up as white boxes.


We’ve added rive.get_go(name) (same as for Spine), in order to get the a bone game object. You can see an example in bones.collection in the example app.


I’m quite curious if, after the initial implementation, it will be possible to use the rive vector render, to render simple shapes via code (like rounded boxes and other shapes) ?


Interesting thought. It’s not something we’ve considered, and currently the implementation is a bit r’n’d so we’ll see where we land in this.

1 Like

Updated info with rive.play_state_machine()
It’s now possible to select a state machine from the editor, or play it from script.

For state machine inputs, you have access to go.set() (and go.get()).
Example here

Here’s the same example (statemachine.collection) as a gif:


I tried to give the extension a try, but Defold is ending process, whenever I try to open a project with Rive data - either a project downloaded from extension repository or a totally new project, where I try just to import Rive model. It just closes Defold, no error pops up or anything. Windows laptop.

Also I would have a question - would I be able to use Rive animations in GUI?

As always, we recommend adding an issue on the repository in question, with a small repro case and repro steps.

As for Rive in Gui, yes that is the long term goal too.


I can’t prepare a repro of this :confused: I tried today on Ubuntu and downloaded the newest alpha (1.3.3) for Linux and extension-rive-main, but the same - I open Defold, select to open game.project from extension-rive-main and it starts to load, but then abruptly closes, before the Editor is opened.

1 Like

Ok, please create a ticket on GitHub in the extension-rive repo!

1 Like