mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-13 08:03:43 +01:00
Merge pull request #6027 from KasparoVy/le-film-noir-est-fini
Returns Colour Vision when you Unequip Noir Glasses
This commit is contained in:
@@ -154,7 +154,7 @@
|
||||
var/invis_override = 0
|
||||
|
||||
var/emagged = 0
|
||||
var/color_view = null//overrides client.color while worn
|
||||
var/list/color_view = null//overrides client.color while worn
|
||||
var/prescription = 0
|
||||
var/prescription_upgradable = 0
|
||||
strip_delay = 20 // but seperated to allow items to protect but not impair vision, like space helmets
|
||||
|
||||
@@ -243,26 +243,35 @@
|
||||
return 1
|
||||
|
||||
/obj/item/clothing/glasses/sunglasses/noir/proc/toggle_noir()
|
||||
var/list/difference = difflist(usr.client.color, color_view)
|
||||
|
||||
if(!noir_mode)
|
||||
if(color_view && usr.client && !usr.client.color)
|
||||
if(color_view && usr.client && (!usr.client.color || difference))
|
||||
animate(usr.client, color = color_view, time = 10)
|
||||
noir_mode = 1
|
||||
else
|
||||
if(usr.client && usr.client.color)
|
||||
animate(usr.client, color = null, time = 10)
|
||||
if(usr.client && usr.client.color && !difference)
|
||||
animate(usr.client, color = initial(usr.client.color), time = 10)
|
||||
noir_mode = 0
|
||||
|
||||
/obj/item/clothing/glasses/sunglasses/noir/equipped(mob/user, slot)
|
||||
var/list/difference = difflist(user.client.color, color_view)
|
||||
|
||||
if(slot == slot_glasses)
|
||||
if(noir_mode)
|
||||
if(color_view && user.client && !user.client.color)
|
||||
if(color_view && user.client && (!user.client.color || difference))
|
||||
animate(user.client, color = color_view, time = 10)
|
||||
else
|
||||
if(user.client && user.client.color && !difference)
|
||||
animate(user.client, color = initial(user.client.color), time = 10)
|
||||
..(user, slot)
|
||||
|
||||
/obj/item/clothing/glasses/sunglasses/noir/dropped(mob/living/carbon/human/user)
|
||||
var/list/difference = difflist(user.client.color, color_view)
|
||||
|
||||
if(istype(user) && user.glasses == src)
|
||||
if(user.client && user.client.color)
|
||||
animate(user.client, color = null, time = 10)
|
||||
if(user.client && user.client.color && !difference)
|
||||
animate(user.client, color = initial(user.client.color), time = 10)
|
||||
..(user)
|
||||
|
||||
/obj/item/clothing/glasses/sunglasses/yeah
|
||||
|
||||
Reference in New Issue
Block a user