$Local::Lang="en";
function onStart()
{   
   new ProffileManager(Pm);
   if(Pm.Load()==false)
        Pm.Save();
   echo("pm created...");
   
}

function onExit(){}

function loadPath( %path )
{
   setModPaths( getModPaths() @ ";" @ %path );
   exec(%path @ "/main.cs");

}

setLogMode(6);
echo("start c.");
loadPath( "common" );
echo("start g.");
loadPath( "game" );
echo("on start...");
onStart();

if( !isFunction( "initializeProject" ) || !isFunction( "_initializeProject" ) )
{
   messageBox( "Game Startup Error", "'initializeProject' function could not be found." @
               "\nThis could indicate a bad or corrupt common directory for your game." @
               "\n\nThe Game will now shutdown because it cannot properly function", "Ok", "MIStop" );
   quit();
}
_initializeProject();

initializeProject();


