Building Client.dll - cl_dll Project Corrupt?

Building Client.dll - cl_dll Project Corrupt?

Re: Building Client.dll - cl_dll Project Corrupt? Posted by StoneFrog on Sun Nov 18th 2007 at 1:16am
StoneFrog
3 posts
Posted 2007-11-18 1:16am
3 posts 0 snarkmarks Registered: Nov 17th 2007
For my mod, I've been using MSVC++ 6.0, as is suggested by most, to program. My hl.dll file builds perfectly. Alas, my client.dll (the thing in the cl_dll file) does not. The default project that is there, if I try to build it, I get these errors:

--------------------Configuration: cl_dll - Win32 Debug--------------------
Compiling...
GameStudioModelRenderer_Sample.cpp
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer_sample.cpp(79) : error C2065: 'm_bLocal' : undeclared identifier
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer_sample.cpp(89) : error C2509: 'StudioSetupBones' : member function not declared in 'CGameStudioModelRenderer'
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer.h(20) : see declaration of 'CGameStudioModelRenderer'
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer_sample.cpp(290) : error C2509: 'StudioEstimateGait' : member function not declared in 'CGameStudioModelRenderer'
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer.h(20) : see declaration of 'CGameStudioModelRenderer'
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer_sample.cpp(360) : error C2509: 'StudioProcessGait' : member function not declared in 'CGameStudioModelRenderer'
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer.h(20) : see declaration of 'CGameStudioModelRenderer'
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer_sample.cpp(450) : error C2039: 'SavePlayerState' : is not a member of 'CGameStudioModelRenderer'
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer.h(20) : see declaration of 'CGameStudioModelRenderer'
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer_sample.cpp(451) : fatal error C1903: unable to recover from previous error(s); stopping compilation
soundsystem.cpp
d:\kenneth\sdk\single-player source\common\r_studioint.h(136) : error C2629: unexpected 'void ('
d:\kenneth\sdk\single-player source\common\r_studioint.h(136) : error C2238: unexpected token(s) preceding ';'
Error executing cl.exe.
Creating browse info file...
BSCMAKE: error BK1506 : cannot open file '.\Debug\GameStudioModelRenderer_Sample.sbr': No such file or directory
Error executing bscmake.exe.


client.dll - 9 error(s), 0 warning(s)



I'm using the 2.3 Half-Life SDK, the source version that lacks the tools. Do I need to tweak the default client project? If so, how? I am still relatively new to Half-Life modding and am unsure how to declare the stuff.

I believe that is all pertaining to Hammer's 3D view regarding models, though I'm not sure why it's having all these declaration errors.

Help would be appreciated!
Re: Building Client.dll - cl_dll Project Corrupt? Posted by Le Chief on Fri Nov 30th 2007 at 8:28pm
Le Chief
2605 posts
Posted 2007-11-30 8:28pm
Le Chief
member
2605 posts 937 snarkmarks Registered: Jul 28th 2006 Location: Sydney, Australia
The project is not corrupt. Its just that there is some code in the filesamestudiomodelrenderer_sample.cpp and gamestudiomodelrenderer.h and r_studioint.h that isn't written properly. If one little thing is not right, it wont compile. Sorry for late reply.
Aaron's Stuff
Re: Building Client.dll - cl_dll Project Corrupt? Posted by StoneFrog on Fri Nov 30th 2007 at 11:35pm
StoneFrog
3 posts
Posted 2007-11-30 11:35pm
3 posts 0 snarkmarks Registered: Nov 17th 2007
I know that they're errors, but I don't know how to fix them. I'm fairly new to coding, though I've been able to do several new things in the hl.dll project, I even made some new monsters and whatnot.

