mirror of
https://github.com/misternebula/quantum-space-buddies.git
synced 2025-01-29 09:32:38 +00:00
rename
This commit is contained in:
parent
8a1ed54818
commit
7f28ee6553
@ -143,7 +143,7 @@ internal class LightSensorPatches : QSBPatch
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// to prevent allocating a new list every frame
|
/// to prevent allocating a new list every frame
|
||||||
/// </summary>
|
/// </summary>
|
||||||
private static readonly List<DreamLanternController> _prevIlluminatingDreamLanternList = new();
|
private static readonly List<DreamLanternController> _illuminatingDreamLanternList = new();
|
||||||
|
|
||||||
[HarmonyPrefix]
|
[HarmonyPrefix]
|
||||||
[HarmonyPatch(nameof(SingleLightSensor.ManagedFixedUpdate))]
|
[HarmonyPatch(nameof(SingleLightSensor.ManagedFixedUpdate))]
|
||||||
@ -165,8 +165,8 @@ internal class LightSensorPatches : QSBPatch
|
|||||||
|
|
||||||
if (__instance._illuminatingDreamLanternList != null)
|
if (__instance._illuminatingDreamLanternList != null)
|
||||||
{
|
{
|
||||||
_prevIlluminatingDreamLanternList.Clear();
|
_illuminatingDreamLanternList.Clear();
|
||||||
_prevIlluminatingDreamLanternList.AddRange(__instance._illuminatingDreamLanternList);
|
_illuminatingDreamLanternList.AddRange(__instance._illuminatingDreamLanternList);
|
||||||
}
|
}
|
||||||
|
|
||||||
var illuminated = __instance._illuminated;
|
var illuminated = __instance._illuminated;
|
||||||
@ -215,7 +215,7 @@ internal class LightSensorPatches : QSBPatch
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (__instance._illuminatingDreamLanternList != null
|
if (__instance._illuminatingDreamLanternList != null
|
||||||
&& !__instance._illuminatingDreamLanternList.SequenceEqual(_prevIlluminatingDreamLanternList))
|
&& !__instance._illuminatingDreamLanternList.SequenceEqual(_illuminatingDreamLanternList))
|
||||||
{
|
{
|
||||||
if (isPlayerLightSensor)
|
if (isPlayerLightSensor)
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user