Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

hittest using dynamic movieclip 1

Status
Not open for further replies.

xmaria

Programmer
Oct 6, 2003
1
SE
i've used an xml file to load coordinats for the movieclip plattform.

duplicateMovieClip(_root.plattform, "plattform"+i, i);
_root["plattform"+i]._x = xaxel;
_root["plattform"+i]._y = yaxel;

My problem is that i cant find a way to check if my other moviclips is in line with the movieclip plattform.
tried the following for-loop:

for (r=0; r<=antalblock; r++){

if (this.hitTest( _root.&quot;plattform&quot;+r)){
_root.test=&quot;hit&quot;;
}
else{ _root.test=&quot;miss&quot;;}

thought it might have something to do with the z_index . HELP!!!
 
The theory is sound enough but this syntax is odd:

this.hitTest( _root.&quot;plattform&quot;+r)

try

this.hitTest(_root[&quot;platform&quot;+r])
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top