78 lines
1.6 KiB
C#
78 lines
1.6 KiB
C#
using System;
|
|
using TMPro;
|
|
using UnityEngine;
|
|
|
|
// Token: 0x020000C3 RID: 195
|
|
public class Minigame : MonoBehaviour
|
|
{
|
|
// Token: 0x06001252 RID: 4690 RVA: 0x00164508 File Offset: 0x00162708
|
|
public void Retry()
|
|
{
|
|
if (this.puzzle)
|
|
{
|
|
this.puzzle.RetryMinigame();
|
|
this.animator.Play("MiniGameClose");
|
|
}
|
|
}
|
|
|
|
// Token: 0x06001253 RID: 4691 RVA: 0x00164532 File Offset: 0x00162732
|
|
public void End()
|
|
{
|
|
if (this.puzzle)
|
|
{
|
|
this.puzzle.EndMinigame();
|
|
this.animator.Play("MiniGameClose");
|
|
}
|
|
}
|
|
|
|
// Token: 0x06001254 RID: 4692 RVA: 0x0016455C File Offset: 0x0016275C
|
|
public void SetVolume()
|
|
{
|
|
foreach (AudioSource audioSource in this.audioSources)
|
|
{
|
|
if (audioSource)
|
|
{
|
|
audioSource.volume = Links.x.options.soundVolume;
|
|
}
|
|
}
|
|
}
|
|
|
|
// Token: 0x06001255 RID: 4693 RVA: 0x0016459F File Offset: 0x0016279F
|
|
public void AddScore()
|
|
{
|
|
this.score++;
|
|
this.scoreAnimator.Play("MiniGameScoreShake", -1, 0f);
|
|
this.constantScoreText.text = this.score.ToString();
|
|
}
|
|
|
|
// Token: 0x04001E2D RID: 7725
|
|
public Animator animator;
|
|
|
|
// Token: 0x04001E2E RID: 7726
|
|
public Animator scoreAnimator;
|
|
|
|
// Token: 0x04001E2F RID: 7727
|
|
public TextMeshProUGUI scoreText;
|
|
|
|
// Token: 0x04001E30 RID: 7728
|
|
public TextMeshProUGUI highScoreText;
|
|
|
|
// Token: 0x04001E31 RID: 7729
|
|
public TextMeshProUGUI constantScoreText;
|
|
|
|
// Token: 0x04001E32 RID: 7730
|
|
public TextMeshProUGUI targetScoreText;
|
|
|
|
// Token: 0x04001E33 RID: 7731
|
|
public TextMeshProUGUI endButtonText;
|
|
|
|
// Token: 0x04001E34 RID: 7732
|
|
public PuzzleActions puzzle;
|
|
|
|
// Token: 0x04001E35 RID: 7733
|
|
public AudioSource[] audioSources;
|
|
|
|
// Token: 0x04001E36 RID: 7734
|
|
public int score;
|
|
}
|