mirror of
https://git.huckle.dev/Huckles-Minecraft-Archive/PCK-Studio.git
synced 2026-05-23 21:14:32 +00:00
SkinRenderer - Add camera position clamping to screen space
This commit is contained in:
@@ -87,7 +87,11 @@ namespace PckStudio.Rendering
|
||||
public Vector2 CameraTarget
|
||||
{
|
||||
get => camera.Position;
|
||||
set => camera.LookAt(value);
|
||||
set
|
||||
{
|
||||
value = Vector2.Clamp(value, new Vector2(camera.Distance / 2f * -1), new Vector2(camera.Distance / 2f));
|
||||
camera.LookAt(value);
|
||||
}
|
||||
}
|
||||
|
||||
private Vector2 _globalModelRotation;
|
||||
|
||||
Reference in New Issue
Block a user