|
-
Nov 16th, 2002, 12:50 PM
#1
Thread Starter
Lively Member
Why use c#?
Hey everyone, I have a few questions.
VB was my first language, and it suited me pretty well for a while. However, I'm looking to make games (powerful ones) and I need a language that is capable of doing what I want to do.
I was considering C++, but then I heard about C# from a friend. He tells me that C#, using the .NET platform, will be more compatible with newer versions of windows.
But my question is, is C# good for 3D game programming? I'd really like some more information on it. Thanks!
www.mindset1.com
Religious Debate Forums
-
Nov 16th, 2002, 03:32 PM
#2
Addicted Member
C# and VB are pretty much the same in the following areas:
1) About the same speed
2) Have pretty much the same functionality
3) Have the same compatibitly because the use the .net framework
I main diference in the applications is the syntax.
Jeremy
-
Nov 16th, 2002, 04:23 PM
#3
PowerPoster
For what you want, you are going to want to go with C++. Don't get me wrong, C# is pretty powerful, but it isn't the language of choice for 3D programming.
You would be hard pressed to find many 3D games written in C#. There will be some, but not a lot. If your determined to use C# though, here is a link to get you started:
http://www.c-sharpcorner.com/Directx.asp
-
Nov 16th, 2002, 04:28 PM
#4
Member
I program in VB too. I am learning C# (not for games) becasue I thought C++ was too hard. C# is half way between VB and C++. If I master C# then I can do Java or C++.
-
Nov 17th, 2002, 03:19 PM
#5
Thread Starter
Lively Member
So it's not very easy to create games with C#?
And vb slam, are you saying that I should learn C# and C++ because it would be easier? Thanks.
Also, I assumed little to no games have been made with C# yet, considering it is a sort of young language. Just wondering it it's possible.
www.mindset1.com
Religious Debate Forums
-
Nov 17th, 2002, 04:19 PM
#6
yay gay
C# is faster than vb...vb6 is a interpreted language and C# is a compiled language
-
Nov 17th, 2002, 04:26 PM
#7
PowerPoster
Originally posted by PT Exorcist
C# is faster than vb...vb6 is a interpreted language and C# is a compiled language
Got your facts a little twisted...
VB6 can be compiled to native code. The default is p-code, but you can switch the options to native code, which creates a completely compiled app. When running an app compiled into p-code, it uses the runtime as interpreter. When running an app compiled into native code, it uses the runtime as a true dll (for the forms, buttons, etc).
C# on the other hand is not compiled to native code at first. It is compiled to MSIL. It isn't until the first time it is ran will the JIT compile the MSIL to machine code. After the JIT is ran, then the C# app will be running with machine code.
-
Nov 17th, 2002, 07:41 PM
#8
yay gay
-
Nov 17th, 2002, 11:08 PM
#9
Hyperactive Member
The .NET languages are very new, and because of that, your not going to find very many games written with .net just yet!
However, DirectX 9 is being written specifically for the .NET platform! This makes it safe to assume that you'll be seeing more and more 3d games written with .NET! Benchmarks I've seen also show that .NET is up to 15x faster than VB6, though I havn't tested that out for myself yet.
Lastly, the previous posts seem to imply that VB6 and VB.NET are pretty similar, and that C# is just a .NET version of C++. (at least this is what I see). However, C# and VB.NET, since they both use only the .NET framework, share exactly the same speed and functionality. (C++.NET, however, is a lower-level language, and is capable of creating non-.net programs. However, for 100% .net applications, I hear that C++.NET offers little or no benefit over C# and vb.net).
-
Nov 18th, 2002, 05:25 AM
#10
Hyperactive Member
C/C++ and Assembler are the langauges of choice for game programming so far.
C++ is not hard. Just a sharp learning curve.
I reckon so far games suffer heavily because of runtimes C# puts on itself.
Same story with VB6
Faster Langauge = Faster Game
I also heard that there was a C# game engine written somewhere but I dont know much about it.
VB.NET 15 times faster than VB6? This is something new... So far judging by the benchmarks I've seen it's at least 2 times slower!
Use the right tool for the right job
-
Nov 18th, 2002, 07:46 AM
#11
yay gay
vb.net isnt 15x faster than vb6! and yea..becuz the JIT compiler it lags a lot in my comp at the first time =\
-
Nov 18th, 2002, 08:51 AM
#12
Fanatic Member
Originally posted by made_of_asp
I also heard that there was a C# game engine written somewhere but I dont know much about it.
yep, there was a link posted here a while ago to it, can't find it though, but it's called exoengine if you want to have a look (source code included).
-
Nov 18th, 2002, 12:52 PM
#13
PowerPoster
Just a note, you can write unmanaged code in C#. This means you can do 'unsafe' things such as pointers and such. I am sure you will get a little speed increase when doing so. Of course, even if you do, I don't know how it compares to the speed of C++ doing the same thing.
-
Nov 18th, 2002, 06:08 PM
#14
yay gay
well i never really understood the real power of pointers...maybe only to big loops?
\m/  \m/
-
Nov 22nd, 2002, 09:44 PM
#15
Hyperactive Member
Points are useful
Example
{
int z[20];
for(int i = 0; i < 20; i++)
{
int* p = &z[i];
//now instead of writing 'z[i]', you can just write 'p'
//points can pass variables by references, make your program smaller and more
}
}
-
Nov 23rd, 2002, 07:58 AM
#16
-
Nov 23rd, 2002, 12:01 PM
#17
Hyperactive Member
...but you were right PT. You will only see the impact of this in big loops and / or large arrays. Essentially, you are removing the array limit checking that C# normally does for you.
-scott
he he he
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|