Friday, 7 March 2014

GA - Development - Setting Up Scenes

I had some trouble because of earlier workflow on getting my animations in and running at the times I would of liked them too. Which then led to complications with my camera, not controlling them but getting them to switch between one another. So instead I opted to go for a scene a shot, in total 16. Each scene would have the one animation for each character and the camera, and would run automatically to each one, efficient in a tidy sense but more costly on the real time playing.

As you can see for scene there is a separate js file that would wait the amount of animation time the camera took and then jump to the next scene. There are plenty of variables to use, e.g. animation.isPlaying would checked if the animation I chose was playing and I could of used an 'if' statement to say if not then switch to the next scene. But getting the length of animation was a little trickier in js so I decided to manually write them out since I had all the numbers already in front of me.

For some reason the project wasn't jumping to the next when ever I would run the game, however after a few minutes of research I quickly realised and remembered that they need to be added in the build settings to be compiled into the game upon hitting play.

The only final problem I found while testing this (obviously less efficient) method was that, it was loading each scene at the end of the previous, so at the end of each one there would be a slight pause that added at least a few seconds on to the whole play time. This also just gave it a really choppy look, I decided to get more things done and fix it later.

No comments:

Post a Comment