- Exclusive Author
- Item was Featured
- Author was Featured
- Author had a File in an Envato Bundle
- Has been a member for 4-5 years
- Sold between 100 000 and 250 000 dollars
- Repeatedly Helped protect Envato Marketplaces against copyright violations
- India
Looking for a solution on this:
- A container Sprite has 2 objects inside and one over another.
- The object on top hides the blow one. So the object below is not visible.
- If we reduce the alpha property of container, the object below becomes visible slightly which is unexpected. But this is the way flash works.
To avoid this, there is an alternative: Instead of setting alpha value to the container, mask the container and apply alpha to the mask object.
But I don’t want to go with mask due to other issues on the project. Is there any alternative for this? Any simple property / blend modes that can help these situations?
Thanks!
- Has been a member for 3-4 years
- Author had a File in an Envato Bundle
- Author was Featured
- Item was Featured
- Exclusive Author
- Interviewed on the Envato Notes blog
- Contributed a Tutorial to a Tuts+ Site
- Microlancer Beta Tester
About alpha,you can try use blendMode = “layer” . I often use it. 
- Exclusive Author
- Item was Featured
- Author was Featured
- Author had a File in an Envato Bundle
- Has been a member for 4-5 years
- Sold between 100 000 and 250 000 dollars
- Repeatedly Helped protect Envato Marketplaces against copyright violations
- India
Thanks activetofocus! That works!
But sadly it works only if objects doesn’t have any 3D properties set. hmm… due to the same reason, mask also doesn’t works! 
and I guess you dont want to double the alpha ? cause if I got this correct all you need to do is when changing the container alpha change the object visibility at the same time. like below object visible false and container alpha reduce. so you’ll only show foreground object as fading.
- Exclusive Author
- Item was Featured
- Author was Featured
- Author had a File in an Envato Bundle
- Has been a member for 4-5 years
- Sold between 100 000 and 250 000 dollars
- Repeatedly Helped protect Envato Marketplaces against copyright violations
- India
XanderRock said
...when changing the container alpha change the object visibility at the same time. like below object visible false and container alpha reduce. so you’ll only show foreground object as fading.
Yes, that will work but objects are only partially overlapped. So we can’t hide them.
Anyway we have whole lot of trouble when using native 3D properties of flash. Really not sure if next flash version will have some solutions. Otherwise it will be a 3D tool that ’s not much supportive to real life interactive projects. What actually happens is even if the child objects are working only with 2D properties, the usual display functionalities (bitmap mask, blendmodes etc) are disabled in player 10.
So I guees its about 3D object properties. But as you know Adobe keeps upgrading AS3 . its a very powerful lang.
And did you also try removing below 3d object from display? and keeping it in cache to add it to stage later. Cause it should probably work.
- Exclusive Author
- Item was Featured
- Author was Featured
- Author had a File in an Envato Bundle
- Has been a member for 4-5 years
- Sold between 100 000 and 250 000 dollars
- Repeatedly Helped protect Envato Marketplaces against copyright violations
- India
XanderRock said
And did you also try removing below 3d object from display? and keeping it in cache to add it to stage later. Cause it should probably work.
Thanks for the suggestions. To be clear, the container is a sprite that has some z position (so it’s parent becomes 3D). All it’s children are within 2D properties. I guess the player has no logical problems applying those display properties to children. Should try some more tricks with hierarchy tree and need to see if I miss something.
- Envato Staff
- Reviewer
- Sold between 100 000 and 250 000 dollars
- Author had a Free File of the Month
- Featured in a Magazine
- Author was Featured
- Item was Featured
- Bought between 10 and 49 items
Try using BitmapData to draw the container Sprite before applying 3D transformation then create a new Bitmap to hold that BitmapData and apply 3D properties and alpha to that Bitmap.
Downside is you’ll need to keep drawing if there is any animation.
- Exclusive Author
- Item was Featured
- Author was Featured
- Author had a File in an Envato Bundle
- Has been a member for 4-5 years
- Sold between 100 000 and 250 000 dollars
- Repeatedly Helped protect Envato Marketplaces against copyright violations
- India
RimV said
Downside is you’ll need to keep drawing if there is any animation.
Yes that is the case.
Just found that the blendmode works but we need to add another container inbetween (on which blendmode set to “layer”), that’s fine. So no problem with the way Flash works!
Also works only when either parent or child is not 3D. Doesn’t work if both has 3d which is understandable.
