Skyrat-SS13 / Skyrat-tg

A Skyrat downstream of /tg/station SS13.
GNU Affero General Public License v3.0
121 stars 686 forks source link

Automated Robot Factory not on spawn cooldown properly #25524

Closed burgerenergy closed 8 months ago

burgerenergy commented 9 months ago

Reporting client version: 514.1589

Issue Summary

During a Malf dealio a Skyrat original cyborg factory was put down. Despite the factory's description listing a cool down on when a cyborg could respawn in minutes, cyborg players were still able to constantly spawn out of it moments after they died. This lead to a bemusing, if not fitting for SR situation of the station's brave heroes crawling through dead synths while they kept respawning as they tried to get to the factory.

That's no good.

The factory timer is I think five minutes and proooobably should be increased, too, but I'll leave that up to the wahlance team.

image

Round ID:

10103

Testmerges:

Reproduction:

idk try to respawn with a factory i guess

Floofies commented 9 months ago

Thanks for reporting this! I saw it happen too.

I checked the code in modular_skyrat\modules\SiliconQoL\code\robotic_factory.dm and it looks like an old bug which no one noticed for many years. It adds to its cooldown timer until it becomes a very large number. The code is not algorithmically correct.

if(cooldown_timer <= world.time)
    cooldown_timer = world.time + cooldown_duration
Floofies commented 8 months ago

Fixing this now