Skip to content

Instantly share code, notes, and snippets.

@pauginer
Last active January 1, 2016 07:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pauginer/8112127 to your computer and use it in GitHub Desktop.
Save pauginer/8112127 to your computer and use it in GitHub Desktop.
Function for Hype that allows to indicate the initial scene using a hash parameter. For example: http://pauginer.github.io/prototypes/draft-space/draft-creation/index.html#home
//To be added as a Timeline "Run Javascript" action at the very first of the Main timeline (of the first scene).
function jumpToParameterScene(hypeDocument, element, event) {
var hash = window.location.hash;
var sceneName=hash.replace('#','');
hypeDocument.showSceneNamed(sceneName, hypeDocument.kSceneTransitionInstant);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment