ios - GameOver screen position swift -


i have implemented game on screen pop when player loses, height in middle of screen images stretches edge of screen don't want do. want image offset screen slightly. have attached code game on screen below. height set need setting width.

    gameoverscreen = skspritenode(texture: gameoverscreentexture)      gameoverscreen.position = cgpoint(x: self.frame.midx, y: self.frame.midy)      gameoverscreen.size.height = self.frame.height / 3      gameoverscreen.zposition = 0      self.addchild(gameoverscreen) 

managed sort out. changed line:

  gameoverscreen = skspritenode(texture: gameoverscreentexture) 

to this:

gameoverscreen = skspritenode(texture: gameoverscreentexture, size: cgsize(width: 600, height: 600)) 

Comments

Popular posts from this blog

account - Script error login visual studio DefaultLogin_PCore.js -

xcode - CocoaPod Storyboard error: -