I've been trying to follow tutorials for a good week now, but I'm finding myself frustrated at the fact that, when someone provides a tutorial code and basically says "just throw this in your compiler and run it", it can't just be entered into any C++ compiler. I'm finding myself lost with the fact that one has to go and, (if I've got this right), hunt down random libraries, headers etc, or compile their own. I guess that's one thing that programming in the QBASIC environment never taught me, and is one of my shortfalls in making the jump to C++. You could take code from anywhere and slap it in, compile it and run it, but as far as C++ goes, I feel like I'm going way too slow. When I was doing my games programming diploma at TAFE, they never even bothered to cover anything past making a simple real time strategy in C, never taught us how to make headers, or utilize custom libraries.
At the moment for example, I'm following Lode V's Raycasting tutorial -> http://lodev.org/cgtutor/raycasting.html and Codeblocks with the GNU C++ compiler. I would love to know what I need to be able to do to take the code he's provided and compile it successfully, have it spit out a .EXE I can run.
However, I'm finding that even after popping the appropriate libraries into their respective directories, (the SDL referred to in his tutorials) I'm running into compiler-killing errors. So I guess my next question is, given that there's no striaghtforward tutorial to setting up up library X with compiler Z, what would you guys recommend I use? Should I abandon codeblocks for another compiler and set of libraries that seem to be the standard? Every tutorial I find seems to always branch off into different directions and this is the one thing that tended to lose me; some will say to use Visual Studio, others will say use DevC++, etc, but often the codes don't seem to be interchangeable.
I would search before posting again, but I'm not quite sure what terms one would search for in regards to my question, but then again, I'm posting because I'm really keen, I really do want to learn, and I don't care how long it takes. I've spent the last week also touching up and studying maths furiously, have torn through a considerable amount of Khan Academy videos and begun quizzing myself, and making simple C++ programs to try and push what I've learnt as I guess this would be a good way to learn, by experimenting.
I know my posts are dead long, but anyone who has the time to respond, it would be mega appreciated, and when the day comes that I become an evil Russian billionaire, I'll happily pay the favor back however you like.
Edited by James Miller, 02 February 2013 - 12:34 AM.