分享

Lua, AngelScript, Haxe, C#, Java, and others

 quasiceo 2014-01-20

Lua, AngelScript, Haxe, C#, Java, and others - which do you prefer, and which have the most versatility (Graphical fidelity, cross-platform, and speed of development). Brief overview of each language included within (self.gamedev)

submitted ago by jonatcer

I've been researching this topic for quite some time, and I've come to the conclusion that the languages listed above seem to be the "best" for indie devs (Please correct me if I'm wrong). The only issue is, would be the issue of versatility. Which balances the issues of graphical fidelity (In terms of existing engines, frameworks, and libraries), ability to create cross-platform games (Desktop platforms, although mobile is important as well), and the speed of development?

A brief list of each language, and a few of the most popular frameworks/engines:

Lua

  • L?VE
  • Corona
  • Cocos2d
  • MOAI
  • Polycode

My issues with Lua:

  1. The language style is just so... Ugly, at least in my opinion. It lacks (Obvious) OOP support, and feels very foreign to me as a C-type developer.
  2. ...That's it. Lua seems great otherwise, it's just a freaky language.

AngelScript

I honestly haven't seen any game engines that are focused on AngelScript. It's a shame, since it looks like a damn nice language. Fast too.

That said, it seems to be useful as a scripting language to embed into existing solutions.

Haxe

  • NME - Not really an engine per se, but definitely gives you a headstart.
  • Haxeflixel
  • Haxepunk
  • awe6

Haxe is actually a pretty nice language, but sadly game support seems to be immature. Shaders were only fairly recently added to NME, and aren't really utilized. It also seems like Flash and HTML5 support are priority, while native / Neko is somewhat forgotten.

C#

  • XNA - Not really an engine, but a framework that is pretty complete... Albeit limited in terms of shader support
  • Monogame - XNA++, but still lacks a content pipeline.
  • Unity3d - Complete solution, but highly limited in what you can do without a Pro license ($1500)
  • Sunburn engine
  • Digitalrune

Not a bad choice, definitely going to be around for awhile but unless you're willing to spend money your choices aren't... That great. At least not in terms of easy cross-platform. Sure there's Monogame, but from everything I've heard it's just not there yet. (Yes I know Unity is cross-platform, but I don't consider it a viable option for all game ideas without pro)

Java

  • jMonkey
  • lwjgl

In all honesty I don't know much about Java. I've dabbled in it with android development, but have always considered it to be a dying language with poor game support.

I'm not trying to start a flame war, this is just my opinion - I'd honestly love to be proven wrong, Java looks great but the VM, Oracle's decisions, the garbage collector, recent security issues, and speeds I've seen all make me not like it. Again, my opinion - I'd love to be shown the error of my ways.

Edit: There seems to be some confusion. I am only referring to Java's desktop capabilities here. Obviously it has the highest reach out of all mobile solutions, and is superior in that regard (Although there's a good argument for Object C too).

Javascript

  • Jaws
  • Gamvas
  • Phaser
  • Unity3d (Kind of)

While Javascript is primarily a web-based scripting language, with the usage of HTML5's canvas and node.js, it can be used to develop both games and web applications. It's also inherently cross-platform, seeing as HTML5 is a standard and most modern web browsers (Even mobile) should support it.

Plus it's (Kind of) one of Unity's languages.


Well uh... Not sure where I was planning on going with that list, but it just came to me. Anyways, I want to know what sorts of experiences people have had with different (scripting) languages, and more importantly - the engines and frameworks that utilize them.

Personally I've used:

  • Haxe - Liked it, but for the reasons listed above I don't think it's for me... Yet
  • C# - Love it, and with a Unity Pro license, it seems like an amazing choice. There is, however, some concern about XNA's announced death and Monogame's issues.
  • and Python - My god I hate Python for serious game development... I'm sorry, but it just doesn't seem like the Python community cares about game development anymore and it shows. Prototyping? Yeah, sure. Actual game development? No, just no.

tl;dr What languages have you used, and which framework/engine did you use with them?

Edits:

  1. Please don't take my opinion on Java as the be all, end all - or reason to downvote this thread. They are my opinion, and I would honestly like to be corrected. The language is amazing (In theory) is amazing to me. Oh, also added Javascript to the list as per request.
一共 138 条评论
排序条件:
最好的

[–]Hrothen 9 分/分 ago

C++ is probably the most versatile language, and with C++11/14 you can generally write about as fast as other languages. Where it falls short IMO is that C++ lacks any framework that's as robust as what can be found with Java or C#, forcing you to either write a bunch of low level code yourself or spend a while getting libraries to play nice with each other.

It's pretty easy to make C++ work with lua/python/haskell too, if you don't want to have to compile scripts.

[–]TrancePhreak 3 分/分 ago

Cocos2dx, irrlicht, Marmalade, UE4, etc

[–]Subpxl@BrandonSPX 7 分/分 ago

C# - Love it, but XNA's announced death, and Monogame's issues make me not want to use it right now. Plus with a Unity Pro license, it seems like an amazing choice.

Those two sentences are sort of strange, since they are emotionally at odds with one another. I would consider rewording it to something like:

C# - Love it, and with a Unity Pro license, it seems like an amazing choice. There is, however, some concern about XNA's announced death and Monogame's issues.

Not trying to be a stickler, but it was very difficult to see if you love it enough to use it right now, or you love it but are abandoning it.

Outside of that minor complaint, I think the bigger concern is that you haven't actually used all of the languages you are commenting on, and so you aren't really qualified to make some of the claims you did, like considering Java to be a dying language. That is a pretty crazy thing to say when the largest mobile platform (Android) has an app framework entirely based on Java, and continues to be supported all over the place.

[–]jonatcer[S] 1 分/分 ago

I've edited it the OP, thanks.

As for your concern - I'm not trying to show myself as an expert, I'm just relaying what I've heard / seen. As for Android - yeah, Java will probably always be a huge part of mobile development, but I'm mostly talking about Desktop use. Sorry if that wasn't clear.

[–]Subpxl@BrandonSPX 2 分/分 ago

Makes sense then. I'm sure there are plenty that are looking at various languages as a starting point to game dev that will find this handy.

[–]g1i1ch 5 分/分 ago

