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

Adds a small vignette that pops up when your laws are changed as AI. #9939

Merged
merged 3 commits into from
Oct 3, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions code/_onclick/hud/fullscreen.dm
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,11 @@
layer = BLIND_LAYER
plane = FULLSCREEN_PLANE

/atom/movable/screen/fullscreen/law_change
icon_state = "law_change"
layer = BLIND_LAYER
plane = FULLSCREEN_PLANE

/atom/movable/screen/fullscreen/curse
icon_state = "curse"
layer = CURSE_LAYER
Expand Down
3 changes: 3 additions & 0 deletions code/modules/mob/living/silicon/laws.dm
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,12 @@
throw_alert("newlaw", /atom/movable/screen/alert/newlaw)
if(announce && last_lawchange_announce != world.time)
to_chat(src, "<b>Your laws have been changed.</b>")
overlay_fullscreen("law_change", /atom/movable/screen/fullscreen/law_change, 1)
// lawset modules cause this function to be executed multiple times in a tick, so we wait for the next tick in order to be able to see the entire lawset
addtimer(CALLBACK(src, PROC_REF(show_laws)), 0)
addtimer(CALLBACK(src, PROC_REF(deadchat_lawchange)), 0)
// Wait a tick and clear the vignette
addtimer(CALLBACK(src, PROC_REF(clear_fullscreen), "law_change"), 0.2 SECONDS)
last_lawchange_announce = world.time

/mob/living/silicon/proc/set_law_sixsixsix(law, announce = TRUE)
Expand Down
Binary file modified icons/mob/screen_full.dmi
Binary file not shown.
Loading