Е Бои
Е Бои

Reputation: 38

Can not set text to SKLabelNode

I can't set the text to an SKLabelNode. Any ideas why this is happening?

I have tried doing like so:

let label = childNode(named:"ScoreLabel")
label.text = "Score: \(score)"

The text doesn't change. It stays as it was.

Upvotes: 1

Views: 64

Answers (1)

ExeRhythm
ExeRhythm

Reputation: 480

You have provided too little information. Try deleting SKLabelNode and creating it again with the same parameters. Comment if it worked

Upvotes: 1

Related Questions