Honestly I'm going to go out on a limb and say you should check out Scala if you don't like Java so much. I honestly can't stand working in Java. Scala compiles to the JVM and can use pretty much any Java library. I myself got lib-gdx working easily. Scala is probably my favorite language of all time right now.

[–]kerajnetC, LibGDX 26 分/分 ago

Java dying? nope. Look at LibGDX. You don't need engines to make a good game anyway.

But if you are really in need of one, there are a few: JMonkeyEngine 3, jPCT, Ardor3D (fork of JMonkey 2, clean one). Also LibGDX is adding some 3D API.

[–]armornick 19 分/分 ago

Plus, Java is immortal (COBOL-esque) because of its widespread use in enterprises.

[–]DrummerHead 17 分/分 ago

That's not necessarily a good attribute...

[–]badsectoracula 2 分/分 ago

It is good from the point of view that it is stable as a platform. Of course games use features outside of Java which might not be as stable.

[–]Easih 14 分/分 ago

indeed, Java is the most popular language currently; saying its dying is insane specially since its used also for mobile(android)

[–]DimonteProgramming guy 9 分/分 ago

It's not used for any of the high-profile games and computation-heavy apps on Android, though. Pure Java (run in Dalvik, not precompiled into native code) is heavily restricted in performance.

Most of its popularity is also due to its adoption by many enterprise solution providers.

[–]Lanaru 3 分/分 ago

How are those high-profile games on Android developed, then? I thought that Java was necessary for Android applications.

[–]DimonteProgramming guy 5 分/分 ago

Nope, it's C/C++ all the way down.

[–]SuperVGA 2 分/分 ago

I'm really interested in doing this. I've been developing for droid with Java for two years now and I'd like to give C++ a shot. Can you link to a tutorial or some other documentation?

[–]DimonteProgramming guy 3 分/分 ago

Well, here's NDK: http://developer./tools/sdk/ndk/index.html And for tutorials just hit Google. I can't really help there as I do not have much experience with those tools. My knowledge mostly comes from co-workers who do native development.

[–]SuperVGA 1 分/分 ago

Hey Thanks! I never got to look into the NDK, but I will now.

[–]pjmlp 2 分/分 ago

Not if you need to interact with Android APIs.

[–]DimonteProgramming guy 2 分/分 ago

I'm pretty sure there are bindings/wrappers for those, though it's not in my main line of work, so I'm not certain on that.

[–]pjmlp 1 分/分 ago

No they are not.

Google sees the NDK as a means to bring legacy code to Android:

In general, you should only use the NDK if it is essential to your app—never because you simply prefer to program in C/C++.

They only provide essential APIs for game development, everything else you have to write the JNI wrappers yourself.

Just check /android-ndk-version/docs/STABLE-APIS.html for the limited set of APIs.

[–]DimonteProgramming guy 1 分/分 ago

I know that Google doesn't care that much about people writing everything in C. But there are 3rd party offerings available that let you do just that. And I may be wrong, but doesn't http://developer./reference/android/app/NativeActivity.html allow you to skip Java completely?

[–]pjmlp 1 分/分 ago

NativeActivity is a Java class with native methods that calls into your native code application, that you provide as a shared object.

So you code your application in C, and can be free to write any Java code to handle event handling, but have to pay the JNI interop price.

Then unless you are doing games, the NDK provided APIs don't give you much more than libc/libc++, resource loading, 2D and 3D graphics and sound. For anything else, there is JNI with the corresponding interop price.

On yesterday's live stream all new gaming APIs that were shown are Java based. I am curious to watch the NDK related sessions to see if there is anything new.

As for 3rd parties, they also have to wrap the Java APIs, so the performance hint is the same.

[–]ISvengaliC++/Scala/C/Java|Networking/AI/Gameplay 3 分/分 ago

And there's always Scala. Writing code in Scala is a ton of fun.

[–]gamesbyangelina@mtrc 1 分/分 ago

Yeah, you ahve to add LibGDX to the list. I'd also add flixel-gdx as a great add on to slot into it. I use it for all sorts now

[–]jonatcer[S] -2 分/分 ago

I know there are game engines and libraries that use Java, but it seems like with the advent of things like .NET (+Mono), NaCl, HTML5 (Kind of), Go, Node.js, Python (Kind of), and hell even Haxe - it's not really alone in its cross-platform ability anymore, and falls short of something like Go, which admittedly is native, is faster.

Not to mention the fact that from everything I've heard from people who were/are fans of Java, Oracle has not been doing too great with it - Java 7 being resisted by a lot of them.

And from my own personal experience, Java has always felt bloated and slow. Java programs requiring significantly more memory, and games like Minecraft being horribly slow and inefficient.

Please correct me if I am wrong. I love the idea of Java. I love the way it looks. I want to use it, but everything I've seen regarding it makes me think it's both dying and is bloated to hell.

Edit: I realize this sounds like I'm attacking Java. I'm not, I actually do want to learn to love it - but the issues I list have always stuck out and prevented me from pursuing it for long.

[–]armornick 6 分/分 ago

Have you taken a look at some of these games written in Java:

  • Blocks That Matter
  • Spiral Knights
  • Revenge of the Titans
  • Titan Attacks!
  • other PuppyGames games

Minecraft is somewhat of an exception.

[–]jonatcer[S] 3 分/分 ago

Spiral Knights... Now there's a game I haven't heard for awhile. Good looking, fun game. Is it really written in Java?

Thanks for the list.

[–]Skullclownlol 3 分/分 ago

http://en./wiki/Spiral_Knights

The free-to-play, Java-based game was released to ...

[–]armornick 1 分/分 ago

Last I heard it was written in Java.

[–]Easih 6 分/分 ago

Minecraft is terrible because the way it was coded, the creator even said so himselft that the code are a mess.As for Java being slow its not quite true ; a remake of an old AAA FPS game that was first made in C was ported to Java and no difference was marked in both language.

[–]jonatcer[S] 1 分/分 ago

Which old AAA FPS game? Because if we're talking about something like Quake 1... Well, yeah.

As for Minecraft being poorly programmed... Oh yeah, Notch isn't the greatest programmer in the world to begin with - and from what I remember of the livestreams, he was uh... Let's say agile.

