difference between C# C++ and Basic

2effe87b59a80742cce3984b0d4614dd
0
krayziez 101 Feb 10, 2011 at 02:26

I wanted to create a game, maybe MMO or at least a single player 3D game, or possibly a 2D game and wanted to know if I can do it in VB? I wanted to avoid C++ or anything similar just because I’ve had better experiences with VB. I remembered my VB classes were so much more fun than C++. I was able to create the programs much faster. I just really don’t like C++ all that much just because it more tedious and isn’t as easy as Basic. But I heard that VB is not powerful enough for powerful games, only for simple programs that you want to program real fast. Let me know your take on these guys for the programmers who program games only.

Also, on another point, I may hire programmers to program the game, and was wondering if it’s a good idea that the employer (me) should know programming so that it’s more effective to communicate with the programmers what to do. I really want to just tell the programmers what to do without having to learn how to program but if that limits the power of the program (or game) then I may have to learn at least the basics of programming. Let me know your thoughts on this. I’d rather use my own time to do what I do best (retail business) to make money to use that money to hire someone else to program.

38 Replies

Please log in or register to post a reply.

6837d514b487de395be51432d9cdd078
0
TheNut 179 Feb 10, 2011 at 03:44

It seems to me it’s not really VB you like most, but rather the availability and ease of use of tools to make games. FYI VB is deprecated and Microsoft recommends you update to .NET. In .NET, you can chose VB.NET or C# language (and there are many others too).

It’s difficult to give you advice because you ask two questions that are complete opposites to each other. If you want to be a developer, you have to get your hands dirty. You need to be technically minded and willing to solve complex problems. Even the best game editors out there will require technical involvement. Since you mentioned you are more in line with the business side of things, I recommend you stick with that unless you’re looking for a career change. Having technical knowledge of game development is a real advantage, but if it’s something you don’t already possess then you will need to gain experience along the way. Your best source of experience will come from the professionals you hire.

A638aa42130293f319eda7fa4ba121f4
0
fireside 141 Feb 10, 2011 at 04:05

If you are trying to make a commercial game, I think you are in trouble because of your lack of experience. It’s a cutthroat market with lots of failures. You should think it over carefully because employing programmers and artists can get very expensive. Most MMO’s fail and they require the largest up front investment.

It doesn’t make much sense to do a hobby game hiring help, unless possibly a small 2d game or something. If you want the experience of designing a small game, I would suggest looking at Gamemaker and design small 2d games, but if you want to do something large and hire people, I think you are going to get taken to the cleaners. At least do yourself a favor and design a small game to start with, then use Gamemaker or some other 2d engine, and possibly hire artists once you get the game play worked out.

2effe87b59a80742cce3984b0d4614dd
0
krayziez 101 Feb 10, 2011 at 13:37

Well when I say “VB” I mean vb.net of course. So the question still remains: is VB.net still good to program these complex games? I’m going to learn to program simple ones first of course, but eventually I wanted to get into complex games. I wanted to get myself technically savy with all of this as well, that’s why I wanted to train myself a bit. However, if the industry standard is with C++ then I’d have to learn that instead of VB.net. I really was hoping I’d learn VB first though but I don’t want to waste my time with it if it’s going to be useless in the future.

Also, when you say 2D, do you mean real 2D or semi-3D ish? Like for example, Warcraft 3 or Starcraft 2 where when the player zooms in, it’s 3D however it’s not first person 3D really. It’s still 2D the way you play it, but it’s turned into 3D just for looks. You don’t really move the camera left or right, just up and down. That’s something I could be interested in doing for now.

I consider myself semi-technically savy because I built my online retail company from the ground up and learned alot along the way. I hope to achieve this as well with the game I’m going to create, just learning as I go, which to me is the best way to go as I can see the results as I learn.

2effe87b59a80742cce3984b0d4614dd
0
krayziez 101 Feb 10, 2011 at 13:51

@fireside

