Add flip button to mapping state (#30636)

This commit is contained in:
metalgearsloth
2024-09-19 10:02:27 +10:00
committed by GitHub
parent 1c839da604
commit 4f77709eed
2 changed files with 17 additions and 0 deletions

View File

@@ -96,6 +96,22 @@ public sealed partial class MappingScreen : InGameScreen
Pick.Texture.TexturePath = "/Textures/Interface/eyedropper.svg.png";
Delete.Texture.TexturePath = "/Textures/Interface/eraser.svg.png";
Flip.Texture.TexturePath = "/Textures/Interface/VerbIcons/rotate_cw.svg.192dpi.png";
Flip.OnPressed += args => FlipSides();
}
public void FlipSides()
{
ScreenContainer.Flip();
if (SpawnContainer.GetPositionInParent() == 0)
{
Flip.Texture.TexturePath = "/Textures/Interface/VerbIcons/rotate_cw.svg.192dpi.png";
}
else
{
Flip.Texture.TexturePath = "/Textures/Interface/VerbIcons/rotate_ccw.svg.192dpi.png";
}
}
private void OnDecalColorPicked(Color color)