Thread: Tutorial on making games in C

  1. #16
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Ireland
    Posts
    8,446
    Alternatively, before delving into Allegro, you can start by looking at the code of some rogue-like or MUD games to get a better grasp of game programming in C using a simpler graphic interface like PDCurses. Not being too cluttered by a more complex video and multimedia programming library, these source codes better illustrate a game programming structure with its main loop and how to branch out from there into the several processing tasks a game demands. Rogue-likes will give you a glimpse into single-threaded game programming (most of them anyways. Some are multi-threaded) and MUDs will help you better understand multi-threading and network game programming.

    You should then be able to better understand how to incorporate Allegro into game programming, once you learn about the usual structure of a game written in a procedural programming language like C.
    Originally Posted by brewbuck:
    Reimplementing a large system in another language to get a 25% performance boost is nonsense. It would be cheaper to just get a computer which is 25% faster.

  2. #17
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Quote Originally Posted by the_jackass View Post
    There's no harm in using C all your life. Sticking to one language lets you actually do serious, skilled stuff. C *is* perfectly ok for big programs. See Apache or Fontforge for example, they're both 100000+ line C softwares.
    No. There is much harm in sticking to one language. Don't sugar coat this. For one, employers are looking for people who have programming skills and knowledge - not just in one programming language - but many.

    Furthermore, today is a dynamic world, but which I mean there are so many things - web, embedded systems, smart cards, computers, mobile phones, etc. All of them have different requirements and different environments and different programming languages are often differently suited for these environments. Sure, you can use C for most things - but why do that? You end up reinventing the wheel so many times - and why do that when you can have your compiler or toolchain do the work for you? It's silly. By actually learning different languages, you can pick the language best suited for the task at hand - the language that best reduces cost, time and bugs.

    C is not a good tool for big programs (but sometimes there is no other choice, such as the linux kernel, for example). There is a reason most of the world does not use C for big programs. Simply because C lacks common modern language features that makes it easier, safer, faster to create big programs. So stop encouraging people to use C for everything. Use the appropriate tool for the task at hand.

    But enough of this - let's actually help the OS satisfy his/her academic lust creating games in C. Experimenting for fun is not a bad thing.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Making Board Games...
    By Junior89 in forum Game Programming
    Replies: 28
    Last Post: 12-31-2005, 12:20 PM
  2. Making 3d Games
    By danepporambo in forum Game Programming
    Replies: 16
    Last Post: 12-01-2005, 10:17 PM
  3. going about making PS2 games
    By DarkViper in forum Game Programming
    Replies: 22
    Last Post: 02-03-2003, 04:31 PM
  4. making games
    By Unregistered in forum Game Programming
    Replies: 2
    Last Post: 02-23-2002, 02:23 PM
  5. best language for making games?
    By Unregistered in forum Game Programming
    Replies: 9
    Last Post: 11-09-2001, 05:37 AM

Tags for this Thread