mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-07-11 06:34:36 +00:00
Parametrize script extension, default to 'tscript'
This commit is contained in:
parent
b8b62292bd
commit
099dd4f1f3
542 changed files with 774 additions and 783 deletions
48
Templates/BaseGame/game/main.tscript.in
Normal file
48
Templates/BaseGame/game/main.tscript.in
Normal file
|
|
@ -0,0 +1,48 @@
|
|||
$Core::windowIcon = "data/icon.png";
|
||||
$Core::splashWindowImage = "data/splash.png";
|
||||
|
||||
// Display a splash window immediately to improve app responsiveness before
|
||||
// engine is initialized and main window created.
|
||||
displaySplashWindow($Core::splashWindowImage);
|
||||
|
||||
// Console does something.
|
||||
setLogMode(6);
|
||||
|
||||
// Disable script trace.
|
||||
trace(false);
|
||||
|
||||
// Set the name of our application
|
||||
$appName = "@TORQUE_APP_NAME@";
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Load up scripts to initialise subsystems.
|
||||
ModuleDatabase.setModuleExtension("module");
|
||||
ModuleDatabase.scanModules( "core", false );
|
||||
ModuleDatabase.LoadExplicit( "CoreModule" );
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Load any gameplay modules
|
||||
ModuleDatabase.scanModules( "data", false );
|
||||
ModuleDatabase.LoadGroup( "Game" );
|
||||
|
||||
//Finally, initialize the client/server structure
|
||||
ModuleDatabase.LoadExplicit( "Core_ClientServer" );
|
||||
|
||||
if(isFunction("loadStartup"))
|
||||
{
|
||||
loadStartup();
|
||||
}
|
||||
else
|
||||
{
|
||||
//If nothing else set a main menu, try to do so now
|
||||
if(!isObject(Canvas.getContent()))
|
||||
{
|
||||
%mainMenuGUI = ProjectSettings.value("UI/mainMenuName");
|
||||
if (isObject( %mainMenuGUI ))
|
||||
Canvas.setContent( %mainMenuGUI );
|
||||
}
|
||||
}
|
||||
|
||||
closeSplashWindow();
|
||||
|
||||
echo("Engine initialized...");
|
||||
Loading…
Add table
Add a link
Reference in a new issue