Skip to main content
GameDev.net gamedev.net
🔒 Locked

Easiest coding language?

Started by Tan Koon Hong Dec 15, 2014 at 12:32 PM 24 replies 6.9k views
Original Post
Tan Koon Hong
Tan Koon Hong

Hello people!

I am new to all this coding and game making stuff and would like to know the easiest coding language to learn and make games from. Planning to make a 3D game. Leave some suggestions and maybe a link to a good tutorial! smile.png

Thanks! biggrin.png See ya around.

DvDmanDT
DvDmanDT

I'd argue C# with Unity, but you are probably asking the wrong question(s) at this time.

alvaro
alvaro
Did you read the sticky at the top of this forum? It links to a FAQ with good information of this sort.
Gian-Reto
Gian-Reto

define easiest... tongue.png

really, just start. Any language will do at your current position. You will have months and years of learning how to program ahead before you can start worrying about making your 3D Game.

Start much smaller, "hello World", text adventure, pong, tetris, and so on... read FAQs and beginners turtorials and you will understand what I mean.

In the end, all of the languages relevant to game dev share common roots in C. Thus the syntax of the languages is sometimes quite close. Besides that, the core basics of programming are the same for any language involved, if you you understand what variables are, you will be able to use them in any language with just a quick google search (or a good reference book for that matter) to look up the syntax of this new language.

In the end, a good programmer most likely is versed in multiple languages, altough he might have only achieved true mastery in one (for that, you will need to know some of the weird and wonderful specialities that set apart the different languages, and some experts might know so much that they are called "living virtual machine" or "living compiler" smile.png )

Having said that, Java is among the easiest Object oriented languages I know, altough this is not as big in game dev as in other fields of software development.

C# Is much bigger in game dev today and IMO just as easy as Java, maybe even better in some ways, while avoiding some of the pitfalls and complexities of C++, which maybe is THE tool to write performant software in an object oriented manner, but as it was created by hackers for hackers, can be used to write horrible code if the programmer is inexpierienced.

Besides this you will find python recommended quite often.

nunobarao
nunobarao

I think that once you learn how programming works in general, from my experience you don´t really need to bother wich one is the easiest, cause at that time you will be able to programming in any language as far as you learn syntax difference and how to use libs or Api´s.

Just start with anyone you feel its ok for you now, and focus to learn how sytanx works, what is a variable, type of variables, what is a function,what is a operator, types of operatprs, types of functions , what is a loop, recursive functions and so on...

Seriously, just start with anything now and then you choose what language it really fit your needs.

mark ds
mark ds

If you're starting from scratch, I'd have to seriously recommend downloading Visual Studio 2013 Community Edition, and learning C#. There are loads of online resources, but better still buy a good C# book.

After several months of hard graft getting your head around programming, look into using an existing game engine, such as Unity or Unreal (both of which can be used with C#).

Storrund
Storrund

I started with and recommend Java, but this depends from person to person.

RLS0812
RLS0812

This all depends on you ... "easiest" is in the eye of the beholder.

It is highly recommended to stick with a chosen language for a while ( until you learn all the basics ) before moving on to another one - jumping from language to language constantly will lead to burn out.

It is NOT recommended IMHO to use a game engine before at least learning the basics of how to write code.

Here is a list of some of the more common "languages" folks consider to be "easier to learn" .

Python

Ruby

Lua

C# ( c sharp )

Basic

Visual Basic

JavaScript

PHP

HTML - CSS ( not recommended unless you want to write your own web pages )

I cannot remember the books I've read any more than the meals I have eaten; even so, they have made me. ~ Ralph Waldo Emerson
Serapth
Serapth

I would actually argue that this is a question with an actual answer.

Lua.

At least so far as game development languages go, with a minimal useful set of functionality, Lua is in fact the easiest option available. This is of course assuming you meant easy as either a) easy to learn b) easy to use.

Why?

One of the easiest type systems ever implemented.

Extremely simple syntax.

No build/link cycle.

Very good logical consistency.

Well documented and supported.

Good tooling available.

Single click download available.