[–]desertfish_ 4 分/分 ago

Well, there is Quake 2: http:///html/jake2.html :-) Written a decade ago? Couldn't find a date on the site but the first time I saw this is a looong time ago

Edit: found dates, first version is from may 2004. It ran pretty well

[–]the_hoser 12 分/分 ago

You're wrong :)

Java tends to perform pretty well, especially when you know what you're doing. I've had really good success with it. LibGDX is just about the most awesome game library I've ever used, and the development of it is very active.

It seems you're making a lot of judgements based on misconceptions and a handful of applications. Stop that. Minecraft is slow because it's doing something computationally hard in a not-so-well-designed manner. Oracle is doing great with Java - Java 8 is only slightly delayed, and their work with JavaFX 2 has been awesome. They're a better steward of Java than Sun ever was. The JCP is alive and kicking. Java 7 has only been resisted because of Android. If Google would stop dicking around and update Dalvik to support InvokeDynamic (one can dream...), we would see a shift to Java 7 for Android development.

[–]jonatcer[S] 1 分/分 ago

I hope so... I think I may look into it again.

Do you have any sort of benchmarks for 3d games on hand? Or even examples of 3d (Well known, well made, or otherwise big) games made in Java? I'm concerned with how Java handles arrays and searching arrays, as that's one of the issues I've heard of in regards to Minecraft - voxels (Boxels) not being Java friendly.

Edit: What about speed of development in Java? I realize it has garbage collection so you don't have to really worry about memory management but... How does it compare to something like Python in that regard? How much low level code do you have to write to get something on the screen / moving around?

[–]the_hoser 9 分/分 ago

You'll be able crank out small code faster in Python, but with experience (and kick-ass tools), Java is a very productive language. Once you're actually developing a large application, the differences become smaller and smaller.

As for putting things on screen... well... it depends on what library you're using. This isn't really an attribute of Java. It'll take about as many lines of code to put something on screen with OpenGL in Java as it does in Python.

My advice to you: Stop worrying about languages

Pick something you like, and write a damn game. You can do it in VisualBasic for all I care. Don't worry about performance. Don't worry about the "right" way to do things. Just get some stuff done. Once you've written a few games, all of these questions will be answered for you.

[–]recursivegamer 7 分/分 ago

My advice to you: Stop worrying about languages

Great advice! I have always felt like it doesn't matter so long as it is a language that works for you that you feel comfortable with it.

[–]jonatcer[S] -3 分/分 ago

Great advice! I have always felt like it doesn't matter so long as it is a language that works for you that you feel comfortable with it.

That's not necessarily true. If I'm, say, most comfortable with PHP - that's not gonna work. Or even Python, since the game libraries are lacking.

Language is definitely important, unless you want to add an extra x(x) months of development time trying to figure out how to do something no one else has, or creating something that exists in another language either nativelyor through a library.

[–]allthediamonds 4 分/分 ago

Python? Take a look at Pyglet.

[–]OpSmashGame Designer :: @Mayples_ 2 分/分 ago

I support Pyglet. Great work from them.

[–]DestroyerOfWombs 3 分/分 ago

You need to break your dependence on other peoples work.

[+]jonatcer[S] comment score below threshold  (9 儿童)

[–]OpSmashGame Designer :: @Mayples_ 0 分/分 ago

This comment makes me vomit a little because your making excuses.

Below is a qoute:

"When it comes time to screw in a screw into a piece of wood, you will have to go to your toolbox. In that toolbox is many tools, each can be used and only a handful effecient. Of those 3 you choose to use, 1 is the right tool that everyone uses, 1 is a tool that probably won't work, and 1 is the tool that no one chooses. Personally, I prefer the hammer."

that qoute was said to me by a game developer who shall not be named, but he is very active here in r/gamedev and works in some high profile games. I had the same issue at one point, do I use C/C++ or run with LUA or maybe just say screw it and build what I need in Obj-C and learn a little. Eventually after 3 months of debate I was so flustered on doing something I would wind up never doing it. Over some coffee I brought this up and he said this to me. As u/destroyerofwombs said, Don't depend on other peoples work, don't compare yourself to them and what they accomplish. People that make great games just focus on making a game and tackle the obstacle as it comes. Obviously you wouldn't choose PHP, so that was a dumb response. But you know the answer to what you want to use and everyone will have there own idea on what works for them.

Me now, I love LUA and Love2d.

[+]jonatcer[S] comment score below threshold  (5 儿童)

[–]Skullclownlol 1 分/分 ago

Here's a LibGDX vs Love2D vs Cocos2d-x vs MonoGame vs XNA benchmark on Windows & Ubuntu. I've made some prototypes and simple 2D games in LibGDX and Cocos2d-x and I can confirm they do run faster on LibGDX. The code I've written was with attention for detail and performance and was reviewed several times.

[–]pooerhC++ gameplay3d 4 分/分 ago

I love LibGDX and wrote my very successful game in it but there is absolutely no way you're going to convince me that it's faster than native. I'm getting significantly better framerates with gameplay3d in C++. Cocos2d-x is terribly written, maybe performance is also bad but there is a clear overhead in Java vs C++, even if Mario and Co. have done such an awesome job coding the library and JNI optimized code.

[–]thedeadlybutter@thedeadlybutter 1 分/分 ago

Maybe a few Java versions ago, but between JIT and overall the fantastic JVM I disagree about a 'clear overhead' compared to native.

To start, both are faster in different areas and there is no true answer for Java vs native. Everyone says "Wow Minecraft is slow, and laggy, and blah blah blah". This isn't Java, this is a poor designed game which needs to be fixed. What are your examples of slow Java games your comparing?

[–]pooerhC++ gameplay3d 2 分/分 ago

