Questions tagged [sklabelnode]

Node that draws strings on iOS systems.

Node that draws strings on iOS systems.

https://developer.apple.com/library/IOs/documentation/SpriteKit/Reference/SKLabelNode_Ref/index.html

196 questions
1
vote
1 answer

SKLabelNode never shows up in TestFlight

In my Sprite Kit Game i use several SKLabelNodes ..on most of them I run SKActions. On all kinds of iOS Simulators as well as on a device (iPhone 6) everything works fine. But! ..on all Testflight devices (including some iPhone 6) one Labels never…
user3138007
  • 637
  • 1
  • 6
  • 19
1
vote
1 answer

SKLabelNode with Children not affected by gravity - not respecting zPosition

I have a wrapper class to create a label node with some subnodes. This is the init for the class: let label = SKLabelNode(text: word) let background = SKShapeNode(rectOfSize: size, cornerRadius: 0.5) let mainNode = SKSpriteNode(color: color, size:…
vale
  • 1,376
  • 11
  • 25
1
vote
0 answers

Sprite Kit: Label nodes with low quality

I'm developing my first iOS game using Swift and Sprite Kit. Everything is working so far, but when testing in different devices with the simulator I discovered that the SKLabelNodes I'm using to show the score in the hud doesn't look good. When…
dpuertas
  • 23
  • 4
1
vote
4 answers

SKLabelNode Creating Black Rectangle

I saw this question, but it did not have a definite solution to the issue, nor is it the exact same. I am trying to simply add a SKLabelNode with some text. I have never had issues but for some reason this is happening: Here is the code I am using…
Kendel
  • 1,698
  • 2
  • 17
  • 33
1
vote
3 answers

How do I make the text of one label node take up 2 lines?

I have this text below that is too long to fit on the screen when it runs. How can I make this 2 lines rather than one? myLabel.text = "The weather today is going to be partly cloudy with a chance of rain"
NickyNick321
  • 213
  • 1
  • 4
  • 12
1
vote
2 answers

SKLabelNode.name target for setText

Question How to target an SKLabelNode by name? to change it's text? Example; SKNode *node = [self childNodeWithName:string]; [node setText:value]; How does one achieve this? I cannot do it by targeting it's instance variable as I have multiple…
Daniel
  • 285
  • 3
  • 12
1
vote
1 answer

SKScene Pausing briefly When SKLabelNode's text is changed

I am programming a small game using SpriteKit I added a SKLabelNode to my SKScene with the initial text of just "0". When I try and update the text of this SKLabel using: func updateScoreLabel() { scoreNumber++ scoreLabel.text =…
Sunny
  • 23
  • 3
1
vote
1 answer

Creating a button using SKLabelNode as a parent in Swift SpriteKit

I'm trying to create a subclass of SKLabelNode for a button in SpriteKit. I tried to create a button using SKLabelNode as a parent, so I can use everything I know about labels while creating my buttons (font, text size, text color, position,…
pizzafoot
  • 125
  • 1
  • 1
  • 8
1
vote
1 answer

How to cache or preload SKLabelNode font in spritekit

I want to load the font once and use it for the other sklabel nodes let originalLabel: SKLabelNode = SKLabelNode(fontNamed: "fontName"); and later var labelNode = originalLabel; var labelNodeSecond = originalLabel; but that gives the following…
grape1
  • 759
  • 2
  • 8
  • 19
1
vote
1 answer

SKLabelNode with Helvetica producing lag

It took me almost 3 days to figured out that my problem was that I set the label font to Helvetica .And every time I will want to change it's text will lag.So my question is whats the problem with Helvetica and SKLabel node.When I set it out I…
Stefan Scoarta
  • 781
  • 9
  • 21
1
vote
1 answer

UITextField action - change SKLabelNode

I am using Objective-C to make an iOS SpriteKit "GameScene" file. I have an SKLabelNode and a UITextField to input a player's name. How can I make whatever the UITextField value equals to change the SKLabelNode to say "Thanks," + UITextField value? …
Cody Taylor
  • 31
  • 1
  • 8
1
vote
1 answer

How to make different objects compatible with IPhone and IPad using Spritekit

So I've been trying to make all my objects the correct size for both IPad and IPhone by using proportions based on the size of the screen. But I've been having trouble doing it with objects such as the SKLabelNode, due to it using fontSize instead…
Varun Wadhwa
  • 35
  • 1
  • 8
1
vote
2 answers

SKLabelNode will disappear but is still clickable

I am making a game using SpriteKit and Swift, running Xcode 6. I have an SKLabelNode, let's call it myLabelNode for this example. When I call myLabelNode.removeFromParent() it removes the node from the scene, as it should. The node count drops by 1,…
Logan
  • 828
  • 7
  • 10
1
vote
2 answers

SKLabelNode sequence animation with unwanted delay inbetween

I have SKLabelNode representing current score, which I'm trying to animate with growing and shrinking sequence, whenever score value hits some particular number(e.g. 10, 20, ...). Problem is that animation itself has some sort of delay inbetween and…
Adam Bardon
  • 3,829
  • 7
  • 38
  • 73
1
vote
0 answers

Adding SKLabelNode producing a lot of draw calls

How to reduce the number of draw calls when using a SKLabelNode? This code will add 20 labels to the scene: for(int i =0; i < 20; i++){ SKLabelNode *label = [[SKLabelNode alloc] initWithFontNamed:@"Futura-Medium"]; label.position =…
Whirlwind
  • 14,286
  • 11
  • 68
  • 157