coinmanager修正
This commit is contained in:
parent
652caebb32
commit
20079e7fab
|
|
@ -40,7 +40,7 @@ public class CoinManager : SingletonMonoBehaviour<CoinManager>
|
|||
coinCountText.CountUpAnimation(coinTextFormat, ownCoin, duration);
|
||||
}
|
||||
|
||||
public void AddCoinWithEffect(int count, Action callback)
|
||||
public void AddCoinWithEffect(int count, Action callback = null)
|
||||
{
|
||||
ownCoin += count;
|
||||
// 生成枚数決定
|
||||
|
|
@ -48,7 +48,7 @@ public class CoinManager : SingletonMonoBehaviour<CoinManager>
|
|||
InstantiateEffeect(coinPrefab, count, Vector3.zero, coinIconTransform.position, () =>
|
||||
{
|
||||
coinCountText.CountUpAnimation(coinTextFormat, ownCoin, duration);
|
||||
callback.Invoke();
|
||||
callback?.Invoke();
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue