From the course: AR for iOS Developers: RealityKit and Reality Composer

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Trigger Reality Composer actions in code

Trigger Reality Composer actions in code - iOS Tutorial

From the course: AR for iOS Developers: RealityKit and Reality Composer

Start my 1-month free trial

Trigger Reality Composer actions in code

- In the last video, we handled a user action based on a trigger, that came from something that we defined in Reality Composer. Now what we'd like to try is to trigger something in code, and indeed trigger an animation that is defined in Reality Composer. Therefore, let's open up our Reality Composer file experience here one more time. And let's again switch to our sun. And let's close down the Properties panel here, close down the Scenes, open up Behaviors. And here we have our showInfo behavior that I already showed to you earlier, and promised that we would talk about this again. Here, as for our action sequence, what is happening here are two things. First, we're hiding our sun text and then we are displaying the mass information that we have in the background. If we play this can see the sun text is disappearing and mass is appearing. And this is something that we'd like to trigger in code once our…

Contents