[Very rough method, which is an offence to Newton physic]
You could, for example, when you want your pivot bouncing:
- create a new pivot just behind your main one
- point to it with pointentity
- move your main pivot, which now will move in the opposite direction, thus bouncing
- destroy the just created pivot with FreeEntity
OR (easyer:)
- if collision then
-- TurnEntity 0,90,0
-- MoveEntity...
Bare in mind that if you, in your main loop, point your entity again toward the locaplayer, then your pivot will change again direction, so you have to make the pointentity direction once - before the mainloop, and then change the direction only when it collides.
Hope this helps,
Sergio.
You could, for example, when you want your pivot bouncing:
- create a new pivot just behind your main one
- point to it with pointentity
- move your main pivot, which now will move in the opposite direction, thus bouncing
- destroy the just created pivot with FreeEntity
OR (easyer:)
- if collision then
-- TurnEntity 0,90,0
-- MoveEntity...
Bare in mind that if you, in your main loop, point your entity again toward the locaplayer, then your pivot will change again direction, so you have to make the pointentity direction once - before the mainloop, and then change the direction only when it collides.
Hope this helps,
Sergio.