Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

当GLoader加载动画并且设置填充, 显示异常 #101

Open
liumazi opened this issue Mar 11, 2022 · 1 comment
Open

当GLoader加载动画并且设置填充, 显示异常 #101

liumazi opened this issue Mar 11, 2022 · 1 comment

Comments

@liumazi
Copy link

liumazi commented Mar 11, 2022

初始加载不可见,若调用 setFillAmount() 则可以看到按比例填充了,但不会播放动画;
因为 ActionMovieClip 中 target->setSpriteFrame() 并没有触发 FUISprite 顶点数据更新。

简单修复:

void FUISprite::setSpriteFrame(SpriteFrame* newFrame)
{
	Sprite::setSpriteFrame(newFrame);

	if (_fillMethod != FillMethod::None)
		setupFill();
}
@xiaoguzhu
Copy link
Member

填充在设计上是不支持动画的。当然,这里对2dx的修复我感觉应该没问题。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants