Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MIRROR] Addresses Icon Smoothing Runtimes #1031

Merged
merged 1 commit into from
Dec 9, 2023
Merged

Conversation

Steals-The-PRs
Copy link
Collaborator

Mirrored on Skyrat: Skyrat-SS13/Skyrat-tg#25494
Original PR: tgstation/tgstation#80171

About The Pull Request

Noticed this in the runtime logs on Terry:

[2023-12-07 02:30:12.334] RUNTIME: runtime error: /obj/structure/table/glass called smooth_icon() without being on a z-level
 - proc name: smooth icon (/atom/proc/smooth_icon)
 -   source file: code/__HELPERS/icon_smoothing.dm,172
 -   usr: null
 -   src: the glass table (/obj/structure/table/glass)
 -   src.loc: null
 -   call stack:
 - the glass table (/obj/structure/table/glass): smooth icon()
 - the glass table (/obj/structure/table/glass): smooth icon()
 - Icon Smoothing (/datum/controller/subsystem/icon_smooth): fire(0)
 - Icon Smoothing (/datum/controller/subsystem/icon_smooth): ignite(0)
 - Master (/datum/controller/master): RunQueue()
 - Master (/datum/controller/master): Loop(2)
 - Master (/datum/controller/master): StartProcessing(0)

Glass tables, on their qdeletion (which occurs when someone breaks one by standing on it), call QUEUE_SMOOTH_NEIGHBORS(), which invokes the smooth on potentially all other glass tables it's merged to. However, since this is a queueing process that we halt if the MC is choked out or we're overtiming elsewhere, it's possible that the queued object qdel()s (like if someone is spamming throwing people on 2x1 glass tables) between fires of SSicon_smooth.

Instead of doing a crash on a null z-level, let's check if we're qdeleted first. It is not unreasonable to just simply early-return because it is always possible that things just get qdeleted while SSicon_smooth sleeps/postpones work when the server is crunching and munching cpu time.

Changelog

No affect to players.

* Addresses Icon Smoothing Runtimes (#80171)

## About The Pull Request

Noticed this in the runtime logs on Terry:

```txt
[2023-12-07 02:30:12.334] RUNTIME: runtime error: /obj/structure/table/glass called smooth_icon() without being on a z-level
 - proc name: smooth icon (/atom/proc/smooth_icon)
 -   source file: code/__HELPERS/icon_smoothing.dm,172
 -   usr: null
 -   src: the glass table (/obj/structure/table/glass)
 -   src.loc: null
 -   call stack:
 - the glass table (/obj/structure/table/glass): smooth icon()
 - the glass table (/obj/structure/table/glass): smooth icon()
 - Icon Smoothing (/datum/controller/subsystem/icon_smooth): fire(0)
 - Icon Smoothing (/datum/controller/subsystem/icon_smooth): ignite(0)
 - Master (/datum/controller/master): RunQueue()
 - Master (/datum/controller/master): Loop(2)
 - Master (/datum/controller/master): StartProcessing(0)
```

Glass tables, on their qdeletion (which occurs when someone breaks one
by standing on it), call `QUEUE_SMOOTH_NEIGHBORS()`, which invokes the
smooth on potentially all other glass tables it's merged to. However,
since this is a queueing process that we halt if the MC is choked out or
we're overtiming elsewhere, it's possible that the queued object
`qdel()`s (like if someone is spamming throwing people on 2x1 glass
tables) between fires of `SSicon_smooth`.

Instead of doing a crash on a null z-level, let's check if we're
qdeleted first. It is not unreasonable to just simply early-return
because it is always possible that things just get qdeleted while
`SSicon_smooth` sleeps/postpones work when the server is crunching and
munching cpu time.
## Changelog
No affect to players.

* Addresses Icon Smoothing Runtimes

---------

Co-authored-by: san7890 <[email protected]>
@Iajret Iajret merged commit 958defa into master Dec 9, 2023
23 checks passed
@Iajret Iajret deleted the upstream-mirror-25494 branch December 9, 2023 13:22
Iajret pushed a commit that referenced this pull request Feb 18, 2024
* Gibbing a Security Officer produces Pig Meat (#81300)

## About The Pull Request

Ports the applicable half of
Bubberstation/Bubberstation#526 here and makes
it apply to every member of security, sans Detective.


## Why It's Good For The Game

Lore accuracy is a very good thing.


## Changelog
:cl: Cursor
add: Security Officers are now Haram.
/:cl:

* Gibbing a Security Officer produces Pig Meat

---------

Co-authored-by: Cursor <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants