Impact

This forum is read only and just serves as an archive. If you have any questions, please post them on github.com/phoboslab/impact

1 decade ago by Joncom

I was wondering if anybody knows of some good examples of slopes.

I'm thinking about an idea I'd like to work on in the future and a couple things I'm curious about are:

- The point when walking up a slope that it becomes too steep to continue.
- Physics objects that roll down slopes and eventually stop when reaching flat ground.

As a second thought, does anybody know of an example of destructible landscapes done well in Impact?

1 decade ago by dominic

Have a look at the Entity&039;s <1> property. Per default entities can't stand on a slope with an angle > 45°. You can use the #.standing property to define the horizontal movement speed - i.e. allow for less horizontal movement when the entity is in the air.

Since all Entity&039;s in Impact are defined by an Axis Aligned Bounding Box, they can't really _roll_ down a slope, but just slide. This should work out of the box. They will stop sliding on the ground if you set a #.friction for the entity.

1 decade ago by stahlmanDesign

In the private forum I have a game that uses slopes. When climbing a slope that is too high, it detects the slope angle and also applies some this.vel.y -= climbAmount

I don't know if there's a better way, but it works to get the bike to go up a steep hill

example

1 decade ago by Joncom

Stahlman, that's exactly what I meant. Thanks for the good example. It reminds me of Elasto Mania which I think would be a thrill to try and clone some day.

Thanks Dom, good to know the framework has support for this kind of thing. I've been loving Impact so far. Cheers.
Page 1 of 1
« first « previous next › last »