Jump to content

  • Log In with Google      Sign In   
  • Create Account

DZee

Member Since 03 Jul 2012
Offline Last Active Aug 25 2012 07:22 PM

#4971913 Realistic Encouragement vs Trolling Tear-down

Posted by DZee on 21 August 2012 - 12:16 PM

There's a fine line one must not cross when giving advice. Although I will say that these boards have NOTHING I say NOTHING to complain about. Go have a look in the C++ irc channel, every question you ask you get trolled by a C++ veteran for being "foolish", "arrogant" or "clueless". Most questions will also spur a rather aggressive debate on the optimal solution.


#4968308 "Must-Learn" Languages

Posted by DZee on 10 August 2012 - 09:45 PM

Ultimately it's a waste of time to spend so much time on different languages. If I had to retake my path I would have jumped into C++ and never looked back. In reality only the specialist really shine in what they do. There's no reason to try and be good at everything. My teacher once told me; sometimes you need to learn to love what you hate and embrace it.

That's what defines if you truly are willing to walk down the path you really set out for you. Don't plan things years ahead, I know plenty of things I wanted to get taken care of that never happened because my priorities changed. Just get started.


#4966899 Best language to make 2d games

Posted by DZee on 06 August 2012 - 09:46 PM

A really great place to start game programming is with Python using the SDL wrapper Pygame. Python is really easy to learn, and if you're going to get into game development, having to worry about learning a much more complex language like C++ or Java AS WELL as game programming theories and concepts, could really set you back. Pygame is also EXTREMELY easy to use with Python and has pages and pages of really usefull documentation on their website, something I found VERY usefull.


I also agree on this choice. Once you get the hang of pygame dump python and just switch to C++ with native SDL. The API is pretty much the same since pyGame is just a bunch of binders to SDL.

It's also advantageous since python is an easy scripting language that takes very little time to deploy. I even know a few C programmers who mock things up with python sometimes.


#4966503 Macs vs PCs?

Posted by DZee on 05 August 2012 - 06:41 PM

I much rather run on Unix for programming. It depends what technology you are using, but if you are an advocate of open source development it is the only real choice. Installing trough the package manager is a snap and gets you started on things instantly.

I don't want to generalize, but from what I've witnessed most companies use Windows for the Visual Studio suite, Visual C++ and C# usually mean using Windows. There's probably an artist department running on macs depending on their preference.


#4965349 std::vector<char> in C++/CLI?

Posted by DZee on 01 August 2012 - 06:13 PM

A few months ago I ported all the Kinect C# code to C++/CLI and it took months. I can't remember exactly, but know that a byte[] is equivalent to unsigned char(Unsigned 8-bit integer). I used regular buffer arrays for my work, I think they were pointers, so I can't help you with that vector signature.

You should be able to get away with a regular [ ] array. Perhaps a ^ handle pointer. Thing is I was porting from C# to C++ and you are doing the opposite, can't help you more than that =/.


I'm not 100%, but from memory, you might have to use a uchar * and point to the first block of memory and pin it in managed code to convert it.


#4963155 Please help, I don't know if it's compiler's problem or my proble...

Posted by DZee on 25 July 2012 - 08:39 PM

#include <iostream>
using namespace std;

int main()
{

int a;

cout << "Please type a letter which will then be printed out: ";

cin >> a;

cout << a;

return 0;
}


1- Use code tags.
2- Why are you asking for a letter when you are declaring an int?
3- Use a proper main function.
4- Make it a habit to initialize local variables in function scope to a default value. Otherwise the compiler fills it with whatever might be lying in the memory at that moment.

#include <iostream>
using namespace std;
int main( int argc, char* args[] )
{
//Buffer
char a[250] = {};

cout << "Please type a letter which will then be printed out: ";
cin >> a;
cout << a;

cin.get();cin.get();

return 0;
}

If you don't feel at ease with arrays you can also use std::string, that is if you need dynamic length strings.


#4959066 Using Multiple Languages In One Project

Posted by DZee on 14 July 2012 - 08:13 AM

I'd like to add, as a general rule don't mix languages unless for the popular combinations such as those that have already been brought up above. I've dabbled for 6 months in C++/CLI and converting array's of bytes trough another language just to get it's data was a very tedious process. I literally spent one month making an interface DLL that would be compiled in /clr. My other choice was creating a servery with some TCP message forwarding the results to the other application.


#4958608 Setting up for a team project

Posted by DZee on 12 July 2012 - 06:49 PM

I recommend git if you have the choice. Here's a resource that can get your started on using it with commands. It might feel slow when you begin, but eventually it becomes second nature.

http://cworth.org/hgbook-git/tour/

Here is the official website just in case.

http://git-scm.com/


#4958234 C++ As First Language

Posted by DZee on 11 July 2012 - 08:20 PM

