Quantcast
Channel: Questions in topic: "xcode"
Viewing all articles
Browse latest Browse all 1047

Is there a work around for my Xcode simulation problem?

$
0
0
I tested my Unity game on target iOS devices using the Xcode simulators. I use Rect Transform, anchoredPosition to position game objects around the periphery of the device screen. The position of game objects using the Rect Transform differs between the hardware and the simulator on at least one device: case UnityEngine.iOS.DeviceGeneration.iPhone6SPlus. The hardware must be right - it's at large so the Unity editor/simulator must be wrong. I suspect other iPhones with the same logical display resolution are also wrong. Comparing the logical resolution of the device screen with the Unity editor values that correspond to the screen limits of the Rect Transform Pos X or Pos Y by dividing the logical resolution values, e.g. X axis 958 / 736 = 1.302, Y axis 540 / 414 = 1.304. The result has a fractional part. It's likely/possible that all devices with fractional scaling between logical resolution and screen limits of the Rect Transform are affected. All such devices are iPhones; all iPads variants are 1:1 and at least one device, my iPad Mini 2 is OK. I tried to create a bug report but no luck: error, error "bad filename". There are a lot of files in my project. This is the first time Unity complained about a filename. Sheesh ,I tested my game on target iOS devices using the Xcode simulators. I use Rect Transform, anchoredPosition to position game objects around the periphery of the device screen. The position of game objects using the Rect Transform differs between the hardware and the simulator on at least one device: case UnityEngine.iOS.DeviceGeneration.iPhone6SPlus. The hardware must be right - it's at large so the Unity editor/simulator must be wrong. I suspect other iPhones with the same logical display resolution are also wrong. Comparing the logical resolution of the device screen with the Unity editor values that correspond to the screen limits of the Rect Transform Pos X or Pos Y by dividing the logical resolution values, e.g. X axis 958 / 736 = 1.302, Y axis 540 / 414 = 1.304. The result has a fractional part. It's likely/possible that all devices with fractional scaling between logical resolution and screen limits of the Rect Transform are affected. All such devices are iPhones; all iPads variants are 1:1 and at least one device, my iPad Mini 2 is OK. My problem is that I can't trust the simulator. If I tailor my app to be right on the simulator it's likely/possible to be wrong on iPhones in the danger group. Having to buy a load of iPhones would suck.

Viewing all articles
Browse latest Browse all 1047

Trending Articles