0

我正在将不同的文本加载到 SKLbeNode 中,它在 iPhone5、模拟器等上运行良好......但在 iPhone4 上,我有时只会得到一条黑线,而不是文本。

奇怪的是总是相同的文本产生失败,但我不知道发生了什么。

代码是:

ButtonText=@"";

    ButtonLabel=[SKLabelNode labelNodeWithFontNamed:@"Marker Felt"];
    ButtonLabel.fontSize=46;
    ButtonLabel.text=ButtonText;
    ButtonLabel.position=CGPointMake(0, 0);
    ButtonLabel.verticalAlignmentMode=SKLabelVerticalAlignmentModeCenter;
    ButtonLabel.horizontalAlignmentMode=SKLabelHorizontalAlignmentModeCenter;
    ButtonLabel.colorBlendFactor=1.0f;

当我更改文本时,只需使用

ButtonLabel.text=NewString;

可能是什么问题?

4

1 回答 1

0

我已向 Apple 提交了有关此错误的错误报告。几周后,他们回复并要求使用更新的 IOS 检查问题。它工作得更好,并接受更长的文本。后来他们完全解决了这个问题。

于 2018-08-27T06:18:52.697 回答