39 lines
972 B
C#
39 lines
972 B
C#
using UnityEngine;
|
|
using UnityEngine.UI;
|
|
|
|
namespace Minigames.Airplane.UI
|
|
{
|
|
/// <summary>
|
|
/// Component for individual airplane selection buttons.
|
|
/// Handles visual highlight feedback via show/hide of a highlight image.
|
|
/// </summary>
|
|
public class AirplaneSelectionButton : MonoBehaviour
|
|
{
|
|
[Header("Highlight Visual")]
|
|
[SerializeField] private Image highlightImage;
|
|
|
|
/// <summary>
|
|
/// Show the highlight visual.
|
|
/// </summary>
|
|
public void HighlightStart()
|
|
{
|
|
if (highlightImage != null)
|
|
{
|
|
highlightImage.gameObject.SetActive(true);
|
|
}
|
|
}
|
|
|
|
/// <summary>
|
|
/// Hide the highlight visual.
|
|
/// </summary>
|
|
public void HighlightEnd()
|
|
{
|
|
if (highlightImage != null)
|
|
{
|
|
highlightImage.gameObject.SetActive(false);
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|