title: Scaling for specific devices
body: <p>I am running into some issues trying to make my SpriteKit game compatible on all devices. I understand how Image.xcassets works, as well as how to reference the phone frame in placing my nodes.</p>
  
  <p>For example, my game looks fine on 6, 6+ and the iPads. Unfortunately, it has the top the cut off for the earlier iPhones. An easy fix for this would just be to reference the top of the screen like so:</p>
  
  <pre><code>node.position = CGPointMake(CGRectGetMidX(self.frame), CGRectGetMaxY(self.frame) - 5)
  </code></pre>
  
  <p><em>This works for all the phones, but not the iPads</em></p>
  
  <p>However if I reference the top of the device like that, then on the iPad the upper nodes are too far up the screen such that the hero is not able to interact with them.</p>
  
  <p>The current way my code is written for positioning of nodes is just by using other nodes to build on top of:</p>
  
  <pre><code>node.position = CGPointMake(CGRectGetMidX(self.frame), CGRectGetMinY(self.frame) + node2.size.height + node3.size.height)
  </code></pre>
  
  <p><em>This works for the 6, 6+ and the iPads</em></p>
  
  <p>How can I make it so there is compatibility on all devices? I Know I could adjust the "2x" image so it could fit for the 5 and 5s, but then it would throw off the game mechanic for 6 (because the 6 and 5 series share the "2x" for some reason).</p>
  
  <p>Is there a way I can specifically test for use on a certain device, and then have certain code run in that case? Are there any solutions? Thanks.</p>