开发者

Cocos2d score label goes off screen

In my game the score will rise every time you collect a treat, I have positioned the label at the bottom left. The problem is when the score goes up part of the label goes off screen. Any ideas on how 开发者_Python百科to fix this.


Try setting the alignment to alignment:UITextAlignmentLeft like so:

        CCLabelTTF *score = [CCLabelTTF labelWithString:@"yeahh" dimensions:CGSizeMake(100, 100) alignment:CCTextAlignmentCenter fontName:@"Marker Felt" fontSize:22];
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