//============================================================================================
// Pluto Strikes Back! Start-up file
//--------------------------------------------------------------------------------------------
// 
//
// Created xx.xx.xxxx by Pete
//
// 
// Window( width, height, bpp, fullscreen, resizable, name, icon_path, frames )
//
//    width:		Screen width in pixels
//    height:	Screen height in pixels
//    bpp:		Screen bits per pixel ( 8, 16, 32 )
//    fullscreen:	Is fullscreen in use or not ( 0 = not, 1 = yes )
//    resizable:	Is the window resizable or not ( not in fullscreen ) ( 0 = not, 1 = yes )
//    name:	The name of the window
//    icon_path:	Path of the icon
//    frames:	Does the window have frames or not ( 0 = not, 1 = yes ) default = yes
//


TaskLoad( "sdl" );
TaskLoad( "sdl_mixer" );

StartTask( "window", Window, 10, 800, 600, 0, 0, 0, "Pluto Strikes Back - release 1.5", "data/gfx/ikoni.bmp", 1 );
StartTask( "event", Event );
StartTask( "mouse", Mouse );

Mouse::CursorChangeTo( "cursor_busy" );
Mouse::CaptureInput( 1 );

StartTask( "audio", Audio );
StartTask( "gfx", Gfx, 1000 );
StartTask( "ui", Ui, 100 );

gfx_flip_rects_size = 75;

// StartTask( "gfxtest", GfxTest );
//............................................................................................

StartTask( "game", Game, "data/level_list.xml" );
StartTask( "unittest", Unittest );

//............................................................................................

StartTask( "keyboard", Keyboard );

Keyboard::Bind( "backquote", "Debug::ToggleConsole()", 0 )
Keyboard::Bind( "escape", "Quit()" );
Keyboard::Bind( "left_alt f4", "Quit()", 0 );
Keyboard::Bind( "left_alt return", "Window::Fullscreen()", 0 )

// Keyboard::Bind( "p", "Game::TogglePause()" );
// Keyboard::Bind( "space", "Game::SetMonsterMoveFrequency(1)" );
// Keyboard::Bind( "f2", "Debug::RecordInput( data/recordings/temp.rec )" );
// Keyboard::Bind( "f3", "Debug::PlaybackInput( data/recordings/temp.rec )" );

//............................................................................................


Audio::PreloadEffect( "data/sfx/asteroid_hit.wav" );
Audio::PreloadEffect( "data/sfx/batswing.wav" );
Audio::PreloadEffect( "data/sfx/bathit_01.wav" );
Audio::PreloadEffect( "data/sfx/bathit_02.wav" );
Audio::PreloadEffect( "data/sfx/bathit_03.wav" );
Audio::PreloadEffect( "data/sfx/bathit_04.wav" );
Audio::PreloadEffect( "data/sfx/bathit_05.wav" );
Audio::PreloadEffect( "data/sfx/bathit_06.wav" );
Audio::PreloadEffect( "data/sfx/planethit_00.wav" );
Audio::PreloadEffect( "data/sfx/planethit_01.wav" );
Audio::PreloadEffect( "data/sfx/planethit_02.wav" );
Audio::PreloadEffect( "data/sfx/planethit_03.wav" );
Audio::PreloadEffect( "data/sfx/planethit_04.wav" );
Audio::PreloadEffect( "data/sfx/planethit_05.wav" );
Audio::PreloadEffect( "data/sfx/plutohit_01.wav" );
Audio::PreloadEffect( "data/sfx/plutohit_02.wav" );
Audio::PreloadEffect( "data/sfx/sunhit.wav" );

Audio::PlayMusicFadeIn( "data/sfx/de-zwervende-keien-the-drifting-boulders_wooden-shoes-in-tirol.ogg", 3000 );

//............................................................................................

Mouse::CursorChangeTo( "cursor_arrow" );
Mouse::CursorHide();
Mouse::CursorShow();


//............................................................................................
// StartTask( "debug", Debug, 100 );

// Debug::BanAsserts( 1 );

