New to flash and I'm having some trouble making gravity and having things not go through barriers and walls. I'm using something like " if (this.hitTest(getBounds(_root).xMax, _y, true)) {
_x -= hitback; hitground = true;
}" and its not so good. Sometimes you can fall through the ground and sometimes you bounce. Could anyone give me a script on Walls and gravity and maybe explain it?