开发者

Does setting setting movieclip.visible = true each frame use any extra resources?

开发者 https://www.devze.com 2023-01-13 00:52 出处:网络
If something is visible, does calling movieclipname.visible = true; each frame do anything开发者_StackOverflow社区 performance wise?If the item is already visible, then setting it visible at each

If something is visible, does calling

movieclipname.visible = true;

each frame do anything开发者_StackOverflow社区 performance wise?


If the item is already visible, then setting it visible at each frame will not produce any performance. From what I know there is a check inside and if the component is already visible then the call is ignored. But you make extra calls for the compiler which in any case is leading to lower performance.

If there is a high number of such components where you keep setting visible to true... then it may lead to performance issues.

0

精彩评论

暂无评论...
验证码 换一张
取 消