If you are trying to make a commercial game, I think you are in trouble because of your lack of experience. It’s a cutthroat market with lots of failures. You should think it over carefully because employing programmers and artists can get very expensive. Most MMO’s fail and they require the largest up front investment. It doesn’t make much sense to do a hobby game hiring help, unless possibly a small 2d game or something. If you want the experience of designing a small game, I would suggest looking at Gamemaker and design small 2d games, but if you want to do something large and hire people, I think you are going to get taken to the cleaners. At least do yourself a favor and design a small game to start with, then use Gamemaker or some other 2d engine, and possibly hire artists once you get the game play worked out.

You mentioned these game making tools, but what programming language should I learn in order to make these games? I’m assuming there’s programming needed of course. But do these tools use VB? I just really want to know where I should start. I’m ready right now to learn VB.net however I really don’t want to have to go through it if it’s not industry standard and if C++ or C# is the only way to program complex games in the future. I would much rather just stick to VB.net at least for now because that will motivate me in at least starting off. Possibly in the future, I’ll do some C++ once I get used to programming.

I know it will take a long time for me to get to the MMO point, but I think I’ll do some small games for now. Thanks for your input.

8676d29610e6c98d6dd2d9c38528cd9c
0
alphadog 101 Feb 10, 2011 at 14:56

VB.NET and C# perform as well; they both get reduced to similar intermediate language, which gets run on the .NET.

The reason to learn C++ is primarily because it is the dominant language of the game industry. Also, it is a lower-level language than C#/VB. With that comes more flexibility, power and fine-grained control at the expense of ease of use, learning curve and maintainability.

Eventually, if you continue to learn the field of software development, you will (hopefully) know more than one language; C#, C++, Python, C and some assembly will be the likeliest ones you’ll encounter.

As for hiring, your challenge is that you seem to be ready to flood yourself with too much new stuff and burn out like a shooting star. Secondarily, not knowing how to code means not knowing a good coder from a bad one. Not a huge issue, but one to think about as you layer challenge over challenge.

Anyways, get a book on game development, and read up on the field. Make sure you want to do this, as it is much more challenging a field than configuring a shopping cart.

6837d514b487de395be51432d9cdd078
0
TheNut 179 Feb 10, 2011 at 15:26

@krayziez

I really was hoping I’d learn VB first though but I don’t want to waste my time with it if it’s going to be useless in the future.

When it comes to .NET, it doesn’t matter what language you use. Everything translates to a common intermediate language. Although the majority of developers use C#, so I would recommend you lean more towards that language to make things easier for you down the road. VB devs are also usually mocked at :lol:

I wouldn’t worry about C++. I can tell you want to stay as high level as possible, so don’t kill yourself over C++. You have access to Win Forms, Windows Presentation Format (WPF), and DirectX in .NET. Whether you want 2D or 3D, you’re going to have an easier time accomplishing your goals with .NET. If you’re interested in 2D games, look into WPF. It’s an amazing UI framework. Microsoft also has a tool called Blend that will help you build and even prototype your games with ease. There is a couple of other powerful frameworks out there for you to eventually try as well.

A638aa42130293f319eda7fa4ba121f4
0
fireside 141 Feb 10, 2011 at 16:09

You mentioned these game making tools, but what programming language should I learn in order to make these games?

I would start with C# rather than vb because a lot of engines don’t offer vb as a choice. Unity, for instance. From what you say, I would not learn c++ because it’s a picky language and you can write games without it these days, even large 3d games, by using an engine. It can lead to a lot of debugging time that is better spent in design. You can choose either 2d or 3d. If you do want to learn 3d, I would recommend picking up Unity’s free engine. There are many tutorials for it and it’s a lot of fun from what I’ve tried. Most of the tutorials are in Javascript, which isn’t much different, but I would still recommend picking tutorials with C# instead.

For a 2d game, I would recommend visual C# and XNA.
2d is 2d. There are tricks to make it appear 3d but they are for advanced programming. You are better off just doing simple 2d games to learn game programming and then going to 3d if that’s the look you want.

The tutorials on this page are in C# for a hack and slash type game in Unity which would be good after the initial tutorials on interface.

http://www.burgzergarcade.com/hack-slash-rpg-unity3d-game-engine-tutorial

I’ve seen one MMO written with Unity on cartoon network, so it is possible, but it probably isn’t the best engine for one, but it’s an excellent design tool, so a good first engine and a way to get your ideas across. Unity is one of the most fun engines I’ve tried.

