Jump to content

C# or C++ for a project

Shoob
Go to solution Solved by as96,

So, first of all with both C# and C++ you'll have to use external libraries but you don't need to use an engine and for simple stuff it's better not to.

They are both good and powerful languages, I'd say pick whatever you like more, people will bring up the performance argument and say "C++ it's faster" but don't listen to them, at this scale you won't notice any difference, and even in big projects to be actually faster than C# projects you need to know what you are doing, the language alone won't make you engine faster if your memory management sucks.

 

Usually I go with C++ but that's just because I've used it a lot more than C# and more comfortable with it. There are good libraries for both languages the main ones are:

 

SFML [C++ but there are .NET bindings] (it's what I use, it's simple, easy to learn and quite fun to use)

SDL [C, being written in C this is not object oriented, there are .NET bindings available] (Never done anything complex with it since I don't really like it that much)

Monogame [.NET languages] (it's the old XNA nothing to add, it's an excellent framework, if you decide C# pick this)

Cocos2d-x [C++/Js/Lua] (This is an engine but it fits your Visual Studio only requirement, it's derived from the Objective-c version so the syntax is odd in some places)

So I have a project to develop a game. It doesn't need to be something very complicated, nor something really easy like a text adventure. I'm thinking about using C#, because I'm more comfortable with it and making something similar and a bit more advanced than this. I feel like it's too easy though. The professor gave us the option to choose a language we like, even though we study mainly C++. I'm still not sure what exactly I'd like to do as C++ seems like a better idea for developing any kind of game, even though I don't like it at all. How hard is it to develop something graphical with C++ without using a game engine?

From salty to bath salty in 2.9 seconds

 

Link to comment
Share on other sites

Link to post
Share on other sites

More info about the game itself?

 

You can't really make graphical stuff in C++ without external libraries. Still, even then it's not too hard. I'm currently using SFML to make a chess game and I really like the way the library was built : http://linustechtips.com/main/topic/460405-chess-game-in-c-and-sfml-wip/

It's not that hard though.

i5 4670k @ 4.2GHz (Coolermaster Hyper 212 Evo); ASrock Z87 EXTREME4; 8GB Kingston HyperX Beast DDR3 RAM @ 2133MHz; Asus DirectCU GTX 560; Super Flower Golden King 550 Platinum PSU;1TB Seagate Barracuda;Corsair 200r case. 

Link to comment
Share on other sites

Link to post
Share on other sites

I don't know any more info as I got the assignment today and it was only mentioned. The example projects that were shown to us were something like Battle City and we have almost full freedom as it's more of a challenge for a lot of extra points this semester. We are going to study some OpenGL after a few lessons, but I'm not really sure if we are going to seriously learn it or the professor will just mention it and show some things with it.

From salty to bath salty in 2.9 seconds

 

Link to comment
Share on other sites

Link to post
Share on other sites

What about using an Engine like Unity or Unreal? It can make things a lot easier.

 

For C# press Unity

For C++ press Unreal

i7-4790k | MSI Z97 GAMING-5 | Corsair Vengeance 16 GB | Samsung EVO-850 250GB SSD & WD blue 1 TB HDD | EVGA 1070 SC | Red NZXT H440 | Cooler Master G650W

 

Link to comment
Share on other sites

Link to post
Share on other sites

What about using an Engine like Unity or Unreal? It can make things a lot easier.

 

For C# press Unity

For C++ press Unreal

I know that it's easier to make something good with a game engine, but we are only allowed to use an IDE like Visual Studio.

From salty to bath salty in 2.9 seconds

 

Link to comment
Share on other sites

Link to post
Share on other sites

I know that it's easier to make something good with a game engine, but we are only allowed to use an IDE like Visual Studio.

I missed that last part of your post xD sorry lol

 

You might also want to look into Java

i7-4790k | MSI Z97 GAMING-5 | Corsair Vengeance 16 GB | Samsung EVO-850 250GB SSD & WD blue 1 TB HDD | EVGA 1070 SC | Red NZXT H440 | Cooler Master G650W

 

Link to comment
Share on other sites

Link to post
Share on other sites

You can use c# with sharpdx or slimdx. Or C++ with directx11 or if youre feeling less adventurous you could go with ogre. Its not really all that complicated to get a basic renderer running in either language. Keep gameplay simple. No fancy physics or graphics.

CPU: Intel i7 - 5820k @ 4.5GHz, Cooler: Corsair H80i, Motherboard: MSI X99S Gaming 7, RAM: Corsair Vengeance LPX 32GB DDR4 2666MHz CL16,

GPU: ASUS GTX 980 Strix, Case: Corsair 900D, PSU: Corsair AX860i 860W, Keyboard: Logitech G19, Mouse: Corsair M95, Storage: Intel 730 Series 480GB SSD, WD 1.5TB Black

Display: BenQ XL2730Z 2560x1440 144Hz

Link to comment
Share on other sites

Link to post
Share on other sites

I missed that last part of your post xD sorry lol

 

You might also want to look into Java

It was the third option for a language. I didn't mention it as I've never touched Java.

 

 

You can use c# with sharpdx or slimdx. Or C++ with directx11 or if youre feeling less adventurous you could go with ogre. Its not really all that complicated to get a basic renderer running in either language. Keep gameplay simple. No fancy physics or graphics.

Aren't these engines (sharpdx, slimdx, ogre)? Sorry for sounding dumb, but until now I've only written console applications.

From salty to bath salty in 2.9 seconds

 

Link to comment
Share on other sites

Link to post
Share on other sites

Aren't these engines (sharpdx, slimdx, ogre)? Sorry for sounding dumb, but until now I've only written console applications.

Kinda .

i5 4670k @ 4.2GHz (Coolermaster Hyper 212 Evo); ASrock Z87 EXTREME4; 8GB Kingston HyperX Beast DDR3 RAM @ 2133MHz; Asus DirectCU GTX 560; Super Flower Golden King 550 Platinum PSU;1TB Seagate Barracuda;Corsair 200r case. 

Link to comment
Share on other sites

Link to post
Share on other sites

I feel like it's going to more of a trial and error until I find something that suits my needs. XNA and SFML seem interesting and might be suitable. I feel like I'm diving into the unknown with this project until I obtain more information.

From salty to bath salty in 2.9 seconds

 

Link to comment
Share on other sites

Link to post
Share on other sites

I feel like it's going to more of a trial and error until I find something that suits my needs. XNA and SFML seem interesting and might be suitable. I feel like I'm diving into the unknown with this project until I obtain more information.

If you do decide to use XNA, I'd suggest MonoGame instead. Official support for XNA ended years ago, while MonoGame is still active and it's essentially just a remade XNA that works on almost all platforms.

1474412270.2748842

Link to comment
Share on other sites

Link to post
Share on other sites

I feel like it's going to more of a trial and error until I find something that suits my needs. XNA and SFML seem interesting and might be suitable. I feel like I'm diving into the unknown with this project until I obtain more information.

 

Then do something simple like a casino.

Link to comment
Share on other sites

Link to post
Share on other sites

If you do decide to use XNA, I'd suggest MonoGame instead. Official support for XNA ended years ago, while MonoGame is still active and it's essentially just a remade XNA that works on almost all platforms.

I'll check it out. Thanks.

 

 

Then do something simple like a casino.

Thanks for the idea.

 

cE3yyyY.png

 

That's one of the games that students in past years have made with C#. Unfortunately I don't have the code, but it doesn't seem hard since it's a C# form. It might even be copied from somewhere else, I'm not so sure. :D

I feel a bit mode adventurous though and I'd probably try doing harder projects, burn myself and go back to something simpler.

From salty to bath salty in 2.9 seconds

 

Link to comment
Share on other sites

Link to post
Share on other sites

It was the third option for a language. I didn't mention it as I've never touched Java.

Aren't these engines (sharpdx, slimdx, ogre)? Sorry for sounding dumb, but until now I've only written console applications.

No these are not engines. These are wrappers for various graphics api's. Ogre provides a lot of functionality that is typically found in an engine however it is not game engine according to the creators nor does it meet the requirements of a full engine. Also none of these wrappers provide ui's to construct game worlds its done strictly through code.

CPU: Intel i7 - 5820k @ 4.5GHz, Cooler: Corsair H80i, Motherboard: MSI X99S Gaming 7, RAM: Corsair Vengeance LPX 32GB DDR4 2666MHz CL16,

GPU: ASUS GTX 980 Strix, Case: Corsair 900D, PSU: Corsair AX860i 860W, Keyboard: Logitech G19, Mouse: Corsair M95, Storage: Intel 730 Series 480GB SSD, WD 1.5TB Black

Display: BenQ XL2730Z 2560x1440 144Hz

Link to comment
Share on other sites

Link to post
Share on other sites

So, first of all with both C# and C++ you'll have to use external libraries but you don't need to use an engine and for simple stuff it's better not to.

They are both good and powerful languages, I'd say pick whatever you like more, people will bring up the performance argument and say "C++ it's faster" but don't listen to them, at this scale you won't notice any difference, and even in big projects to be actually faster than C# projects you need to know what you are doing, the language alone won't make you engine faster if your memory management sucks.

 

Usually I go with C++ but that's just because I've used it a lot more than C# and more comfortable with it. There are good libraries for both languages the main ones are:

 

SFML [C++ but there are .NET bindings] (it's what I use, it's simple, easy to learn and quite fun to use)

SDL [C, being written in C this is not object oriented, there are .NET bindings available] (Never done anything complex with it since I don't really like it that much)

Monogame [.NET languages] (it's the old XNA nothing to add, it's an excellent framework, if you decide C# pick this)

Cocos2d-x [C++/Js/Lua] (This is an engine but it fits your Visual Studio only requirement, it's derived from the Objective-c version so the syntax is odd in some places)

Link to comment
Share on other sites

Link to post
Share on other sites

So, first of all with both C# and C++ you'll have to use external libraries but you don't need to use an engine and for simple stuff it's better not to.

They are both good and powerful languages, I'd say pick whatever you like more, people will bring up the performance argument and say "C++ it's faster" but don't listen to them, at this scale you won't notice any difference, and even in big projects to be actually faster than C# projects you need to know what you are doing, the language alone won't make you engine faster if your memory management sucks.

 

Usually I go with C++ but that's just because I've used it a lot more than C# and more comfortable with it. There are good libraries for both languages the main ones are:

 

SFML [C++ but there are .NET bindings] (it's what I use, it's simple, easy to learn and quite fun to use)

SDL [C, being written in C this is not object oriented, there are .NET bindings available] (Never done anything complex with it since I don't really like it that much)

Monogame [.NET languages] (it's the old XNA nothing to add, it's an excellent framework, if you decide C# pick this)

Cocos2d-x [C++/Js/Lua] (This is an engine but it fits your Visual Studio only requirement, it's derived from the Objective-c version so the syntax is odd in some places)

For some reason I saw your response now, 3 days later.

I've settled with C#, because I just feel more comfortable using it and there won't be such a learning curve. I'll follow your SFML tutorial though - it's really interesting. :)

From salty to bath salty in 2.9 seconds

 

Link to comment
Share on other sites

Link to post
Share on other sites

For some reason I saw your response now, 3 days later.

I've settled with C#, because I just feel more comfortable using it and there won't be such a learning curve. I'll follow your SFML tutorial though - it's really interesting. :)

C# is a great language you won't regret it, and thanks for following my SFML tutorial :)

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×