mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-20 14:45:05 +00:00
* Adds more bitrunning antagonists + fixes (READY) * Update role_preferences.dm * Update poll_ignore.dm * Update poll_ignore.dm * Update cyber_police.dm --------- Co-authored-by: Jeremiah <42397676+jlsnow301@users.noreply.github.com> Co-authored-by: Bloop <13398309+vinylspiders@users.noreply.github.com>
44 lines
1.2 KiB
Plaintext
44 lines
1.2 KiB
Plaintext
/// Creates a digital effect around the target
|
|
/atom/proc/create_digital_aura()
|
|
var/list/overlays = get_digital_overlays()
|
|
if(!length(overlays))
|
|
return
|
|
|
|
add_overlay(overlays)
|
|
alpha = 210
|
|
set_light(2, l_color = LIGHT_COLOR_BUBBLEGUM, l_on = TRUE)
|
|
update_appearance()
|
|
|
|
/// Removes the digital effect around the target
|
|
/atom/proc/remove_digital_aura()
|
|
var/list/overlays = get_digital_overlays()
|
|
if(!length(overlays))
|
|
return
|
|
|
|
cut_overlay(overlays)
|
|
alpha = 255
|
|
set_light(0, l_color = null, l_on = FALSE)
|
|
update_appearance()
|
|
|
|
/// Returns a list of overlays to be used for the digital effect
|
|
/atom/proc/get_digital_overlays()
|
|
var/base_icon
|
|
var/dimensions = get_icon_dimensions(icon)
|
|
if(!length(dimensions))
|
|
return
|
|
|
|
switch(dimensions["width"])
|
|
if(32)
|
|
base_icon = 'icons/effects/bitrunning.dmi'
|
|
if(48)
|
|
base_icon = 'icons/effects/bitrunning_48.dmi'
|
|
if(64)
|
|
base_icon = 'icons/effects/bitrunning_64.dmi'
|
|
|
|
var/mutable_appearance/redshift = mutable_appearance(base_icon, "redshift")
|
|
redshift.blend_mode = BLEND_MULTIPLY
|
|
|
|
var/mutable_appearance/glitch_effect = mutable_appearance(base_icon, "glitch", MUTATIONS_LAYER, alpha = 150)
|
|
|
|
return list(glitch_effect, redshift)
|