2effe87b59a80742cce3984b0d4614dd
0
krayziez 101 Feb 10, 2011 at 17:30

Thanks for all the responses. One quick question, is C# almost the same as C++ in terms of complexity and level? I heard it’s a low level language like C++ right? I’ve never delved into it before so I don’t know, but I do hope it’s as fun as VB.net. I’ll pick up a book on C# today.

A638aa42130293f319eda7fa4ba121f4
0
fireside 141 Feb 10, 2011 at 17:59

I heard it’s a low level language like C++ right?

No, it’s not a low level language. Any language that is doing memory management can’t be considered low level. However, C# is derived from C, so the structure of the language is largely the same. It’s just better designed and it takes care of memory, which makes it also slower. Normally that doesn’t have much effect because most of the engines like Unity and XNA are written in C++ or C, so 90 percent of the code is being run at low level.

8676d29610e6c98d6dd2d9c38528cd9c
0
alphadog 101 Feb 10, 2011 at 18:01

C# is more approachable than C++, has less of a learning curve to get functional with it. However, it can get very complicated too. For example, while generics are similar to templates, they aren’t as powerful, but they are pretty darn complicated for a newbie!

C# is a higher-level language than C++, because it abstracts more of the machine (ex: memory management).

I see VB going the way of Pascal and COBOL. Always will be there, but generally at a low-level, and probably not present in game development.

2effe87b59a80742cce3984b0d4614dd
0
krayziez 101 Feb 11, 2011 at 00:38

@fireside

No, it’s not a low level language. Any language that is doing memory management can’t be considered low level. However, C# is derived from C, so the structure of the language is largely the same. It’s just better designed and it takes care of memory, which makes it also slower. Normally that doesn’t have much effect because most of the engines like Unity and XNA are written in C++ or C, so 90 percent of the code is being run at low level.

OK so if I go with C# then you’re saying most of the engines won’t be written in this language right? Only in C++ and C? I might have misunderstood you when you say “most of the engines are written in C++”. You mean the software itself is written in C++ but we can still use C# or other languages to write codes on it?

I do hope some popular game engines will allow for C# programming and also C# programmers won’t be mocked like VB programmers :) I wouldn’t be mocked by my employees if I only know C# right? I just want to avoid C++ and C like the plague.

I have the C# program ready and the book ready so if you guys give me the go-ahead, I’ll start on C# now. Thanks!

A638aa42130293f319eda7fa4ba121f4
0
fireside 141 Feb 11, 2011 at 03:34

Yes. The engines are written in c or c++, so they are fast, but a lot of them are made to script with c#, so you’ll have your choice of quite a few 3d engines that you can program whatever type of game you like. It’s really the better way to go if your main focus is on game design because it will save you time in writing code and debugging, and in learning the language in the first place, and there is normally only about a 5 percent drop in speed, so unless you are doing an extremely processor intensive game, it will be unnoticeable. It’s common even for high end professional games anymore, because it allows artists, etc, to add game levels.

877747431c7c13326469c4bbaf48d61d
0
victory08 101 Feb 15, 2011 at 08:52

As for me, I think that the difference between them is not so important, because a lot of engineers had chosen one language and it became like a habit in using. But the difference is clear and consists of convenience, speed and the result.

46462f88a1670d7e9cbbfa360aa20134
0
juhnu 101 Feb 15, 2011 at 20:59

Lots of people tend to focus too much on performance differences and choose C++ purely on that basis, but is it the only thing to consider?

C++ superiority might very well true if a project is given infinite amount of development time and resources, but that’s hardly ever never the case and thus modern and more productive languages can often be a better choice as they let developers to create better code in shorter time.

This practically means that when C++ programmer is wasting time on building application framework, compiling code and doing low-level “optimizations”, other developers using a modern language such as C# can focus their time on working on gameplay and doing high-level optimizations - things that will give better ROI in the end.

I would personally choose C# or another modern language for making a new game (AAA) any day.

8676d29610e6c98d6dd2d9c38528cd9c
0
alphadog 101 Feb 15, 2011 at 21:01