I honestly don't think C++ is that hard. It's just very broad and flexible so it's easy to overlook certain features. Or if I rephrase you can do so much with it that it can be a little confusing for someone who's new to understand why the language is so detailed and let's you do certain things until you understand more advanced concepts.

Personally if I had to learn a first language I would choose Java because it's syntax is similar to C++ and it's easier ; pretty much every problem is documented on the web making it easy to move on. It also renders the same results no matter your OS.

Then again, my two friends learned C as their first language and they rock. It's all about how much effort you are willing to put into learning. They are both in electrical engineering though and rather strong in arithmetic's.


#4958206 "Make Games, Not Engines".. But how?

Posted by DZee on 11 July 2012 - 05:37 PM

Obviously not getting my hands dirty hasn't worked out for me well because after what seems like a year haha. I haven't actually finished a game-related project in that long :/. Looks like I should stop trying to be perfect Posted Image


Rule #1 Always finish what you have started.

There's nothing worse than seeing a clutter of half-finished projects in a folder. You have nothing to show and you have nothing to be proud of if you know what I mean. Even when you are nearing the completion of something that is starting to bore you, take some time off and try finishing it off at a later time. You'll feel more confident knowing you have a few games that work well.


#4957866 "Make Games, Not Engines".. But how?

Posted by DZee on 10 July 2012 - 08:48 PM

They say you shouldn't try to write the most optimized version of a function and instead write the function and get something that works first. I'd like to thing it's the same with writing your game down. I don't see how you can fall into such troubles thinking of a pong game. When you start writing it aim for the simplest parts first. I'd start with drawing rectangles on the screen, eventually moving the ball and then collision detection. After that you can start thinking of showing off some stats and putting sound effects. You can't possibly go out and think of everything at once.

I'm not saying it's bad to plan ahead a little, but if you don't have the experience take one step at a time. If you are smart, you will divide your functionality into classes. A few games down the road you will probably be able to reuse a sound class, a timer class, a physics class... and that can compose an "engine". You seem to worry way too much about the global aspect of your project, don't get overwhelmed. Worse thing that can happen is having to re-write a class because it wasn't good enough or you realized you could make it more generic. Aren't you noticing something? By making that mistake you are writing better code!

Biggest problem for all the beginners around here is that their too afraid to make mistakes. Get your hands dirty.


#4957824 Setting up for a team project

Posted by DZee on 10 July 2012 - 05:12 PM

You can just download git or svn and use the command-line. Some other third-party software enable most of these commands as GUI buttons integrated within the explorer(RabbitCVS/Tortoise etc).

Personally I like using the command-line because it pulls you out of being dependent on the OS. We have installed both of them on our server for private use because we didn't want our code uploaded on an external server.


#4957494 How to not become overwhelmed....

Posted by DZee on 09 July 2012 - 09:22 PM

The more I look at game programming the more the rift between what I’m doing and what’s needed is growing.


Here's the harsh truth, everything that's considering "fun" is complicated and takes hard work. Some small teams have managed to create great indie games trough a lot of time and stress and you know where I'm getting at. It's the humans fundamental approach to life. Why is it that building a sand castle involves more time and knowledge than destroying one?

Have you ever tried creating mathematical models that simulate the action of a car suspension getting repeatedly hit by an external force to see how it behaves trough time? It's a second order differential(linear) function, you need to have knowledge of derivatives and integrals and ideally how to do LaPlace transformations. Why is that so difficult? because the laws that govern are world are complex.

And this is great; because it separates people with willpower and tenacity from the weak. If games like D3 and Skyrim took some guy one night to build we'd be out of work.


All I can say is either you change your perspective on how you see your progress or you might as well quit now.


#4957490 looks like I remember less than I thought... *smiles*

Posted by DZee on 09 July 2012 - 09:13 PM

lua arrays ( well tables ) start from 1, and I would consider it a grown man's language.

I would also consider it a mistake on the lua designers behalf, but that's a completely different conversation.


Lol yeah, I can recall it's not the only language that has an index start of one. Although I agree, should be in an ISO standard somewhere for defining new languages. It's unnecessary trouble for us.


#4956957 I can play sounds?:O

Posted by DZee on 08 July 2012 - 10:35 AM

The easiest and most straight forward way is to use an external library. I've written my own .wav decoder once and it's rather nightmarish.

Now, which library depends on what exactly you want to do. If you want to analyse streams of bytes as the sound goes then some libraries are better suited for that. If you are simply looking for something that will let you read a specific file format then there's easier stuff you can use.

I'd recommend checking out SDL since it comes with image loading features, threading, sound, etc. It's a nice package that will get you up and running fast. Check this page out : http://lazyfoo.net/SDL_tutorials/lesson11/index.php




PARTNERS