modify scripts
This commit is contained in:
@ -18,6 +18,7 @@ using WordsToolkit.Scripts.GUI;
|
||||
using WordsToolkit.Scripts.System;
|
||||
using VContainer;
|
||||
using WordsToolkit.Scripts.GUI.Buttons;
|
||||
using WordsToolkit.Scripts.Services;
|
||||
|
||||
namespace WordsToolkit.Scripts.Popups
|
||||
{
|
||||
@ -26,6 +27,9 @@ namespace WordsToolkit.Scripts.Popups
|
||||
[SerializeField]
|
||||
private CustomButton privacypolicy;
|
||||
|
||||
[SerializeField]
|
||||
private CustomButton googleUMPConsent;
|
||||
|
||||
[SerializeField]
|
||||
private Button restorePurchase;
|
||||
|
||||
@ -38,6 +42,7 @@ namespace WordsToolkit.Scripts.Popups
|
||||
protected virtual void OnEnable()
|
||||
{
|
||||
privacypolicy?.onClick.AddListener(PrivacyPolicy);
|
||||
googleUMPConsent?.onClick.AddListener(ReconsiderGoogleUMPConsent);
|
||||
LoadVibrationLevel();
|
||||
vibrationSlider.onValueChanged.AddListener(SaveVibrationLevel);
|
||||
closeButton.onClick.RemoveAllListeners();
|
||||
@ -94,6 +99,14 @@ namespace WordsToolkit.Scripts.Popups
|
||||
Close();
|
||||
}
|
||||
|
||||
private void ReconsiderGoogleUMPConsent()
|
||||
{
|
||||
StopInteration();
|
||||
DisablePause();
|
||||
adsManager.ReconsiderUMPConsent();
|
||||
Close();
|
||||
}
|
||||
|
||||
private void DisablePause()
|
||||
{
|
||||
if (stateManager.CurrentState == EScreenStates.Game)
|
||||
|
||||
Reference in New Issue
Block a user