I'm not comparing games, I don't play that many. I'm comparing simple benchmarks that I wrote myself to check if there is really any performance difference. Think thousands of triangles rendered, plus box2d physics and some basic data structures behind it. My C++ was rusty back then so I think my Java sample was better written yet the performance difference was there. It wasn't very relevant on desktop, and most certainly not noticeable for the average user (100 vs 120 fps maybe, I don't remember the exact numbers) but on mobiles, it made a big difference. Even on Android, which has native Java environment, there was a noticeable boost in fps between LibGDX and gameplay3d which uses Android NDK, especially on a slow device. On iOS, the performance boost between C++ and LibGDX was more than 20%. I wish I had the exact numbers to show you now but I don't, I didn't bother to migrate these repos when I switched from svn to git.

Mind you, I'm not saying "don't write in Java". Fact is, even though I like C++ and I'm a big supporter of gameplay3d, I was more productive writing in Java just because C++ is more low level and you have to code solutions that are handed in to you in Java, well tested and with good performance. More room to make mistakes and introduce bugs. Had I known the iOS port for LibGDX will be as functional as it is, I probably wouldn't decide on going with C++ but I don't regret that decision either. There are absolutely pros and cons to each solution but if we're talking about straight performance for games, nothing beats native.

[–]gamesbyangelina@mtrc 1 分/分 ago

I think saying .NET is as cross-platform as Java is stretching a bit. :P

[–]AlbertWily -2 分/分 ago

Java is dying in the sense that, as a language, it's a mess and is obsolete.

There will always be systems running it, but unless you're doing android dev, there's no reason to go anywhere near this abortion of a language.

[–]pooerhC++ gameplay3d 5 分/分 ago

I'm all in for crossplatform development. I chose C++ with gameplay3d, it has built-in lua bindings so it's piss easy to script your game in it. Other than that, it has everything you might need from a game engine and the performance is great.

Java + LibGDX is also awesome, my love for LibGDX is still strong and I miss its ease of use, excellent API, documentation and community.

[–]theblindone 4 分/分 ago

I'm currently using Haxe and NME. I definitely found it to be a challenge to learn with the lack of decent tutorials, but I'm reading lots of source code and learning what I can as I go.

It's awesome though to see it compile to both flash and windows with one click without changing the code at all.

[–]BaconSoapC# & MonoGame 11 分/分 ago

C# Monogame is my system of choice. I have continuous integration set up on my server that compiles/runs tests on every commit, and I haven't had a problem yet.

Like you said, the content pipeline isn't there yet, and looks like it has a bit to go. It doesn't affect me though; I develop in windows, and I have an XNA content project in my monogame solution. The effect of this is that I have never noticed a difference between use of monogame and XNA.

Plus, C# the language is easily my favorite. LINQ, await/async, anonymous everything, and the godly tooling that is visual studio all combine to make the best developer environment.

With regards to Java dying, it is one of the most installed pieces of software in the world. It is on every single Android phone, which has the greatest market share. It may be ugly, slow (but not compared to python or lua), locking, insecure, and a tool for Oracle to monetize, but it isn't going anywhere.

I'd say give C# and monogame another try if you get the chance. You can pretty easily setup a dev environment using it (on windows). Also, check out the gamedev wiki.

Edit: Unity also is a really nicely integrated editor, but it is difficult to do 2D games that don't run horribly in it. Unity is an 'I have a golden hammer' choice, and 2D games are screws.

Double edit: apparently LuaJIT beats out or matches Java in performance, and I'm not as sure about python anymore so I'm removing my speculation.

[–]Danthekilla 3 分/分 ago

What are you using for your build server?

[–]BaconSoapC# & MonoGame 4 分/分 ago

For hardware, I got one of the APU's from AMD (CPU + Graphics on the same chip), 8gb ram, and a low-profile HTPC case. I'm using it as my music server (with Subsonic (think personal google music)), my home theater server (for my non-existing television...), and my build server. I also can spin up VMs on it for quick experimenting.

For software, I run TeamCity on it, with a build agent on the windows part, and a build agent on a virtual machine of Mint Linux on the same computer. Even with everything running and a build going it only uses about 2-3gb of memory.

Teamcity can be set up to watch both private and public repositories of most source-control systems, pulling in changes performing builds/tests. It runs on java, I think, and works pretty well cross platform. Free for small team usage (or at the least, free for individual usage).

I use Youtrack for my project management, but that might be a bit overkill for one person.

[–]Mycal 2 分/分 ago

Are you sponsored by JetBrains or something?

[–]BaconSoapC# & MonoGame 4 分/分 ago

I wish. Their stuff is expensive.

Edit: I just looked at how much of my toolchain is Jetbrains: Youtrack, R#, TeamCity, Intellij (with all of the language plugins), Dotcover. I have been largely a .NET dev with C#, so R# is a given (I don't know anybody that prefers to work without, unless they have less than 4gb RAM). At work we use TFS, but I don't want to shell out a license, so I stackoverflow'd it and found that a lot of people recommended the combination of TeamCity for CI and YouTrack for project management/agile planning.

Intellij and Dotcover I bought on a whim at their ridiculous 75% off sale. I kind of wish I hadn't bought Dotcover because I don't use it much more than clicking 'Cover unit tests', which I could have done using a free plugin. The other functionality it provides is also provided by R#.

[–]jonatcer[S] 1 分/分 ago

Damn... That's impressive. Thanks for sharing

[–]BaconSoapC# & MonoGame 2 分/分 ago

It sounds more impressive than it is. I had it running on a super-old XP laptop for a while, but that ended up dying just after I finished saving for a new computer. It took me about a day to set up the entire environment.

[–]Danthekilla 1 分/分 ago

Thanks for that I will look into teamcity, I need a good build system for our xna projects.

[–]BaconSoapC# & MonoGame 3 分/分 ago

Make sure that you check out the free license restrictions before committing to it. I messed up saying it was a person limit; it's actually a build agent limit.

[–]Danthekilla 1 分/分 ago

Oh wow its jetbrains! I use all there c# tools already this could work well.

[–]jonatcer[S] 1 分/分 ago

Oh god yes, LINQ and Visual Studio. If there are two things that Microsoft ever got right, it's LINQ and Visual Studio. Even the most hardcore Linux/Mac users can't deny that VS is the best IDE out there. And that makes me sad, since it's so expensive and the newer versions aren't that great.

As far as Java on mobile - yeah, it'll probably always be #1 or close to #1 on Mobile, since they seem to put a lot of work into the mobile side of things but... Lua being slower? Not with LuaJIT.

As for giving C# a try again... Ugh, I keep coming back to it. Don't get me wrong, the language is beautiful - but XNA only supports shader 3.0, and Monogame sounds like a PITA still. The reason I made this thread is because I still don't think Monogame is there for me. Damn close, but not quite. Plus OpenTK seems dead, and I want stable cross-platform support for Linux and Mac.

And Unity... Yeah, 3d support seems amazing - but 2d support, until they come out with Unity2d (And they supposedly will), is kind of hacked together. Plus the free license is really restrictive, and I'm more of a coder than a designer and... Unity just feels like a designer's tool.

[–]gaymenonaboatjava 6 分/分 ago

Personally not a big fan of VS. First used VS while getting to know C++ (thought VS was pretty cool at the time), then when i started learning Java, I used IntelliJ (which is amazing), and now i'm using VS again for university work and now i'm pretty sick of it.

I have to move the mouse so much more and I can't navigate through projects as easily with the keyboard in the same way i could with IntelliJ. Reaching for the mouse all the time in VS is a huge productivity killer for me since i'm so use to having everything at my finger tips.

[–]jonatcer[S] 5 分/分 ago

Where VS shines, is with Intellisense and debugging.

[–]EdwardRec 1 分/分 ago

And the VS2012's design. It's damn hot!

[–]provobrony 1 分/分 ago

EXCEPT ITS YELLING AT YOU ALL THE TIME

[–]EdwardRec 1 分/分 ago

Huh?

[–]provobrony 1 分/分 ago

The top menus. They are in all caps. Its yelling at me.

Other than that its a damn fine IDE.

[–]EdwardRec 1 分/分 ago

Oh, didn't notice that!

[–]BaconSoapC# & MonoGame 5 分/分 ago

There's an extension a buddy of mine at work uses to make navigating much easier from keyboard. It's supposed to replicate from intellij. I wasn't aware of this issue because Resharper has all of that built in, and we have site licenses for it so I've never worked without. I'll try to track down that extension to make it easier for you.

[–]gaymenonaboatjava 1 分/分 ago

That would be awesome!

[–]BaconSoapC# & MonoGame 2 分/分 ago

Hopefully you can see this. It's a bit different than I remembered - I haven't actually used it. This is the extension. Resharper is really the best choice, but it's not close to being free. If you have spare cash then check out the trial and see if it's for you. You should be able to qualify for the academic license at $50 if you are a student.

[–]gaymenonaboatjava 1 分/分 ago

I'll be sure to check it out, thanks!

[–]TrancePhreak 3 分/分 ago

Visual Assist or Resharper would fix that

[–]gaymenonaboatjava 2 分/分 ago

From what i hear ReSharp is pretty amazing, although i don't know much about visual assist.

[–]TrancePhreak 2 分/分 ago

They both do almost the same thing these days. I started in the VAX camp, so that's where I stayed.

[–]jeremiahnunn@sketchycode 2 分/分 ago

Spend some time learning the keyboard shortcuts, and even modifying the shortcuts (there's tons of navigation options that aren't bound by default). If you have Pro, for example, ctrl + comma is a godsend; navigate to symbol (any symbol, variable, method, class, interface) as well as filenames. I've used lots and lots of IDEs (been a commercial developer for nearly 10 years), and my opinion is that keyboard navigation in VS is hard to beat, but does require some mental investment.

[–]BaconSoapC# & MonoGame 4 分/分 ago

If you recently graduated, you should still be able to get a student license from DreamSpark if you have an .edu address. The express versions are... meh.

Yeah, shader support in monogame is a pain, and honestly I spent a weekend day setting up the entire environment (server, monogame, content pipeline). If you like OpenGL and C#, try out OpenTK. It's a very precise binding of C# to OpenGL, with a focus on making it more C#-style. Instead of gl_do_stuff, it's GL.DoStuff. Instead of gl_I_hate_this_flag, it's StupidFlags.IHateThis (or something along those lines). I went through a GL book using it, albeit with a few problems around extensions.

I feel you about the free license and coder. I heard that Futile is a pretty cool code-oriented framework for it, but can't confirm since I haven't used it.

[–]jeremiahnunn@sketchycode 1 分/分 ago

Check out Futile for Unity. It's a smallish, open-source framework for doing 2D which is super easy to use.

[–][deleted] 8 分/分 ago

Clojure is my pick. It is a lisp, so it's fun and elegant to use, and your indie project will be coded 10* faster. It runs on, and fixes concurrency issues on the JVM. So you know it's got the speed, portability, and security of a Java app. Plus it interops with anything Java. Got a Java http server or game engine? You can easily make it communicate with Clojure.

I don't want to sound like I'm advertising it, but I really love everything about Clojure. It fits well.

[–]aerique 4 分/分 ago

Can one use Clojure to develop for iOS or Android?

[–][deleted] 3 分/分 ago

People are porting Clojure to many different platforms.

  • Clojure (main) lives on the JVM.
  • Clojure CLR lives on CLR (.net runtime/mono).
  • Clojurescript lives on Javascript and Node.js.

Clojure on Android is half-baked, but they're working on it. Since Android is Java, a lot of it is already done, but there's a lot of native API stuff that needs to be ported over.

For instance, with Clojure on JVM, you can access any of Java's classes or objects by using a period before the name:

(.java.util.String new "this is pseudo code")

The only thing that Android shares in common with JVM is Java. Pretty much none of the API is the same. And that is the biggest part of porting Clojure to Android.


Clojurescript made leaps and bounds on a project that we call Clojure-in-Clojure. Basically, they are rewriting Clojure in Clojure, so only clojure.core needs to be written in the host language.

This will make it easy to be portable.


Lisp the language

Clojure is often described as the new lisp. And if you know any lisp language, you'll pick up Clojure pretty fast. Don't be scared of Lisps, they are incredible. They have a bit of a learning curve, but they are much more fun to use than any C-based imperative programming language.

Lisp is one of the most elegant languages ever, and almost every high level language was, in some way, inspired by Lisp. Lisp has been around for ages, and is the second high level language to be invented. C, Java, Javascript, C++, C#, Ruby, Python, Lua, etc... All of them have borrowed concepts from Lisp.

Lisp uses functional programming. This means that instead of having objects and classes, we have functions as first class citizens.

Lisps introduce the use of macros, that allow you, the programmer, to radically change the way the programming language works. If you want a new feature added to the language, then it'll be easy for you to add it.

Because of these, a good lisp programmer can run rings around a good programmer of any other language. Projects that take 15 programmers, and a year, can take 4 programmers and 4 months in Lisp (ballpark).

Lisp introduced a REPL, which means that as soon as you type in code, it reads, evaluates (executes it), and displays it on the screen. This means you don't have to wait ages for your program to build, you can build your software while it is running.

Lisp can be compiled into anything. Scheme (a lisp) compiles to C. Clojure compiles to Java, C#, and Javascript. Nu compiles to Objective C. There is a lisp that compiles to PHP (but why?).

Many of the criticisms that you will find about Lisp come from the amount of parentheses that are used while coding. It can be quite scary to look at for a beginner. But any good editor (Vim, Emacs, any IDE ever) will automatically keep track of the parentheses for you. And after you use it for a bit, the scary parts of Lisp start to make sense. The parentheses actually help you, believe it or not.

Lisp isn't one dimensional, like most code. It's multi-dimensional. Code and data are one, and you can build complex trees out of them easily. It's amazing what you can do with Lisp so easily.

I can't describe the feeling of programming in a Lisp, it's surreal. Everything you ever knew about limits of programming languages and boundaries are gone. You're in a blank world, where you can rapidly create anything. You go from being an engineer, to being a god. Instead of making something with ingredients, you are truly creating.

It takes quite a learning curve, but Lisp will change your life for the better. If nothing else, it will make you a better programmer in every other language.

You will not regret learning Lisp, I can guarantee it. There are a small amount of people that decide never to use Lisp again, but they walk away changed. Lisp makes you better.

And well, Lisp + JVM = Clojure.


Solving Java's concurrency problems

Moore's Law says that every year the speed of a computer doubles. This was true until Intel hit a brick wall a few years ago. They came to a point where they could not make CPUs any faster. There were physical issues that stopped it, like heat, and there were issues with the fact that metal CPUs can not go any faster than how fast they go now.

Bear in mind this all happened at around 2006.

After failing to make a faster CPU, Intel decided to add more CPUs to a computer. This is where multi-core stuff comes in. Instead of trying to make everything go fast, instructions in a computer could be delegated across multiple threads (or processes).

Most modern day languages are not designed to make use of more than once core. Even Java was not designed from the core to allow concurrency; that was a feature that was only more recently added. There are issues with OOP and concurrency, they don't play nice together. Java is OOP by nature, and therefore makes concurrent programming harder than it needs to be.

Clojure solves this by using immutable data constructs, and system transaction management (STM). Immutable data means that the variables and arrays and all that can't be changed, unless they are changed on all threads at once. STM is a way to do this.

STM has a lot of different ways to make sure that all the threads (processes) have the same information. This turns concurrency from a difficult task to a trivial task.


I've run out of time to write this post. I apologize for its sheer length. I hope you enjoy it, and at least give Clojure (and therefore Lisp) a go. I can't guarantee that you will love it (though, nearly everybody does, there are a few people that don't). I can, however, agree that it will turn you into a wizard.

Good luck, and let me know if you have any questions.

[–]aerique 1 分/分 ago

Thanks for the extensive reply. I'm pretty much a Common Lisp zealot which I why I was curious about the state of Clojure on iOS and Android. Mostly because my research in the past didn't turn up anything useful.

I'm currently going with haXe but would switch in a heartbeat if there was a solid Scheme, Common Lisp or Clojure solution for Android and iOS. Scheme seems to be the most viable currently, but haXe offers too many extras to ignore.

I've invested a chunk of time into Unity (got the free iOS and Android versions last year) and even bought nGUI, Playmaker and some other stuff but for an open source hippy like me developing on Linux, OS X and Windows it is just too much of a fucking hassle.

I hope you've inspired others with your reply ;-)

[–]mycall 3 分/分 ago

You normally have to spend money to make money. Unity3D is worth it.. $1500, $149 for students. While mono is a few years old i it, they are actively working on updating it.

With the new xbox coming out soon, there will be something to take XNAs place.

[–]armornick 7 分/分 ago

I've always thought Lua has one of the most beautiful syntaxes of any programming language. Of course, you can argue about tastes, but it's never a smart thing to do. The object orientation of Lua is sort-of the same as JavaScript.

Haxe is one of my third-favorite languages. It's great because you've got type-safety, cross-platform deployment, and somewhat nice syntax.

One you've forgotten is JavaScript. It's web-only, of course, but canvas seems to be pretty cool. There's also a few really cool game engines like Jaws, Gamvas and Phaser by the makers of Flixel power tools.

[–]jonatcer[S] 1 分/分 ago

I don't know, I mean Lua isn't really that bad looking I guess... It's just so jarring coming from over a decade of C-like languages.

As for JS, thanks, I'll add that to the list.

[–]tomlu709 3 分/分 ago

Regarding syntax I can almost guarantee you'll get used to it to the point where you will prefer it. IMO Lua is way better looking than the curly-brace family of languages. Just make sure you get some syntax highlighting going.

While I'm banging on about it I might add that Lua is one of the fastest dynamic languages there is (way faster than Angelscript). If you can use LuaJIT it's in the same league as C#.

[–][deleted] 3 分/分 ago

The lua syntax is okay but in some cases I find it a bit too verbose.

var = var + 1 -- increment

Also the fact arrays are indexed from 1 bothers me greatly.

[–]tomlu709 3 分/分 ago

I don't really think the increment thing is a big deal. You don't really write very much code like that in Lua or you're not doing it right. I'd take shorter lambda syntax or ruby-style blocks over an increment operator any day of the week.

1-indexing is stupid. I've no idea what they were smoking in Rio when they thought of that.

[–][deleted] 1 分/分 ago

You don't really write very much code like that in Lua or you're not doing it right.

I'm not sure what you're trying to tell me there? You think that using increment in lua is "not doing it right" or something... I mean sure I wouldn't use increment for a loop but sometimes you do need it... Also operators like /= and *= and += etc.

[–]jonatcer[S] 2 分/分 ago

Also the fact arrays are indexed from 1 bothers me greatly.

What in the hell!? From ONE? Why? Every other language that I can think of starts off with 0.

[–][已删除] ago

[deleted]

[–]jerenept 1 分/分 ago

Pascal/Freepascal indexes arrays from 1, although this is because historically, using array[0] would get you the length of the array.

[–]adnzzzzZ 1 分/分 ago

Once you "get" Lua I feel you'll appreciate it more. Anyway,

The language style is just so... Ugly, at least in my opinion. It lacks (Obvious) OOP support, and feels very foreign to me as a C-type developer.

Like OP said, it has OOP support in a kinda similar way to JS. There are also tons of OOP libraries that make it super easy.

Haxe is actually a pretty nice language, but sadly game support seems to be immature. Shaders were only fairly recently added to NME, and aren't really utilized. It also seems like Flash and HTML5 support are priority, while native / Neko is somewhat forgotten.

You could do pixel shaders before with BitmapData, no? But I'll agree that support/documentation is usually lacking, which makes everything a bit harder. Also, I've found that (at least for HaXePunk and HaxeFlixel) HTML5 support is non-existent.

[–]TrancePhreak 2 分/分 ago

c++ with cocos2dx, irrlicht, or my own stuff depending on what platforms I need to hit. Highly portable, very fast, full control of everything. For me, it's also the fastest development language. All problems known for years and solved, just get to the developing.

[–]inmatarian 2 分/分 ago

In defense of Lua, its syntax is kind of a cross between Pascal and Ruby (with the explicit then and end keywords). Its object system is fairly minimal and roughly equivalent to the type of object system you'd get using Javascript's {} and Object.create to create objects. Instead you use {} and setmetatable, with the understanding that Lua uses .__index instead of .prototype as where it delegates the prototype chain.

[–]rogue780 2 分/分 ago

Currently I use Java + libGDX. I am thinking of transitioning to C++ with SFML2, though, for my next project since it wil have Android and iOS support

[–]the_hoser 4 分/分 ago

I'd stick with libGDX, unless you're doing a ridiculous amount of raw drawing. My last foray into SFML2 was... lukewarm. It just doesn't feel complete. If you're only doing what the SFML developer(s) thought about, then it works great, but once you step outside those lines...

The extension-oriented nature of libGDX avoids this problem nicely.

[–]jonatcer[S] 3 分/分 ago

Doesn't libGDX support shaders? If so, why not offload the drawing to the GPU? That way it's not really Java that's limiting the speed and you'll get roughly(?) the same speed as native.

[–]BTMPL 4 分/分 ago

LibGDX support OGL 2.0, so that's the right way to do it, yes.

[–]the_hoser 3 分/分 ago

Yes, it absolutely does, and this is a sound strategy.

[–][已删除] ago

[deleted]

[–]jonatcer[S] 2 分/分 ago

I'm not sure what you mean by XNA's lack of shader support

XNA only supports 3.0, and you have to use the 'HiDef' profile to get it.

[–][已删除] ago

[deleted]

[–]jonatcer[S] 2 分/分 ago

Yes, as far as I'm aware Monogame should support 4.0.

[–]badlogicgameslibgdx slavemaster @badlogicgames 3 分/分 ago

mhhh, tasty flamebait with zero content. use the right tool for the right job...

[–]the_hoser 1 分/分 ago

Or not. I'm of the position that it really doesn't matter what you use. If you like the tools and you like the results, who's got the right to tell you that you did it wrong?

LibGDX and Java feel good and help me get things done, but that's a matter of my personal taste. Worrying too much about doing it "right" has stalled more of my younger self's games than I care to count.

EDIT: Just noticed your username. Cheers :)

[–]badlogicgameslibgdx slavemaster @badlogicgames 5 分/分 ago

It's up to you to define "right". Could be JS, could be QBasic, doesn't matter.

[–]the_hoser 3 分/分 ago

I agree 100%. The problem is that, for someone who's maybe not so experienced with software development (and even a few that should be), defining "right" becomes such a huge part of their thought process that they miss the point of the endeavor. That's why I try to use other terms, to encourage them to stop worrying and write a game.

[–]Ace-O-Matic 1 分/分 ago

Stencyl 3.0 is uses HAXE.

[–]shitflavoredlollipop 1 分/分 ago

Ethanon Engine is angelscript based. It's a free, cross platform 2d engine with pretty cool graphics capabilities (see dynamic lighting out of the box)

http:///

[–]brokenyoyo 1 分/分 ago

Of the list I've only worked with LOVE and Unity. I prefer Unity by far because how quick I can get things working. You mention how restrictive Unity free is, but I don't find that to be the case.

The things that Unity free is restrictive on are things that are easy to do without or achieve the same affect in a different way (List of differences). The group I work with creates all of our own stuff for use with Unity. Unless I'm mistaken (and I don't think I am), Unity has access to all .NET class libraries. If you wanted to use Delegates or Generics for something, that isn't a problem.

