23 lines
599 B
C#
23 lines
599 B
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using UnityEngine;
|
|
using UnityEngine.Events;
|
|
|
|
public class RouletteManager : MonoBehaviour
|
|
{
|
|
private static float moneyAvailable = 1000;
|
|
public static float MoneyAvailable {get{ return moneyAvailable;} set{OnMoneyAvailablChanged.Invoke(value); moneyAvailable = value;}}
|
|
public static UnityEvent<float> OnMoneyAvailablChanged = new UnityEvent<float>();
|
|
|
|
|
|
void Start()
|
|
{
|
|
Spinner.OnSpinStopped.AddListener(OnSpinStopped);
|
|
}
|
|
|
|
void OnSpinStopped(int landedValue){
|
|
MoneyAvailable -= 100;
|
|
}
|
|
|
|
}
|