Hello all!

I am creating a chart with hitTestPoint in it. I have 7 MovieClips. 1 is the point that moves around on the chart and it is to “hit” 1 of the other 6 that make the chart. I am not too sure how to use hitTestPoint but I used hitTestObject and it worked, but I don’t want to use the bounding box so I decided to use hitTestPoint. My problem I think is the X and Y coordinates. I am not too sure which X Y to use and how they are used. Any help would be great. The chart is inside a MovieClip and the Dot is added to it. The chart is made up of MovieClips (6) that make up a square.

Here is my code:

function hitChart()

{

hitDot.x = 25;

hitDot.y = -130;

chartMC.addChild(hitDot);

if (hitDot.x > 183)

{

hitDot.x = 183;

}

if (hitDot.y < -183)

{

hitDot.y = -183;

}

var tpoint:Point = localToGlobal(new Point(hitDot.x,hitDot.y));

if(chartMC.ChartSection1.hitTestPoint(tpoint.x, tpoint.y, true))

{

myColor1 = chartMC.ChartSection1.transform.colorTransform;

myColor1.color = parseInt(slideCounter.chartHitOn);

chartMC.ChartSection1.transform.colorTransform = myColor1;

}

else

{

myColor1 = chartMC.ChartSection1.transform.colorTransform;

myColor1.color = parseInt(slideCounter.chartHitOff);

chartMC.ChartSection1.transform.colorTransform = myColor1;

}

}

hitChart();