# hitTest issue

**URL:** <https://forum.kirupa.com/t/hittest-issue/270454>\
**Category:** flash\
**Created:** [September 10, 2008, 7:04am UTC](https://forum.kirupa.com/t/hittest-issue/270454 "2008-09-10T07:04:04Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![outlaw\_xXx](https://avatars.discourse-cdn.com/v4/letter/o/ecccb3/32.png) [@outlaw\_xXx](https://forum.kirupa.com/u/outlaw_xXx)\
**Post date:** [September 10, 2008, 7:04am UTC](https://forum.kirupa.com/t/hittest-issue/270454/1 "2008-09-10T07:04:04Z")

</div>

Ok here is the deal:

I made 3 objects and assigned a tween for each one, like so

```php

var redTween:Tween = new Tween(newRed, "y", Strong.easeOut, 500, 10, GetRandomRange(10,18), true);
var greenTween:Tween = new Tween(newGreen, "y", Strong.easeOut, 500, 10, GetRandomRange(10,15), true);
var badTween:Tween = new Tween(newBad, "y", Strong.easeOut, 500, 10, GetRandomRange(10,17), true);

```

and then after assigning the x value to 100 for all 3 objects i added this code

```php

if (newBad.hitTestObject(newRed)) {
		removeChild(newRed);
} else if (newBad.hitTestObject(newGreen)) {
		removeChild(newGreen);
}

```

and for some reason it is not removing the objects if they hit eachother.

any help is appreciated:beam:
