Game Development Community

Torque Lighting Kit and the RTS Kit - quick and easy

by John Kabus (BobTheCBuilder) · in Torque Game Engine · 09/23/2005 (5:11 pm) · 22 replies

Hello Torque Lighting Kit community!

I've created a utility to add quick and easy support for the RTS Kit, and for nearly any new TGE based Starter Kit to come along.

The utility (named Auto Patch) performs the entire merge process automatically. Only the final integration steps are required after the automatic merge (these are; adding the TLK source files into the new Starter Kit project files, and compiling the source).

This tool is very new and although it's been tested there may be a few problems, so be patient.

If you do come across a problem make sure to copy the text from your console window and to post it here, so I can see what's happening, also include your OS in the post.

Auto Patch is available on the TLK download page.

-John Kabus
Synapse Gaming
Page «Previous 1 2
#1
09/23/2005 (5:11 pm)
From the Auto Patch Guide:


Torque Lighting Kit - Auto Patch Guide
Copyright
#2
10/08/2005 (8:40 am)
I'll be honest, I didn't believe just how easy it would be... it took less than 30s to run on my laptop. And it works! The biggest problem I had was that I didn't read the instructions first, and installed the RTS kit in the wrong directory...

I guess we now have no more excuses for not getting on with our projects. Damn you John! ;)
#3
10/09/2005 (12:41 pm)
Hey thanks! worked great.
#4
10/10/2005 (9:00 am)
One little note, as an aside. Visual Studio 2005 beta's upconversion of VC7(VS 2003) solutions is hella broken. I'm pretty sure that converting any torque project is going to result in the same errors. If you're trying this for the first time and don't want to see errors, use VS 2003.
#5
10/14/2005 (9:03 am)
Hi Karthik,

It was cool meeting you at IGC, I hope you'll attend next year too.


All,

RTS kit support seemed to be a big deal for a while, are people using this tool successfully or not at all?

-John
#6
10/14/2005 (3:39 pm)
Karthik,

Weird ... I've converted many Torque and TSE VS2003 projects with VS2005 Beta 2 and not had any problems. I dont remember if I tried the RTS kit's project, though. There are a few caveats, such as having to add a couple of defines due to MS deprecating some standard library functions, but on the whole its fairly easy to sort out.

Glad you posted here otherwise I would never have remembered how to spell your name :)

John,

I tried the patcher out today, VC6 projects were pretty easy to update. I havent tried converting to VS2005 since the VS2003 projects were more of a pain in the arse to update with WinMerge. I suppose I could try converting the VC6 projects.

One comment I have about the auto patcher is that the docs do not mention what name the RTS Starter Kit directory needs to be. It just says "install into the contentPacks dir," whereas my loathing for source code installers caused me to install the RTS kit once, copy the files to somewhere that i actually wanted it, then uninstalled the RTS kit. Seeing as I am probably not the norm here, I had to reverse engineer the auto patcher to figure out the directory name. That is a fancy way of saying "I looked at the data section of the .exe in a hex editor and made an educated guess". Anyway, the correct directory name is RTSStarterKit.

Other then that, it went pretty smoothly. The only annoyance being the updating of the projects. I know spaces are a problem for patch, but one option might be to write some code to update the projects after a successful patch. There is some degree of cheating that is possible for writing the projects. I have some perl scripts that diff VC6, VC7 and VC8 projects if you need some pointers.

Anyway, the autopatcher is pretty damn sweet. Now I just need to find a use for the RTS-SK + TLK :)

T.
#7
10/15/2005 (9:13 am)
"I am probably not the norm here"

Really? :) (J/k)

Glad you got it working.

It was great seeing you again this year at IGC. So when is the next GID?

