Fix docking control size (#9833)

This commit is contained in:
metalgearsloth
2022-07-17 21:11:54 +10:00
committed by GitHub
parent 69b76ba233
commit 63b48e05af
2 changed files with 3 additions and 4 deletions

View File

@@ -16,7 +16,6 @@ public class DockingControl : Control
private readonly IEntityManager _entManager;
private readonly IMapManager _mapManager;
private const int MinimapRadius = 384;
private const int MinimapMargin = 4;
private float _range = 8f;
@@ -24,8 +23,8 @@ public class DockingControl : Control
private const float GridLinesDistance = 32f;
private int MidPoint => SizeFull / 2;
private int SizeFull => (int) ((MinimapRadius + MinimapMargin) * 2 * UIScale);
private int ScaledMinimapRadius => (int) (MinimapRadius * UIScale);
private int SizeFull => (int) ((RadarControl.MinimapRadius + MinimapMargin) * 2 * UIScale);
private int ScaledMinimapRadius => (int) (RadarControl.MinimapRadius * UIScale);
private float MinimapScale => _range != 0 ? ScaledMinimapRadius / _range : 0f;
public EntityUid? ViewedDock;

View File

@@ -22,7 +22,7 @@ public sealed class RadarControl : Control
private const float ScrollSensitivity = 8f;
private const int MinimapRadius = 320;
public const int MinimapRadius = 320;
private const int MinimapMargin = 4;
private const float GridLinesDistance = 32f;