Sprite/tile-based game

This is a discussion on Sprite/tile-based game within the Game Programming forums, part of the General Programming Boards category; I'm interested in creating a 2-dimensional tile-based game utilizing sprites and such, but I have no idea where to begin. ...

  1. #1
    Registered User
    Join Date
    Jan 2008
    Posts
    24

    Sprite/tile-based game

    I'm interested in creating a 2-dimensional tile-based game utilizing sprites and such, but I have no idea where to begin. I have a 14 year background in programming console applications in C++, but zero experience with graphical programming. Most of what I can find related to game programming tends to lean toward 3D games or pre-made applications that "make the game for you". I'm not interested in either of these, so any help would be appreciated.

  2. #2
    Kernel hacker
    Join Date
    Jul 2007
    Location
    Farncombe, Surrey, England
    Posts
    15,677
    There is fairly little support in modern hardware for "sprites" as such. But you can probably draw a full screen background and overlay that with some "sprites" of your own design, using for example SDL.

    The only think classifying as a sprite in a standard PC would be the mouse cursor, which in the implementation I know of is implemented as a separate layer - and there where only three of those in one graphics card, so hardly useful for a game...

    --
    Mats
    Compilers can produce warnings - make the compiler programmers happy: Use them!
    Please don't PM me for help - and no, I don't do help over instant messengers.

  3. #3
    pwns nooblars
    Join Date
    Oct 2005
    Location
    Portland, Or
    Posts
    1,094
    Drrcknlsn, Go the 3D route, it may seem a little more complicated at first, but it will save you trouble because almost all the graphics APIs now do things in a 3d way, There are a lot of tutorials on gamedev.net (if I recall right) for doing this sort of thing.

  4. #4
    Dr Dipshi++ mike_g's Avatar
    Join Date
    Oct 2006
    Location
    On me hyperplane
    Posts
    1,218
    And whats wrong with using a 2d game development lib? Something like SDL or Allegro would make more sense to me.

    Theres a fairly good SDL tutorial on Lazy foo that shows how to set up a window with double buffering, load/draw images, mask sprites, do collision detection, and deal with event handling.

    I'd say making a tile editor that saves maps would be a good place to start.

  5. #5
    (?<!re)tired Mario F.'s Avatar
    Join Date
    May 2006
    Location
    Portugal
    Posts
    7,403
    Quote Originally Posted by mike_g View Post
    I'd say making a tile editor that saves maps would be a good place to start.
    Bubba was working on one a couple of years ago. Don't know how it turned out. But you may want to PM him or something... if he doesn't see this thread before that.
    The programmer’s wife tells him: “Run to the store and pick up a loaf of bread. If they have eggs, get a dozen.”
    The programmer comes home with 12 loaves of bread.


    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.

  6. #6
    Dr Dipshi++ mike_g's Avatar
    Join Date
    Oct 2006
    Location
    On me hyperplane
    Posts
    1,218
    Yeah I made one a couple of years back too. Kind of ended up as a bug infested mess with all the features I kept addding to it. For anyone thats interested you can download it here.

    That said my original point was that a simple tile editor can be done in a couple of k of code and would probably make a good little testing project before beginning something bigger like a game.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Text based game
    By beene in forum Game Programming
    Replies: 10
    Last Post: 05-12-2008, 07:52 PM
  2. A begginer writing a text based dungeon game.
    By deadherorising in forum C Programming
    Replies: 55
    Last Post: 11-10-2007, 05:16 PM
  3. C Programming 2d Array Question
    By jeev2005 in forum C Programming
    Replies: 3
    Last Post: 04-26-2006, 03:18 PM
  4. PC Game project requires c++ programmers
    By drallstars in forum Projects and Job Recruitment
    Replies: 2
    Last Post: 02-21-2006, 11:23 PM
  5. Tile Based game map
    By unanimous in forum Game Programming
    Replies: 2
    Last Post: 07-13-2003, 08:07 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21