-John
#8
10/16/2005 (10:56 am)
Quote:RTS kit support seemed to be a big deal for a while, are people using this tool successfully or not at all?
I will probably be using this. Unless the game design changes too radical. Then I'll be using "normal" Lighting Pack instead.
#9
10/30/2005 (11:12 pm)
When will we see linux support?
( it's the only platform i use )
#10
11/01/2005 (5:52 am)
I'll look into a linux port sometime in the next week, not promising anything, but I'll take a look.

-John
#11
11/21/2005 (11:22 pm)
Hello,

I followed the the steps and patched with no problems, used winmerge to transfer copies over to the new LightingPack-RTS folder. I have 156 link errors upon compiling.

I don't understand why because both the LightingPack and RTSStarterKit I used were freshly installed copies and they both complied perfectly.

Any help is greatly appreciated. I've been pulling my hair out on this one for a couple of days now.
#12
11/22/2005 (7:13 am)
Hi David,

Did you remember to add the TLK files to your projects?

Quote:
After running Auto Patch the Torque Lighting Kit source files must be included in the newly created project files (the source files are already included in the GCC and TBE make files). For instructions on which source files belong in each project see the bottom of the TLK Migration Guide.

Also make sure the following source files are included in the 'Torque Demo' and XCode project files:

-concretePolyList.cc (located in the 'collision' folder)
-volLight.cc (located in the 'game/fx' folder or the 'game' folder in XCode)

-John
#13
11/22/2005 (4:03 pm)
Sorry if this comes up twice. I just tried to post it and my browser went squirly. Anyway, yes I have put the files in that the TLK migration guide asks for, In fact they were already there. To make a long story short, and so I dont have to retype my whole grandiose email that just ended up in an alternate universe, I have attached below the error I am getting. Apparently I have rid myself of 4 errors. Only 152 more to go!!! Unfortunately I can't send the whole thing in a post it is too large.

Linking...
worldEditor.obj : error LNK2001: unresolved external symbol "public: static void __cdecl sgLightingFilter::sgRenderAllowedObjects(void *)" (?sgRenderAllowedObjects@sgLightingFilter@@SAXPAX@Z)
simPath.obj : error LNK2001: unresolved external symbol "protected: virtual void __thiscall SceneObject::uninstallLights(void)" (?uninstallLights@SceneObject@@MAEXXZ)
sky.obj : error LNK2001: unresolved external symbol "protected: virtual void __thiscall SceneObject::uninstallLights(void)" (?uninstallLights@SceneObject@@MAEXXZ)
terrData.obj : error LNK2001: unresolved external symbol "protected: virtual void __thiscall SceneObject::uninstallLights(void)" (?uninstallLights@SceneObject@@MAEXXZ)
..................................................................................
GuiRTSTSCtrl::getSelectedColor(void)" (?getSelectedColor@GuiRTSTSCtrl@@QAE?AVColorF@@XZ)
tsMesh.obj : error LNK2001: unresolved external symbol "public: static void __cdecl sgTSMesh::sgInitMaterials(void)" (?sgInitMaterials@sgTSMesh@@SAXXZ)
tsMesh.obj : error LNK2001: unresolved external symbol "public: static void __cdecl sgTSMesh::sgResetMaterials(void)" (?sgResetMaterials@sgTSMesh@@SAXXZ)
tsMesh.obj : error LNK2001: unresolved external symbol "public: static void __cdecl sgTSMesh::sgSetMaterials(unsigned int)" (?sgSetMaterials@sgTSMesh@@SAXI@Z)
../example/RTS_DEBUG.exe : fatal error LNK1120: 61 unresolved externals
Error executing link.exe.

RTS_DEBUG.exe - 152 error(s), 0 warning(s)
#14
11/24/2005 (7:56 pm)
Update... I found that I did not have all the core files in the LightingPack-RTS directory. I have since used win merge to update and have solved the linker problems.

Unfortunately I have a new problem:

c:\documents and settings\david\desktop\synapsegaming\contentpacks\lightingpack-rts\engine\terrain\terrrender.cc(402) : error C2511: 'emitTerrChunk' : overloaded member function 'void (struct SquareStackNode *,float,unsigned int,bool,bool,bool)' not
found in 'TerrainRender'
c:\documents and settings\david\desktop\synapsegaming\contentpacks\lightingpack-rts\engine\terrain\terrrender.h(281) : see declaration of 'TerrainRender'
c:\documents and settings\david\desktop\synapsegaming\contentpacks\lightingpack-rts\engine\terrain\terrrender.cc(616) : error C2660: 'emitTerrChunk' : function does not take 6 parameters
c:\documents and settings\david\desktop\synapsegaming\contentpacks\lightingpack-rts\engine\terrain\terrrender.cc(639) : error C2660: 'emitTerrChunk' : function does not take 6 parameters

I'm getting these 3 errors when compiling.
#15
11/28/2005 (7:57 am)
Hi David,

I'm a little concerned that auto-patch didn't automatically copy the TLK files over (that's part of it's job), are you using clean copies of TLK and the RTS Kit?

I would try creating a new folder and installing the latest versions of TLK and the RTS Kit there, running auto-patch, and adding the TLK files (which should already be in the new LightingPack-RTS folder) into the project files.

If that works correctly and the project builds fine, then add in any custom code changes you have.

Let me know if this helps!

-John
#16
12/05/2005 (12:09 am)
Hi John,

I have been doing this a couple of times now with new TLK and RTS kits and still have gotten no where with this.

David
#17
12/05/2005 (12:34 am)
Hi David,

Are you sure you have the latest version of TLK and the RTS-Kit, and they're both un-altered?

I just tried downloading the latest TLK, RTS Kit, and auto-patch, and running it here and everything worked great.

Also, do you receive any errors while running auto-patch?

-John
#18
12/07/2005 (10:21 pm)
Hi John,

Yes, I started all over again and downloaded the copies of RTS and TLK and patch, and came up with the same 156 errors.

I've done this many times now with the same results. I've also tried altering project settings and nothing changes.

-David
#19
12/07/2005 (10:33 pm)
Hi David,

If you're getting the same errors from your first post:

Quote:
Sorry if this comes up twice. I just tried to post it and my browser went squirly. Anyway, yes I have put the files in that the TLK migration guide asks for, In fact they were already there. To make a long story short, and so I dont have to retype my whole grandiose email that just ended up in an alternate universe, I have attached below the error I am getting. Apparently I have rid myself of 4 errors. Only 152 more to go!!! Unfortunately I can't send the whole thing in a post it is too large.

Linking...
worldEditor.obj : error LNK2001: unresolved external symbol "public: static void __cdecl sgLightingFilter::sgRenderAllowedObjects(void *)" (?sgRenderAllowedObjects@sgLightingFilter@@SAXPAX@Z)
simPath.obj : error LNK2001: unresolved external symbol "protected: virtual void __thiscall SceneObject::uninstallLights(void)" (?uninstallLights@SceneObject@@MAEXXZ)
sky.obj : error LNK2001: unresolved external symbol "protected: virtual void __thiscall SceneObject::uninstallLights(void)" (?uninstallLights@SceneObject@@MAEXXZ)
terrData.obj : error LNK2001: unresolved external symbol "protected: virtual void __thiscall SceneObject::uninstallLights(void)" (?uninstallLights@SceneObject@@MAEXXZ)
..................................................................................
GuiRTSTSCtrl::getSelectedColor(void)" (?getSelectedColor@GuiRTSTSCtrl@@QAE?AVColorF@@XZ)
tsMesh.obj : error LNK2001: unresolved external symbol "public: static void __cdecl sgTSMesh::sgInitMaterials(void)" (?sgInitMaterials@sgTSMesh@@SAXXZ)
tsMesh.obj : error LNK2001: unresolved external symbol "public: static void __cdecl sgTSMesh::sgResetMaterials(void)" (?sgResetMaterials@sgTSMesh@@SAXXZ)
tsMesh.obj : error LNK2001: unresolved external symbol "public: static void __cdecl sgTSMesh::sgSetMaterials(unsigned int)" (?sgSetMaterials@sgTSMesh@@SAXI@Z)
../example/RTS_DEBUG.exe : fatal error LNK1120: 61 unresolved externals
Error executing link.exe.

RTS_DEBUG.exe - 152 error(s), 0 warning(s)

That's good, these are link errors that occur when the TLK files are not added to the RTS kit project. The errors you received later regarding the terrain were very odd and definitely not TLK related, avoid doing whatever caused those.
#20
12/07/2005 (10:33 pm)
To resolve these link errors you need to add the TLK files to the RTS kit project files (as mentioned in the docs). Open 'LightingPack-RTS/VC7/RTS Full Project.sln' and add the TLK files referenced in the Migration Guide to the RTS project under 'source files'.

The TLK files:

Quote:
engine\synapseGaming\contentPacks\lightingPack\sgLighting.h
engine\synapseGaming\contentPacks\lightingPack\sgLightManager.cc
engine\synapseGaming\contentPacks\lightingPack\sgLightManager.h
engine\synapseGaming\contentPacks\lightingPack\sgLightingModel.cc
engine\synapseGaming\contentPacks\lightingPack\sgLightingModel.h
engine\synapseGaming\contentPacks\lightingPack\sgLightMap.cc
engine\synapseGaming\contentPacks\lightingPack\sgLightMap.h
engine\synapseGaming\contentPacks\lightingPack\sgMissionLightingFilter.cc
engine\synapseGaming\contentPacks\lightingPack\sgMissionLightingFilter.h
engine\synapseGaming\contentPacks\lightingPack\sgNewMethods.cc
engine\synapseGaming\contentPacks\lightingPack\sgNewMethods.h
engine\synapseGaming\contentPacks\lightingPack\sgSceneLighting.cc
engine\synapseGaming\contentPacks\lightingPack\sgSceneLighting.h
engine\synapseGaming\contentPacks\lightingPack\sgSceneLightingInsert.h
engine\synapseGaming\contentPacks\lightingPack\sgSceneObject.cc
engine\synapseGaming\contentPacks\lightingPack\sgSceneObject.h
engine\synapseGaming\contentPacks\lightingPack\sgTGE.cc
engine\synapseGaming\contentPacks\lightingPack\sgTSStatic.cc
engine\synapseGaming\contentPacks\lightingPack\sgTSStatic.h
engine\synapseGaming\contentPacks\lightingPack\sgUniversalStaticLight.cc
engine\synapseGaming\contentPacks\lightingPack\sgUniversalStaticLight.h

-John
Page «Previous 1 2