Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 2 [3]

Author Topic: Learning a coding language  (Read 3117 times)

Grishnak

  • Bay Watcher
    • View Profile
Re: Learning a coding language
« Reply #30 on: December 04, 2010, 11:17:12 pm »

Programming will infuriate you. You will get a bug that you just cannot figure out for hours. It will be something stupid and you will rage, but the moment you fix that bug, you will be the happiest person on the planet.  You will get irritated that you cant figure out how to do something. You will spend a lot of time thinking of "the best way" to do something. Realize that there really is no "Best way".  You will dream in code. When you shower, you will just think about programming. It generally consumes you.
^ Exactly how I feel about programming. Still learning the ropes in Python, currently I know how to use loops, conditionals, lists and such, and some functions. Might make a game once I get some more experience. I hope dad will catch my hints and get me a book on programming/a Python reference book for christmas.

Once you get the hang of Python, I recommend getting "Game Programming with Python" by Sean Riley. NOT to be confused with "Game Programming with Python, Ruby and Lua" by some other people.  This book completely forgoes teaching you the ropes of programming or Python and assumes you know your language, but has plenty of awesome stuff involving using PyGame and a little bit of OpenGL. It takes you through writing an entire game engine in Python, and even goes so far as to show you how to Embed and Extend Python, although not extremely deeply. 

It also isnt too overbearing or confusing, atleast until it starts getting into the Python C API for Extending/Embedding, thats where it will get a bit complex.

Here is a link to it if you are interested. It is definitely worth the money if you want to learn game programming in Python.
http://www.amazon.com/Game-Programming-Python-Development/dp/1584502584
Logged
I'm a saint when it comes to pirating.  I've ripped and burned many a .iso, went .rar at my maties and sailed the .7z's.
Blog for my new roguelike Lost Horizon. <- kind of on hold
My SoundCloud
My Youtube Channel

zilpin

  • Bay Watcher
  • 437 forever!
    • View Profile
Re: Learning a coding language
« Reply #31 on: December 05, 2010, 01:30:33 am »


I see many fad posts here.
Considering that you are starting naked, here's my bit.
Don't read this all at once.  Read first and last two paragraphs, come back later.

Python, start there.
Although I frown upon Python for practical applications, I do highly recommend it as a wonderful learning language.
That was it's designed purpose, and it performs admirably.
Then move on.  The training wheels feel safe and comfortable, but it's time to move on.

For object oriented methodology, I (regretfully) must recommend Java.  It is almost a purely object oriented language, and forces you to think and code in an OO manner for everything.  The primary utility of OO is thoughtful extension of what already exists, so Java's extensive library is good; the primary intent of OO was simulations, which Java performs adequately.  NetBeans is a good IDE for learning, though Eclipse is better for professional work.  Although I consider Objective-C better at teaching the nature of OO, and Smalltalk better still, I can not recommend them, simply due to smaller implementation base and fewer resources.

At this point, take a retro detour back to C.  Not C++.  C.  It gets you close to the hardware, but still gives you structured logic.  It lets you cut out your own heart with a laser torch... albeit by accident when you were just trying to peel a potato.  Learning it will give you a better understanding at what is going on at the base of all other platforms and languages out there.  Only Assembly and raw machine code get closer to the bare, naked hardware.  And, more importantly, coupled with what you learned in Java, it shall prepare you for the insane power of C++ (should you elect to learn it).

For learning the nature of lambda expressions and functional programming, nothing beats Scheme.  Ignore Ruby, Scala, Clojur, Haskell, Erlang, no matter how temped.
Why?  Scheme forces your brain to think in only a functional manner, which is the goal when learning something alien to you, and please trust me, lambda is quite alien to most human brains.
Ruby advocates will point out that it has a more friendly and natural syntax, which is true.  Please go read the sentence above, again.
Only move on to the others once you truly grok lambda in Scheme.
(Or Common Lisp, but Scheme is better at teaching, IMHO).
First Scheme project I typically assign: Write a simple program to replace all square braces [] with parentheses (), and vice versa.  It will make writing any Lisp based language much faster on keyboards where the square brace is a single keystroke, but the parentheses require shift, while teaching some of the basics of how Scheme sees the universe.


Everything I've suggested has many books written for it, many enthusiast guides, formal standards bodies, at least a decade of maturity behind it, implementations on many platforms, formal classes at colleges (should you so desire), and free accessibility.

By no means should you stop there, if you make it this far.
Those are the teaching languages.
Lua is a great little embeddable scripting language.
C++ is still around for a reason.  Consider it the most Dwarfy language of all time.  The Boost library is Adamantine.
C# (and the rest of the .NET stack) are going to be around for a long time.  But you should see things done philosophically correct before seeing them done by a marketing department.
Not to mention whatever is (re)invented between now and then.

Cheers, and best luck.
Logged
Pages: 1 2 [3]