Reset options menu data when exiting download menu

This commit is contained in:
2025-08-31 09:08:20 -07:00
parent 862026e760
commit ad1e14b54c
2 changed files with 10 additions and 6 deletions

View File

@@ -31,14 +31,14 @@ public class IconMarketplaceDownloadIcon : MonoBehaviour
public TMP_InputField optionsPanelSearchForInputField;
public AudioSource iconPurchaseSound;
private bool priceRangeEnabled = false;
private string priceRangeMin = "10";
private string priceRangeMax = "250";
internal bool priceRangeEnabled = false;
internal string priceRangeMin = "10";
internal string priceRangeMax = "250";
private bool searchForEnabled = false;
private string searchForValue = "";
internal bool searchForEnabled = false;
internal string searchForValue = "";
private bool anyChanges = false;
internal bool anyChanges = false;
void Awake()
{

View File

@@ -34,6 +34,10 @@ public class IconMarketplaceManager : MonoBehaviour
internal void SwitchPanel(int panelIndex)
{
downloadPanelScript.iconPurchaseSound.Stop();
downloadPanelScript.anyChanges = true;
downloadPanelScript.optionsPanelSortByDropdown.value = 3;
downloadPanelScript.optionsPanelPriceRangeToggle.isOn = false;
downloadPanelScript.optionsPanelSearchForToggle.isOn = false;
switch (panelIndex)
{
case 0: