0

This is from a macOS 10.12.6 app (Xcode 9.3; Swift 4), and it appears when the app starts running: I get seven of these in the console.

This is the storyboard scene:

Storyboard

In my viewController, I have an outlet for the scrollView; I create an SKView, and add it to the scrollView. (This is the complete code).

let skView: SKView = SKView(frame: NSRect(x: 0, y: 0, width: 2000, height: 1400))

@IBOutlet weak var scrollView: NSScrollView!

override func viewDidLoad() {
    super.viewDidLoad()

    if let scene = SKScene(fileNamed: "GameScene") {
        scene.scaleMode = .resizeFill
        scrollView.contentView.addSubview(skView)
        skView.presentScene(scene)
    }
}

(The purpose of this is to have a SpriteKit view I can scroll; this only seems to work with an imageView embedded in the scrollview.)

This error seems to have no effect on the app or how content is displayed; but I'm curious to know what is is and if I can get rid of it.

green_knight
  • 1,319
  • 14
  • 26
  • Did you do a full clean? It is claiming your drawing surface is not supported – Knight0fDragon May 21 '18 at 13:42
  • I have, and the error persists. I've reconstructed the code in a new project, and it builds without errors, so this remains a mystery. But thanks, that helps me out. (For now, I'm treating this as a weird one-off and shall ignore it unless it happens again.) – green_knight May 22 '18 at 08:24
  • The latest version of XCode seems buggier than ever. I find myself constantly having to do disk repair to get my application to work correctly – Knight0fDragon May 22 '18 at 15:08
  • Its not a bug, the imageView and its image residing inside the Sprite do not conform to the expected format. – Ol Sen Jun 19 '21 at 05:30
  • Thank you. I've not pursued that route; but it's good to know. – green_knight Jun 20 '21 at 09:44

0 Answers0