tnt graphics, bug fixes, folder organization

This commit is contained in:
2026-03-28 20:47:10 -05:00
parent 57b14d4ba9
commit 6491a3df11
45 changed files with 10533 additions and 148 deletions
+31
View File
@@ -0,0 +1,31 @@
using System;
using System.Linq;
using UnityEngine;
public class Streetlight : MonoBehaviour
{
// Hours that the light starts and ends
public int[] activeHours = { 18, 19, 20, 21, 22, 23, 0, 1, 2, 3, 4, 5, 6 };
Light objectLight;
private float lightIntensity;
void Start()
{
objectLight = GetComponent<Light>();
lightIntensity = objectLight.intensity;
}
// Update is called once per frame
void Update()
{
if (activeHours.Contains(GameManager.Instance.TimeManager.GetCurrentHour()))
{
objectLight.intensity = lightIntensity;
}
else
{
objectLight.intensity = 0;
}
}
}