Announcement

Collapse
No announcement yet.

Why C++ for Unreal 4?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Originally posted by Serapth View Post
    I have trouble picturing too many AAA studios that would hire someone with such a closed minded perspective on tools.


    C#, Java or Python (or any other similar scripting languages) are sometimes pretty nice tool, but obviously improper to some cases. If I have an ultimate tool which can cover everything, why should I waste my time to look up others which cannot cover everything?

    Comment


      Originally posted by drawtree View Post
      C#, Java or Python (or any other similar scripting languages) are sometimes pretty nice tool, but obviously improper to some cases. If I have an ultimate tool which can cover everything, why should I waste my time to look up others which cannot cover everything?
      Actually, and please dont take this as an insult, but any programmer having the perception that C++ "is an ultimate tool" needs to broaden their horizons. I certainly wouldn't hire a candidate that showed a lot of the animosity towards languages I've seen in this thread. For the record, I am not talking about void in the slightest. I disagree with his conclusions, but his decisions are at least informed. Many of the other comments frankly smack of parroting the whole "C++ is uber" party line that is so common amongst beginning game developers.

      Even in the world of game programming, single language pipelines are virtually non-existent. Even look at Unreal which is about as C++-centric of any of the engines out there and you will see plenty of different languages used. C# is used as part of the build process, various shading languages are used, Blueprint they even make pretty heavy use of batch/bash programming. This is because you pick the best tool for the job. The ultimate argument going on here is if C++ is the best tool for the job of gameplay programming, and many believe it's not, which is why you have a C# project being undertaken. That every single game engine offers some level of scripting support ( CryEngine has LUA, Unity has C#/JavaScript/Boo, Hero Engine has HSL, Havok uses LUA, Gamebryo uses LUA ) and those engines have powered dozens of AAA titles. Most of the art pipeline is programmable in Python. Hell, an entire AAA game ( Eve Online ) was written in (stackless) Python, while Civilizations 5 game logic was implemented in it.

      There is no one ring, er... language to rule them all.

      EDIT: Oh, and C# and Java are *not* scripting languages, although the lines can certainly get blurry.
      Last edited by Serapth; 04-16-2014, 03:25 PM.

      Comment


        Originally posted by Serapth View Post
        ... with such a closed minded perspective on tools.
        Nope, not closed, but firmly made up based on over a decade of experience.
        I am not 'dissing' any languages, but for game development C++ is the best choice.
        Sure you can write game in virtually any language.

        The big question is, why would you if you have C++?

        For me the best example of failure of C# is Visual Studio. Since it has been rewritten fully in C# (VS2010), downpour of complaints about its poor performance couldn't stop - and still continues. Just look at what VS 2013 is now. It simply cannot deal with code. It's nothing but sluggish and unresponsive. Why? Why people who invented C# cannot make a normally behaving software, and struggle for years now to improve its performance in the language they've created?

        The truth is that managed languages due to technicalities will never be able to outperform natives.

        I am not a language zealot. I am over a decade long professional programmer and I worked with number of different languages.I also always try to pick best tool for the job. For my job (making AAA games) C++ is best tool in my opinion.

        If in the future there will be a language better than C++ I will not cling to C++ but try to learn that new language. I will not moan, complain or try to by being "passively aggressive" insult people who actually work with it and provide proves of its superiority.

        If C# or Java were better for writing games than C++ I would most certainly use them. But they are not. That's why I use C++.
        Last edited by smallB; 04-16-2014, 05:06 PM.

        Comment


          Sorry I've not read any post's in this thread. All i can say is 'What the.... Why C++? That in it's self explains large amounts about your understanding of realtime code', Realtime is exactly that REALTIME. Math functions the base of any good engine are far faster in C++, Threading is far better in C++, Yep you have no automatic memory control and garbage collection but with a little extra effort you want it for realtime anyway. Your far better of rolling your own memory allocation and threading. Why C++ lol, If anyone knows of a faster code base let me know, I've been asking for a C++ replacement for years. Lets face it it's like what 20 years old now, Someone for the love of God come up with something faster and ill be the first inline.

          Comment


            I don't get why people want high level scripting languages when, if those same people would pull the finger out (and I'm not talking about their mouth) they'd realise that c++ isn't all that bad. If they feel its a step up, well then they need to step up and bat. Games making isn't, and shouldn't be for tards. If you are that lazy go do something else. c++ is perfect for this application. I don't want to come across as harsh but for goodness sake you can't expect to make a AAA game without some kind of learning and pushing yourself a bit.

            Comment


              Originally posted by KingBadger3D View Post
              Realtime is exactly that REALTIME. Math functions the base of any good engine are far faster in C++, Threading is far better in C++.
              I'm glad we can all agree that the engine should be re-written in Fortran.



              I don't get why people want high level scripting languages when, if those same people would pull the finger out (and I'm not talking about their mouth) they'd realise that c++ isn't all that bad.
              I've been doing C/C++ for roughly 20 years, it's not that people are unwilling to learn C++, most of us who want other language options already have extensive experience with C/C++. We just don't prefer it for game logic, that's it. I personally much prefer flavors of LISP, Haskell, Scheme, etc, because those are the languages I can work the fastest in, not C++.

              Time is the most valuable thing in my life, and anything that saves it is important to me. I'll sacrifice 1% performance for it.
              Last edited by VFe; 04-16-2014, 06:30 PM.

              Comment


                Originally posted by VFe View Post
                I'm glad we can all agree that the engine should be re-written in Fortran.





                I've been doing C/C++ for roughly 20 years, it's not that people are unwilling to learn C++, most of us who want other language options already have extensive experience with C/C++. We just don't prefer it for game logic, that's it. I personally much prefer flavors of LISP, Haskell, Scheme, etc, because those are the languages I can work the fastest in, not C++.

                Time is the most valuable thing in my life, and anything that saves it is important to me. I'll sacrifice 1% performance for it.
                Couldn't agree more..

                Comment


                  Originally posted by smallB View Post
                  Nope, not closed, but firmly made up based on over a decade of experience.
                  I am not 'dissing' any languages, but for game development C++ is the best choice.
                  Sure you can write game in virtually any language.

                  The big question is, why would you if you have C++?

                  For me the best example of failure of C# is Visual Studio. Since it has been rewritten fully in C# (VS2010), downpour of complaints about its poor performance couldn't stop - and still continues. Just look at what VS 2013 is now. It simply cannot deal with code. It's nothing but sluggish and unresponsive. Why? Why people who invented C# cannot make a normally behaving software, and struggle for years now to improve its performance in the language they've created?

                  The truth is that managed languages due to technicalities will never be able to outperform natives.

                  I am not a language zealot. I am over a decade long professional programmer and I worked with number of different languages.I also always try to pick best tool for the job. For my job (making AAA games) C++ is best tool in my opinion.

                  If in the future there will be a language better than C++ I will not cling to C++ but try to learn that new language. I will not moan, complain or try to by being "passively aggressive" insult people who actually work with it and provide proves of its superiority.

                  If C# or Java were better for writing games than C++ I would most certainly use them. But they are not. That's why I use C++.
                  From 4 pages of posts, all I've seen you be, is a god d@mn zealot. You don't just advocate C++ as a superior choice to other languages, you made it your alpha and omega.

                  You want to have the most power possible to make the best games, etc.? Learn Assembly and write in nothing but assembly. A recent engine written in 100 % assembly is in the works for the Nintendo 3DS and have amazing 60fps 3D performance. Sure, it will take 10x longer to write whatever it is you need to write, but it will run approximately 40x faster than anything you could ever write in any other higher level language in existence. Your argument now crumbled.

                  People are not whining or moaning because they need to learn something new. C++ is just not taught as much as any more. It's usually C# or Java. A lot of those who learned C++ so many years ago says that people today can't learn C++ any more because they were not around when computers were invented and Hardware Architecture was taught like a d@mn religion! Please take your C++ crusade elsewhere because you are brining nothing positive to this discussion whatsoever and your posts have generally been nothing but in bad taste.


                  Now that that's out of the way, I have something else to say which I noticed that z0id seemed to relish in:

                  Use Cases.

                  Use Cases are actually useless if the requirements are clear. This was taught to be my an industry professional of about 20 years. You don't actually *need* use cases for anything if your requirements are clear enough. Which is why a lot of the performance talks of language versus language is useless. If the Requirements are clear-cut then you won't need anything else to determine the right tools for the job.

                  Comment


                    Originally posted by smallB View Post
                    To some it doesn't, to some who actually want to do more than just bare minimum and are not afraid to put sweat and blood into it, it does matter a lot.
                    The only thing I would put that much effort into is my own language, I simply use other peoples languages and never contribute to their betterment, though UScript and Blueprint I did/do make that effort because C++ is less important to me as a gameplay programmer. I just fail to see your argument anymore, youre saying C++ is better because its an industry standard yet APIs are all over the place and never adhere to any single standard, web technology is very pervasive in todays industry and there are alot of programmers who know multiple languages, languages that VS doesnt support. I personally love Sublime Text it is super fast and whilst it might not be considered an IDE it is better off for it, for the reasons you mention and more, VS has always been slow even before the C# additions I guess this just made it worse so you just gave us an extra point against using C++ with VS.

                    I hope youre actually as good a programmer as you make out, I'll be looking forward to seeing your AAA title. In the mean time I must return to vector calculus and player physics, its alittle slow going because of C++ even though my maths is decent.

                    Originally posted by iniside View Post
                    To be honest I also would prefer some other languague instead of C++. Header files drive my crazy, no built in reflection system also doesn't help, some of syntax is just atrocious compares to C# (lambdas), lack of LINQ for collections browsing also can be PITA.

                    Important thing to realize that for gameplay programming we only use small subset of C++ functionality. If you are pro you can get all the power, but if you are not, can still produce working code without known any of more esoteric functionality of C++.
                    All off this, well said iniside Its great to hear that. For me if we know C++'s weaknesses we might be able to improve on it in the future rather than just accepting blindly, C++ has come along way just since I originally began using it but in comparison UScript came further but C++ has made alot of headway the past few years and is looking to improve more. C++ just seemed to stagnate for awhile there.
                    Last edited by MonsOlympus; 04-16-2014, 09:13 PM.

                    Comment


                      These kind of threads are always interesting as they grow along. To me it seems we have the c++ folks who are probably all pretty happy they can get in there and tinker with their fav language. Then there is all the folks who use and know C#, javascript , python ,lua etc and are not so happy with having to learn or relearn c++ and many may even have come over from Unity where they were happy coders and now have to start a new. So that group is a little disappointed and maybe a little frustrated having to learn something new. Then there are the rest of the folks ---basically a blank slate who do not know know much of anything ....and are off to learn c++ or at least that is their plan for now.

                      Now I am certainly more in the last group so I have no real zeal for c++ or any other language. Since I have really been blown away by the possibilities of UE4 and the entire package --I plan along with learning blueprints plan on starting on learing c++ . Since its all new anyhow ---- to me its not such a bad thing what Epic did here.

                      Its seems to me alot of this conversation is really just where folks find themselves as to how they care or don't about c++ and UE4. And maybe if I was not such a noob I would know which arguements were better --but for now I am on the c++ side. Smiles.

                      And if anyone wants to chime in with resources ie books, tutorials etc worth checking out to learning c++ ---- please share them.

                      Rich

                      Comment


                        No argument is better, wrong, or right RichG. Everyone is sort of stuck in their ways. You just have to find a good fit for yourself. I am so excited for you! I got my first start (modding) in Unreal Tournament with UnrealScript & C++ (we could use DLLs and Epic gave some limited source for us to link against).

                        Hm, not too sure where to start. Try Blueprints first Rich. Slowly work your way into C++ land as needed.

                        Start with Ivor Horton's Beginning C++ perhaps? I really liked that book when I get started. You know, C++ can be quite forgiving. I wasn't very good when I started out. I had a lot of memory leaks. But when I crashed it was easy to track down. Of course, I was working in my own codebase working on tools (not a full blown AAA game Engine)
                        Godz for UT '99 / UT 2003

                        Comment


                          Originally posted by RichGelles View Post
                          These kind of threads are always interesting as they grow along. To me it seems we have the c++ folks who are probably all pretty happy they can get in there and tinker with their fav language. Then there is all the folks who use and know C#, javascript , python ,lua etc and are not so happy with having to learn or relearn c++ and many may even have come over from Unity where they were happy coders and now have to start a new. So that group is a little disappointed and maybe a little frustrated having to learn something new. Then there are the rest of the folks ---basically a blank slate who do not know know much of anything ....and are off to learn c++ or at least that is their plan for now.

                          Now I am certainly more in the last group so I have no real zeal for c++ or any other language. Since I have really been blown away by the possibilities of UE4 and the entire package --I plan along with learning blueprints plan on starting on learing c++ . Since its all new anyhow ---- to me its not such a bad thing what Epic did here.

                          Its seems to me alot of this conversation is really just where folks find themselves as to how they care or don't about c++ and UE4. And maybe if I was not such a noob I would know which arguements were better --but for now I am on the c++ side. Smiles.

                          And if anyone wants to chime in with resources ie books, tutorials etc worth checking out to learning c++ ---- please share them.

                          Rich
                          Originally posted by RichGelles View Post
                          These kind of threads are always interesting as they grow along. To me it seems we have the c++ folks who are probably all pretty happy they can get in there and tinker with their fav language. Then there is all the folks who use and know C#, javascript , python ,lua etc and are not so happy with having to learn or relearn c++ and many may even have come over from Unity where they were happy coders and now have to start a new. So that group is a little disappointed and maybe a little frustrated having to learn something new. Then there are the rest of the folks ---basically a blank slate who do not know know much of anything ....and are off to learn c++ or at least that is their plan for now.

                          Now I am certainly more in the last group so I have no real zeal for c++ or any other language. Since I have really been blown away by the possibilities of UE4 and the entire package --I plan along with learning blueprints plan on starting on learing c++ . Since its all new anyhow ---- to me its not such a bad thing what Epic did here.

                          Its seems to me alot of this conversation is really just where folks find themselves as to how they care or don't about c++ and UE4. And maybe if I was not such a noob I would know which arguements were better --but for now I am on the c++ side. Smiles.

                          And if anyone wants to chime in with resources ie books, tutorials etc worth checking out to learning c++ ---- please share them.

                          Rich
                          I think your plan to learn Blueprints and C++ as you go is a great idea. In particular Blueprints are something you should focus on given your background. There's a good reason for that actually:

                          Getting into blueprints will give you a good foundation is some of the fundamental components of the engine: actors, player controllers, materials etc. Blueprint is actually a visual programming language. It is probably one of the best ways to learn some of the fundamentals of programming and it will give you a good sense of the kinds of library functions that you will have access to in C++ as you get more confident with that.

                          Once you've got enough Blueprint in your head to have an idea of some of the types of Blueprint nodes that exist and how you build some simple graphs I'd start with a beginning C++ book. I learned C++ so long ago that I can't remember what sources I used but I'd recommend you probably get a couple different books OR even just use the internet, there may be quite a few resources to draw on without cracking open a book.

                          Using UE4 to learn C++ is actually really cool. I should start a thread about this. Starting a C++ project in Unreal will take care of all the setup and building configuration you need to do. It's a major source of headache that you can avoid entirely and it will just allow you to focus on writing code.

                          You should try to replicate some simple of the simpler Blueprint graphs in C++ as a first goal. There are some good C++ tutorials on the wiki. A good project actually would be for someone to show a Blueprint example and then a C++ example that does the equivalent thing.

                          I'm also learning the engine like everyone else on here, but I'll keep this in mind and I might be able to produce some tutorials like that.

                          In the meantime feel free to PM me or post here if you have any problems or questions I'd be glad to help.

                          Comment


                            Originally posted by Serapth View Post
                            There is no one ring, er... language to rule them all.
                            I think I have to advocate myself a little. For the record.

                            First, what I mention the *ultimate tool* is limited to *product* code. As I clarified in another reply, I don't care whatever used in non-product code. It's OK if they produce result.

                            And I have clear reasons of preference to C++. I won't repeat it because I believe everyone here knows pros and cons of C++. I have investigated most major languages, and the pros and cons of C++ are the best deal to me even in productivity perspective.

                            For the using of DSL in product code, I apology. I haven't worked in AAA studio, so I don't know what they need and how they're running. So my claim on large scale team would hardly be correct. But in general, I wouldn't prefer using extra DSL if the problem is easily solvable with primary language.

                            Anyway I am getting think it could make sense if it is incredible hard to hire properly skilled C++ programmers. (well, I haven't tried to hire some C++ programmers, so far) Maybe you would like to use even less-skilled programmers by providing proper sandbox…

                            Comment


                              Originally posted by RichGelles View Post
                              These kind of threads are always interesting as they grow along. To me it seems we have the c++ folks who are probably all pretty happy they can get in there and tinker with their fav language. Then there is all the folks who use and know C#, javascript , python ,lua etc and are not so happy with having to learn or relearn c++ and many may even have come over from Unity where they were happy coders and now have to start a new.
                              There is an entire demographic you are missing out here.

                              Many of the people that oppose C++ as a gameplay language know C++ already, they just find it ill suited for the task. It's not about not wanting to learn a new language, it's about programmer productivity. Many people in this thread act like scripting languages were only used by "those too stupid to know C++". This is very far from the truth. There is no sense spending the extra effort C++ requires if you don't need the extra benefits it provides. For a lot, perhaps the vast majority, of a game's code, performance really isnt all that important. We all wait at the same speed, regardless to the language you choose. To say nothing of the fact that many of the games people will be creating wont even come close to taxing the machine unless they make a pretty serious mistake.

                              Comment


                                Originally posted by drawtree View Post
                                Anyway I am getting think it could make sense if it is incredible hard to hire properly skilled C++ programmers. (well, I haven't tried to hire some C++ programmers, so far) Maybe you would like to use even less-skilled programmers by providing proper sandbox…
                                ... this is a perfect example. People use scripting languages for many reasons that have nothing to do with the programmer's talent level. Hell, many single developer C++ based games still expose a scripting language. Just a few reasons:

                                Programmer productivity
                                Security/sandboxing
                                Modding/extensibility by end user
                                Data storage (Especially LUA/JSON)
                                Easy Tooling
                                Optimize link/build cycle
                                (Logical) Separation of responsibility

                                and yes
                                Ease of Use.

                                Comment

                                Working...
                                X