troubleshooting Question

Flash AS2 - on(press) to attach MovieClip and reveal image

Avatar of dev09
dev09 asked on
Adobe FlashMultiMedia ApplicationsScripting Languages
8 Comments1 Solution965 ViewsLast Modified:
Hi Guys,

I'm stuck on some code I hope someone can help with. It's Actionscript 2 in Flash CS4.

I have a MovieClip that i want to attach to the Stage onClick, and for that to start to reveal an image on the lowest layer.  I have a MovieClip which i want to gradually be remove(masked) everytime i click.  So onClick 'newName' will affect 'maskMC' to reveal the image underneath.


This is what i have so far...

on(press) {
	_root.clickAmount++;
	// ATTACH MOVIE
	newName = "crack"+_root.clickAmount;
	_root.attachMovie("crackMC", newName, _root.clickAmount, {_x:this._x, _y:this._y});
	// MASK
	_root.newName.setMask(maskMC);  // This doesnt work, not sure how to make it work
}

Hope someone can help.

Thanks
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 8 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 8 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros