mirror of
https://github.com/storytold/storyteller-bevy.git
synced 2026-10-20 07:54:50 +00:00
Scene storage backend integration (#51)
This PR adds Storyteller.ai API integration for saving and loading Storyteller Studio scenes to/from the backend. ### Known issues * The skybox is not currently stored in the serialized scene format
This commit is contained in:
+7
-5
@@ -1,6 +1,6 @@
|
||||
use bevy::{app::Update, window::close_on_esc};
|
||||
use clap::Parser;
|
||||
use studio::{screenshot::ScreenShotPlugin, StudioMode, ViewportSize};
|
||||
use studio::{screenshot::ScreenShotPlugin, InitSeed, StudioMode, ViewportSize};
|
||||
|
||||
#[derive(Parser)]
|
||||
#[command(name = "StorytellerStudio")]
|
||||
@@ -16,13 +16,15 @@ struct StudioArgs {
|
||||
fn main() {
|
||||
let args = StudioArgs::parse();
|
||||
|
||||
let model_path = args.model.unwrap_or("Mannequin.gltf".to_string());
|
||||
let skybox_path = args.skybox.unwrap_or("gum_trees_4k".to_string());
|
||||
let object_id = args.model.unwrap_or("Mannequin.gltf".to_string());
|
||||
let skybox_id = args.skybox.unwrap_or("gum_trees_4k".to_string());
|
||||
|
||||
// Edit the arguments here to change the default startup scene or skybox
|
||||
let mut app = studio::start_internal(
|
||||
model_path.as_str(),
|
||||
skybox_path.as_str(),
|
||||
InitSeed::FromLibrary {
|
||||
object_id,
|
||||
skybox_id,
|
||||
},
|
||||
"", // ignored for non-WASM
|
||||
"Storyteller Studio",
|
||||
ViewportSize::default(),
|
||||
|
||||
Reference in New Issue
Block a user