# A little problem with my walls

**URL:** https://forum.kirupa.com/t/a-little-problem-with-my-walls/51956
**Category:** Uncategorized
**Created:** [May 18, 2004, 7:56pm UTC](https://forum.kirupa.com/t/a-little-problem-with-my-walls/51956 "2004-05-18T19:56:17Z")
**Posts on this page:** 1
**Page:** 1

<div class="post-metadata">

### Author: ![TjomasC](https://avatars.discourse-cdn.com/v4/letter/t/9f8e36/32.png) [@TjomasC](https://forum.kirupa.com/u/TjomasC)
#### Post date: [May 18, 2004, 7:56pm UTC](https://forum.kirupa.com/t/a-little-problem-with-my-walls/51956/1 "2004-05-18T19:56:17Z")

</div>

I have a slight problem with my walls when I use hittest.

In my game I have a sort of maze thing, which is navigated by a guy I nicknamed “Joe”

I’m using hittest to stop Joe passing through the walls, and was having sucess untill I split the walls in half, so that the charecter wouldn’t pass through it.

The wall looks like this: (if it was a diagram!)

-------------- Top movie clip  
-------------- Bottom movie clip

I did this to stop the charecter passing through the walls, but when I try to pass through top movie clip, it lets me through, even though I coded to push the charecter away

the top wall code:

```auto

onClipEvent (enterFrame) {
    if (this, hittest(_root.Joe)) {
        _root.Joe._y = _root.Joe._y - 12;
    }
}

```

The bottom code works fine (it’s the same, but with a + sign)

Any ideas? or even better, is there another way?

Thankyou!
