AB.clockTick = 150;
// Speed of run: Step every n milliseconds. Default 100.
AB.maxSteps = 1000;
// Length of run: Maximum length of run in steps. Default 1000.
AB.screenshotStep = 50;
// Take screenshot on this step. (All resources should have finished loading.) Default 50.
//---- global constants: -------------------------------------------------------
const OBJ_SKELETON = '/uploads/starter/skelet.obj' ;
// skeleton credit
// formerly here:
// http://tf3dm.com/3d-model/skeleton-with-organs-91102.html
const OBJPATH = "/uploads/starter/"; // path of OBJ and MTL (Peter Parker model)
const OBJNAME = "Peter_Parker.obj";
const MTLNAME = "Peter_Parker.mtl";
// Peter Parker credit
// formerly here:
// https://free3d.com/3d-model/spider-man-4998.html
// multiply model sizes by some amount:
const SCALE_HERO = 70;
// random size skeleton with each run:
const SCALE_SKELETON = AB.randomFloatAtoB ( 1, 6 );
// const SCALE_SKELETON = 4;
const TEXTURE_MAZE = '/uploads/starter/latin.jpg' ;
const TEXTURE_SKELETON = '/uploads/starter/ghost.3.png' ;
// credits:
// https://commons.wikimedia.org/wiki/Category:Skull_and_crossbone_icons
const MUSIC_BACK = '/uploads/starter/SuspenseStrings.mp3' ;
// music credit
// http://www.dl-sounds.com/royalty-free/suspense-strings/
const gridsize = 30; // number of squares along side of world
const squaresize = 100; // size of square in pixels
const MAXPOS = gridsize * squaresize; // length of one side in pixels
const NOBOXES = Math.trunc ( (gridsize * gridsize) / 15 );
const SKYCOLOR = 0xffffcc; // a number, not a string
const LIGHTCOLOR = 0xffffff ;
const startRadiusConst = MAXPOS * 0.8 ; // distance from centre to start the camera at
const maxRadiusConst = MAXPOS * 5 ; // maximum distance from camera we will render things
// camera on "Move With" should move up/down in y axis as we re-scale objects
// to place the follow camera just above the agent, something like:
const FOLLOW_Y = SCALE_HERO * 4 ;
// to point the camera at skeleton's face, something like:
const LOOKAT_Y = SCALE_SKELETON * 40;
//--- change ABWorld defaults: -------------------------------
ABHandler.MAXCAMERAPOS = maxRadiusConst ;
ABHandler.GROUNDZERO = true; // "ground" exists at altitude zero
//--- skybox: -------------------------------
// urban photographic skyboxes, credit:
// http://opengameart.org/content/urban-skyboxes
const SKYBOX_ARRAY = [
"/uploads/dg/corona_ft.png",
"/uploads/dg/corona_bk.png",
"/uploads/dg/corona_up.png",
"/uploads/dg/corona_dn.png",
"/uploads/dg/corona_rt.png",
"/uploads/dg/corona_lf.png"
];