Open
Conversation
只有在 colorDirty 真正发挥过作用后 ,再执行 node->_setColorDirty(false). 目前的逻辑存在一个 bug: 某帧: - node.colorDirty=true, - 但是 entity.isEnabled === false, - 那么 entity 的 透明度并不会被更新. - 可是在这一帧 node.colorDirty 仍然被设置为了 false. 下一帧: - entity.isEnabled === true 了, - 但是 node.colorDirty 在上一帧已经被设置为 false - 当前帧 entity 的 透明度仍然不会被更新 其实 cocos在 ts 端的逻辑也是 只有 visible 时, 才去修改 opacityDirty . ----- 我在实际项目中遇到的现象是 对 某个当前不可用 的 label 节点设置 透明度 , 当节点可用时 之前设置的透明度无效.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
只有在 colorDirty 真正发挥过作用后 ,再执行 node->_setColorDirty(false).
目前的逻辑存在一个 bug:
某帧:
下一帧:
其实 cocos在 ts 端的逻辑也是 只有 visible 时, 才去修改 opacityDirty .
我在实际项目中遇到的现象是
对 某个当前不可用 的 label 节点设置 透明度 , 当节点可用时 之前设置的透明度无效.
Re: #
Changelog
Continuous Integration
This pull request:
Compatibility Check
This pull request: