Fix #7574 - Lights stay off if taken from the fixture and placed back (#7595)

* Fix 7574

* Added .Load to broken and burned states

* 2am head

* I swear after this I'm reading every single power code line there eis
This commit is contained in:
Júlio César Ueti 2022-04-18 19:47:04 -03:00 committed by GitHub
parent b99b14b143
commit bea86f3ddc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -244,7 +244,6 @@ namespace Content.Server.Light.EntitySystems
}
else
{
powerReceiver.Load = (light.On && lightBulb.State == LightBulbState.Normal) ? lightBulb.PowerUse : 0;
switch (lightBulb.State)
{
@ -275,6 +274,8 @@ namespace Content.Server.Light.EntitySystems
appearance?.SetData(PoweredLightVisuals.BulbState, PoweredLightState.Burned);
break;
}
powerReceiver.Load = (light.On && lightBulb.State == LightBulbState.Normal) ? lightBulb.PowerUse : 0;
}
}