that is all of it, the very basicis collision test, which I worked out a lot more so it is perfect for head on collision. I don't feel like opening that up though so I'm not posting that.Code:if(this.hitTest(_root.ground) && speed > 1 || speed < -1){ speed = -speed/3;
Now I'm trying to think of how to have it so if the car hits the object at an angle, it rotates toward the object to become aligned with it. It would have to be above 0 degrees and below 45 degrees and I'm thinking it rotates half the speed in degrees untill it hits 0 or untill the hit test is false. I will work on that all today and maybe post my progress if nobody cares to add on.




Reply With Quote