Sample
Instantiation without the createExperience factory
Adways builds the player and the interactivity from the publication informations (media and player used in the Adways studio)
<div style="width: 560px; height: 315px; background-color: black; overflow: visible;" id="adways-interactive"></div> <script type="text/javascript" src="//dj5ag5n6bpdxo.cloudfront.net/libs/interactive/loader.js"></script> <script type="text/javascript"> var experience = new adways.interactive.Experience(); experience.setPublicationID("mpNHyTH"); experience.setPlayerContainer("adways-interactive"); experience.load(); </script>
Same instantiation without the load() method:
<script type="text/javascript"> var experience = new adways.interactive.Experience(); experience.setPublicationID("mpNHyTH"); experience.setPlayerContainer("adways-interactive"); experience.addEventListener(adways.interactive.Experience.Event.PUBLICATION_JSON_CHANGED, function(){ if (experience.getPublicationJSON()!=null) { experience.buildPlayer(); experience.buildScene(); } }); experience.addEventListener(adways.interactive.Experience.Event.PLAYER_STATE_CHANGED, function(){ if (experience.getPlayerState().valueOf()==adways.interactive.Experience.playerStates.BUILT) { experience.buildDelegate(); } }); experience.requestPublicationJSON(); </script>