# Flash professional CS 5.5 actionscript 2.0 platform game help, can't jump over rock

**URL:** <https://forum.kirupa.com/t/flash-professional-cs-5-5-actionscript-2-0-platform-game-help-cant-jump-over-rock/326568>\
**Category:** flash\
**Created:** [December 25, 2011, 7:44am UTC](https://forum.kirupa.com/t/flash-professional-cs-5-5-actionscript-2-0-platform-game-help-cant-jump-over-rock/326568 "2011-12-25T07:44:19Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![arch01](https://avatars.discourse-cdn.com/v4/letter/a/c37758/32.png) [@arch01](https://forum.kirupa.com/u/arch01)\
**Post date:** [December 25, 2011, 7:44am UTC](https://forum.kirupa.com/t/flash-professional-cs-5-5-actionscript-2-0-platform-game-help-cant-jump-over-rock/326568/1 "2011-12-25T07:44:19Z")

</div>

Sorry, need some help again!

I have took a video of the problem  
[URL=“[http://www.youtube.com/watch?v=Hye39hn4KgE](http://www.youtube.com/watch?v=Hye39hn4KgE)”][http://www.youtube.com/watch?v=Hye39hn4KgE](http://www.youtube.com/watch?v=Hye39hn4KgE)

[COLOR=#000000]  
[/COLOR]I want to make my character jump over an object and also jump onto higher platforms  
I drew a rock, made it into MC, and gave it a script

onClipEvent (enterFrame){  
if(\_root.miku.hitTest(this)){  
\_root.miku.\_x-=10;  
}

}

this stops my char from going through the rock but when i jump over, it resets back my position somewhere else, and i can still go through the rock from the top, i set a platform on top of the rock and put a barrier script

onClipEvent (enterFrame){  
if(\_root.miku.hitTest(this)){  
\_root.miku.\_y-=10;  
}  
}

it doesn’t help much, and my char is now floating

question is : how do i set it to jump over the rock smoothly instead of it reseting my position  
and how do i make my char jump to a higher platform and make her stay there (i think it has something to do with gravity)

sorry i m getting all the key terms mixed up, like barriers, collision detect, gravity etc…

but yea, my **objective** is : to make like a mario style game, **able to jump on higher platforms, and jump over objects. t** hat’s for the basic. thank you all and merry christmas!

=)=)

ArCh~  
Cheers
