Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Accessing state machine of nested artboard #188

Open
annarack opened this issue Jul 4, 2023 · 4 comments
Open

Accessing state machine of nested artboard #188

annarack opened this issue Jul 4, 2023 · 4 comments
Labels

Comments

@annarack
Copy link

annarack commented Jul 4, 2023

Hello! :)

Short background on what I'm working on:
I have a multiscreen setup on a wall where each monitor is attached to a single computer. The idea is to have a dynamic background animation that spans over all those monitors. Since I would love to have that dynamic with different triggerable transitions I'm currently looking into rive. Fallback option will be a video solution but then I loose the dynamic interaction/transitions...

Definitely love how easy it is to create animations and build state machines with rive! Current problem tho is:
I went the path of creating one big artboard that contains the different background animations for the whole wall. Also a state machine with different layers. Idea was to have an artboard for each screen that shows a specific area of the full composition, that I can export then. I used the full animation composition (scaled and moved to correct area) as a nested artboard for that. The only thing now is, that I need access to the state machine of the nested artboard. Didn't manage to do so in the app and haven't found a way programmatically yet.

Is this too much of a special case, or is that possible somehow?

@github-actions github-actions bot added the triage label Jul 4, 2023
@zplata
Copy link
Contributor

zplata commented Jul 19, 2023

Hey @annarack - there isn't a way yet to set nested state machine inputs, but it is definitely on the roadmap!

@ascholz81
Copy link

Any update on this roadmap item? I have a site with nested artboards and events that I need to listen to in rive-react.
I am only able to get events from the default state machine, even though I provide the Rive hook all the state machine names.

@skittlesaur
Copy link

Any update on this? I have exposed the input to its parent, but I can’t find a way to update this input programmatically.

CleanShot 2024-07-02 at 09 02 05@2x

@woro83c
Copy link

woro83c commented Aug 8, 2024

my workaround to this was to:

  1. create new timelines in the parent consisting of the state machine / timeline of the nested artboard you want to control
  2. add these as states to your parent state machine
  3. recreate the inputs you need for transitioning between these states
  4. for each transition that needs to trigger a nested input, fire a custom event
  5. set up a listener in your parent state machine to listen to this event
  6. have the listener fire the state machine input on the nested arboard

hopefully that makes sense.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants