if (this.parentEntity === data.entity) { console.log('Entity Impact Test Loaded'); } else { return; } if (!this.initialized) { this.initialized = true; } ig.module( 'game.impact-test' ) .requires( 'impact.font', 'impact.game', 'impact.image', 'game.levels.snake' ) .defines(function(){ // code for this module // Create your own game class ig.global.Snake = ig.Game.extend( { font: new ig.Font( 'media/04b03.font.png' ), init: function() { console.log('init called'); // initialize your game world, bind some // keys, etc. //ig.input.bind( ig.KEY.SPACE, 'jump' ); ig.System.drawMode = ig.System.SCALE.CRISP; this.loadLevel( LevelSnake ); }, draw : function() { this.parent(); } } ); R3.Event.Subscribe( R3.Event.GAME_START, function(data) { var size = R3.Utils.GetWindowSize(); ig.main('1cvwv04mfw', Snake, 60, 720, 1280, 1 ); } ); R3.Event.Emit(R3.Event.GAME_LOADED); }); //@ sourceURL=entityLoaded.js