Jump to content

  • Log In with Google      Sign In   
  • Create Account

We're offering banner ads on our site from just $5!

1. Details HERE. 2. GDNet+ Subscriptions HERE. 3. Ad upload HERE.


Progamming for beginners


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
14 replies to this topic

#1 greenthingsjump   Members   -  Reputation: 109

Like
0Likes
Like

Posted 07 October 2012 - 12:48 AM

Hello!

First let me say I have ZERO programming experience. However, I love playing video games. I am not good at math but enjoy the challenge. I like the order and definitve set of rules that programing seems to have. I will learn C++ but that is not what I want to start with. I was looking for a language that would go well with C++, but is easy to learn and works well with it. After I pick the langugae and learn then I will worry about 2D vs 3D games and the engines for it... On to the questions..!

1. What would be a good language that fits the above critirea?
2. Which would be easier for beginners 2d or 3d games?
3. Is it wise to go the "easy route" first?
4. Im attracted to python because I like snakes, weird I know... Would this be a good choice, why (or) why not?

Sponsor:

#2 jbadams   Senior Staff   -  Reputation: 19068

Like
6Likes
Like

Posted 07 October 2012 - 01:42 AM

1. What would be a good language that fits the above critirea?

Python would be an excellent choice. It is generally considered to be easier to learn than C++, but is a very capable and expressive language that sees a extensive professional use both in and out of games development. It can also be extended with C or C++ (for performance reasons or to gain access to an existing library) relatively easily, or can be embedded in a C++ program as a scripting language. There are plenty of resources for learning the language and a selection of libraries for games development. Python has been used in Eve Online and Civilization 4 amongst others.

You might also consider Lua, which is also a popular and performant scripting language in the games industry but can also be used stand-alone to create games. You could use LOVE to create 2d games in Lua. The advantages are very similar to those offered by Python.

C# is also a popular choice.


2. Which would be easier for beginners 2d or 3d games?

In depends on your selection of language, libraries and engines. A beginner using Unity might find 3d more approachable than 2d thanks to the functionality provided. Generally however, 2d is usually considered to be more approachable and achievable unless you're using a tool-set that makes 3d the better option.

2d would be more approachable with either Python or Lua.


3. Is it wise to go the "easy route" first?

I think it's a great idea to learn a language like Python before -- or simply instead of -- C++. By choosing a language with less complications and a shorter learning curve you can focus more on the basics of programming itself rather than getting caught up with the many exceptions and corner cases a language like C++ presents. Depending on your goals you may even discover you don't actually need C++ at all, but you'll find it much easier to pick up if you're just learning the specifics of the language rather than programming as well.

Not everyone agrees with this opinion, but I expect you'll be hard pressed to find anyone who would suggest that learning a language such as Python would set you back or make learning C++ any more difficult -- it's certainly not wasted time to learn a different language; especially a popular one like Python or Lua. Skilled professional developers know a range of different languages, and there's no reason you shouldn't start off with one that will allow you to see some faster results.


Hope that helps! Posted Image

#3 greenthingsjump   Members   -  Reputation: 109

Like
0Likes
Like

Posted 07 October 2012 - 06:19 AM

Thanks!

Im new and know I want to get into game programming. I have no Idea where to start. Everyone says C++ Is the way to go... for games. I would was thinking of doing 2d games for now just to get a good understanding of how to develop them. Then later move on to something more advanced. I will be reading in depth on python and lua now. Thanks!

#4 zalzane   Members   -  Reputation: 191

Like
1Likes
Like

Posted 07 October 2012 - 12:49 PM

Thanks!

Im new and know I want to get into game programming. I have no Idea where to start. Everyone says C++ Is the way to go... for games. I would was thinking of doing 2d games for now just to get a good understanding of how to develop them. Then later move on to something more advanced. I will be reading in depth on python and lua now. Thanks!


C++ is the industry standard for games so a lot of people suggest it, but it's a horrible starting point for a beginner looking to make their own games.

I back the python recommendation.

#5 Goran Milovanovic   Members   -  Reputation: 1104

Like
2Likes
Like

Posted 07 October 2012 - 07:27 PM

Another vote for Python, and another chance for me to push my Python 3 video tutorial series.

+---------------------------------------------------------------------+

| Game Dev video tutorials  ->   http://www.youtube.com/goranmilovano |
+---------------------------------------------------------------------+

#6 ELawson   Members   -  Reputation: 118