Generally agreed, except that if you are making a game pushing the envelope, you don’t have libraries and/or performance is an issue. This isn’t an issue solely for AAA games.

That’s why C++ isn’t going anywhere. However, it’s dominance isn’t what it used to be…

2b97deded6213469bcd87b65cce5d014
0
Mihail121 102 Feb 15, 2011 at 22:17

@juhnu

Lots of people tend to focus too much on performance differences and choose C++ purely on that basis, but is it the only thing to consider?

C++ superiority might very well true if a project is given infinite amount of development time and resources, but that’s hardly ever never the case and thus modern and more productive languages can often be a better choice as they let developers to create better code in shorter time.

This practically means that when C++ programmer is wasting time on building application framework, compiling code and doing low-level “optimizations”, other developers using a modern language such as C# can focus their time on working on gameplay and doing high-level optimizations - things that will give better ROI in the end.

I would personally choose C# or another modern language for making a new game (AAA) any day.

C# is even too much as the developer is overwhelmed with some heavy syntax if not professional in that language. I would definetely go for the .NET platform providing vast number of tools, but probably pick IronPython/Boo/LUA.NET or something similar as language of choice. C++ is forbidden at the place I work for, after a number of idiotic revisions, it has become absolutely unusable. No one is willing to maintain such code and I understand that. Also, as software engineers, we must be aware that the compiler can optimize for me quite nicely as I enjoy advanced technologies and tools as LINQ. For everything low-level, there’s now C1X.

8676d29610e6c98d6dd2d9c38528cd9c
0
alphadog 101 Feb 16, 2011 at 13:22

@Mihail121

after a number of idiotic revisions, it has become absolutely unusable.

While it is definitely one of the more complex languages out there, I don’t know of any revision that makes the whole language unusable. There are, however, a lot of semantics that many will never need.

340bf64ac6abda6e40f7e860279823cb
0
_oisyn 101 Feb 16, 2011 at 13:37

Maybe he’s referring to their own C++ codebase? Or a specific compiler?

6837d514b487de395be51432d9cdd078
0
TheNut 179 Feb 16, 2011 at 15:32

@.oisyn

Maybe he’s referring to their own C++ codebase?

:lol:

I ported my engine to quite a few languages and the effort involved in making anything is roughly the same. It all comes down to code quality and frameworks, both of which are independent of the language.

2b97deded6213469bcd87b65cce5d014
0
Mihail121 102 Feb 16, 2011 at 16:39

With usability I mean the standard combo of effectivity, efficiency and user-satisfaction with respect to some goal. C++ is just archaic in the sense that the user is expected to do quite a lot and the compiler is assumed to be rather dumb. Well modern compilers are quite smart so languages can be simplified which in turn requires less reading and reduces the price of software (while quality is high enough).

While I don’t expect Smalltalk-like standard library from any language other than Smalltalk, C++ fails to meet even basic principles of code reuse. It’s easy to reuse primitives like strings, stacks, vectors etc., but managing COM objects, service containers etc. becomes quite hard (don’t give me the ATL argument). Managing Java Beans on the other side is quite easy.

The whole purpose of C++ is performance and some code reuse, but I believe only the first goal is achieved and that particular goal is achievable with pure C as well. Can you really tell your customers you’ll boost the price of the product by $10 just to get one additional frame per second? Nope. Will they be happy that I can generate half of the code base from nicely structured, understandable, domain-specific UML models and then manually link the rest of the puzzle? Yes!

There is no single truth of course, but writing a whole game in just C++ sounds quite a bit of an overkill.

8676d29610e6c98d6dd2d9c38528cd9c
0
alphadog 101 Feb 16, 2011 at 17:09

You’ve conflated a lot of different issues.

For example, COM is a framework. In fact, Microsoft bills COM as a language-neutral concept that allows objects to communicate across systems, platforms, languages, etc. And, managed C++ is different from the broader concept of the C++ language itself.

Take C++, sprinkle in the right few libraries as needed, so as to minimize the amount of code you have to write in your project, and it’s no less effective, efficient or satisfying that C# or Java.

