Goonstation Forums

Full Version: SMES units don't check for exact power when charging
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
SMES units wait 5 ticks before charging. The check to increment the "start charging" counter or not is:

"input < incoming power"

This means that it won't charge if it's receiving exactly the amount of power the input is set to. It needs to be:

"input ≤ incoming power"

Once the SMES unit starts charging, it uses the latter to determine if it should continue charging or stop.

Effectively, this means that to get an APC to charge off of a fixed value, like a furnace, you need to set the SMES input to 4900 (or 100 less than whatever the total is) until it starts charging, at which point you can tick it back up to the full value.

It would be nice if the wait-to-charge thing was indicated somewhere as well, because there's no indication if the settings are right until it actually begins charging.
do you know where this code is located? it would be nice if, since you know where the check is located, you could provide the erroneous line
I didn't actually know where it was; I merely used psychic debugging and observation.

The section (and line) in question is here: obj/machinery/power/