Code viewer for World: New World
 
	
	AB.world.newRun = function()
	{
		// Code for Three.js initial drawing of objects.
		// Should include one of:
	 	// ABWorld.init2d ( arguments ); 	
	 	// ABWorld.init3d ( arguments ); 	
	};


	AB.world.nextStep = function()		 
	{
		// Code for Three.js re-drawing of objects.  		
	};


	AB.world.endRun = function()
	{
	};





function initSkybox() 
{

// x,y,z positive and negative faces have to be in certain order in the array 

  var materialArray = [
 	( new THREE.MeshBasicMaterial ( { map: THREE.ImageUtils.loadTexture( "/uploads/dg/corona_ft.png" ), side: THREE.BackSide } ) ),
 	( new THREE.MeshBasicMaterial ( { map: THREE.ImageUtils.loadTexture( "/uploads/dg/corona_bk.png" ), side: THREE.BackSide } ) ),
 	( new THREE.MeshBasicMaterial ( { map: THREE.ImageUtils.loadTexture( "/uploads/dg/corona_up.png" ), side: THREE.BackSide } ) ),
 	( new THREE.MeshBasicMaterial ( { map: THREE.ImageUtils.loadTexture( "/uploads/dg/corona_dn.png" ), side: THREE.BackSide } ) ),
 	( new THREE.MeshBasicMaterial ( { map: THREE.ImageUtils.loadTexture( "/uploads/dg/corona_rt.png" ), side: THREE.BackSide } ) ),
 	( new THREE.MeshBasicMaterial ( { map: THREE.ImageUtils.loadTexture( "/uploads/dg/corona_lf.png" ), side: THREE.BackSide } ) )
 	];

  var skyGeometry = new THREE.CubeGeometry ( skyboxConst, skyboxConst, skyboxConst );	
  var skyMaterial = new THREE.MeshFaceMaterial ( materialArray );
  var theskybox = new THREE.Mesh ( skyGeometry, skyMaterial );
  threeworld.scene.add( theskybox );						// We are inside a giant Cube
}