It sounds like you're a more experienced programmer than myself, so you might find some faults with it that I haven't yet. At the very least give it a try.

[–]jonatcer[S] -1 分/分 ago

The main concern I have with Unity Free, is the lack of support of loading assets on demand (I.e. Assets not already in the scene) - which hurts dynamically generated worlds.

[–]jeremiahnunn@sketchycode 2 分/分 ago

I'm curious what you mean here. I have free, and I often only load assets at run time. I'm pretty sure you can build meshes dynamically, too. (That's how RageSpline works, I believe).

[–]uber_neutrino 1 分/分 ago

It's hard to pick something without more context on what you are trying to build. Personally I've used a lot of different things. Mostly focused on Javascript for the scripting side at the moment but the game engine is C++. We argue all the time about re-writing it in something else.

[–]hg341 1 分/分 ago

Since no one has said this yet OverGrowth uses Angel Script for game logic.

[–]Mad_Dugan 1 分/分 ago

AngelScript is great if your main project is also C/C++. I have used it in a couple of projects (even contributed code several years ago).

My usual decision on what scripting language to use is based on who will be writing the scripts. I think JavaScript will end up being the next big thing so learning its syntax via an applications scripting library would also have long term career benefits.

[–]Qwerberc++ haxe python 1 分/分 ago

In all honesty I don't know much about Java. I've dabbled in it with android development, but have always considered it to be a dying language with poor game support.

It's not dying... I don't even use Java and I know that.

[–]m2c 1 分/分 ago

check out moonscript for lua - makes it nice to use, syntax remake.

[–]JyrroeC++ | C# | Obj-C 0 分/分 ago

I've just finished graduating a 3 year game dev program, and while I'm not familiar with everything in your list, I can tell you what I've learned in general over the course of it.

I learned C/C++ first, because it's a great place to start when learning programming of course. What came next though was C#/XNA. XNA is interesting, in that it simplifies the game development process, but isn't exactly cross-platform or heavily supported. That's why I recommend it to everyone as a learning tool, not for real-world development. With XNA, I learned even more about programming, like entity-component systems, some basic physics, and even shaders. I spent so much time learning HLSL, I want to become a graphics programmer now.

What came next was Unity. It's a big thing around here now, I've even got a job in a local company working with it. Sliding into Unity was a breeze for me, because of my experience with XNA (C# scripts are practically identical). Unity presents the opportunity to develop games far more quickly than other engines/frameworks, and for a variety of platforms. At the end of the day, I'm all about making fun games for as many people as possible to play, so cross-platform versatility is a big plus for me.

In between, I learned more C++, OpenGL, GLSL, and Objective-C. I've developed small games for Windows, Windows Phone, and iPhone, and worked at 2 companies that developed iOS games. In the end, Objective-C just takes a long time to drudge through (XCode is the devil), and even cocos2D and cocos2D-X, while being big steps forward, still present problems and slow-downs during development.

Overall, Unity has come out on top in many respects. Perhaps I'll stop explaining and just make a short list like yours of what I've learned personally:

  • Lua - I've used it before with L?VE, and I agree about it's weirdness. It felt more like a fun experiment than something I would really dedicate myself to using, but still a powerful scripting language. I would like the chance to get into again, should the need arise.

  • AngelScript/Haxe - Unfortunately, never heard of either of these...

  • C# - With tools like XNA for learning and Unity for development, C# has definitely come out on top for me, and the whole game dev program I went through. It can now be used to develop games for Windows, Mac, Linux, web, iOS, android, and even the three major consoles.

  • Java - Agree with you again, I don't know a lot about it, only what I learned on my own time. I haven't developed any Android games... it is on my to-do list, though.

So there's my dump from three years of learning about this industry. Hope it helps, if only to show what they're teaching to us newbies these days.

[–]the_hoser 10 分/分 ago

Javascript is not Java. Not even related. Apples and oranges.

[–]JyrroeC++ | C# | Obj-C 0 分/分 ago

That's my point. By "closest I get" I meant "not even". That's why I don't know a lot about it.

[–]Canazza 3 分/分 ago

Java, like The_hoser said, is nothing like Javascript.

I mean, seriously. It has nothing in common besides the name.

Java is much closer to C# than to anything else. Language wise, C# is basically Java with all the crap taken out.

[–]AffenKopf 3 分/分 ago

Still a misleading statement to make...

[–]jonatcer[S] 0 分/分 ago

Not sure why you're being downvoted. I, for one, greatly appreciate your comment. Thank you for it.

[–]RSFlux 1 分/分 ago

I think you are confusing "game engine" and "language" in a number of places which is really confusing the discussion. For the vast majority of your concerns, you are really asking about engines. I also don't think it is fair to compare different game engines without having any context of what your needs are, so I will focus on what the languages above can REALLY offer...

Speed - Some languages are faster at executing a basic statement than other languages. Generally, compiled languages are faster than interpreted languages, but that can sometimes be flipped with JIT optimizations. Also, in ALMOST EVERY real-world application of a language, algorithmic or architectural changes can provide improvements that are an order of magnitude+ faster than what a different language could provide with the same algorithm/architecture. Unless you have the time, resources and know-how to milk a platform for every bit of performance, a language shift is unlikely to make a significant difference in what you ship with regards to performance.

Compatibility - This is a big one for indy games because you probably don't have the resources to build your game multiple times for multiple platforms. Engine choice will have to be accounted for here, but know what your potential target platforms are and try to pick a language that can be compiled (or hosted in an application in the case of LUA, etc) onto your target platform. This requires a compiler, but also platform libs and conformance to any platform owner restrictions (no interpreted code on iOS, for example).

Ease of development - First and foremost, which languages are you comfortable with? That should affect your decision and is completely personal. After that, modern languages have a number of features that are intended to speed up development and reduce common categories of bugs. This includes garbage collection, generic object support, OOP constructs, functional programming constructs, reflection, data access libs, etc. Most of these are good and WILL multiply your productivity. The tradeoff is that you lose a bit of control and sometimes a bit of performance (but good luck writing a better general purpose garbage collector than Python or Java provides...you're not going to. Your alternative is to manually manage memory which not only increases implementation time but also drastically increases bugs/debugging time).

Graphics - Completely irrelevant to the language discussion. All of the languages you are discussing either have or could be easily extended to support anything you would want to do. Engine choice is the thing you need to consider for graphical decisions.

Community support - If you haven't made games before or work in an organization that can provide you with resources, you are going to need help. Picking a popular language that other people are using to make games will make getting those answers easier and more reliable. Don't discount this - if you pick some obscure language very few people are familiar with, you are going to have a bad time when you get stuck.

Source: I make AAA games for a living and have used every language you listed above + Python which you discounted way too quickly :)

[–]jonatcer[S] 2 分/分 ago

I think you are confusing "game engine" and "language" in a number of places which is really confusing the discussion. For the vast majority of your concerns, you are really asking about engines. I also don't think it is fair to compare different game engines without having any context of what your needs are, so I will focus on what the languages above can REALLY offer...

Sorry for the confusion, but I wasn't. I was actually referring to the game engines and frameworks that each language may have / has.

Anyways, thanks for the post :)

    本站是提供个人知识管理的网络存储空间,所有内容均由用户发布,不代表本站观点。请注意甄别内容中的联系方式、诱导购买等信息,谨防诈骗。如发现有害或侵权内容,请点击一键举报。
    转藏 分享 献花(0

    0条评论

    发表

    请遵守用户 评论公约

    类似文章 更多