ios - EXC_BAD_INSTRUCTION bug -


I have found this problem several times in xcode 6. This thing is that I am running a ball and when he is a block he dies. He can jump though, but the first block always crashes as if I do not normally like in the air and hit the first block, it just freeze and closes.

This gives me this error:

Thread 1: EXC_BAD_INSTRUCTION (code = EXC_1386_INVOP, subcode = 0x0)

line number 2 and 7 have a green background (count of space).

This error line is:

  func didBeginContact (contact: spspscactact) {died (func)} func died (if visual = GameScene.unarchiveFromFile ("GameScene ") In form of? SKYView skView.ignoresSiblingOrder = true scene.size = skView.bounds.size scene.scaleMode = .spectFill skView.presentScene (scene)}}  as gameScene {skView = self.view}    

EXC_BAD_INSTRUCTION means that there was a loud elsewhere in your code. The only line of code that you can provide is that it is:

  Let's skView = svView as self.view   

This self-reliant If self will The view can not be inserted on the SKView. It seems like self.view is not actually a SKView.

To make sure, you can do an optional cast as you did with the scene:

  as GameScene.unarchiveFromFile ("GameScene")? GameScene {If give a squaw then = self.view? SKView {skView.ignoresSiblingOrder = true scene.size = skView.bounds.size scene.scaleMode = .proview.presentScene (view)}}    

Comments

Popular posts from this blog

ios - Adding an SKSpriteNode to SKScene from a child SKSpriteNode -

Matlab transpose a table vector -

c# - Textbox not clickable but editable -