Hello, I started a project using SpriteKit in Playground.
However, there's an error "Unable to get image data for SKSpriteNode"
code:
func createPlayer(){
player.texture = SKTexture(imageNamed: "nurse.png")
player.size = blockSize!
player.position = CGPoint(x: self.size.width * 0.5, y: self.size.height * 0.5)
player.zPosition = 300
self.addChild(player)
}
My image name is nurse.png, it is correct
Is there something wrong?