Sandwich247's Forum Posts

  • 4 posts
  • Darn. Nice.

    I shall implement these tips.

    Thank you.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • That's a thing? Would you be able to explain how I would do this?

    Thanks.

  • Hi,

    I am working on a very small project, and I've run into an issue.

    In the game, the character is a 32x32px sprite, that moves 32 pixels in what ever direction you choose, in a grid. W goes up by 32 Pixels, S goes down, etc. However, in this game, walls will be included. As such, there needs to be a check in place, so the player character does not phase through walls.

    I thought I could implement this by creating the wall as a sprite, and adding a boolean to the player character, that will get set to 1, should the player co-ordinates be the same as co-ordinates for a wall sprite. There would also be a check on the player movement, that checks if the boolean is set to 1. If it is set to 1, the player character would then be sent 32 pixels back the way, and then set the boolean to 0.

    I'm not entirely sure how to go about this, and was wondering how I would do so. Or even if there was a much more light-weight way to do this. e.g. not having the walls be individual sprites, as there could be thousands per in-game level.

    Thanks.

    EDIT:I accidentally posted this, originally, in the wrong place. I've moved it here, and I also figured out how to do it.

    Solution: dl.dropbox.com/s/pjeusiarv44rt27/Movement%20Example.capx

    Basically, there are 4 unique, pink, sprites that move alongside the player. When they intersect the wall sprite, they set the value to the corresponding detection variable to 1. Whilst this variable is set to 1, the player can't move in that direction. If the player moves in any other direction, all the wall detection variables are set to 0.

  • Hi,

    My name's Andrew, and I am looking into making small games in my free time using Construct 2!

    I believe I first heard about this by a youtube named Nerd³, who used this software to make a small game of pool.

    My first project is a very simplistic, top-down, grid-based game, in which you navigate a grid to reach the end. I plan on developing this idea into something much more substantial, but for now, I will be happy if I can achieve this.

    As of right now, I work software support full time.

  • 4 posts