views:

76

answers:

3

Hey guys,

I am trying to learn Visual C++ 2008 and C++ at the same time to get involved with sourcemod, a server side modding tool for valve games. However I have never touched Visual C++ or C++ in general, and doing some preliminary research I am quite confused on these different versions of C++ (mfc, cli, win32), and why a lot of people seem to hate Visual C++ and use something like Borland instead.

I really learn visually, and have used videos from places like Lynda.com with great success. I was wondering if anyone had any exceptional resources they had come across to teach Visual C++ 2k8, with its intricacies and setting up the IDE along with C++ at the same time. Books would be nice, but videos would be preferred, and I don't mind paying for resources. Thanks in advance!

+4  A: 

why a lot of people seem to hate Visual C++ and use something like Borland instead
You must be looking at old data. Borland's C++ department is essentially defunct nowadays if I'm not mistaken. Their commandline compiler is still available for free, but it seems Borland is happier to focus on Delphi rather than continuing to maintain C++ Builder. (Actually, it seems they don't even own C++ Builder anymore)

Visual Studio 6 ha[sd] one of the worst implementations if the Standard Template Library and templates in general, which is why Visual Studio often gets a bad rap in C++ circles. The more recent versions of the compiler, say 2005 and up, should be perfectly fine.

VS comes with a whole bunch of libraries you can use like ATL and MFC, but if you're looking to help out on sourcemod you can probably ignore all those goodies. They're helpful if you know what you're doing with them, but if you are working on a simple plugin (like sourcemod is) which does not display any UI then these frameworks are not going to be very helpful for you. (Not to mention I believe sourcemod is cross platform which sort of precludes any platform specific dependencies)

Worry less about the intricacies of the IDE itself -- it's there to help you but beyond the simple task of creating a project and hitting Go, most of the time it should not be your focus. Learn how to write correct code first, then go back and look for IDE bells and whistles if you want. For the most part, these bells and whistles don't apply to native C++ development anyway :(

Billy ONeal
+1  A: 

The answer to this depends on your programming experience.

C++ is a very extensive language and can be overwhelming by someone with little to no programming experience. That being said, there are a number of excellent sources to learn from.

MSDN (Microsoft Developers Network) has a number of tutorials for getting started with Visual C++ (Google "MSDN visual C++ guided tour"); however, if you really want to be able to code well in C++ I would highly recommend the book "C++ Primer" by Stanley B. Lippman et. al. (ISBN 0-201-72148-1). The book is a not really one you want to read cover to cover (though it is packed full of great information) it is an excellent reference. Additionally, there are a number of you tube videos that will give you some bare bones "Hello World" examples.

Hope this helps! :-D

Matt
+2  A: 

@Billy is right on with his answer. Microsoft has a number of videos on their Channel 9 web site, I would think that's a good place for you to start.

kenny