The only difference is that C++, without libraries/frameworks, does less for you than C# without libraries/frameworks. That can be both a curse and a boon. What if you don’t like how C# garbage collects? What if you have an actual need for multiple inheritance? What if you could make efficient use of pointers and be really user satisfied by it?

But, although the road you took seems wrong to me, the final conclusion is something I agree with: writing a whole game these days in C++ may not be your best option. Writing the non-critical parts in a productive, higher-level language like C# or Python, and cutting in the performance-critical parts with C is a useful, best-of-breed approach.

46462f88a1670d7e9cbbfa360aa20134
0
juhnu 101 Feb 16, 2011 at 23:03

@alphadog

Take C++, sprinkle in the right few libraries as needed, so as to minimize the amount of code you have to write in your project, and it’s no less effective, efficient or satisfying that C# or Java.

One problem with C++ in this scenario is that it doesn’t have commonly accepted coding conventions, programming patterns and rich enough base API. This means that every library must implement it’s own coding standards, which means libraries do not fit well together and have different look’n’feel in them: starting from basic error handling to parameter passing, memory handling. Even worse thing is that since there is no rich enough base API to use, every library must use a framework of some sort to do similar things. There are lots of boilerplate you need to write to make things interoperate in a nice way and it’s not prettly really and even worse - it’s not efficient in any way.

The only difference is that C++, without libraries/frameworks, does less for you than C# without libraries/frameworks. That can be both a curse and a boon. What if you don’t like how C# garbage collects? What if you have an actual need for multiple inheritance? What if you could make efficient use of pointers and be really user satisfied by it?

You are right that there are some features in C++ that someone might favor, but don’t forget that there are many constructs in modern languages that are simply impossible to do in C++ in a sane way. For example C# has LINQ, support for anonymous delegates, etc. which have no C++ counterparts at all.

But, although the road you took seems wrong to me, the final conclusion is something I agree with: writing a whole game these days in C++ may not be your best option. Writing the non-critical parts in a productive, higher-level language like C# or Python, and cutting in the performance-critical parts with C is a useful, best-of-breed approach.

This one I think we all agree on, but that said I think that most games could do without C-coded parts completely and not even notice it.

8676d29610e6c98d6dd2d9c38528cd9c
0
alphadog 101 Feb 17, 2011 at 00:03

@juhnu

One problem with C++ in this scenario is that it doesn’t have commonly accepted coding conventions, programming patterns and rich enough base API.

Unless I misunderstand you, this is an issue pretty much for any language. Are you saying that all C# library/framework writers write with the same conventions and patterns, and create similar look-and-feel APIs?
@juhnu

You are right that there are some features in C++ that someone might favor, but don’t forget that there are many constructs in modern languages that are simply impossible to do in C++ in a sane way.

And, vice versa. That was exactly my counterpoint to Mihail121… perhaps poorly made. My point was that generally-speaking, selecting a language is selecting tradeoffs. C++ is not universally less useable, in toto, than C#. But, with that said, yes, there are tradeoffs. An OO language will be different than a functional language.
@juhnu

For example C# has LINQ, support for anonymous delegates, etc. which have no C++ counterparts at all.

Sure. And, C# isn’t quite on par with Haskell. For example, the Haskell system of type classes is more “powerful” than the generic type system in C#.

As my own counterpoint, lambda functions and expressions are in the C++0x specification, and is already part of many compilers. So, you can get some lambda sugar in your C++, if you crave for it. But, you should make one type of language pretend its another. :)

340bf64ac6abda6e40f7e860279823cb
0
_oisyn 101 Feb 17, 2011 at 08:08

@TheNut

:)

I wasn’t trying to be funny or sarcastic, I’m sorry if I came across that way. Mihail spoke about “idiotic revisions” that made it completely unusable. Since he couldn’t be talking about C++ (as it only had 1 revision since standardization, in 2003, and the next one on the way - both of which are far from idiotic let alone made it unusable), I assumed he must’ve been talking about something else.

46462f88a1670d7e9cbbfa360aa20134
0
juhnu 101 Feb 17, 2011 at 11:19

@alphadog

Unless I misunderstand you, this is an issue pretty much for any language. Are you saying that all C# library/framework writers write with the same conventions and patterns, and create similar look-and-feel APIs?

