Parametrize script extension, default to 'tscript'

This commit is contained in:
Lukas Aldershaab 2020-12-12 16:54:16 +01:00
parent b8b62292bd
commit 099dd4f1f3
542 changed files with 774 additions and 783 deletions

View file

@ -34,7 +34,7 @@ function initializeEditorClasses()
// Load Editor Profiles
//-----------------------------------------------------------------------------
exec("./scripts/fileLoader.ed.cs");
exec("./scripts/fileLoader.ed.tscript");
loadDirectory( expandFilename("./gui/panels") );
@ -43,39 +43,39 @@ function initializeEditorClasses()
// Setup Preferences Manager
//-----------------------------------------------------------------------------
exec("./scripts/preferencesManager.ed.cs");
exec("./scripts/preferencesManager.ed.tscript");
initPreferencesManager();
//-----------------------------------------------------------------------------
// Load Form Managers
//-----------------------------------------------------------------------------
exec("./scripts/guiFormLibraryManager.ed.cs");
exec("./scripts/guiFormContentManager.ed.cs");
exec("./scripts/guiFormReferenceManager.ed.cs");
exec("./scripts/guiFormLayoutManager.ed.cs");
exec("./scripts/guiFormMessageManager.ed.cs");
exec("./scripts/expandos.ed.cs");
exec("./scripts/utility.ed.cs");
exec("./scripts/guiFormLibraryManager.ed.tscript");
exec("./scripts/guiFormContentManager.ed.tscript");
exec("./scripts/guiFormReferenceManager.ed.tscript");
exec("./scripts/guiFormLayoutManager.ed.tscript");
exec("./scripts/guiFormMessageManager.ed.tscript");
exec("./scripts/expandos.ed.tscript");
exec("./scripts/utility.ed.tscript");
setupBaseExpandos();
// User Display
exec("./scripts/contextPopup.ed.cs");
exec("./scripts/contextPopup.ed.tscript");
// Project Support
exec("./scripts/projects/projectEvents.ed.cs");
exec("./scripts/projects/projectInternalInterface.ed.cs");
exec("./scripts/projects/projectEvents.ed.tscript");
exec("./scripts/projects/projectInternalInterface.ed.tscript");
// Input
exec("./scripts/input/inputEvents.ed.cs");
exec("./scripts/input/dragDropEvents.ed.cs");
exec("./scripts/input/applicationEvents.ed.cs");
exec("./scripts/input/inputEvents.ed.tscript");
exec("./scripts/input/dragDropEvents.ed.tscript");
exec("./scripts/input/applicationEvents.ed.tscript");
// Form Class
exec("./scripts/guiFormClass.ed.cs");
exec("./scripts/guiClasses/guiThumbnailPopup.ed.cs");
exec("./scripts/guiClasses/guiThumbnail.ed.cs");
exec("./scripts/RSSNews/RSSFeedScript.ed.cs");
exec("./scripts/guiFormClass.ed.tscript");
exec("./scripts/guiClasses/guiThumbnailPopup.ed.tscript");
exec("./scripts/guiClasses/guiThumbnail.ed.tscript");
exec("./scripts/RSSNews/RSSFeedScript.ed.tscript");
loadDirectory( expandFilename("./scripts/core") );
loadDirectory( expandFilename("./scripts/platform") );

View file

@ -28,7 +28,7 @@ $RSSFeed::userAgent = "TorqueGameEngineAdvances/1.1";
$RSSFeed::maxNewHeadlines = 10;
// Load up the helper objects
exec( "./RSSStructs.ed.cs" );
exec( "./RSSStructs.ed.tscript" );
function RSSFeedObject::onConnected(%this)
{
@ -93,7 +93,7 @@ function RSSFeedObject::onDisconnect(%this)
{
// Create collection and load cache.
%ret = constructRSSHeadlineCollection();
%ret.loadFromFile( "RSSCache.cs" );
%ret.loadFromFile( "RSSCache.tscript" );
// Ok, we have a full buffer now, hopefully. Let's process it.
//echo(" - Got " @ $RSSFeed::lineCount @ " lines.");
@ -137,7 +137,7 @@ function RSSFeedObject::onDisconnect(%this)
eval( %this._callback @ "(" @ %params @ ");" );
}
%ret.writeToFile( "RSSCache.cs", false );
%ret.writeToFile( "RSSCache.tscript", false );
}
function RSSUpdate::initialize( %callback )

View file

@ -23,13 +23,13 @@
function loadDirectory(%path, %type, %dsoType)
{
if( %type $= "" )
%type = "ed.cs";
%type = "ed.tscript";
if( %dsoType $= "" )
%dsoType = "edso";
%cspath = %path @ "/*." @ %type;
// Because in a shipping version there will be no .cs files, we can't just
// Because in a shipping version there will be no .tscript files, we can't just
// find all the cs files and exec them.
// First we find all the scripts and compile them if there are any

View file

@ -37,7 +37,7 @@ function GuiFormManager::InitLayouts( %libraryName, %layoutName, %layoutObj )
}
// Load up all Layouts in the layout base path.
loadDirectory( %libraryObj.basePath, "cs", "dso" );
loadDirectory( %libraryObj.basePath, "tscript", "dso" );
}
@ -77,7 +77,7 @@ function GuiFormManager::RegisterLayout( %libraryName, %layoutName, %layoutObj )
layoutName = %layoutName;
layoutLibrary = %libraryObj;
layoutObj = %layoutObj;
layoutFile = %libraryObj.basePath @ %layoutName @ ".cs";
layoutFile = %libraryObj.basePath @ %layoutName @ ".tscript";
};
// Tag Layout Object Properly so it can reset itself.
@ -192,7 +192,7 @@ function GuiFormManager::SaveLayout( %library, %layoutName, %newName )
// Do any form layout specifics saving.
GuiFormManager::SaveLayoutContent( %layoutObjRef.layoutObj );
%newFile = %libraryObj.basePath @ "/" @ %newName @ ".cs";
%newFile = %libraryObj.basePath @ "/" @ %newName @ ".tscript";
if( %newName $= "" )
{
%newName = %layoutObjRef.layoutName;