Advertisement

VB vs C++

Started by January 01, 2002 12:32 AM
9 comments, last by DarkenMerlin 22 years, 11 months ago
Im in a comp sci class and we just spend first semster learning VB, so i known the basics of it. Next semster we start C++. I was just wondering if i should spend time learning more VB (towards making games) or wait and learn C++ and dont even waster my time with VB? Thanks for any responses.
To do all that one is able to do, is to be a man; to do all that one would like to do, is to be a god.- Napoleon Bonaparte
Its all down to personal preference, but most people (including myself) prefer C/C++ over any other language for making games in.

-----------------------
0wn 0wn 0wn your goat
gently down the pw33n
-----------------------"When I have a problem on an Nvidia, I assume that it is my fault. With anyone else's drivers, I assume it is their fault" - John Carmack
Advertisement
id say go learn c++, vb is crapola

c++ is portable
c++ doesnt require runtime libraries like vb
c++ can do low level stuff as easily as high level stuff
c++ is more widely used

of course this is just my opinion, so dont flame me
quote: Original post by barazor
c++ doesnt require runtime libraries like vb

Actually, it can require runtime libraries. However, they''re much small libraries and most often you can statically link them with your executable if you''d like to.
quote: Original post by barazor
c++ is more widely use

For what? For games? Yes, it is. It depends what type of application you meant .

I''m also of the opinion that you should for C/C++ before you get into making games.

[Resist Windows XP''s Invasive Production Activation Technology!]
quote:
c++ can do low level stuff as easily as high level stuff


I''d probably have to disagree with this one too. Fairly subjective, but consider something low level, say executing the code (if there is any) in an arbitary block of memory. This is what most people would call low level. Now, what if instead you wanted to do something like create a window which accepts messages from windows and so on. High level, but for some, it is a lot harder.

Personally, I prefer VB, but I know a bit of C++ now just because I read so much of it. I find that doing the lower level stuff in VB fine, and I''ve never reached a roadblock. If anyone says that any mainstream language is crap, then there are obviously going to be lots of people who use it who disagree... COBOL is the exception just in case any of you think it is mainstream.

What VB can''t do is write a non-Windows application. You can tweak as much as you want, but it just isn''t going to happen. (Although you could get Phoenix Basic from www.janus-software.com which is pretty much VB for linux)

About VB being slow, (maybe 2 or three more posts and someone will say it I reckon ), the speed difference for most things in minimal, a few rough estimates:

2d graphics: 10% slower
3d graphics: 15% slower
CPU intensive calculations (eg fractals or something like that): 25% slower

I''ve seen people saying that VB is slow and showing me a comparision between 2 programs, one in C++ and one in VB, where they are supposed to be identical... most cases, it isn''t that VB is slow, it is that the person who programmed the VB code didn''t understand VB very well. So the lesson is, always blame yourself.

Oh, and one more thing with VB. Because it is MS only, there is only one IDE, and unfortunately it has a few bugs. Most of which you won''t encounter for a long time. But they are there. Annoying bugs like VB compiling code it isn''t supposed to are ''fixed'' by just inserting a blank line and removing it. But I''ve seen people working on large projects have VB get into a state where it won''t compile even though nothing has changed. I''m not sure what the solution for it was though.

C++ doesn''t really have that problem because there are so many IDEs that one of them is bound to get it right ... and you don''t need an IDE.

Finally... I really love the quick development time of VB. I tend to be a curious person a lot, so when doing maths problems, sometimes I want to graph something weird or whatever to see what it looks like, in a few minutes it can be working. The other day, I needed some webspace temporarily, so in a couple of minutes, I coded a simple web server for my own computer.

Trying is the first step towards failure.
Trying is the first step towards failure.
Ease of use is relitive; everything you have done before is easy to you now:

C is easy
C++ is easy
Assembly is easy
Ray tracing is easy
Terrain is easy
Volumetric rendering is easy

Doing something that has never been thought of before.. thats hard; untill you do it.

So the main thing in question here, is power; and these are the questions you should ask:
Can C/C++ do things that you simply can not do in VB?
Is C/C++ faster then VB?
Is it significantly faster?
For someone who knows VB; how much more effort would it take to learn C/C++?
How much effort am I willing to exert?

And the answers to those questions are: Yes, Yes, Yes, Not too much, and the last you should answer yourself.. and you should ask that last to yourself for almost all solutions in anything. As professional programming isn''t about what you can do in an infinite ammount of time and resources; but what you can do with a limited ammount of time, and a limited ammount of resources.

It would be prudent for one to tell you what choice to make; we can lay out the angles, but the choice is yours.
"All programmers are playwrights and all computers are lousy actors." -Anon.
Advertisement
To study is to screw up,
To learn is to remember those screw ups,
To become wise is to screw up alot.

Experience is the only real teacher.
"All programmers are playwrights and all computers are lousy actors." -Anon.
I have never heard of a commercial game title programmed in VB. They are all done in C/C++

In the professional world, VB is seen as a beginner language for kids (although this is not true, since VB isn''t that bad), don''t try to apply at some pro development company by telling them you know VB. Be prepared for a big laugh, and a ''no thanks, we use C/C++''.
I personally use C/C++, because of all the points mentioned above, plus it definitely is the marketleading language. Not that VB is bad, but C/C++ is better.

But in the end, you should just try it out for yourself, it always is a metter of preference (flame-retarding statement )
I don''t know many pros (professional game programmers that is, not professional programmers, ''cos I''m one of them ), but one I do know was telling me about how he got the job. Basically, he showed them some VB demos, and finished VB games, told them that he knew C++, and they gave him the job. Big deal, one story. The point is, that it isn''t what language you use, it is whether you can program - problem solving and stuff like that.

A language is just a language. It doesn''t matter how well you speak English, it doesn''t mean you can write a great book. Same kind of deal here.

Use VB, use C++. In the end, I''m pretty sure that the end result will be the same. But I''m also pretty sure that for people who won''t be able to program unless they devote more time than they are willing to spend, then they will get further in VB than they would in C++... this is not necessarily a good thing.

Trying is the first step towards failure.
Trying is the first step towards failure.
No doubt! U should learn more C++! VB might be good sometimes due to it´s easy interface and such, but C++ is more a low level language and you will have much more use of that if you ever want to get into the gaming industries.

<>

This topic is closed to new replies.

Advertisement