1
Support / Re: Using TK2DCamera Override Fit Width so no space is lost at the bottom
« on: November 06, 2013, 07:42:43 am »In tk2dCamera.cs, these lines reposition the camera after scaling:Code: [Select]if (currentResolutionOverride.autoScaleMode != tk2dCameraResolutionOverride.AutoScaleMode.StretchToFit)
{
switch (currentResolutionOverride.fitMode)
{
case tk2dCameraResolutionOverride.FitMode.Center:
offset = new Vector2(Mathf.Round((settings.nativeResolutionWidth * scale.x - pixelWidth ) / 2.0f),
Mathf.Round((settings.nativeResolutionHeight * scale.y - pixelHeight) / 2.0f));
break;
default:
case tk2dCameraResolutionOverride.FitMode.Constant:
offset = -currentResolutionOverride.offsetPixels; break;
}
}
You can disable the re-entering vertically if you like, or simply add another fit mode to do this for you.
Cool, thanks for the reply!