Monday, 15 August 2011

objective c - Can I selectively display physicsBody's? -


I have this in GameViewController:

  - (zero) viewDidoadload {[Super Viewedload]  

"post-text" itemprop = "text"; // Configure View Self.skView = (SKView *) self.view; Self.skView.showsFPS = Yes; Self.skView.showsNodeCount = Yes; Self.skView.showsPhysics = Yes; // & lt; & Lt; & Lt; & Lt; & Lt; Question about this // create & amp; Configure the view self.scene = [Size with the GameScan View: self.skView.bounds.size]; Self.scene.scaleMode = SKSceneScaleModeAspectFill; // submit the view [self.skView presentScene: self.scene];

}

When physics = yes shows, is there any code I could write that just wants to show physics body? Some physics body looks very good in combination with some presets during the gameplay.

You can not show physical science bodies by selecting self.skView.showsPhysics < / Code>. Although you can use too much of SKShapeNode, there is the same effect as showing your physics body. Using SKShapeNode will give you more control using some of its properties and stroke properties.


No comments:

Post a Comment