I just can't get the cl_dll to work though, because of those GameStudioRender errors!
Re: Building Client.dll - cl_dll Project Corrupt? Posted by Le Chief on Fri Nov 30th 2007 at 11:52pm
Le Chief
2605 posts
Posted 2007-11-30 11:52pm
Le Chief
member
2605 posts 937 snarkmarks Registered: Jul 28th 2006 Location: Sydney, Australia
Well, from what little I know (I'm new to) your missing some declarations. Your member functions need to be declared in CGameStudioModelRenderer. Have a look at the other member functions from that file, and see how they are decleared. Remember, if I have the function

int aaron ()
{
somebullcrapcodehere
here
here
and here
}

I have to first type int aaron (); to let the code know that somewhere in your code, there is a function called "aaron ()". This is called a declaration.
Aaron's Stuff
Re: Building Client.dll - cl_dll Project Corrupt? Posted by omegaslayer on Sat Dec 1st 2007 at 7:02am
omegaslayer
2481 posts
Posted 2007-12-01 7:02am
2481 posts 595 snarkmarks Registered: Jan 16th 2004 Occupation: Sr. DevOPS Engineer Location: Seattle, WA
to let the code know that somewhere in your code, there is a function called "aaron ()". This is called a declaration.
Its called the prototype.....
Posting And You
Re: Building Client.dll - cl_dll Project Corrupt? Posted by Crono on Sat Dec 1st 2007 at 7:49am
Crono
6628 posts
Posted 2007-12-01 7:49am
Crono
super admin
6628 posts 700 snarkmarks Registered: Dec 19th 2003 Location: Oregon, USA
GameStudioModelRenderer_Sample.cpp
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer_sample.cpp(79) : error C2065: 'm_bLocal' : undeclared identifier
In GameStudioModelRenderer_Sample.cpp on line 79, the identifier used "m_bLocal" has not previously been defined. Define it, or include the header file that does.
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer_sample.cpp(89) : error C2509: 'StudioSetupBones' : member function not declared in 'CGameStudioModelRenderer'
d:\kenneth\sdk\single-player source\cl_dll\gamestudiomodelrenderer.h(20) : see declaration of 'CGameStudioModelRenderer'
It looks like you're using the wrong class. GameStudioModelRenderer_Sample is the one you made and where you prototyped the method "StudioSetupBones", right? Well, you need to use an instance of "GameStudioModelRenderer_Sample" and not "CGameStudioModelRenderer" to access that.

It looks like you copied some existing code then changed a couple things and all of sudden there's a bunch of errors. Remember, you changed the NAME of the class, you need to update all the references to that name.
Blame it on Microsoft, God does.
Re: Building Client.dll - cl_dll Project Corrupt? Posted by Le Chief on Sat Dec 1st 2007 at 8:45am
Le Chief
2605 posts
Posted 2007-12-01 8:45am
Le Chief
member
2605 posts 937 snarkmarks Registered: Jul 28th 2006 Location: Sydney, Australia
Declaration, prototype, same s**t different smell.
Aaron's Stuff
Re: Building Client.dll - cl_dll Project Corrupt? Posted by Crono on Sat Dec 1st 2007 at 11:29am
Crono
6628 posts
Posted 2007-12-01 11:29am
Crono
super admin
6628 posts 700 snarkmarks Registered: Dec 19th 2003 Location: Oregon, USA
Get them straight. Because they're not the same thing.
Blame it on Microsoft, God does.
Re: Building Client.dll - cl_dll Project Corrupt? Posted by Le Chief on Sat Dec 1st 2007 at 11:46am
Le Chief
2605 posts
Posted 2007-12-01 11:46am
Le Chief
member
2605 posts 937 snarkmarks Registered: Jul 28th 2006 Location: Sydney, Australia
There not?
Aaron's Stuff
Re: Building Client.dll - cl_dll Project Corrupt? Posted by Crono on Sat Dec 1st 2007 at 12:03pm
Crono
6628 posts
Posted 2007-12-01 12:03pm
Crono
super admin
6628 posts 700 snarkmarks Registered: Dec 19th 2003 Location: Oregon, USA
No they're not, and I'm not explaining why, because I know it's above your knowledge level right now.
Blame it on Microsoft, God does.
Re: Building Client.dll - cl_dll Project Corrupt? Posted by Le Chief on Sat Dec 1st 2007 at 12:08pm
Le Chief
2605 posts
Posted 2007-12-01 12:08pm
Le Chief
member
2605 posts 937 snarkmarks Registered: Jul 28th 2006 Location: Sydney, Australia
A function decleration is for example int aaronrulz (); . And according to my book, as I read it, this is also called the function prototype.

Edit:

Quoting from my book.

Function Declaration = Tells the compiler the name, return type and parameters of the function.

Prototype = The Declaration of a function.
Aaron's Stuff
Re: Building Client.dll - cl_dll Project Corrupt? Posted by omegaslayer on Sat Dec 1st 2007 at 6:46pm
omegaslayer
2481 posts
Posted 2007-12-01 6:46pm
2481 posts 595 snarkmarks Registered: Jan 16th 2004 Occupation: Sr. DevOPS Engineer Location: Seattle, WA
A function decleration is for example int aaronrulz (); . And according to my book, as I read it, this is also called the function prototype.

Edit:

Quoting from my book.

Function Declaration = Tells the compiler the name, return type and parameters of the function.

Prototype = The Declaration of a function.
...
No they're not, and I'm not explaining why, because I know it's above your knowledge level right now.
Your book is probably a 'beginners guide to c++'. I bet it doesn't even really explain what the * & -> symbols really do (im sure you can look it up and give us definitions, but what do they really mean), because THATS what it means to be a good c++ coder: manipulating memory references to achieve an infinite and dynamic program capable of storing/sorting and handling an indefinite amount of data.

Basic Jist arron: the definition is the implementation of the function, the prototype is the froward declaration (but even then calling it a declaration is stretching it). Its like this:

compiler reads the prototype it means to the compiler "hey theres this function called int *arronlolz() and I haven't defined it yet, but its coming up, so don't freak out whenever I call the function in the code because I haven't defined it yet.

That sure isnt a declaration of the function....
Posting And You
Re: Building Client.dll - cl_dll Project Corrupt? Posted by Le Chief on Sat Dec 1st 2007 at 7:56pm
Le Chief
2605 posts
Posted 2007-12-01 7:56pm
Le Chief
member
2605 posts 937 snarkmarks Registered: Jul 28th 2006 Location: Sydney, Australia
Oh right, thanks for that :wink: . Yes you are right, its a "complete starter kit" and on the back it says by the end of the book, you'll know the basics.
Aaron's Stuff
Re: Building Client.dll - cl_dll Project Corrupt? Posted by fishy on Sat Dec 1st 2007 at 9:59pm
fishy
2623 posts
Posted 2007-12-01 9:59pm
fishy
member
2623 posts 1476 snarkmarks Registered: Sep 7th 2003 Location: glasgow
who else would use an idiots guide to 'anything' in an arguement with Crono; but coding! hah, nice one aaron. :razz:

/offtopic
i eat paint
Re: Building Client.dll - cl_dll Project Corrupt? Posted by Crono on Sat Dec 1st 2007 at 10:02pm
Crono
6628 posts
Posted 2007-12-01 10:02pm
Crono
super admin
6628 posts 700 snarkmarks Registered: Dec 19th 2003 Location: Oregon, USA
Remember that "A lot of C++ books are wrong" discussion we had? Welcome to the world of misinformation.

The difference between a declaration and a prototype is that a declaration is something you define when you declare it, like a variable or type. They need no further information on how to be used ... unlike a function.

The only time you can say a function is a declaration is in the new age thinking of object orientation where variables are fields and functions are methods, in which case, it's a method declaration. But, that's still in the instance where it's used in a class structure and not on its own.
Blame it on Microsoft, God does.
Re: Building Client.dll - cl_dll Project Corrupt? Posted by Le Chief on Sat Dec 1st 2007 at 10:37pm
Le Chief
2605 posts
Posted 2007-12-01 10:37pm
Le Chief
member
2605 posts 937 snarkmarks Registered: Jul 28th 2006 Location: Sydney, Australia
Thats stupid. Books shouldn't be published if they have inaccurate information. Mabye its some stupid clash with the normal c++ and microsoft's c++. Thanks for informing me :wink: .Anyway ladies, I just added the poison zombie and poison headcrab into reddawn. If any of you'll are interested: http://www.chatbear.com/unity2/839/164,1174058843,15226/1040811/0?v=flatold .
Aaron's Stuff
Re: Building Client.dll - cl_dll Project Corrupt? Posted by Crono on Sat Dec 1st 2007 at 11:00pm
Crono
6628 posts
Posted 2007-12-01 11:00pm
Crono
super admin
6628 posts 700 snarkmarks Registered: Dec 19th 2003 Location: Oregon, USA
Not only is this someone else's thread ... but it's in the editing forum. If you want people to look at your work put it where it belongs.

Lots of books are wrong, ESPECIALLY in the world of technology (well software, anyway, it's kind of hard to be wrong about hardware). The only reason why other similar books are correct, like Math or Physics or something like that is because they're far more defined and older.

But, books on language have the same issues.

Just wait, you'll run across stuff that is wrong for more than a language semantics issue. It'll flat out not work and the author will use it as some crutch to explain everything with and the entire book will not make sense because of it.

I wonder if that guy tried my suggestions.
Blame it on Microsoft, God does.