The only knocks against Lua, for beginners anyways, are the lack of REPL out of the box, the 5.1 vs 5.2 fragmentation and the fact it's 1 based unlike well every other programming language since Visual Basic

Most of the "conventional" programming languages ( Java, C++, C#, etc... ) are an order of magnitude more complex than Lua. This isn't a bash on any of them, but in terms of "easy", they aren't.

You can look at comparable scripting languages and each of it's competitors have "easy" issues.

  • python is a great deal more complex, and vastly more fragmented. The fragmentation has basically killed this languages momentum.
  • ruby is much smaller in community size (at least in gaming) and is also more complicated.
  • PERL is shit, outside of it's intended string processing role
  • PHP is what someone gets when they take a shitty language and make it shittier
  • JavaScript is... well first off, there is the DOM, JavaScript in the browser is a nightmare, because the implementations are crap. When just looking at the language itself, certain horrible design decisions ( this implementation, comparison operators, etc... ) are a huge hazard for new (and experienced) devs
  • ActionScript... is actually a pretty good choice. It's like JavaScript where someone polished away a lot of the stupidity. Being tied to a vendor as awful as Adobe though... and a very questionable future make this one iffy. ActionScript is actually a pretty solid beginner choice, well documented, clean language, good community... tooling is kinda crap though, unless you are on windows
  • F#, Smalltalk, LISP, Haskell, et al. Well, they are just too weird for beginners... good idea to learn though.... eventually
  • Visual Basic.. too old. Modern Visual Basic is just C# in a pretty dress, so the language is basically dead
  • Haxe... it's a nice clean language, but ultimately requires knowledge of other languages when shit breaks, and it will

Now, once you take "language" out of the equation, and look purely at game development tools, then it gets a bit more interesting with players like Stencyl (Haxe), Construct2 (Javascript), Gamemaker (GML), RPG Maker(Ruby), etc... basically acting as code generators for you. In those cases, easy isn't so clearly defined.

But when it come down to actual programming languages, for game development, defining easy as "easy to use" or "easy to learn", I do think Lua is actually a clear winner. Put simply, if I was going to start a game programming class for young teens, I would almost certainly start with Lua.

Brain
Brain
I started out with bbc basic, but I come from an earlier time. These days i would start out with c# and mono... Also consider that you need a library like monogame and make sure you read up on the logic and maths of 3D and games in general, things like mainloops and patterns/antipatterns..

Good luck!
Nypyren
Nypyren
Some languages are great for beginners learning how to program, but bad for teams of developers trying to maintain large projects.

Dynamic typing is one of those things that is great for beginners, small projects, and single-programmer teams. Once you start dealing with non-trivial projects and large teams, static typing becomes much more important because it DRAMATICALLY increases the reliability and ease of maintaining a codebase.
mark ds
mark ds

To Serapth

From Lua's Wiki: Lua is crap!

"Lua is a tiny and simple language, partly because it does not try to do what C is already good for, such as sheer performance, low-level operations, or interface with third-party software. Lua relies on C for those tasks. What Lua does offer is what C is not good for: a good distance from the hardware, dynamic structures, no redundancies, ease of testing and debugging. For that, Lua has a safe environment, automatic memory management, and great facility to handle strings and other kinds of data with dynamic size."

In this modern age, battery life is just as important as absolute performance.

Serapth
Serapth

To Serapth

From Lua's Wiki: Lua is crap!

"Lua is a tiny and simple language, partly because it does not try to do what C is already good for, such as sheer performance, low-level operations, or interface with third-party software. Lua relies on C for those tasks. What Lua does offer is what C is not good for: a good distance from the hardware, dynamic structures, no redundancies, ease of testing and debugging. For that, Lua has a safe environment, automatic memory management, and great facility to handle strings and other kinds of data with dynamic size."

In this modern age, battery life is just as important as absolute performance.


Of course, all features come with a price tag, this is certainly true of ease of use.

That said, we aren't talking about performance or battery life ( granted, they are often very similar ), we are talking about ease of use. I am by no means calling Lua the greatest or best language, simply the easiest, within the defined terms.

If you ever meet someone that proclaims one language as superior in every way, congratulations, you've met an idiot. Sadly, the world is full of them.
Ravyne
Ravyne

I don't think anyone's recommending that OP starts with Lua and never moves on, or to try and create complete software in Lua alone.

Lua is a nice start because of the reasons Serapth mentions that make it a good language in which to learn programming concepts. When one is ready to move on to a more production-ready language, Lua skills remain valuable because its a popular scripting language in all kinds of software but in games especially. LuaBind makes it relatively easy to write your game's core low-level logic in C++ for things like performance and battery life, but to script high-level game behaviors in Lua for its ease of use and better productivity.

Lua is a perfectly reasonable start, as would be C#, or Java (as much as I dislike the language myself), or JavaScript -- all of which remain useful skills even if one changes gears. C and even C++ are not bad choices, provided you are willing to take things slowly and deal with a certain amount of non-trivial trivia.

The easiest language to learn is whatever is easiest now -- there is no requirement beyond that, not even that it is suitable itself for production work.

Anyways, every programmer learns and throws away knowledge of several programming languages over their career, but it does not mean that time was wasted because they were a necessary stepping stone or maybe just an interesting exercise. Of the first 4-5 languages I learned and used (4 BASIC variants, and C), I never use BASIC of any flavor these days and use vanilla C only rarely, on top of that I've learned and played with a dozen or more languages just to see what was interesting about them and stretch my brain a bit (Haskell, Scala, Lisp, SQL, D, etc.), and I've written code in a few flavors of assembly over the years (z80, 6502, ARMv4, x86) -- I use today maybe 10% of the languages I've non-trivially-used over all my years, namely C++ (and a little bit of vannilla C), C#, and JavaScript. Even now I've got my eye on Rust, eagerly awaiting its stable 1.0 release scheduled for January.

throw table_exception("(? ???)? ? ???");
lightxbulb
lightxbulb

Off topic, would Rust be a good language to pick up? I am looking to learn more languages apart from C++, Java and C#.

Valoon
Valoon

Honestly I started with C++ then I went to C# out of curiosity and I definitly think its easier.

Then when you are decent at C# (no need to be really good), you can do games on Unity which, at least to me, was very motivating.

I did that and now I am back on C++ but I still use C#.

Ravyne
Ravyne

For practical real world use...?



No, not really, at least, not yet


But soon, if you're so inclined. The plan is that they will release version 1.0 of Rust in January, at which time the language will be 'stable' -- it will continue to grow and evolve, but things that are stable in 1.0 won't disappear or be radically changed thereafter like they might have been in the early days of the language.

IMO, Rust is interesting, and because its got the backing of Mozilla and because they're already writing their next-generation webkit competitor in it, its not going to be just another academic exercise.

That said, its aimed at the same domain as C++ and while there are many important differences between them they are not the kind of radical differences you would experience in a functional or dynamically-typed language, so it might not be that fruitful as an exercise in expanding your brain -- one would be most interested in Rust if they were looking for a safer and less cumbersome alternative to C or C++.
throw table_exception("(? ???)? ? ???");
lightxbulb
lightxbulb

Thanks for the info. That's what I expected - a more "elegant" version of C++. I'll have functional programming next year anyways, so I won't be missing out on it.

Ravyne
Ravyne

For me to leave the impression that its just a more elegant version of C++ is certainly selling it short. It does a lot differently than C++, different concepts and models for things, and a few tricks of its own. For example, one rather neat thing about it is that a defined subset of the language can execute on bare metal with no runtime support and you can compile against this subset, so its suitable for embedded systems but also higher-level than C -- I intend to do some bare-metal programming in Rust next year, either on the Raspberry Pi, Nintendo DS, or GBA, just for kicks. Anyway, when I said it was an safer and less cumbersome alternative to C++, I meant that its focussed on safety and is a more-coherent language than C++ is, but it serves mainly the same domain and you're programming at roughly the same level of abstraction with a procedural language -- but it is a very different language than C++, not a direct derivitive; its much further removed from C++ than, say, D, C#, or Java.

Anyways, I'll stop derailing the thread now :) If anyone wants to continue this thread of discussion, PM me, or start a new thread and PM me the link.

throw table_exception("(? ???)? ? ???");

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.