Yes, that’s exactly what I meant. Another thing is that since the .NET API is rich enough, the libraries do not need to reinvent the wheel or use some third party frameworks, which in turn makes them simpler and more lightweight to use and include in your project.

Sure. And, C# isn’t quite on par with Haskell. For example, the Haskell system of type classes is more “powerful” than the generic type system in C#. As my own counterpoint, lambda functions and expressions are in the C++0x specification, and is already part of many compilers. So, you can get some lambda sugar in your C++, if you crave for it. But, you should make one type of language pretend its another. :wacko:

Sure things can be in theory anything and what not, but it ultimately boils down to productivity/quality/usability in the end. I guess my original point was that “performance” shouldn’t be the main factor deciding what language to use and people need to take account many other things, that are often much more important, as well.

00000000000000000000000000000000
0
Anonymous Feb 25, 2011 at 20:18

VB is for total noobs
c# is for medium noobs
c++ is for non noobs

00000000000000000000000000000000
0
Anonymous Feb 25, 2011 at 20:23

i learned basic when i was 9
and thats the sad truth

2b97deded6213469bcd87b65cce5d014
0
Mihail121 102 Feb 25, 2011 at 20:31

@enjoycrf

i learned basic when i was 9
and thats the sad truth

I’ll be sorry to disappoint you, but all three languages are Turing-complete, well accepted and in active use. “Learning” a language just because is not a wise choice, picking the right language for a specific job on the other hand is.

00000000000000000000000000000000
0
Anonymous Feb 25, 2011 at 20:34

i know them all MISHA plz stop bothering me jeezus
listen to what you just said
its kind of like saying
being wise is not wise

8676d29610e6c98d6dd2d9c38528cd9c
0
alphadog 101 Feb 25, 2011 at 21:05

@enjoycrf

VB is for total noobs
c# is for medium noobs
c++ is for non noobs

Thank you for your in-depth evaluation and poignant comparison of the pros and cons of three major languages. I definitely learned a lot.

340bf64ac6abda6e40f7e860279823cb
0
_oisyn 101 Feb 26, 2011 at 12:10

@enjoycrf

VB is for total noobs
c# is for medium noobs
c++ is for non noobs

I’m sorry but I just can’t take someone who thinks that way seriously. It just shows a complete lack of professionality. How old are you? Like, 12? And for god’s sake, learn to use punctuation.

Fd80f81596aa1cf809ceb1c2077e190b
0
rouncer 104 Aug 13, 2011 at 07:26

I learnt basic when i was 7, and now i just code procedurally. :)

(actually if im honest it was 8, i was begging my father for a computer at 7… i remember in year 2, “what do you want to be when you grow up?” “i want to be a computer programmer” :) )

Ceee4d1295c32a0c1c08a9eae8c9459d
0
v71 105 Aug 13, 2011 at 14:03

i learned basic at 4

Fd80f81596aa1cf809ceb1c2077e190b
0
rouncer 104 Aug 13, 2011 at 17:59

wow! not lieing?
Im not sure I even knew what a computer was at that age, I was too busy climbing the cupboards. :)

87e614b8b888bb2c4485c1ac16d8c779
0
moe 101 Aug 13, 2011 at 18:16

When I was 4 nobody could afford a homecomputer… damn I am getting old :(

Ceee4d1295c32a0c1c08a9eae8c9459d
0
v71 105 Aug 14, 2011 at 14:28

Well , i was lying, i learned at 6 , lol, it was my daddy’s tandy 8 bit

Fd80f81596aa1cf809ceb1c2077e190b
0
rouncer 104 Aug 14, 2011 at 22:49

hehe still very young computer scientist there.

58f167e03cd71a8d45301e2ef4a6d48c
0
jcurtis 101 Sep 05, 2011 at 02:21

It actually is difficult to give an advice as the two questions you posted are not in parallel with each other. Though for the language, I suggest that you do not use VB unless you are willing to upgrade it to .net or just use C#.

I have to agree with the post above that you need to know the base knowledge in game development or you might find it hard to cope up. Though I am sure that you will learn from whatever experience you pick up and from feedback from people you will hire, which I assume are professionals.