[Flash Development Notes] problems with dynamic text boxes and masks in Flash

Source: Internet
Author: User
Because the visible area of the map in the game uses a mask, and the visible area contains dynamic text. Before using the mask Program Always good. However, after the mask was used, this strange thing happened. This BT problem finally happened to me today: by default, the dynamic text box cannot use the mask, because it has never been met before, I do not know this ,#-_-!!. Previously, we only know that _ alpha of dynamic text requires special settings.

So when the problem occurs, I almost want to go crazy. The severity of the problem is not to solve the problem of using a mask in a dynamic text box, but to realize that this is a problem.

So I deleted the text box and changed it to plain text and dynamic text...

Almost crazy. As shit went on, his head suddenly lit up. Could the "dynamic text" Monster not support masks? So hurry up and add a filter effect like the method of adjusting _ Alpha. When you try again, everything is normal, and again shit ~

After the problem was solved, I went to Baidu to search for it. I was not the only one who met it. I just wish I was too ignorant:

Network reference: UseCodeSolution to dynamic text

In flash, you cannot mask dynamic text directly by using the mask layer. You can use the setmask method.
Example:
Targetmc. setmask (maskmc );
Targetmc is the masked object, and maskmc is the masked object.


To solve this problem, I recommend that you add a filter effect to the dynamic text, whether it isLuminousOrProjection, Add only oneEmpty EffectYou can, For details, refer to: "How to adjust the _ Alpha value of the" dynamic text "box in flash", the same solution is very simple.

Summary:In fact, sometimes the problem itself is very simple, but what is difficult is that we do not realize this is a problem.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.