I am working on a 2D, Top-Down Racing Game and I am trying to get it to look “pixel perfect”!
I have watched what feels like every single tutorial made on this topic, but I cannot get this to work. My character’s movement always looks choppy/jumpy.
The only way to get it to look smooth is to enable Crop Frame X, Y and Stretch Fill on the Pixel Perfect Camera component. But I do not want my frame cropped. If the device is wider or higher than the reference aspect ratio, I simply want it to show more of my level on those sides. No cropping, no black bars, no super secret magic, simply “show more level”.
Here is my setup:
Main Camera Game Object
Camera Component
- Projection: Orthographic
- Size: Doesn’t matter, because will get overwritten by Pixel Perfect Camera
CinemachineBrain Component
- Update Method: Late Update
- Blend Update Method: Late Update
Pixel Perfect Camera Component
- Assets Pixels Per Unit: 16
- Reference Resolution X: 240: Y 520
- All checkboxes disabled
Follow Player Camera Game Object
CinemachineVirtualCamera Component
- Follow: Player
- Lens > Orthographic Size: Doesn’t matter, because will get overwritten by Pixel Perfect Camera
- Body: Framing Transposer
Cinemachine Pixel Perfect Component
- No settings
Cinemachine Confiner Component
- Confine Mode: Confine 2D
- Bounding Shape 2D: Polygon Collider 2D
- Confine Screen Edges: Enabled
- Damping: 0
Cinemachine Independent Impulse Listener Component
- Defaults
On iPhone 11 Device Simulator, in Play Mode, this gives me an Orthographic Size of 14. That’s exactly what I want. However, my character’s movement looks so choppy/jumpy that its basically unusable.
Also, using Update Method Late Update instead of Fixed Update in the CinemachineBrainComponent means that the Impulse Listener / Screen Shake no longer has any effect. However, changing it to Fixed Update to get the Screen Shake to work changes the Orthographic Size to 18.66667 instead of my desired 14.
Please help!