Perfect Collision mask for physics?

This forum is currently in read-only mode.
0 favourites
From the Asset Store
Particles support animations, collisions, effects and etc.
  • So.. is there any plans to add a perfect collision mask to objects with the physics behavior? You know.. not rectangular or oval, but in the actual shape of the sprite!

  • It's already there - "Per Pixel."

  • That's only for the platform movement, object overlaps etc. The physics engine uses it's own collision mask which is set in the properties of the physics behavior. Right now you can choose between Bounding box, Ellipse and None.

  • Well hey, guess what? You didn't say physics in your first post!

  • Well.. eh.. look again.

  • "Last edited by Attan on Tue Apr 15, 2008 12:02 am; edited 1 time in total"

    Mmhmm, yes ...

    Anyways, depends on if the physics engine Ashley used supports it, I would think.

  • Hmm.. I think it uses Newton Game Dynamics, so.. probably not since it's an engine for 3D originaly. Well.. We'll have to wait for ash for a final statement.

  • I wonder if maybe as a work-around, you can use a separate sprite set to the angle/position of the physics to detect for you.

  • I don't know if it's possible either, but I'd really like to see it. I've been wanting to make a pinball game for some time, which isn't feasible without smooth curves. Well, not a good-looking pinball game anyway.

  • I don't know if it's possible either, but I'd really like to see it. I've been wanting to make a pinball game for some time, which isn't feasible without smooth curves. Well, not a good-looking pinball game anyway.

    http://futurepinball.com/

  • http://futurepinball.com/

    That program looks kind of interesting but there are two things wrong with it:

    1. I'd have to learn (and master) yet another dev environment, and one that is rather limited in scope. Plus if I knew Visual Basic (which it uses for game logic scripting) I'd probably just be coding my own games from scratch.

    2. It doesn't build an .exe, which means only the niche Future Pinball users would be playing my game. I'd much rather be able to reach a wider audience, and casual players wouldn't be very willing to install a separate program just to run my table.

  • Heh future pinball was cool. I made a few tables with that in the past, quite complicated tables in fact... I wonder where they got to?

    Also, I had the same collision problems with the 3D box object, so I turned collision off on the box and made a simple sprite object that was the same dimensions/position as the box and that now works properly. I guess you could do the same thing with physics objects as well?

  • I had the same collision problems with the 3D box object, so I turned collision off on the box and made a simple sprite object that was the same dimensions/position as the box and that now works properly. I guess you could do the same thing with physics objects as well?

    No, the collision stuff is completely different for physics objects as it is for plain sprites. Yes, you can detect if a physics object is overlapping a per-pixel collision sprite, but it won't interact with it in a physics simulation.

  • > I had the same collision problems with the 3D box object, so I turned collision off on the box and made a simple sprite object that was the same dimensions/position as the box and that now works properly. I guess you could do the same thing with physics objects as well?

    >

    No, the collision stuff is completely different for physics objects as it is for plain sprites. Yes, you can detect if a physics object is overlapping a per-pixel collision sprite, but it won't interact with it in a physics simulation.

    Ah yes of course... my brain doesn't work at night lol XD

  • Try Construct 3

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

    Try Now Construct 3 users don't see these ads
  • The short answer is no, physics collisions won't be per pixel, because the collision engine in Newton is substantially different - it operates on convex polygons rather than bitmap masks. Also, many bitmap masks are impossible to convert to a convex polygon. I was thinking about adding some kind of polygon editor, so you could at least approximate the object's shape with a convex polygon, but it's probably some way off.

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