• Lucid Dreaming - Dream Views




    Results 1 to 16 of 16
    1. #1
      Member
      Join Date
      Feb 2008
      Gender
      Posts
      210
      Likes
      2

      Question Need to learn a computer language

      I REALLY need to learn a computer language. Can anyone tell me what is the best language to learn? I want to make video game when I get into college... since Im not doing much now that is contributing to my future... I have ALOT of time. I have a game written out and ready for programming but there are problems... 1. I dont have my own computer yet and 2. I do not know a computer language. Can anyone help me with this?

    2. #2
      Peaceful Warrior MrDamon's Avatar
      Join Date
      Jan 2008
      Gender
      Location
      Ireland
      Posts
      76
      Likes
      1
      Wowser!

      Well, at least you have an idea

      I first started with Q-Basic and from there progressed to Visual Basic and have "basically" stuck with that ever since.. While I find it is a good language to learn as its got the object design interface, you will never make really good "video" games with it so I would reccomend perhaps learning C/C++

      You will need a bit of Mathematical knowledge and unless your a wizz, a little bit of patience too.. Good luck


    3. #3
      FBI agent Ynot's Avatar
      Join Date
      Oct 2005
      Gender
      Location
      Southend, Essex
      Posts
      4,337
      Likes
      14
      I don't mean to piss in your cornflakes
      but that's like saying you want to learn metal-work so you can build a bridge

      yes, you can learn a language - you could probably pick the basics up in a few weeks
      but the average consumer-grade computer game takes many years to develop - with a team of 50 people

      by all means learn a language
      and have a look at some of the other threads about learning languages
      Eg. http://www.dreamviews.com/community/...ad.php?t=51395
      or http://www.dreamviews.com/community/...ad.php?t=36140

      Just don't get any illusions of grandeur
      (\_ _/)
      (='.'=)
      (")_(")

    4. #4
      dsr
      dsr is offline
      我是老外,可是我會說一點中文。
      Join Date
      Nov 2006
      Gender
      Location
      my mind
      Posts
      374
      Likes
      1
      As Ynot said, don't expect to learn one language in one week/month/year/whatever and be able to write a consumer-grade video game. Google's Peter Norvig wrote an article on this subject called Teach Yourself Programming in Ten Years. It's worth the read.

      If you do want to take up programming as a hobby, occupation, or lifelong pursuit, I highly recommending starting with Python because it's easy to learn and use and it produces both clear and concise code much more easily than comparable languages like Perl and Java. It also has a huge problem domain: you can use Python for quick and dirty scripts, desktop applications, CGI scripts, web applications, etc. The official tutorial is a great place to start. Once you're comfortable with Python, you should learn the aforementioned Java and Perl as well as lower level languages like C++ and even C. While increasingly less useful as time goes on, knowledge of assembly will expand your horizons, as will knowledge of functional programming languages such as Haskell and lisp. The more languages you expose yourself to, the more experience you will have in solving a wider range of problems. If memory serves, Eric Raymond's article How To Become A Hacker explores this notion. As for writing commercial-grade video games, you'll probably want a relatively low level object-oriented language like C++, at least for the bulk of the code. However, you'll also want years of experience and a team of 50+ people who are willing to work overtime especially during crunch time.

    5. #5
      Banned
      Join Date
      Apr 2007
      Location
      Out Chasing Rabbits
      Posts
      15,193
      Likes
      935
      Games huh? Learn C. C and C++ are used almost exclusively in gaming and C++ is just a kind of extension of C. It's object oriented which can be tricky to learn if you don't have any basics so C is the best bet.

      Nobody uses Basic for games, but it is a good way to start out, it's very simple. C is hard for beginners because it does exactly what you tell it to do and if you tell it to do something incorrectly it won't yell at you and you'll get confused. I would not recommend Visual Basic because it has some nasty little habits. For starters arrays begin at index one and every other language in the world starts at zero. It will confuse you when you try and convert. Qbasic is impractical because it doesn't work with XP and Vista. There was a 32 bit version created by a group of guys about three years ago called FreeBASIC. It's really powerful and has a GNU C backend. It's out for Windows and Linux.

      www.freebasic.net

      Also learn how to use the OpenGL library, it's the de facto standard for graphics and most companies use it.

      DirectX is used too, but companies are steering away from it. It'd also be difficult to learn at first because it's designed for object oriented languages.

      EDIT: Actually dsr, when dealing with the OpenGL pipeline a knowledge of inline assembly can be very useful.
      Last edited by ninja9578; 02-22-2008 at 01:17 AM.

    6. #6
      dsr
      dsr is offline
      我是老外,可是我會說一點中文。
      Join Date
      Nov 2006
      Gender
      Location
      my mind
      Posts
      374
      Likes
      1
      Quote Originally Posted by ninja9578 View Post
      C++ is just a kind of extension of C.
      But don't think of it that way because to use C++ well you have to program in a completely different mindset from C. In fact, Accelerated C++, often regarded as the best (although somewhat dry) introduction book to C++, jumps right into the STL with vectors, linked lists, and strings, and it doesn't teach C arrays or pointers until chapter 10.

      Quote Originally Posted by ninja9578 View Post
      EDIT: Actually dsr, when dealing with the OpenGL pipeline a knowledge of inline assembly can be very useful.
      I'm sure it can be, although my knowledge of both OpenGL and inline assembly is quite low. I just meant that with faster CPUs to support higher level languages and with compilers like GCC that convert C or C++ code into fairly optimized assembly, a working knowledge of assembly is not as much of a necessity in today's world. Of course, it helps for specific things like your example of a rendering pipeline, and it can't hurt to expand your knowledge.

    7. #7
      Banned
      Join Date
      Apr 2007
      Location
      Out Chasing Rabbits
      Posts
      15,193
      Likes
      935
      Quote Originally Posted by dsr View Post
      But don't think of it that way because to use C++ well you have to program in a completely different mindset from C. In fact, Accelerated C++, often regarded as the best (although somewhat dry) introduction book to C++, jumps right into the STL with vectors, linked lists, and strings, and it doesn't teach C arrays or pointers until chapter 10.
      Yeah, the mindset when programming in one verses the other is very different, I was merely stating that syntactically they are very similar. C will compile under a C++ compiler, doesn't CPP convert C++ to C then use it's GCC compiler for the final compilation? Maybe I'm thinking of a different compiler, but I know there is a common one that does that.

      I'm sure it can be, although my knowledge of both OpenGL and inline assembly is quite low. I just meant that with faster CPUs to support higher level languages and with compilers like GCC that convert C or C++ code into fairly optimized assembly, a working knowledge of assembly is not as much of a necessity in today's world. Of course, it helps for specific things like your example of a rendering pipeline, and it can't hurt to expand your knowledge.
      True, I know the code that GCC comes up with as a whole is far better than anything that I could write, it's just for little methods that are the difference between 30 and 60 fps where my assembly beats the compiler. That's important in CG and since he wants to do games, he's going to be optimizing his pipelines a lot.

      I love how I never have to create a single thread for my projects, GCC magically does it for me

    8. #8
      dsr
      dsr is offline
      我是老外,可是我會說一點中文。
      Join Date
      Nov 2006
      Gender
      Location
      my mind
      Posts
      374
      Likes
      1
      Quote Originally Posted by ninja9578 View Post
      Yeah, the mindset when programming in one verses the other is very different, I was merely stating that syntactically they are very similar.
      Indeed they are.

      Quote Originally Posted by ninja9578 View Post
      C will compile under a C++ compiler
      That's actually not true. C will compile under an Objective-C compiler but not under a C++ compiler because C++ is not a complete superset of C.

      Quote Originally Posted by ninja9578 View Post
      doesn't CPP convert C++ to C then use it's GCC compiler for the final compilation? Maybe I'm thinking of a different compiler, but I know there is a common one that does that.
      By CPP are you referring to the C Preprocessor? If so, I don't see how that would be possible. If you're referring to a compiler called CPP, I've never heard of it. Perhaps you mean G++ (the GNU compiler for C++)? If so, I don't know the answer. I've never studied how things work. I leave that up to these guys.

    9. #9
      Banned
      Join Date
      Apr 2007
      Location
      Out Chasing Rabbits
      Posts
      15,193
      Likes
      935
      Oops, yeah I was thinking of G++. I don't use command line for compilation, I always forget what the compilers are really called

      That's actually not true. C will compile under an Objective-C compiler but not under a C++ compiler because C++ is not a complete superset of C.
      Huh, I didn't know that. What's missing from the set?

    10. #10
      dsr
      dsr is offline
      我是老外,可是我會說一點中文。
      Join Date
      Nov 2006
      Gender
      Location
      my mind
      Posts
      374
      Likes
      1
      C++ is not a true superset of C because some constructs behave differently in C++. Wikipedia lists some of the differences here and here. Take for example the fact that char literals in C have type int rather than char, so sizeof('a') == sizeof(int) is true in C while sizeof('a') == sizeof(char) is true in C++. Therefore, you cannot use a C++ compiler to compile some C code.

    11. #11
      Cosmic Citizen ExoByte's Avatar
      Join Date
      Aug 2006
      LD Count
      ~A Dozen
      Gender
      Location
      Ontario
      Posts
      4,394
      Likes
      117
      Coding in C is like sending a 3 year old to do groceries. You gotta tell them exactly what you want, or you'll end up with a cupboard full of pop tarts and pancake mix.
      This space is reserved for signature text. A signature goes here. A signature is static combination of words at the end of a post. This is not a signature. Its a signature placeholder. One day my signature will go here.

      Signed,
      Me

    12. #12
      Banned
      Join Date
      Apr 2007
      Location
      Out Chasing Rabbits
      Posts
      15,193
      Likes
      935
      Didn't I say that? I even put exactly in italics too

      I've never heard such a great analogy for C before. I love it.

    13. #13
      FBI agent Ynot's Avatar
      Join Date
      Oct 2005
      Gender
      Location
      Southend, Essex
      Posts
      4,337
      Likes
      14
      I can just see the 3 yr.old sitting on the curb, crying
      holding a paper bag, with the bottom split
      apples and pears strewn across the road

      "Mummy, I had a Veg Fault !!"
      (\_ _/)
      (='.'=)
      (")_(")

    14. #14
      dsr
      dsr is offline
      我是老外,可是我會說一點中文。
      Join Date
      Nov 2006
      Gender
      Location
      my mind
      Posts
      374
      Likes
      1
      Quote Originally Posted by ExoByte View Post
      Coding in C is like sending a 3 year old to do groceries. You gotta tell them exactly what you want, or you'll end up with a cupboard full of pop tarts and pancake mix.
      Great analogy.

      Quote Originally Posted by Ynot View Post
      I can just see the 3 yr.old sitting on the curb, crying
      holding a paper bag, with the bottom split
      apples and pears strewn across the road

      "Mummy, I had a Veg Fault !!"

    15. #15
      Banned
      Join Date
      Feb 2008
      Posts
      3
      Likes
      0
      The best lang to learn for the gaming business is c++.

    16. #16
      Banned
      Join Date
      Apr 2007
      Location
      Out Chasing Rabbits
      Posts
      15,193
      Likes
      935
      It depends on what you're doing in it. The gaming business is pretty diverse. C++ is better for the engine, physics, and artificial intelligence. For the renderer C is still king.

      EDIT: Unless using DirectX which some of the larger companies are ditching because it's not portable.
      Last edited by ninja9578; 02-24-2008 at 01:34 AM.

    Bookmarks

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •