Paths for objects / Collisions with specific sides

This forum is currently in read-only mode.
From the Asset Store
Build your own spaceship for your side scroller space shooter games with various components.
  • Hello all. I'm making an extreeemely simple single-screen platformer, just to get my feet wet, and I have a couple of embarrassingly basic questions. Pardon the lack of proper terminology.

    Paths: Is it possible, in Construct, to create a path, and then say to a specific object, hey you, follow this path? Like platforms or nasty spike blocks or what have you.

    Collisions: Is there a simple way to make collisions only occur on certain sides of an object? For example, imagine a block that's flat on the top but spiky on the bottom, so the character can stand on it, but gets hurt if he jumps into it from beneath. (I can think of some creative solutions that might work, but I thought I'd ask first if there was a simple, obvious-to-everyone-but-me way.)

    Oh! One more thing: Is it just me, or does 'Max fall' in the Platform behaviour not have any effect? I've had my character fall infinitely (using the Wrap behaviour), and he just gets faster and faster. All of the other variables seem to work like they should.

  • Um... I thought I posted this in the Help forum. Did I post it in the wrong forum accidentally, because I'm an idiot, or did it get moved?

    If it got moved, well... I'm not actually making any feature requests; I'm asking for help doing these things I want to do.

  • Check out deadeyes platform school it will answer alot of questions about this kind of stuff and shoy you how to do it.

    There is not path object but it is explained in the tut i mentioned above.

    also you can check collisions by comparing the positions but your better off making 2 separate object and checking collisions on the spike object. Or if you have to use one object for the spikes and platform make an invisible sprite and check collisions on that for spikes.

  • You posted in the wrong place. I moved it to Help/Tech for you

    There is currently no path object, but you can create your own paths by making "waypoint" objects, and having the object you want to move around just move from waypoint to waypoint. There are a few examples of this on the forum if you want to search around.

    If you want an object that is flat on top and spiky on the bottom, the easiest way to do it would be to make two objects. A platform and a spike. Or you could make your Platform/Spike hybrid tile and use that as decoration, while using invisible solid and hurty objects that are placed over the decoration in the appropriate place.

    And "Max Fall" should limit the speed at which your character falls. It appears it's broke in 98.9 but in 99.2 it's fixed. So, congrats on finding your first bug and thanks to David for fixing it already

    [quote:1badnt0f]There is not path object but it is explained in the tut i mentioned above.

    What? I don't do path stuff in my tutorial . Unless you count "back and forth" as a path.

  • Back and forth is a path just not a very complicated one.

  • You posted in the wrong place. I moved it to Help/Tech for you

    Gah! How did I even do that? Well, thanks.

    [quote:2bckt89p]There is currently no path object, but you can create your own paths by making "waypoint" objects, and having the object you want to move around just move from waypoint to waypoint. There are a few examples of this on the forum if you want to search around.

    Will do; thanks!

    [quote:2bckt89p]If you want an object that is flat on top and spiky on the bottom, the easiest way to do it would be to make two objects. A platform and a spike. Or you could make your Platform/Spike hybrid tile and use that as decoration, while using invisible solid and hurty objects that are placed over the decoration in the appropriate place.

    My platform/spike might be a moving object, but I can probably make that work by having one of the objects constantly checking for the position of the other, right?

    Ideally I would like this object to be safe on the top and the sides, and only hurty on the bottom. I think I can work out a solution, though, using the same 'two objects as one' idea.

    If I can't, well... you'll hear about it.

    Thanks again!

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • I see two ways to do this (untested, as usual):

    Method 1: make them all part of a container, then move the container object.

    • sprite1 - underspikey-moving-platform: visible, with movement events
    • sprite2 - solid platform: invisible, solid, platform
    • sprite3 - spikey bit: invisible, kills player on contact

    If you make a container on sprite 1 with sprite 2 & 3 inside it, moving sprite 1 should move the others automatically.

    Method 2: different sub-events for different conditions

    For example:

    + Player collides with platform
    ++ Player moving down
    ++ Player.y > platform.y
    --> land on platform, standing animation, etc.
    ++ Player moving up
    ++ Player.y < platform.y + platform.height
    --> kill player, lives-1, death sound, reset layout, etc.[/code:2ap95zkr]
    
    Let me know if either of these work.
Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)