Need help with 8Direction

0 favourites
  • 11 posts
From the Asset Store
Game with complete Source-Code (Construct 3 / .c3p) + HTML5 Exported.
  • Hey guys,

    first, my english is not really good, i hope you will understand my problem.

    I made a map (1440 x 1080) and a small guy which i want to control trough the Map. (Map: )

    If i move around with my character in the map, its like there is a big Cross trough the whole map, where my character can't past trough. (I try to show you what i mean: Green: I can move around, Red: i get blocked )

    Is this a bug, or did i something wrong?

    I hope you guys can help me with this. If you are German, it would be really helpfull to me, if you can help me in german, but english should be also okay

    Regards

    KiiBa

  • You don't yet have enough rep to post links so we can't see the image you are linking.

    Can you post your capx? That would actually give a better idea of what is going on anyway. An image doesn't allow me to look at what objects you have on the layout and the collision bounds for the objects.

  • Thanks for the fast answer, i'm sorry, i didn't know that.

    What do you mean with "capx"?

  • That is the file extension for a project in Construct, if you save it as a single file. Basically, find your saved project and attach it to your post. I will download it, open it and take a look at what is going on.

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • Okay, here it is

  • Ok, it was what I thought. Your collision bounds are not set to what you think they are. Below is a picture of the actual collision bounds:

    [attachment=0:3sbf925e][/attachment:3sbf925e]

    As you can see, this is your MapWalls image. You are trying to get collisions according to where the black lines are on this image. Construct doesn't work that way. The blue lines with red dots are the actual collision bounds set. When an image is imported, Construct tries to create a collision polygon automatically but, in cases like your image, it is impossible. The collision polygon expects a single enclosed area to wrap. With a map of walls, there is no real enclosed portion. To get the result you want, remove collisions from the wall image, add a new rectangle object called wall and place it along the places you want collisions to happen. You will have 1 instance of the wall for each wall in the image.

    I hope that helps and good luck with your project.

  • Okay, i see the problem, and i know what you mean.

    But i don't know Construct very well, and i have no idea how can make collision at more different parts :/

  • See this edited version of your project. The upper left 3 buildings have the wall object. In game the walls are set to invisible so the player only sees your background image. You would have to do the same for all the buildings.

  • Yay it actually works, thank you so much.

    Can you explain me what do you had to change that the red Wall get work as collision? (I bet this english is not english lol)

    I want try to understand Construct 2, cause i really like making video games

    Again thank you for your help!

  • The red wall is a sprite with the solid behavior. It's not an image like yours was. You have to place a single sprite on each wall of the background. Try to move 1 of the red lines in the editor and you'll see what I mean.

  • oh i see, thank you very much

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