# Using hitTest inside class

**URL:** <https://forum.kirupa.com/t/using-hittest-inside-class/229037>\
**Category:** Uncategorized\
**Created:** [June 13, 2007, 3:48pm UTC](https://forum.kirupa.com/t/using-hittest-inside-class/229037 "2007-06-13T15:48:25Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![tagdigital](https://avatars.discourse-cdn.com/v4/letter/t/f475e1/32.png) [@tagdigital](https://forum.kirupa.com/u/tagdigital)\
**Post date:** [June 13, 2007, 3:48pm UTC](https://forum.kirupa.com/t/using-hittest-inside-class/229037/1 "2007-06-13T15:48:25Z")

</div>

I’m kind of new to classes and am having trouble getting a hitTest to work inside a method. I created a class for an object and extend movieClip. It all works except I can’t figure out how to pass the object(s) that I want to test for a collision to the class object. I tried passing it in a method but it didnt’ work. Can someone please steer me in the right direction?

Thanks!