Like
2Likes
Like

Posted 09 October 2012 - 07:17 AM

Ok, I hear this a lot. What exactly is "HARD" about C++ ?? It is unfair since I've been programming since '88, and the only language around was either C or assembly (or BASIC). But why disuade people from any language? C++ isn't any "harder" than any other object oriented language out there. If by "hard" you mean all the crashes you get from undisciplined pointer use, then I would say better to do it now while you're learning than at your first job.

So my actual question is: Why is C++ considered hard?
I always seem to solve my bugs on the drive back to work the following day! So why wont my boss let me go home now? Twitter_Follow

#7 jbadams   Senior Staff   -  Reputation: 19068

Like
3Likes
Like

Posted 09 October 2012 - 07:45 AM

Difficulty is to a certain degree subjective, but I personally think there are a couple of reasons C++ is (or can be) hard:

Firstly, C++ is difficult because it assumes the programmer is an expert who knows what they are doing. This provides great freedom and flexibility when the assumption is true, but means there are many mistakes that are more easily avoided or simply aren't possible in other languages. Making it worse, there are plenty of mistakes where the code will often appear to work perfectly but cause subtle problems elsewhere or fail at some later stage.

Secondly, "undefined behavior": this term appears more often than might be desirable in the standard, and the language is therefore rife with situations where it's possible for all sorts of difficult to diagnose problems can occur, and again these situations are often hidden from beginners when faulty code seems to work just fine.

Third, there are a lot of bad or mediocre learning materials available teaching "c with classes" or making recomendations against standard library and other common code for reasons that have no business being applied to beginners.

#8 Goran Milovanovic   Members   -  Reputation: 1104

Like
0Likes
Like

Posted 09 October 2012 - 09:44 AM

So my actual question is: Why is C++ considered hard?


Difficulty is subjective, as jbadams pointed out, but I personally don't consider C++ "hard".

It's tedious, because manual memory management is tedious, and that's why I usually recommend a higher-level language as a starting point.

+---------------------------------------------------------------------+

| Game Dev video tutorials  ->   http://www.youtube.com/goranmilovano |
+---------------------------------------------------------------------+

#9 GeneralQuery   Crossbones+   -  Reputation: 1263

Like
3Likes
Like

Posted 09 October 2012 - 09:58 AM

If you're learning to drive, the mechanics of actually driving the car is but a minor point, the rest is about learning road awareness, the highway code, learning how to read and anticipate situations and generally learning to be a safe, competent driver. Learning to drive in, say, a Porsche 911 adds an unnecessary layer of complexity and potential for danger so instead people learn to drive in cars that are far more forgiving. Same goes for programming. Any unnecessary layers of complexity and potential for danger only hinder the learning process, beginners have enough on their plate as it is.

#10 Serapth   Crossbones+   -  Reputation: 5594

Like
0Likes
Like

Posted 09 October 2012 - 10:51 AM

Difficulty is to a certain degree subjective, but I personally think there are a couple of reasons C++ is (or can be) hard:


Difficulty is, complexity isn't.
C++ is a complex language. Needlessly complex in many ways. Complexity is a direct contributor to difficulty.

To the OP, I would recommend reading this, it's my standard and incredibly long answer to this question. But it should get you much further along then you are now if you read it.

Since I wrote that guide, I have been working more and more with Lua, and I am quickly coming to the conclusion that Lua is actually the perfect starting point for any new developer. It is just a wonderfully concise but remarkably expressive programming language. An experienced developer can learn the basics in a weekend, but then write 95% of a complete game in it, perhaps even 100%.

My only real beef with Lua are
a- defaulting to global
b- indexing arrays from 1

Those flaws aside, it really might be the perfect starting language. It is faster and easier then Python, far easier than C++ or C#/Java, etc... Is commonly used as a embedded scripting language, and has a few wonderful libraries to get started with.

#11 Serapth   Crossbones+   -  Reputation: 5594

Like
1Likes
Like

Posted 09 October 2012 - 10:54 AM

If you're learning to drive, the mechanics of actually driving the car is but a minor point, the rest is about learning road awareness, the highway code, learning how to read and anticipate situations and generally learning to be a safe, competent driver. Learning to drive in, say, a Porsche 911 adds an unnecessary layer of complexity and potential for danger so instead people learn to drive in cars that are far more forgiving. Same goes for programming. Any unnecessary layers of complexity and potential for danger only hinder the learning process, beginners have enough on their plate as it is.


This analogy doesn't quite go far enough. At the end of the day, driving a Porsche 911 in the city is really not that different from driving a Ford Focus. Also, the performance difference between languages isn't so deep either.

I would think a more apt comparison would be a Bugatti Veyron to a Formula One car. Both have comparable performance characteristic, but in a certain niche, in the right properly trained hands, the Formula One car will be superior. In other regards, and in ease of use, the Veyron will be superior. But at the end of the day, the Formula One car requires a hell of a lot more knowledge, special treatment and is just generally more of a pain in the ass to operate. On the flipside, you throw a formula one driver ( or C++ programmer ) at any other car ( language) they will do a pretty passable job with it.

Except LISP.

Edited by Serapth, 09 October 2012 - 10:55 AM.


#12 jbadams   Senior Staff   -  Reputation: 19068

Like
1Likes
Like

Posted 09 October 2012 - 08:17 PM

Goran, Serapth: Great points, I'd definitely agree. C++ is more complicated and tedious than it is hard.

#13 greenthingsjump   Members   -  Reputation: 109

Like
0Likes
Like

Posted 09 October 2012 - 09:03 PM

Wow! I did not realize I had started such a large topic... lmao.

#14 EddieV223   Members   -  Reputation: 1406

Like
0Likes
Like

Posted 09 October 2012 - 10:01 PM

I did python as a first programming language. I do not recommend it. It will teach you many bad habits. Your best bet to get something that works some what close to c++ is java or c#. Java is more cross platform than c#. C# is a microsoft language, though there is a open source port of it called mono, this however is going to be similar to a much older version of c# 2.0 I believe.

Both languages have a C style syntax so you will feel rather comfortable going from either to c++. Python has a rather nasty syntax in my opinion. It makes a decent scripting language though.

I would say choose c# if you plan on only programming microsoft oses. Choose java if you're doing cross platform or working on linux.

The microsoft Visual studio IDE for c# is very good. This is why I suggest c# over java on microsoft oses. Also msdn is a really good place for documentation which you should get used to reading in a hurry.

Move up to c++ when you have made some fully functional and usable applications in your beginning language.

If your serious about programming. I suggest visiting 3dbuzz.com and checking out their videos for the live C# classes they did, for 35$ a month you get access to all of them via streaming of the recorded video, it's a college level education for 35 freaking dollars. I was there and participated live, they are really good. They also did c++ classes. They're building a new website and then they are going to come out with all kinds of new stuff, like iOS and andriod programming classes, more c# and c++ classes too.

Edited by EddieV223, 09 October 2012 - 10:06 PM.

If this post or signature was helpful and/or constructive please give rep.

 

// C++ Video tutorials

http://www.youtube.com/watch?v=Wo60USYV9Ik

 

// Easy to learn 2D Game Library c++

SFML2.1 Download http://www.sfml-dev.org/download.php

SFML2.1 Tutorials http://www.sfml-dev.org/tutorials/2.1/

 

// SFML 2 book

http://www.amazon.com/gp/product/1849696845/ref=as_li_ss_tl?ie=UTF8&camp=1789&creative=390957&creativeASIN=1849696845&linkCode=as2&tag=gamer2creator-20

 


#15 jbadams   Senior Staff   -  Reputation: 19068

Like
0Likes
Like

Posted 09 October 2012 - 11:10 PM

I did python as a first programming language. I do not recommend it. It will teach you many bad habits.

What bad habits do you think you learned from Python? Obviously it's not going to teach you the curly-braces style syntax found in languages such as C/C++/C#/Java and you'll need to learn the syntax and adjust to the particular idioms if later changing to any of those languages, but I don't see any reason Python should impart bad habits.

In addition, beginners (and even more experienced programmers) can benefit from the interactive shell which allows you to try out and see the results of single lines of code without having to go through a laborious compilation process. This becomes less beneficial when writing larger pieces of code, but is an absolute god-send when a beginner is trying to learn the basics and can easily try out code for themselves.

Python has a rather nasty syntax in my opinion.

To each their own -- and this really is just personal preference on both our parts -- but just to represent an opposing point of view I personally find the syntax of Python very pleasing. In particular, because indentation has meaning, poor or inconsistent formatting of code seems to be far less commonplace, and with only a small amount of experience Python code listings can often be read just as clearly as pseudo-code.




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS