Added: 1 year ago
From: callistek
Views: 439
Sort by time | Sort by thread (beta)

Link to this comment:

Share to:

All Comments (7)

Sign In or Sign Up now to post a comment!
  • cool, cool. are the building sprites your own btw?

  • @H3llkn0wz Yes. I'm not the artist, an employee of mine is. We will be revamping the art later to make it look a little better. It's still not.. 100% :)

  • Impressive stuff! How do you sort your items? As in move the items at the bottom in front of images at the top based on their Y value or something like that. I'm trying to come up a decent depth sorting method but I have no idea where to start :P

  • @legoVideos114 ... hope you can follow what I'm about to say: I start at the top left most visible tile... then i work 'down' the Y tiles, until I'm off screen, then I go +1 on the x tiles, and start at the top-most tile that is visible, and work my way back down again, I do this over and over, until I'm at the far bottom right point, and then I stop.

    As I arrive on each tile, I render what's on that tile. This is good if your maps are small enough. If your map is huge (100mx100m) i suggest...

  • @legoVideos114 another method, using link'ed lists' or maybe a library of objects, then just render them as soon as you go by the tile. (on tile X, check through all the items that match .x and .y)... there are tons of other ways of doing it. I do NOT like doing it based on screen position... because I just have too many things that can go wrong with that...

  • @callistek So objects that span more than 1 tile in length are technically two objects on their own tile?

  • @legoVideos114 Yes, and that will get you other issues, for example. age of empires 2, when you are trying to build a building, over top of a preexisting building, you will notice an issue where parts of the building suddenly cut off. That's why in my game, if you try to build over top of something, it will display red tiles instead of the building itself (not yet implemented)

Loading...
Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more