TGE Simplification
by Tom Perry · in Torque Game Engine · 06/15/2006 (7:06 am) · 11 replies
I am following the TGE simplification resource, to get a better idea on how torque as well as to simplify things, and I have hit a snag. There are other paths etc I need to change but I have found most of them, except one. It is my understanding that the LK loads up the .dso and .cs files in the sgFilters and sgLights files when the mission loads. I found the path names in sgDeployConfig, however changing them from "common/synapseGaming/sgLights/" to "server/synapseGaming/sgLights/" doesn't work (the new files are in the server folder. I have a search through the source and scripts but can't find anything. Can anyone shed some light on this for me!
About the author
#2
Each one has a TLK code block that execs the script library, like this one:
Also the script library itself has paths that need to be changed (located in 'common/synapseGaming/contentPacks/lightingPack/sgDeployConfig.cs') that reference the gui textures and light/filter db paths:
06/15/2006 (10:52 am)
The two files that reference the TLK script library are:// from the Developer's Guide... example\starter.fps\client\init.cs example\starter.fps\server\scripts\game.cs
Each one has a TLK code block that execs the script library, like this one:
//-----------------------------------------------
// Lighting Pack code block
//-----------------------------------------------
exec("common/synapseGaming/contentPacks/lightingPack/...");
//-----------------------------------------------
// Lighting Pack code block
//-----------------------------------------------Also the script library itself has paths that need to be changed (located in 'common/synapseGaming/contentPacks/lightingPack/sgDeployConfig.cs') that reference the gui textures and light/filter db paths:
$sgLightEditor::profilePath = "common/ui/"; ... $sgLightEditor::lightDBPath = "common/synapseGaming/sgLights/"; $sgLightEditor::filterDBPath = "common/synapseGaming/sgFilters/";
#3
06/15/2006 (10:59 am)
Yep I changed all of those and the datablocks still don't load. I have no idea whats gone wrong!
#4
06/15/2006 (11:03 am)
Are there errors in the log? And do you at least see this in the log://----------------------------------------------- Synapse Gaming Lighting Pack Loading Synapse Gaming datablocks from: common/synapseGaming/sgFilters/*.dso
#5
06/15/2006 (12:31 pm)
Yes that appears, both for filters and lights. The errors that appear are telling me that things such as "sgGooDataBlock" isn't a gamebase datablock....or somthing similar. Sorry I am not at home at the moment to see the log.
#6
I get a few errors in the console because of this but they are all because the datablocks weren't loaded:
Are these connected to anything else in the common folder? When I leave it in there and leave all the paths unaltered it still doesn't work when the rest of the common folder has been removed (by the end of the first part of the simplification the common folder is completely gone).
06/26/2006 (11:37 am)
Ok still having trouble with this. Exams stopped me from doing any work on this but they're all over now. I came back to this with fresh eyes and still can't see the problem. The files mentioned have all had their paths changed. this is the relevant section of the log://----------------------------------------------- Synapse Gaming Lighting Pack Loading Synapse Gaming datablocks from: client/synapseGaming/sgLights/*.dso Loading Synapse Gaming datablocks from: client/synapseGaming/sgLights/*.cs Loading complete. //----------------------------------------------- //----------------------------------------------- Synapse Gaming Lighting Pack Loading Synapse Gaming datablocks from: client/synapseGaming/sgFilters/*.dso Loading Synapse Gaming datablocks from: client/synapseGaming/sgFilters/*.cs Loading complete. //-----------------------------------------------
I get a few errors in the console because of this but they are all because the datablocks weren't loaded:
Object 'sgSpotDataBlock' is not a member of the 'GameBaseData' data block class Object 'sgGooDataBlock' is not a member of the 'GameBaseData' data block class Object 'sgSpotDataBlock' is not a member of the 'GameBaseData' data block class Object 'sgSpotDataBlock' is not a member of the 'GameBaseData' data block class Object 'sgDynamicFireDataBlock' is not a member of the 'GameBaseData' data block class Object 'sgMountLight' is not a member of the 'GameBaseData' data block class Object 'sgMountLight' is not a member of the 'GameBaseData' data block class Object 'sgSpotSwingStaticDataBlock' is not a member of the 'GameBaseData' data block class
Are these connected to anything else in the common folder? When I leave it in there and leave all the paths unaltered it still doesn't work when the rest of the common folder has been removed (by the end of the first part of the simplification the common folder is completely gone).
#7
If you try to load files from a non-mod directory branch Torque won't find the files, because Torque pre-loads file handles from the mod directories on start up (this improves performance and adds security in the form of a sandbox). If the common folder is no longer set as a mod folder then the contained datablock files won't be found.
06/26/2006 (7:29 pm)
Is your mod directory named 'client' and are the light datablock files located under 'client/synapseGaming/sgLights/' (thats where your setup is looking for them)?If you try to load files from a non-mod directory branch Torque won't find the files, because Torque pre-loads file handles from the mod directories on start up (this improves performance and adds security in the form of a sandbox). If the common folder is no longer set as a mod folder then the contained datablock files won't be found.
#8
06/27/2006 (4:40 am)
Yea that makes sence, but like I said when I leave them in the "common" folder, which now only contains the synapseGaming folder, and leave all the file paths unaltered they still don't load. I have work today but if I get a chance tonite I will start from the begining and see if I can find out precisely when they stop geting loaded.
#9
07/25/2006 (7:45 pm)
Was wondering if you got the Synapse Lighting Kit to work with Darrel Cusey resource on torque simplification yet? Any details would be greatly appreciated!
#10
07/26/2006 (2:11 am)
Nope never did, I gave up and started on more pressing issues (exams for the most part!). You having the same trouble?
#11
....
$sgLightEditor::lightDBPath = "client/synapseGaming/sgLights/";
$sgLightEditor::filterDBPath = "client/synapseGaming/sgFilters/";
client
client/data
client/ui
client/synapsegaming
client/synapsegaming/sgfilters
client/synapsegamingsglights
client/synapsegaming/contentpacks
client/synapsegaming/contentpacks/lightingpack
client/synapsegaming/contentpacks/lightingpack/client
client/synapsegaming/contentpacks/lightingpackgui
Thats my layout and profiles. Works like a champ.
07/26/2006 (2:55 am)
$sgLightEditor::profilePath = "client/ui/";....
$sgLightEditor::lightDBPath = "client/synapseGaming/sgLights/";
$sgLightEditor::filterDBPath = "client/synapseGaming/sgFilters/";
client
client/data
client/ui
client/synapsegaming
client/synapsegaming/sgfilters
client/synapsegamingsglights
client/synapsegaming/contentpacks
client/synapsegaming/contentpacks/lightingpack
client/synapsegaming/contentpacks/lightingpack/client
client/synapsegaming/contentpacks/lightingpackgui
Thats my layout and profiles. Works like a champ.
Torque Owner Berserk