-
11 May 2012 11:16 AM #1
Open new URL in same window: going to a specific scene
Open new URL in same window: going to a specific scene
Hi, I want to do the following: Create a link to open new URL upon. Instead of jumping to scene1, want to specify a particular scene to start. (The linked URL page is also created in Animator with multiple scenes) Is there a way to do this? Thx.
-
11 May 2012 4:50 PM #2
Just to verify I am getting it. You want an Animator page that starts a different scene depending on the link?
like
example.com/animator.html?startSceneId=1
example.com/animator.html?startSceneId=2
Here is a quick way to get that done, but you'll have to manually edit the index.html (or js file if you export separately).
Original (inside the setConfig function: ~ line 44 in index.html)
replace withCode:this.startSceneByID(this.scenesArray[0].id);
then you just have to add startSceneId to the back of the link, similar to thisCode:var query = location.search; var result = query.match(/startSceneId=(\d+)/); if (result) { this.startSceneByID(result[1]); } else { this.startSceneByID(this.scenesArray[0].id); }
index.html?startSceneId=0
index.html?startSceneId=1
Where id is the scene id (you can get that by hovering over the scene panel).
Attaching sample file.
-
12 May 2012 10:15 AM #3
It works! Thank you so much Arne. Just made by Animator workflow so much easier.
-
14 May 2012 9:16 AM #4
Is there a way to stop the screen from flickering? When the linked webpage loads, the screen flickers for a moment. It doesn't flicker when navigating within the same URL, it only flickers when jumping from lets say index.html to index2.html. Thx.
-
14 May 2012 3:59 PM #5
The problem seems to be solved in Safari v. 5.1.7 on mac but still exists on same version of safari for Windows. The problem also is highly noticeable in iphone OS 5.1.
-
14 May 2012 4:18 PM #6
There will probably always be some flicker when you are going from one URL to another since you have to load a whole page.
-
16 May 2012 3:12 PM #7
Is there a way to achieve the same thing? I have about 60 scenes as of now and Animator is starting to really slow down and crash alot. I need a way to split the scenes up so I can keep my sanity and help with the performance. I thought by pointing to a different HTML link would solve this, but I have elements that are constant during transition making the "refresh flash" noticeable. Thanks.
-
16 May 2012 4:29 PM #8
Yeah, I am not sure if there is a good way to split it up into several files while not having it flash when loading. If you wouldn't mind, I'd be great if you could give me a copy of the project ( send me a PM ) so I could take a look at some of the performance issues.


Reply With Quote