A tileset concept-need help

This forum is currently in read-only mode.
  • Well, I had this weird idea- store an entire tileset in one object as seperate animations and have the computer figure out what animation to play depending on how many tiles a block comes in contact with.

    The problem is this: It doesn't work. Is it something wrong on my part or is there no way for this to work? (I probably did something really stupid and will regret posting this topic later...)

    LINK: http://a.imagehost.org/download/0572/tileset

  • Slightly bettered version

    First of all you got the offset for Up/Down confused. Use a negative offset for Up and a positive offset for Down on the Y axis. I also added a pseudo-grid event (first event). It's more intuitive to work with this kind of stuff like this I believe.

    EDIT: And I forgot something very important. You can't check like that for overlap of the same kind of object. You'll have to use the old trick of adding 2 families to your ground sprite (blue + green for example) and then check for overlap of those 2 families then instead.

    With the slight changes I made it's at least possible to build boxes out of four ground pieces. But your events in the Tileset Events group don't really work they way you want them to. I already made something like this btw with my PUOP example (tell me if you want to see that source), but it didn't use offset (because I was too stupid back then or there even was no offset yet) and it did load the tiles from PNG files.

    If you fiddle around with the events you should be able to get it to work. I just don't have time on my hands right now to set it up myself. Hope this helped a little already.

  • Okay forget the other version, this should work like you wanted it to:

    Kind of proper version

    Building any kind of boxes now should just work fine. You're missing sprites that are closed on three sides for example, which you'd need to properly form other shapes.

    Also note that I made the changes in version 0.99.42, while your original cap appears to have been saved in an older Construct version. Just in case you're wondering why you can't open it, you'll need the latest Construct.

  • Hey that sounds like a good idea.

    Make sure collisions are set to bounding box

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Wow, this helped alot. Now if I could implement that into a level editor of some kind, that would be awesome

  • Now if I could implement that into a level editor of some kind, that would be awesome

    You could simply use an array to save your levels. Store your object coordinates in the array and use the "Save to file" action. With "Load from file" you can load your level back into the game.

    That's how I did it before and I think it would be the simplest way to go.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)