Jump to content
  • Advertisement
Sign in to follow this  
LifeIsGood

Unity Modern Programming Language for Game Engines

This topic is 680 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hey, I just found this forum so I'm pretty new here.

 

First at all, let me introduce myself real quick.

I'm not a beginner. I'm a relatively experienced game programmer.
I've started programming games around 6 years ago, spending 5 years with Unity & C#.

I just hope to get some advice from some Guru's.

 

Just to have it mentioned, I don't plan to compete with engines like Unity, Unreal or CryEngine, I just want to start writing my own engine for fun & learning purpose.

In fact, I already made a few early experiences with DirectX & some basic drawing based on WindowsForms using C#.

 

But, I'm just not sure which language I want to use.

I love C#, but I worked for 5 years with it, so learning something new seems to be a good idea to me.
 

Here are some Languages I took a few looks at:

-> C++ (of course)

    I messed around a little in C++, mostly writing Console Applications, but also trying some stuff in the CryEngine & I'm not going to argue the facts, C++ is for a reason one of the most used languages for game programming, but, coming from C# & just looking at the style of the language, C++ seems to be a little outdated to me. Just all the combinations of operators & keywords like "const" make me feel like "Do I really want to use this language ?", it doesn't seem to be that much of fun for me.

-> F# (a little surprising, I guess :D)

    Same as C++, just a few hours of tutorials, throwing basic stuff in consoles. But, I kinda like F#. It's just a completly different thing & a completly new style of programming (it's pretty difficult to understand though, for someone who has no experience in using functional programming languages) & I like the fact that F# is managed land (Though, I don't mind managing memory by myself, that C++ is native land is no real downside for me)

-> Rust

    Rust is the language I have the least experience with. I just had a little talk about it with a friend (who is also a quite experienced programmer & to mention, also more experienced than I am.) & he seems to be pretty convinced of the language. Rust looks like it is pretty close to C++, but also combines functional programming in it (reminding me a little of F#) which seems pretty cool to me.

-> Java

    I know Java a little more than the other languages listed here, because I used to help a friend who studied Informatics & had to write some simple applications in Java. But Java is no option for me, it's a kind of Half-hearted OOP Language & I just don't like it's style.

 

Based on my few experiences with these languages, is there some advice you would like to give me ?
Or even a completly new language I haven't mentioned ?

Share this post


Link to post
Share on other sites
Advertisement

One option is to use the D language. Fast compile times, modules, package system, array slices, readable templates, compile-time functions, unit testing, variables initialized by default etc. make it a good, modern language. At least one commercial game, Quantum Break, uses it.

Share this post


Link to post
Share on other sites

C++ fun is the same type of fun found in Dwarf Fortress :wink:.

 

For Engine coding i would recommend you go with C++. The jump from C# to C++ should not be to hard. Never used to other languages. Select what your focus is, it is learning a new fun language pick one of them. Is it engine coding go with C++.

Share this post


Link to post
Share on other sites

You missed Ada, Fortran 2017, OOCobol, and LISP.  All of them have better syntax than C++ and are powerful enough to write OSes in, so something like a game engine should be no problem for them to handle.

Share this post


Link to post
Share on other sites

C++ may be old but the rules are generally there for a reason. Stuff like const is in the language because it controls access to things, gives the compiler hints on things it can resolve at compile time, or gives hints to programmers as to whether values can change. There's quite a big difference between C++ and any of the GC'd languages like Java or C# if that's all you are used to.

 

Is it the language you need to use? Who knows. You can certainly write a game engine in any language, different languages just have different pros and cons. C++ lets you get very bare metal and people are very experienced in it, that's why it is king for the side of game development that needs to be super speedy.

Share this post


Link to post
Share on other sites

Every single good 3D game engine is written in C++. There is no other reasonable choice.

Share this post


Link to post
Share on other sites

You missed Ada, Fortran 2017, OOCobol, and LISP.  All of them have better syntax than C++ and are powerful enough to write OSes in, so something like a game engine should be no problem for them to handle.

Fortran 2017? The newest standard I'm aware of is Fortran 2008 (released in 2010...)

Share this post


Link to post
Share on other sites

Thanks for all the answers !

 

 

One option is to use the D language

At least one commercial game, Quantum Break, uses it.

D looks indeed interesting, thanks for that.
Also, that it is being used by a quite fresh game sounds awesome.

 

 

C++ isn't outdated. It's just old

Yep, I gotta agree with you there, outdated might be the wrong word to descripe what I meant.

 

 

you handle things yourself. Despite how things going to be (bad or good), you'll have more fun doing these things

No doubts about that ! That's one of the main reasons for me to even start writing my engine, earning some more background knowledge.

 

 

Have you heard about .Net Native?

I haven't, I was aware of the "common" .Net way to compile into IL Code, however, I didn't know there was an approach to avoid this. It sounds a bit against the whole idea of .Net in the first instance to me.

 

 

The jump from C# to C++ should not be to hard.

I wouldn't bother if it was, as long as I like the language & it makes sense to me in the end. I got enough time, no deadline in the background :)

 

 

You missed Ada, Fortran 2017, OOCobol, and LISP.

All of these seem to be preeetty old, with a lot of history. But I'm definitly going to look them up, thanks !

 

 

C++ may be old but the rules are generally there for a reason.
There's quite a big difference between C++ and any of the GC'd languages like Java or C# if that's all you are used to.

Absolutely, I didn't meant to say there isn't a good reason for them to be, just that I don't like all of these combinations. Using the same keywords / operators but with quite different meanings.
To be honest, when I dived into C++ I was kinda surprised that the difference doesn't seem to be that great.
I thought you would have to manage every bit of memory, instead of "just" the things that you want to be (or even have to be) on the heap.

 

 

Every single good 3D game engine is written in C++. There is no other reasonable choice

I wouldn't say that, Xenko for example is written in C#, and I know a good friend who's also writing his own Game Engine completly in C#.
I guess that especially C++ Guru's tend to say that, but I'm not quite sure if I can agree there.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!