コード例 #1
0
ファイル: GameEngine.cs プロジェクト: lucidsheep/ssj19
    void StartGathering()
    {
        titleText.SetText("A Natural Selection...\n\n\nLoading World");

        TimeControl.StartTimer(.1f, () =>
        {
            foodGathered = 0;
            timeLeft     = startingTime;
            onTimeTick.Invoke(timeLeft);
            onFoodGathered.Invoke(foodGathered, foodRequirement);
            player.GetComponent <Health>().RestoreHealth(999);
            MapManager.instance.GenerateMap(mapSize, 10);
        });
    }
コード例 #2
0
ファイル: Area.cs プロジェクト: StudentBeast99/Task5
 public void TimeTick()
 {
     if (TimeTickEvent != null)
     {
         TimeTickEvent.Invoke();
     }
 }