未使用処理削除

This commit is contained in:
kimura 2022-02-14 17:51:06 +09:00
parent ff392e8a45
commit f1d0e27e5e
1 changed files with 1 additions and 13 deletions

View File

@ -169,7 +169,6 @@ public class CornField : MonoBehaviour
SetCornField(true); SetCornField(true);
var push = new Subject<Unit>().AddTo(this);
// 既存の株は成長済みにする // 既存の株は成長済みにする
foreach (var plantLine in plantLines) foreach (var plantLine in plantLines)
{ {
@ -182,23 +181,12 @@ public class CornField : MonoBehaviour
var progressData = gameData.SeedlingDataList.First(data => data.type == plantLineData.Type).Seedlings[i]; var progressData = gameData.SeedlingDataList.First(data => data.type == plantLineData.Type).Seedlings[i];
progressData.FirstTime = progressData.FirstTime.AddSeconds(-maxPeriod); progressData.FirstTime = progressData.FirstTime.AddSeconds(-maxPeriod);
plantLine.Seedlings[i].PromoteGrowth(progressData.FirstTime); plantLine.Seedlings[i].PromoteGrowth(progressData.FirstTime);
// エフェクト出すだけ
// push.Subscribe(unit =>
// {
// if (Random.value < .5f)
// {
// seedling.PromoteGrowth(progressData.FirstTime);
// }
// }).AddTo(this);
} }
} }
Observable.Timer(TimeSpan.FromSeconds(1f), TimeSpan.FromSeconds(1f)) Observable.Timer(TimeSpan.FromSeconds(1f), TimeSpan.FromSeconds(1f))
.Select(x => (int)(fertilizerDuration - x)) .Select(x => (int)(fertilizerDuration - x))
.TakeWhile(x => x > 0) .TakeWhile(x => x > 0)
.Subscribe(x => .Subscribe(x => { }, () =>
{
push.OnNext(Unit.Default);
}, () =>
{ {
SoundManager.Instance.PlayBGM("bgm_Main"); SoundManager.Instance.PlayBGM("bgm_Main");
brotherFertilizerAnimation.EndAnimation(); brotherFertilizerAnimation.EndAnimation();