Game Development Community

Engine coding error

by Jeff C. · in Torque Game Engine · 06/06/2004 (12:52 pm) · 2 replies

I got to

File : gameConnection.cc
after the S32 GameConnection::smVoiceConnections[MaxClients]; add:

in walkthrough --

http://www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=3645


but i can't find this line in that file... where do I put those lines now. I tried adding everything else but those lines and get --

------ Build started: Project: Torque Demo, Configuration: Debug Win32 ------

Linking...

gameConnection.obj : error LNK2001: unresolved external symbol "private: static bool GameConnection::mCameraZooming" (?mCameraZooming@GameConnection@@0_NA)

gameConnection.obj : error LNK2001: unresolved external symbol "private: static float GameConnection::mCameraDist" (?mCameraDist@GameConnection@@0MA)
../example/torqueDemo_DEBUG.exe : fatal error LNK1120: 2 unresolved externals

Build log was saved at "file://c:\torque\engine\out.VC6.DEBUG\BuildLog.htm"
Torque Demo - 3 error(s), 0 warning(s)

and while do have experience with some limiited programming, this is the first attempt at a project of this size....any suggestions?

#1
06/06/2004 (1:04 pm)
You haven't specified any storage space for the two static member variables. I don't have the source anymore but I'll take a wild stab in the dark. In the top (or wherever it fits) of gameConnection.cc(??) add:

bool GameConnection::mCameraZooming;
float GameConnection::mCameraDist;

Why those are statics though I have no idea... Someone else probably should give you a more complete answer.
#2
06/06/2004 (9:28 pm)
You rock... thanks!

its not perfect, since the reaction time is slow, but for a demo, its good enough for me. :)