diff --git a/code/__DEFINES/misc.dm b/code/__DEFINES/misc.dm
index 5e9815b7758..09ea7bf366f 100644
--- a/code/__DEFINES/misc.dm
+++ b/code/__DEFINES/misc.dm
@@ -250,16 +250,9 @@
#define MAP_MAXZ 6
//Matricies
-#define MATRIX_DEFAULT list(1, 0, 0, 0,\
- 0, 1, 0, 0,\
- 0, 0, 1, 0,\
- 0, 0, 0, 1)
-
-#define MATRIX_GREYSCALE list(0.33, 0.33, 0.33, 0,\
- 0.33, 0.33, 0.33, 0,\
- 0.33, 0.33, 0.33, 0,\
- 0.00, 0.00, 0.00, 1,\
- 0.00, 0.00, 0.00, 0)
+#define MATRIX_GREYSCALE list(0.33, 0.33, 0.33,\
+ 0.33, 0.33, 0.33,\
+ 0.33, 0.33, 0.33)
//Gun trigger guards
#define TRIGGER_GUARD_ALLOW_ALL -1
#define TRIGGER_GUARD_NONE 0
diff --git a/code/__HELPERS/AnimationLibrary.dm b/code/__HELPERS/AnimationLibrary.dm
index fcabe2e0a78..fd79fe197f2 100644
--- a/code/__HELPERS/AnimationLibrary.dm
+++ b/code/__HELPERS/AnimationLibrary.dm
@@ -7,7 +7,7 @@
/proc/animate_fade_grayscale(var/atom/A, var/time = 5)
if(!istype(A) && !istype(A, /client))
return
- A.color = MATRIX_DEFAULT
+ A.color = null
animate(A, color = MATRIX_GREYSCALE, time = time, easing = SINE_EASING)
/proc/animate_melt_pixel(var/atom/A)
diff --git a/code/modules/client/client procs.dm b/code/modules/client/client procs.dm
index 6e1fe9126fd..3e2e1f54e0c 100644
--- a/code/modules/client/client procs.dm
+++ b/code/modules/client/client procs.dm
@@ -621,3 +621,6 @@
if(lang.flags & RESTRICTED)
message += " (RESTRICTED)"
to_chat(world, "[message]")
+
+/client/proc/colour_transition(var/list/colour_to = null, var/time = 10) //Call this with no parameters to reset to default.
+ animate(src, color=colour_to, time=time, easing=SINE_EASING)
diff --git a/code/modules/client/preference/preferences.dm b/code/modules/client/preference/preferences.dm
index ba51996f4e7..4ec7516a409 100644
--- a/code/modules/client/preference/preferences.dm
+++ b/code/modules/client/preference/preferences.dm
@@ -282,6 +282,8 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
dat += "Species: [species]
"
if(species == "Vox")
dat += "N2 Tank: [speciesprefs ? "Large N2 Tank" : "Specialized N2 Tank"]
"
+ else if(species in list("Vulpkanin", "Tajaran"))
+ dat += "Colour Vision: [speciesprefs ? "Unaugmented" : "Surgically Corrected"]
"
dat += "Secondary Language: [language]
"
dat += "Blood Type: [b_type]
"
if(species in list("Human", "Drask", "Vox"))
@@ -1337,9 +1339,13 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
//Reset prosthetics.
organ_data = list()
rlimb_data = list()
- if("speciesprefs")//oldvox code
- speciesprefs = !speciesprefs
-
+ if("speciesprefs")
+ if(species == "Vox") //oldvox code
+ speciesprefs = !speciesprefs //Starts 0, so if someone clicks the button up top there, this won't be 0 anymore. If they click it again, it'll go back to 0.
+ else if(species in list("Vulpkanin", "Tajaran")) //Species that can be colourblind.
+ var/list/vision_options = list("Surgically Corrected", "Unaugmented") //Surgically corrected eyes (default option) see in full colour but have 2 darksight. Unaugmented eyes are colourblind but have 8 darksight.
+ speciesprefs = input("Please select your vision preference. \nOverridden by mech. assisted or mechanical eyes. \nSurgically Corrected: Full colour, low darksight. \n Unaugmented: Colourblind, full darksight.", "Character Generation", 0) in vision_options
+ speciesprefs = (speciesprefs != "Surgically Corrected") //Ensure the default option (surgically corrected) returns 0. I would've set up the vision_options list such that Surgically Corrected = 0, but input() didn't care for it.
if("language")
// var/languages_available
var/list/new_languages = list("None")
@@ -2020,8 +2026,6 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
return 1
/datum/preferences/proc/copy_to(mob/living/carbon/human/character)
- var/datum/species/S = all_species[species]
- character.change_species(species) // Yell at me if this causes everything to melt
if(be_random_name)
real_name = random_name(gender,species)
@@ -2173,7 +2177,7 @@ var/global/list/special_role_times = list( //minimum age (in days) for accounts
character.dna.SetSEState(MUTEBLOCK,1,1)
character.disabilities |= MUTE
- S.handle_dna(character)
+ character.species.handle_dna(character)
if(character.dna.dirtySE)
character.dna.UpdateSE()
diff --git a/code/modules/clothing/glasses/glasses.dm b/code/modules/clothing/glasses/glasses.dm
index 4fde338ba54..5b38adc6a82 100644
--- a/code/modules/clothing/glasses/glasses.dm
+++ b/code/modules/clothing/glasses/glasses.dm
@@ -232,8 +232,6 @@
name = "noir sunglasses"
desc = "Somehow these seem even more out-of-date than normal sunglasses."
actions_types = list(/datum/action/item_action/noir)
- var/noir_mode = 0
- color_view = MATRIX_GREYSCALE
/obj/item/clothing/glasses/sunglasses/noir/attack_self()
toggle_noir()
@@ -243,36 +241,8 @@
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 || difference))
- animate(usr.client, color = color_view, time = 10)
- noir_mode = 1
- else
- 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 || difference.len))
- animate(user.client, color = color_view, time = 10)
- else
- if(user.client && user.client.color && !difference.len)
- 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 && !difference.len)
- animate(user.client, color = initial(user.client.color), time = 10)
- ..(user)
+ color_view = color_view ? null : MATRIX_GREYSCALE //Toggles between null and grayscale, with null being the default option.
+ usr.update_client_colour()
/obj/item/clothing/glasses/sunglasses/yeah
name = "agreeable glasses"
diff --git a/code/modules/mob/living/carbon/carbon.dm b/code/modules/mob/living/carbon/carbon.dm
index 827f0ded62e..1ec1695352a 100644
--- a/code/modules/mob/living/carbon/carbon.dm
+++ b/code/modules/mob/living/carbon/carbon.dm
@@ -309,7 +309,7 @@
Stun(2)
var/obj/item/organ/internal/eyes/E = get_int_organ(/obj/item/organ/internal/eyes)
- if(!E)
+ if(!E || (E && E.weld_proof))
return
switch(damage)
diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm
index ae88df869d9..c2e2f090bb2 100644
--- a/code/modules/mob/living/carbon/human/human.dm
+++ b/code/modules/mob/living/carbon/human/human.dm
@@ -721,8 +721,6 @@
if(istype(id))
return id
-
-
/mob/living/carbon/human/update_sight()
if(!client)
return
@@ -1533,12 +1531,6 @@
if(species.default_language)
add_language(species.default_language)
- see_in_dark = species.darksight
- if(see_in_dark > 2)
- see_invisible = SEE_INVISIBLE_LEVEL_ONE
- else
- see_invisible = SEE_INVISIBLE_LIVING
-
hunger_drain = species.hunger_drain
digestion_ratio = species.digestion_ratio
@@ -1608,8 +1600,17 @@
dna.real_name = real_name
species.handle_post_spawn(src)
+
+ see_in_dark = species.get_resultant_darksight(src)
+ if(see_in_dark > 2)
+ see_invisible = SEE_INVISIBLE_LEVEL_ONE
+ else
+ see_invisible = SEE_INVISIBLE_LIVING
+
species.handle_dna(src) //Give them whatever special dna business they got.
+ update_client_colour(0)
+
spawn(0)
overlays.Cut()
update_mutantrace(1)
@@ -1632,7 +1633,6 @@
return null
return species.default_language ? all_languages[species.default_language] : null
-
/mob/living/carbon/human/proc/bloody_doodle()
set category = "IC"
set name = "Write in blood"
diff --git a/code/modules/mob/living/carbon/human/inventory.dm b/code/modules/mob/living/carbon/human/inventory.dm
index 4e90d763e9e..c375d718e3d 100644
--- a/code/modules/mob/living/carbon/human/inventory.dm
+++ b/code/modules/mob/living/carbon/human/inventory.dm
@@ -119,6 +119,7 @@
if(G.vision_flags || G.darkness_view || G.invis_override || G.invis_view)
update_sight()
update_inv_glasses()
+ update_client_colour()
else if(I == head)
head = null
if(I.flags & BLOCKHAIR || I.flags & BLOCKHEADHAIR)
@@ -271,6 +272,7 @@
if(G.vision_flags || G.darkness_view || G.invis_override || G.invis_view)
update_sight()
update_inv_glasses(redraw_mob)
+ update_client_colour()
if(slot_gloves)
gloves = W
update_inv_gloves(redraw_mob)
diff --git a/code/modules/mob/living/carbon/human/species/abductor.dm b/code/modules/mob/living/carbon/human/species/abductor.dm
index 3bcade9f00d..4690529524f 100644
--- a/code/modules/mob/living/carbon/human/species/abductor.dm
+++ b/code/modules/mob/living/carbon/human/species/abductor.dm
@@ -7,8 +7,16 @@
language = "Abductor Mindlink"
default_language = "Abductor Mindlink"
unarmed_type = /datum/unarmed_attack/punch
- darksight = 3
eyes = "blank_eyes"
+ has_organ = list(
+ "heart" = /obj/item/organ/internal/heart,
+ "lungs" = /obj/item/organ/internal/lungs,
+ "liver" = /obj/item/organ/internal/liver,
+ "kidneys" = /obj/item/organ/internal/kidneys,
+ "brain" = /obj/item/organ/internal/brain,
+ "appendix" = /obj/item/organ/internal/appendix,
+ "eyes" = /obj/item/organ/internal/eyes/abductor //3 darksight.
+ )
flags = HAS_LIPS | NO_BLOOD | NO_BREATHE
diff --git a/code/modules/mob/living/carbon/human/species/apollo.dm b/code/modules/mob/living/carbon/human/species/apollo.dm
index faeecdfcc5f..476f1aa9049 100644
--- a/code/modules/mob/living/carbon/human/species/apollo.dm
+++ b/code/modules/mob/living/carbon/human/species/apollo.dm
@@ -9,7 +9,6 @@
punchdamagelow = 0
punchdamagehigh = 1
//primitive = /mob/living/carbon/monkey/wryn
- darksight = 3
slowdown = 1
warning_low_pressure = -300
hazard_low_pressure = 1
@@ -32,7 +31,7 @@
has_organ = list(
"heart" = /obj/item/organ/internal/heart,
"brain" = /obj/item/organ/internal/brain,
- "eyes" = /obj/item/organ/internal/eyes,
+ "eyes" = /obj/item/organ/internal/eyes/wryn, //3 darksight.
"appendix" = /obj/item/organ/internal/appendix,
"antennae" = /obj/item/organ/internal/wryn/hivenode
)
@@ -89,7 +88,7 @@
name_plural = "Nucleations"
icobase = 'icons/mob/human_races/r_nucleation.dmi'
unarmed_type = /datum/unarmed_attack/punch
- blurb = "A sub-race of unforunates who have been exposed to too much supermatter radiation. As a result, \
+ blurb = "A sub-race of unfortunates who have been exposed to too much supermatter radiation. As a result, \
supermatter crystal clusters have begun to grow across their bodies. Research to find a cure for this ailment \
has been slow, and so this is a common fate for veteran engineers. The supermatter crystals produce oxygen, \
negating the need for the individual to breathe. Their massive change in biology, however, renders most medicines \
@@ -109,8 +108,8 @@
reagent_tag = PROCESS_ORG
has_organ = list(
"heart" = /obj/item/organ/internal/heart,
- "crystalized brain" = /obj/item/organ/internal/brain/crystal,
- "eyes" = /obj/item/organ/internal/eyes/luminescent_crystal,
+ "crystallized brain" = /obj/item/organ/internal/brain/crystal,
+ "eyes" = /obj/item/organ/internal/eyes/luminescent_crystal, //Standard darksight of 2.
"strange crystal" = /obj/item/organ/internal/nucleation/strange_crystal,
"resonant crystal" = /obj/item/organ/internal/nucleation/resonant_crystal
)
diff --git a/code/modules/mob/living/carbon/human/species/golem.dm b/code/modules/mob/living/carbon/human/species/golem.dm
index 1bb4ba8e214..a2f2eb30467 100644
--- a/code/modules/mob/living/carbon/human/species/golem.dm
+++ b/code/modules/mob/living/carbon/human/species/golem.dm
@@ -40,7 +40,8 @@
has_organ = list(
"brain" = /obj/item/organ/internal/brain/golem
- )
+ ) //Has standard darksight of 2.
+
suicide_messages = list(
"is crumbling into dust!",
"is smashing their body apart!")
diff --git a/code/modules/mob/living/carbon/human/species/monkey.dm b/code/modules/mob/living/carbon/human/species/monkey.dm
index dffc73d4e1d..34f4e16bfdf 100644
--- a/code/modules/mob/living/carbon/human/species/monkey.dm
+++ b/code/modules/mob/living/carbon/human/species/monkey.dm
@@ -26,6 +26,7 @@
tail = "chimptail"
bodyflags = FEET_PADDED | HAS_TAIL
reagent_tag = PROCESS_ORG
+ //Has standard darksight of 2.
//unarmed_types = list(/datum/unarmed_attack/bite, /datum/unarmed_attack/claws)
//inherent_verbs = list(/mob/living/proc/ventcrawl)
@@ -106,6 +107,16 @@
tail = "farwatail"
reagent_tag = PROCESS_ORG
+ has_organ = list(
+ "heart" = /obj/item/organ/internal/heart,
+ "lungs" = /obj/item/organ/internal/lungs,
+ "liver" = /obj/item/organ/internal/liver/tajaran,
+ "kidneys" = /obj/item/organ/internal/kidneys,
+ "brain" = /obj/item/organ/internal/brain,
+ "appendix" = /obj/item/organ/internal/appendix,
+ "eyes" = /obj/item/organ/internal/eyes/tajaran //Tajara monkey-forms are uniquely colourblind and have excellent darksight.
+ )
+
/datum/species/monkey/vulpkanin
name = "Wolpin"
@@ -121,6 +132,16 @@
tail = "wolpintail"
reagent_tag = PROCESS_ORG
+ has_organ = list(
+ "heart" = /obj/item/organ/internal/heart,
+ "lungs" = /obj/item/organ/internal/lungs,
+ "liver" = /obj/item/organ/internal/liver/vulpkanin,
+ "kidneys" = /obj/item/organ/internal/kidneys,
+ "brain" = /obj/item/organ/internal/brain,
+ "appendix" = /obj/item/organ/internal/appendix,
+ "eyes" = /obj/item/organ/internal/eyes/vulpkanin //Vulpkanin monkey-forms are uniquely colourblind and have excellent darksight.
+ )
+
/datum/species/monkey/skrell
name = "Neara"
diff --git a/code/modules/mob/living/carbon/human/species/plasmaman.dm b/code/modules/mob/living/carbon/human/species/plasmaman.dm
index 1a79374407c..d0d9d10fd94 100644
--- a/code/modules/mob/living/carbon/human/species/plasmaman.dm
+++ b/code/modules/mob/living/carbon/human/species/plasmaman.dm
@@ -20,6 +20,8 @@
heat_level_2 = 400 // Heat damage level 2 above this point.
heat_level_3 = 500 // Heat damage level 3 above this point.
+ //Has default darksight of 2.
+
suicide_messages = list(
"is twisting their own neck!",
"is letting some O2 in!",
diff --git a/code/modules/mob/living/carbon/human/species/shadow.dm b/code/modules/mob/living/carbon/human/species/shadow.dm
index ca26348d188..35f008af802 100644
--- a/code/modules/mob/living/carbon/human/species/shadow.dm
+++ b/code/modules/mob/living/carbon/human/species/shadow.dm
@@ -7,12 +7,12 @@
default_language = "Galactic Common"
unarmed_type = /datum/unarmed_attack/claws
- darksight = 8
blood_color = "#CCCCCC"
flesh_color = "#AAAAAA"
has_organ = list(
- "brain" = /obj/item/organ/internal/brain
+ "brain" = /obj/item/organ/internal/brain,
+ "eyes" = /obj/item/organ/internal/eyes/shadow //8 darksight.
)
flags = NO_BLOOD | NO_BREATHE | RADIMMUNE
diff --git a/code/modules/mob/living/carbon/human/species/skeleton.dm b/code/modules/mob/living/carbon/human/species/skeleton.dm
index 4a3b087e93d..d09c8dd1699 100644
--- a/code/modules/mob/living/carbon/human/species/skeleton.dm
+++ b/code/modules/mob/living/carbon/human/species/skeleton.dm
@@ -41,7 +41,7 @@
"is twisting their skull off!")
has_organ = list(
"brain" = /obj/item/organ/internal/brain/golem,
- )
+ ) //Has default darksight of 2.
/datum/species/skeleton/handle_reagents(var/mob/living/carbon/human/H, var/datum/reagent/R)
// Crazylemon is still silly
diff --git a/code/modules/mob/living/carbon/human/species/species.dm b/code/modules/mob/living/carbon/human/species/species.dm
index e2238057533..73c557c9c58 100644
--- a/code/modules/mob/living/carbon/human/species/species.dm
+++ b/code/modules/mob/living/carbon/human/species/species.dm
@@ -49,7 +49,6 @@
var/siemens_coeff = 1 //base electrocution coefficient
var/invis_sight = SEE_INVISIBLE_LIVING
- var/darksight = 2
var/hazard_high_pressure = HAZARD_HIGH_PRESSURE // Dangerously high pressure.
var/warning_high_pressure = WARNING_HIGH_PRESSURE // High pressure warning.
var/warning_low_pressure = WARNING_LOW_PRESSURE // Low pressure warning.
@@ -586,12 +585,23 @@ It'll return null if the organ doesn't correspond, so include null checks when u
return null
return has_organ[organ_slot]
+/datum/species/proc/get_resultant_darksight(mob/living/carbon/human/H) //Returns default value of 2 if the mob doesn't have eyes, otherwise it grabs the eyes darksight.
+ var/resultant_darksight = 2
+ var/obj/item/organ/internal/eyes/eyes = H.get_int_organ(/obj/item/organ/internal/eyes)
+ if(eyes && eyes.dark_view)
+ resultant_darksight = eyes.dark_view
+ return resultant_darksight
/datum/species/proc/update_sight(mob/living/carbon/human/H)
H.sight = initial(H.sight)
- H.see_in_dark = darksight
+ H.see_in_dark = get_resultant_darksight(H)
H.see_invisible = invis_sight
+ if(H.see_in_dark > 2) //Preliminary see_invisible handling as per set_species() in code\modules\mob\living\carbon\human\human.dm.
+ H.see_invisible = SEE_INVISIBLE_LEVEL_ONE
+ else
+ H.see_invisible = SEE_INVISIBLE_LIVING
+
if(H.client.eye != H)
var/atom/A = H.client.eye
if(A.update_remote_sight(H)) //returns 1 if we override all other sight updates.
@@ -642,7 +652,7 @@ It'll return null if the organ doesn't correspond, so include null checks when u
if(rig.visor && rig.visor.vision && rig.visor.active && rig.visor.vision.glasses)
var/obj/item/clothing/glasses/G = rig.visor.vision.glasses
if(istype(G))
- H.see_in_dark = (G.darkness_view ? G.darkness_view : darksight) // Otherwise we keep our darkness view with togglable nightvision.
+ H.see_in_dark = (G.darkness_view ? G.darkness_view : get_resultant_darksight(H)) // Otherwise we keep our darkness view with togglable nightvision.
if(G.vision_flags) // MESONS
H.sight |= G.vision_flags
@@ -652,7 +662,7 @@ It'll return null if the organ doesn't correspond, so include null checks when u
H.see_in_dark = max(lesser_darkview_bonus, H.see_in_dark)
if(H.vision_type)
- H.see_in_dark = max(H.see_in_dark, H.vision_type.see_in_dark, darksight)
+ H.see_in_dark = max(H.see_in_dark, H.vision_type.see_in_dark, get_resultant_darksight(H))
H.see_invisible = H.vision_type.see_invisible
if(H.vision_type.light_sensitive)
H.weakeyes = 1
diff --git a/code/modules/mob/living/carbon/human/species/station.dm b/code/modules/mob/living/carbon/human/species/station.dm
index 5bde6ce8e5b..4ae52431e9a 100644
--- a/code/modules/mob/living/carbon/human/species/station.dm
+++ b/code/modules/mob/living/carbon/human/species/station.dm
@@ -18,6 +18,7 @@
worlds tumultous at best."
reagent_tag = PROCESS_ORG
+ //Has standard darksight of 2.
/datum/species/unathi
name = "Unathi"
@@ -30,7 +31,6 @@
tail = "sogtail"
unarmed_type = /datum/unarmed_attack/claws
primitive_form = "Stok"
- darksight = 3
blurb = "A heavily reptillian species, Unathi (or 'Sinta as they call themselves) hail from the \
Uuosa-Eso system, which roughly translates to 'burning mother'.
Coming from a harsh, radioactive \
@@ -66,7 +66,7 @@
"kidneys" = /obj/item/organ/internal/kidneys,
"brain" = /obj/item/organ/internal/brain,
"appendix" = /obj/item/organ/internal/appendix,
- "eyes" = /obj/item/organ/internal/eyes,
+ "eyes" = /obj/item/organ/internal/eyes/unathi //3 darksight.
)
allowed_consumed_mobs = list(/mob/living/simple_animal/mouse, /mob/living/simple_animal/lizard, /mob/living/simple_animal/chick, /mob/living/simple_animal/chicken,
@@ -91,7 +91,6 @@
language = "Siik'tajr"
tail = "tajtail"
unarmed_type = /datum/unarmed_attack/claws
- darksight = 8
blurb = "The Tajaran race is a species of feline-like bipeds hailing from the planet of Ahdomai in the \
S'randarr system. They have been brought up into the space age by the Humans and Skrell, and have been \
@@ -126,7 +125,8 @@
"kidneys" = /obj/item/organ/internal/kidneys,
"brain" = /obj/item/organ/internal/brain,
"appendix" = /obj/item/organ/internal/appendix,
- "eyes" = /obj/item/organ/internal/eyes,
+ "eyes" = /obj/item/organ/internal/eyes/tajaran /*Most Tajara are surgically augmented at birth for full colour vision, although it cost them their darksight (darksight = 2) unless they choose otherwise in character creation (darksight = 8 but colourblind).
+ However, this organ define is for unaugmented eyes so cloned Tajara are colourblind but have excellent darksight.*/
)
allowed_consumed_mobs = list(/mob/living/simple_animal/mouse, /mob/living/simple_animal/chick, /mob/living/simple_animal/butterfly, /mob/living/simple_animal/parrot,
@@ -138,6 +138,15 @@
"is twisting their own neck!",
"is holding their breath!")
+/datum/species/tajaran/equip(var/mob/living/carbon/human/H) //Handles colourblindness preferences. Should only happen if the client is in a mob otherwise it won't work.
+ var/sight_pref = H.client.prefs.speciesprefs
+ if(!sight_pref)
+ var/obj/item/organ/internal/eyes/tajaran/tajeyes = H.get_int_organ(/obj/item/organ/internal/eyes)
+ if(tajeyes && !tajeyes.robotic) //To avoid overriding the properties of cybernetic/mechassisted eyes, apply the colour matrix and darksight modifier only if the organ is organic. Robotic/mechassisted eyes currently do this, too, as is necessary.
+ tajeyes.colourmatrix = null //For individuals who recieved the modification, they lose much of their darksight and gain full colour vision.
+ tajeyes.dark_view = 2 //If they didn't, they would have their unique colour-vision and full darksight. See code\modules\surgery\organs\subtypes\tajaran.dm
+ H.update_client_colour(0)
+
/datum/species/tajaran/handle_death(var/mob/living/carbon/human/H)
H.stop_tail_wagging(1)
@@ -152,7 +161,6 @@
primitive_form = "Wolpin"
tail = "vulptail"
unarmed_type = /datum/unarmed_attack/claws
- darksight = 8
blurb = "Vulpkanin are a species of sharp-witted canine-pideds residing on the planet Altam just barely within the \
dual-star Vazzend system. Their politically de-centralized society and independent natures have led them to become a species and \
@@ -176,7 +184,8 @@
"kidneys" = /obj/item/organ/internal/kidneys,
"brain" = /obj/item/organ/internal/brain,
"appendix" = /obj/item/organ/internal/appendix,
- "eyes" = /obj/item/organ/internal/eyes,
+ "eyes" = /obj/item/organ/internal/eyes/vulpkanin /*Most Vulpkanin are surgically augmented at birth for full colour vision, although it cost them their darksight (darksight = 2) unless they choose otherwise in character creation (darksight = 8 but colourblind).
+ However, this organ define is for unaugmented eyes so cloned Vulpkanin are colourblind but have excellent darksight.*/
)
allowed_consumed_mobs = list(/mob/living/simple_animal/mouse, /mob/living/simple_animal/lizard, /mob/living/simple_animal/chick, /mob/living/simple_animal/chicken,
@@ -188,6 +197,15 @@
"is twisting their own neck!",
"is holding their breath!")
+/datum/species/vulpkanin/equip(var/mob/living/carbon/human/H) //Handles colourblindness preferences. Should only happen if the client is in a mob otherwise it won't work.
+ var/sight_pref = H.client.prefs.speciesprefs
+ if(!sight_pref)
+ var/obj/item/organ/internal/eyes/vulpkanin/vulpeyes = H.get_int_organ(/obj/item/organ/internal/eyes)
+ if(vulpeyes && !vulpeyes.robotic) //To avoid overriding the properties of cybernetic/mechassisted eyes, apply the colour matrix and darksight modifier only if the organ is organic. Robotic/mechassisted eyes currently do this, too, as is necessary.
+ vulpeyes.colourmatrix = null //For individuals who recieved the modification, they lose much of their darksight and gain full colour vision.
+ vulpeyes.dark_view = 2 //If they didn't, they would have their unique colour-vision and full darksight. See code\modules\surgery\organs\subtypes\vulpkanin.dm
+ H.update_client_colour(0)
+
/datum/species/vulpkanin/handle_death(var/mob/living/carbon/human/H)
H.stop_tail_wagging(1)
@@ -226,7 +244,7 @@
"kidneys" = /obj/item/organ/internal/kidneys,
"brain" = /obj/item/organ/internal/brain,
"appendix" = /obj/item/organ/internal/appendix,
- "eyes" = /obj/item/organ/internal/eyes,
+ "eyes" = /obj/item/organ/internal/eyes //Default darksight of 2.
)
suicide_messages = list(
@@ -315,7 +333,7 @@
"kidneys" = /obj/item/organ/internal/kidneys,
"brain" = /obj/item/organ/internal/brain,
"appendix" = /obj/item/organ/internal/appendix,
- "eyes" = /obj/item/organ/internal/eyes,
+ "eyes" = /obj/item/organ/internal/eyes, //Default darksight of 2.
"stack" = /obj/item/organ/internal/stack/vox //Not the same as the cortical stack implant Vox Raiders spawn with. The cortical stack implant is used
) //for determining the success of the heist game-mode's 'leave nobody behind' objective, while this is just an organ.
@@ -439,7 +457,7 @@
"liver" = /obj/item/organ/internal/liver,
"kidneys" = /obj/item/organ/internal/kidneys,
"brain" = /obj/item/organ/internal/brain,
- "eyes" = /obj/item/organ/internal/eyes,
+ "eyes" = /obj/item/organ/internal/eyes, //Default darksight of 2.
"stack" = /obj/item/organ/internal/stack/vox //Not the same as the cortical stack implant Vox Raiders spawn with. The cortical stack implant is used
) //for determining the success of the heist game-mode's 'leave nobody behind' objective, while this is just an organ.
@@ -478,7 +496,7 @@
"kidneys" = /obj/item/organ/internal/kidneys,
"brain" = /obj/item/organ/internal/brain,
"appendix" = /obj/item/organ/internal/appendix,
- "eyes" = /obj/item/organ/internal/eyes,
+ "eyes" = /obj/item/organ/internal/eyes //Default darksight of 2.
)
allowed_consumed_mobs = list(/mob/living/simple_animal/diona)
@@ -517,6 +535,7 @@
exotic_blood = "water"
//ventcrawler = 1 //ventcrawling commented out
butt_sprite = "slime"
+ //Has default darksight of 2.
has_organ = list(
"brain" = /obj/item/organ/internal/brain/slime
@@ -685,7 +704,6 @@
default_language = "Galactic Common"
language = "Psionic Communication"
unarmed_type = /datum/unarmed_attack/punch
- darksight = 5 // BOOSTED from 2
eyes = "grey_eyes_s"
butt_sprite = "grey"
@@ -696,7 +714,7 @@
"kidneys" = /obj/item/organ/internal/kidneys,
"brain" = /obj/item/organ/internal/brain/grey,
"appendix" = /obj/item/organ/internal/appendix,
- "eyes" = /obj/item/organ/internal/eyes,
+ "eyes" = /obj/item/organ/internal/eyes/grey //5 darksight.
)
brute_mod = 1.25 //greys are fragile
@@ -771,13 +789,13 @@
has_organ = list(
"nutrient channel" = /obj/item/organ/internal/liver/diona,
"neural strata" = /obj/item/organ/internal/heart/diona,
- "receptor node" = /obj/item/organ/internal/diona_receptor,
+ "receptor node" = /obj/item/organ/internal/eyes/diona, //Default darksight of 2.
"gas bladder" = /obj/item/organ/internal/brain/diona,
"polyp segment" = /obj/item/organ/internal/kidneys/diona,
"anchoring ligament" = /obj/item/organ/internal/appendix/diona
)
- vision_organ = /obj/item/organ/internal/diona_receptor
+ vision_organ = /obj/item/organ/internal/eyes/diona
has_limbs = list(
"chest" = list("path" = /obj/item/organ/external/chest/diona),
"groin" = list("path" = /obj/item/organ/external/groin/diona),
@@ -878,10 +896,10 @@
has_organ = list(
"brain" = /obj/item/organ/internal/brain/mmi_holder/posibrain,
"cell" = /obj/item/organ/internal/cell,
- "optics" = /obj/item/organ/internal/optical_sensor
+ "optics" = /obj/item/organ/internal/eyes/optical_sensor //Default darksight of 2.
)
- vision_organ = /obj/item/organ/internal/optical_sensor
+ vision_organ = /obj/item/organ/internal/eyes/optical_sensor
has_limbs = list(
"chest" = list("path" = /obj/item/organ/external/chest/ipc),
"groin" = list("path" = /obj/item/organ/external/groin/ipc),
@@ -927,7 +945,6 @@
language = "Orluum"
unarmed_type = /datum/unarmed_attack/punch
eyes = "drask_eyes_s"
- darksight = 5
speech_sounds = list('sound/voice/DraskTalk.ogg')
speech_chance = 20
@@ -977,7 +994,7 @@
"heart" = /obj/item/organ/internal/heart/drask,
"lungs" = /obj/item/organ/internal/lungs/drask,
"metabolic strainer" = /obj/item/organ/internal/liver/drask,
- "eyes" = /obj/item/organ/internal/eyes/drask,
+ "eyes" = /obj/item/organ/internal/eyes/drask, //5 darksight.
"brain" = /obj/item/organ/internal/brain/drask
)
diff --git a/code/modules/mob/login.dm b/code/modules/mob/login.dm
index 8cc51882ebf..27197474c00 100644
--- a/code/modules/mob/login.dm
+++ b/code/modules/mob/login.dm
@@ -72,6 +72,8 @@
for(var/datum/alternate_appearance/AA in viewing_alternate_appearances)
AA.display_to(list(src))
+ update_client_colour(0)
+
callHook("mob_login", list("client" = client, "mob" = src))
// Calling update_interface() in /mob/Login() causes the Cyborg to immediately be ghosted; because of winget().
diff --git a/code/modules/mob/mob_helpers.dm b/code/modules/mob/mob_helpers.dm
index 0b04647d094..e07fb765ce7 100644
--- a/code/modules/mob/mob_helpers.dm
+++ b/code/modules/mob/mob_helpers.dm
@@ -22,6 +22,24 @@
return 0
return 1
+/mob/proc/get_screen_colour()
+
+/mob/proc/update_client_colour(var/time = 10) //Update the mob's client.color with an animation the specified time in length.
+ if(!client)
+ return
+ client.colour_transition(get_screen_colour(), time = time)
+
+/mob/living/carbon/human/get_screen_colour() //Fetch the colour matrix from wherever (e.g. eyes) so it can be compared to client.color.
+ . = ..()
+ if(.)
+ return .
+ var/obj/item/clothing/glasses/worn_glasses = glasses
+ var/obj/item/organ/internal/eyes/eyes = get_int_organ(/obj/item/organ/internal/eyes)
+ if(istype(worn_glasses) && worn_glasses.color_view) //Check to see if they got those magic glasses and they're augmenting the colour of what the wearer sees. If they're not, color_view should be null.
+ return worn_glasses.color_view
+ else if(eyes && eyes.colourmatrix) //If they're not, check to see if their eyes got one of them there colour matrices.
+ return eyes.colourmatrix
+
/proc/isloyal(A) //Checks to see if the person contains a mindshield implant, then checks that the implant is actually inside of them
for(var/obj/item/weapon/implant/loyalty/L in A)
if(L && L.implanted)
@@ -291,10 +309,10 @@ proc/muffledspeech(phrase)
/mob/proc/abiotic(var/full_body = 0)
- if(full_body && ((src.l_hand && !(src.l_hand.flags & ABSTRACT)) || (src.r_hand && !(src.r_hand.flags & ABSTRACT)) || (src.back || src.wear_mask)))
+ if(full_body && ((l_hand && !(l_hand.flags & ABSTRACT)) || (r_hand && !(r_hand.flags & ABSTRACT)) || (back || wear_mask)))
return 1
- if((src.l_hand && !(src.l_hand.flags & ABSTRACT)) || (src.r_hand && !(src.r_hand.flags & ABSTRACT)))
+ if((l_hand && !(l_hand.flags & ABSTRACT)) || (r_hand && !(r_hand.flags & ABSTRACT)))
return 1
return 0
@@ -586,8 +604,8 @@ var/list/intents = list(I_HELP,I_DISARM,I_GRAB,I_HARM)
if(5)
newletter="glor"
newphrase+="[newletter]";counter-=1
- return newphrase
-
+ return newphrase
+
/mob/proc/get_preference(toggleflag)
if(!client)
return FALSE
diff --git a/code/modules/mob/new_player/new_player.dm b/code/modules/mob/new_player/new_player.dm
index bccd7990de9..2233c617b6e 100644
--- a/code/modules/mob/new_player/new_player.dm
+++ b/code/modules/mob/new_player/new_player.dm
@@ -483,7 +483,7 @@
close_spawn_windows()
check_prefs_are_sane()
- var/mob/living/carbon/human/new_character = new(loc)
+ var/mob/living/carbon/human/new_character = new(loc, client.prefs.species)
new_character.lastarea = get_area(loc)
if(ticker.random_players || appearance_isbanned(new_character))
diff --git a/code/modules/research/designs/mechfabricator_designs.dm b/code/modules/research/designs/mechfabricator_designs.dm
index 702afa68f2f..46e5a478c88 100644
--- a/code/modules/research/designs/mechfabricator_designs.dm
+++ b/code/modules/research/designs/mechfabricator_designs.dm
@@ -1100,7 +1100,7 @@
name = "IPC Optical Sensor"
id = "ipc_optics"
build_type = MECHFAB
- build_path = /obj/item/organ/internal/optical_sensor
+ build_path = /obj/item/organ/internal/eyes/optical_sensor
materials = list(MAT_METAL=1000, MAT_GLASS=2500)
construction_time = 200
category = list("Misc")
diff --git a/code/modules/surgery/organs/helpers.dm b/code/modules/surgery/organs/helpers.dm
index a61537f1985..24ae966cd14 100644
--- a/code/modules/surgery/organs/helpers.dm
+++ b/code/modules/surgery/organs/helpers.dm
@@ -13,7 +13,6 @@
/mob/living/carbon/get_int_organ(typepath)
return (locate(typepath) in internal_organs)
-
/mob/living/carbon/get_organs_zone(zone, var/subzones = 0)
var/list/returnorg = list()
if(subzones)
diff --git a/code/modules/surgery/organs/organ.dm b/code/modules/surgery/organs/organ.dm
index 66436d22b64..f2da2d0a949 100644
--- a/code/modules/surgery/organs/organ.dm
+++ b/code/modules/surgery/organs/organ.dm
@@ -228,10 +228,10 @@ var/list/organ_cache = list()
/obj/item/organ/proc/take_damage(amount, var/silent=0)
if(tough)
return
- if(src.status & ORGAN_ROBOT)
- src.damage = between(0, src.damage + (amount * 0.8), max_damage)
+ if(status & ORGAN_ROBOT)
+ damage = between(0, damage + (amount * 0.8), max_damage)
else
- src.damage = between(0, src.damage + amount, max_damage)
+ damage = between(0, damage + amount, max_damage)
//only show this if the organ is not robotic
if(owner && parent_organ && amount > 0)
@@ -241,18 +241,18 @@ var/list/organ_cache = list()
/obj/item/organ/proc/robotize() //Being used to make robutt hearts, etc
robotic = 2
- src.status &= ~ORGAN_BROKEN
- src.status &= ~ORGAN_BLEEDING
- src.status &= ~ORGAN_SPLINTED
- src.status &= ~ORGAN_CUT_AWAY
- src.status &= ~ORGAN_ATTACHABLE
- src.status &= ~ORGAN_DESTROYED
- src.status |= ORGAN_ROBOT
- src.status |= ORGAN_ASSISTED
+ status &= ~ORGAN_BROKEN
+ status &= ~ORGAN_BLEEDING
+ status &= ~ORGAN_SPLINTED
+ status &= ~ORGAN_CUT_AWAY
+ status &= ~ORGAN_ATTACHABLE
+ status &= ~ORGAN_DESTROYED
+ status |= ORGAN_ROBOT
+ status |= ORGAN_ASSISTED
/obj/item/organ/proc/mechassist() //Used to add things like pacemakers, etc
- robotize()
- src.status &= ~ORGAN_ROBOT
+ robotize(1) //Skip the icon/name setting that occurs in robotize to avoid having to reset the icon file.
+ status &= ~ORGAN_ROBOT
robotic = 1
min_bruised_damage = 15
min_broken_damage = 35
@@ -325,7 +325,7 @@ var/list/organ_cache = list()
affected.internal_organs |= src
if(!target.get_int_organ(src))
target.internal_organs += src
- src.loc = target
+ loc = target
if(robotic)
status |= ORGAN_ROBOT
diff --git a/code/modules/surgery/organs/organ_internal.dm b/code/modules/surgery/organs/organ_internal.dm
index 5dd4d570ee2..79d1ed5faae 100644
--- a/code/modules/surgery/organs/organ_internal.dm
+++ b/code/modules/surgery/organs/organ_internal.dm
@@ -201,7 +201,7 @@
/obj/item/organ/internal/heart/prepare_eat()
var/obj/S = ..()
- S.icon_state = "heart-off"
+ S.icon_state = dead_icon
return S
/obj/item/organ/internal/heart/cursed
@@ -343,16 +343,17 @@
parent_organ = "head"
slot = "eyes"
var/list/eye_colour = list(0,0,0)
+ var/list/colourmatrix = null
+ var/dark_view = 2 //Default dark_view for Humans.
+ var/weld_proof = null //If set, the eyes will not take damage during welding. eg. IPC optical sensors do not take damage when they weld things while all other eyes will.
/obj/item/organ/internal/eyes/proc/update_colour()
dna.write_eyes_attributes(src)
-/obj/item/organ/internal/eyes/insert(mob/living/carbon/M, special = 0)
+/obj/item/organ/internal/eyes/insert(mob/living/carbon/human/M, special = 0)
..()
if(istype(M) && eye_colour)
- var/mob/living/carbon/human/H = M
- // Apply our eye colour to the target.
- H.update_body()
+ M.update_body() //Apply our eye colour to the target.
/obj/item/organ/internal/eyes/surgeryize()
if(!owner)
@@ -362,6 +363,38 @@
owner.SetEyeBlurry(0)
owner.SetEyeBlind(0)
+/obj/item/organ/internal/robotize(var/icon_bypass) //If icon bypass isn't null, skip the processing here and go straight to the parent call.
+ if(!icon_bypass && !(status & ORGAN_ROBOT)) //Don't override the icons for the already-mechanical IPC organs.
+ var/list/states = icon_states('icons/obj/surgery.dmi') //Insensitive to specially-defined icon files for species like the Drask or whomever else. Everyone gets the same robotic heart.
+ if(slot == "heart" && ("[slot]-prosthetic-on" in states) && ("[slot]-prosthetic-off" in states)) //Give the robotic heart its robotic heart icons if they exist.
+ var/obj/item/organ/internal/heart/H = src
+ H.icon = icon('icons/obj/surgery.dmi')
+ H.icon_base = "[slot]-prosthetic"
+ H.dead_icon = "[slot]-prosthetic-off"
+ H.update_icon()
+ else if("[slot]-prosthetic" in states) //Give the robotic organ its robotic organ icons if they exist.
+ icon = icon('icons/obj/surgery.dmi')
+ icon_state = "[slot]-prosthetic"
+ name = "mechanical [slot]"
+ ..() //Go apply all the organ flags/robotic statuses.
+
+/obj/item/organ/internal/eyes/robotize()
+ colourmatrix = null
+ dark_view = 2
+ ..() //Make sure the organ's got the robotic status indicators before updating the client colour.
+ owner.update_client_colour(0) //Since both mechassisted and mechanical eyes give dark_view of 2 and full colour vision atm, just having this here is fine as mechassist() will call it anyway.
+
+/obj/item/organ/internal/mechassist()
+ ..() //Go back, call robotize(), adjust the robotic status indicators and the organ damage parameters.
+ var/list/states = icon_states(icon) //Sensitive to specially-defined icon files since the organs are not fully synthetic.
+ if(slot == "heart" && ("[organ_tag]-assisted-on" in states) && ("[organ_tag]-assisted-off" in states)) //Give the mechassisted heart its mechassisted heart icons if they exist.
+ var/obj/item/organ/internal/heart/H = src
+ H.icon_base = "[organ_tag]-assisted"
+ H.dead_icon = "[organ_tag]-assisted-off"
+ H.update_icon()
+ else if("[organ_tag]-assisted" in states) //Give the mechassisted organ its mechassisted organ icons if they exist.
+ icon_state = "[organ_tag]-assisted"
+ name = "mechanically assisted [initial(name)]" //Avoid setting the organ's name to something like "mechanically assisted mechanical eyes".
/obj/item/organ/internal/liver
name = "liver"
@@ -372,7 +405,6 @@
var/alcohol_intensity = 1
/obj/item/organ/internal/liver/process()
-
..()
if(!owner)
diff --git a/code/modules/surgery/organs/subtypes/abductor.dm b/code/modules/surgery/organs/subtypes/abductor.dm
new file mode 100644
index 00000000000..6fd234bc501
--- /dev/null
+++ b/code/modules/surgery/organs/subtypes/abductor.dm
@@ -0,0 +1,4 @@
+/obj/item/organ/internal/eyes/abductor
+ name = "abductor eyeballs"
+ dark_view = 3
+ species = "Abductor"
diff --git a/code/modules/surgery/organs/subtypes/diona.dm b/code/modules/surgery/organs/subtypes/diona.dm
index a4b0d8fb92b..729a87d2819 100644
--- a/code/modules/surgery/organs/subtypes/diona.dm
+++ b/code/modules/surgery/organs/subtypes/diona.dm
@@ -116,74 +116,42 @@
/obj/item/organ/diona/process()
return
-/obj/item/organ/internal/heart/diona
+/obj/item/organ/internal/heart/diona // Turns into a nymph instantly, no transplanting possible.
name = "neural strata"
icon = 'icons/obj/objects.dmi'
icon_state = "nymph"
- organ_tag = "heart" // Turns into a nymph instantly, no transplanting possible.
- origin_tech = "biotech=3"
- parent_organ = "chest"
- slot = "heart"
species = "Diona"
-/obj/item/organ/internal/brain/diona
+/obj/item/organ/internal/brain/diona // Turns into a nymph instantly, no transplanting possible.
name = "gas bladder"
- parent_organ = "head"
icon = 'icons/obj/objects.dmi'
icon_state = "nymph"
- organ_tag = "brain" // Turns into a nymph instantly, no transplanting possible.
- origin_tech = "biotech=3"
- slot = "brain"
species = "Diona"
-/obj/item/organ/internal/kidneys/diona
+/obj/item/organ/internal/kidneys/diona // Turns into a nymph instantly, no transplanting possible.
name = "polyp segment"
icon = 'icons/obj/objects.dmi'
icon_state = "nymph"
- organ_tag = "kidneys" // Turns into a nymph instantly, no transplanting possible.
- origin_tech = "biotech=3"
- parent_organ = "groin"
- slot = "kidneys"
species = "Diona"
-/obj/item/organ/internal/appendix/diona
+/obj/item/organ/internal/appendix/diona // Turns into a nymph instantly, no transplanting possible.
name = "anchoring ligament"
icon = 'icons/obj/objects.dmi'
icon_state = "nymph"
- organ_tag = "appendix" // Turns into a nymph instantly, no transplanting possible.
- origin_tech = "biotech=3"
- parent_organ = "groin"
- slot = "appendix"
species = "Diona"
-/obj/item/organ/internal/diona_receptor
+/obj/item/organ/internal/eyes/diona // Turns into a nymph instantly, no transplanting possible.
name = "receptor node"
- organ_tag = "eyes"
icon = 'icons/mob/alien.dmi'
icon_state = "claw"
- origin_tech = "biotech=3"
- parent_organ = "head"
- slot = "eyes"
species = "Diona"
-/obj/item/organ/internal/diona_receptor/surgeryize()
- if(!owner)
- return
- owner.CureNearsighted()
- owner.CureBlind()
- owner.SetEyeBlurry(0)
- owner.SetEyeBlind(0)
-
-
//TODO:Make absorb rads on insert
-/obj/item/organ/internal/liver/diona
+/obj/item/organ/internal/liver/diona // Turns into a nymph instantly, no transplanting possible.
name = "nutrient vessel"
- parent_organ = "chest"
- organ_tag = "liver"
icon = 'icons/mob/alien.dmi'
icon_state = "claw"
- slot = "liver"
alcohol_intensity = 0.5
species = "Diona"
diff --git a/code/modules/surgery/organs/subtypes/drask.dm b/code/modules/surgery/organs/subtypes/drask.dm
index b3b260a28a0..6e1e6662d0a 100644
--- a/code/modules/surgery/organs/subtypes/drask.dm
+++ b/code/modules/surgery/organs/subtypes/drask.dm
@@ -9,51 +9,29 @@
/obj/item/organ/internal/heart/drask
name = "drask heart"
icon = 'icons/obj/surgery_drask.dmi'
- icon_state = "heart-on"
- dead_icon = "heart-off"
- organ_tag = "heart"
parent_organ = "head"
- slot = "heart"
species = "Drask"
/obj/item/organ/internal/lungs/drask
- name = "lungs"
icon = 'icons/obj/surgery_drask.dmi'
- icon_state = "lungs"
- gender = PLURAL
- organ_tag = "lungs"
- parent_organ = "chest"
- slot = "lungs"
species = "Drask"
/obj/item/organ/internal/liver/drask
name = "metabolic strainer"
icon = 'icons/obj/surgery_drask.dmi'
- icon_state = "kidneys"
- gender = PLURAL
- organ_tag = "kidneys"
- parent_organ = "groin"
- slot = "kidneys"
alcohol_intensity = 0.8
species = "Drask"
/obj/item/organ/internal/brain/drask
- name = "brain"
icon = 'icons/obj/surgery_drask.dmi'
icon_state = "brain2"
- organ_tag = "brain"
- slot = "brain"
mmi_icon = 'icons/obj/surgery_drask.dmi'
mmi_icon_state = "mmi_full"
species = "Drask"
/obj/item/organ/internal/eyes/drask
- name = "eyes"
+ name = "drask eyeballs"
icon = 'icons/obj/surgery_drask.dmi'
- icon_state = "eyes"
- gender = PLURAL
- organ_tag = "eyes"
- parent_organ = "head"
- slot = "eyes"
desc = "Drask eyes. They look even stranger disembodied"
+ dark_view = 5
species = "Drask"
diff --git a/code/modules/surgery/organs/subtypes/grey.dm b/code/modules/surgery/organs/subtypes/grey.dm
index a47ab801d6f..6c06da373b7 100644
--- a/code/modules/surgery/organs/subtypes/grey.dm
+++ b/code/modules/surgery/organs/subtypes/grey.dm
@@ -14,3 +14,8 @@
/obj/item/organ/internal/brain/grey/remove(var/mob/living/carbon/M, var/special = 0)
. = ..()
M.remove_language("Psionic Communication")
+
+/obj/item/organ/internal/eyes/grey
+ name = "grey eyeballs"
+ dark_view = 5
+ species = "Grey"
diff --git a/code/modules/surgery/organs/subtypes/machine.dm b/code/modules/surgery/organs/subtypes/machine.dm
index 0f402a42e5d..b3bb3f61e07 100644
--- a/code/modules/surgery/organs/subtypes/machine.dm
+++ b/code/modules/surgery/organs/subtypes/machine.dm
@@ -117,37 +117,26 @@
robotize()
..()
-/obj/item/organ/internal/optical_sensor
+/obj/item/organ/internal/eyes/optical_sensor
name = "optical sensor"
- organ_tag = "eyes"
- parent_organ = "head"
icon = 'icons/obj/robot_component.dmi'
icon_state = "camera"
- slot = "eyes"
status = ORGAN_ROBOT
species = "Machine"
// dead_icon = "camera_broken"
+ weld_proof = 1
-/obj/item/organ/internal/optical_sensor/New()
+/obj/item/organ/internal/eyes/optical_sensor/New()
robotize()
..()
-/obj/item/organ/internal/optical_sensor/remove(var/mob/living/user,special = 0)
+/obj/item/organ/internal/eyes/optical_sensor/remove(var/mob/living/user,special = 0)
if(!special)
to_chat(owner, "Error 404:Optical Sensors not found.")
. = ..()
-/obj/item/organ/internal/optical_sensor/surgeryize()
- if(!owner)
- return
- owner.CureNearsighted()
- owner.CureBlind()
- owner.SetEyeBlurry(0)
- owner.SetEyeBlind(0)
-
-
// Used for an MMI or posibrain being installed into a human.
/obj/item/organ/internal/brain/mmi_holder
name = "brain"
@@ -160,7 +149,6 @@
species = "Machine"
var/obj/item/device/mmi/stored_mmi
-
/obj/item/organ/internal/brain/mmi_holder/Destroy()
if(stored_mmi)
qdel(stored_mmi)
diff --git a/code/modules/surgery/organs/subtypes/nucleation.dm b/code/modules/surgery/organs/subtypes/nucleation.dm
index d234b666ae3..4223834501d 100644
--- a/code/modules/surgery/organs/subtypes/nucleation.dm
+++ b/code/modules/surgery/organs/subtypes/nucleation.dm
@@ -26,8 +26,6 @@
icon_state = "crystal-eyes"
organ_tag = "luminescent eyes"
light_color = "#1C1C00"
- parent_organ = "head"
- slot = "eyes"
species = "Nucleation"
/obj/item/organ/internal/eyes/luminescent_crystal/New()
@@ -35,8 +33,7 @@
..()
/obj/item/organ/internal/brain/crystal
- name = "crystalized brain"
+ name = "crystallized brain"
icon_state = "crystal-brain"
- organ_tag = "crystalized brain"
- slot = "brain"
+ organ_tag = "crystallized brain"
species = "Nucleation"
diff --git a/code/modules/surgery/organs/subtypes/shadow.dm b/code/modules/surgery/organs/subtypes/shadow.dm
new file mode 100644
index 00000000000..f81fc54bfb1
--- /dev/null
+++ b/code/modules/surgery/organs/subtypes/shadow.dm
@@ -0,0 +1,4 @@
+/obj/item/organ/internal/eyes/shadow
+ name = "dark orbs"
+ dark_view = 8
+ species = "Shadow"
diff --git a/code/modules/surgery/organs/subtypes/tajaran.dm b/code/modules/surgery/organs/subtypes/tajaran.dm
index e37686a05ca..f65070feb6c 100644
--- a/code/modules/surgery/organs/subtypes/tajaran.dm
+++ b/code/modules/surgery/organs/subtypes/tajaran.dm
@@ -1,3 +1,12 @@
/obj/item/organ/internal/liver/tajaran
alcohol_intensity = 1.4
species = "Tajaran"
+
+/obj/item/organ/internal/eyes/tajaran /*Most Tajara are surgically augmented at birth for full colour vision, although it cost them their darksight (darksight = 2) unless they choose otherwise in character creation (darksight = 8 but colourblind).
+ However, this organ define is for unaugmented eyes so cloned Tajara are colourblind but have excellent darksight.*/
+ name = "tajaran eyeballs"
+ species = "Tajaran"
+ dark_view = 8
+ colourmatrix = list(0.4,0.2,0.4,\
+ 0.4,0.6,0.0,\
+ 0.2,0.2,0.6) //Slightly less richness of hues or saturation of colours than Vulpkanin eyes. Pastel colour scheme, blues slightly green-shifted, reds slightly blue-shifted, greens yellow-shifted.
diff --git a/code/modules/surgery/organs/subtypes/unathi.dm b/code/modules/surgery/organs/subtypes/unathi.dm
index a769bce7a02..0fb45319ce5 100644
--- a/code/modules/surgery/organs/subtypes/unathi.dm
+++ b/code/modules/surgery/organs/subtypes/unathi.dm
@@ -1,3 +1,8 @@
/obj/item/organ/internal/liver/unathi
alcohol_intensity = 0.8
species = "Unathi"
+
+/obj/item/organ/internal/eyes/unathi
+ name = "unathi eyeballs"
+ dark_view = 3
+ species = "Unathi"
diff --git a/code/modules/surgery/organs/subtypes/vulpkanin.dm b/code/modules/surgery/organs/subtypes/vulpkanin.dm
index ca47ac83ddd..39ee9463425 100644
--- a/code/modules/surgery/organs/subtypes/vulpkanin.dm
+++ b/code/modules/surgery/organs/subtypes/vulpkanin.dm
@@ -1,3 +1,12 @@
/obj/item/organ/internal/liver/vulpkanin
alcohol_intensity = 1.4
species = "Vulpkanin"
+
+/obj/item/organ/internal/eyes/vulpkanin /*Most Vulpkanin are surgically augmented at birth for full colour vision, although it cost them their darksight (darksight = 2) unless they choose otherwise in character creation (darksight = 8 but colourblind).
+ However, this organ define is for unaugmented eyes so cloned Vulpkanin are colourblind but have excellent darksight.*/
+ name = "vulpkanin eyeballs"
+ species = "Vulpkanin"
+ dark_view = 8
+ colourmatrix = list(0.5,0.4,0.1,\
+ 0.5,0.4,0.1,\
+ 0.0,0.2,0.8) //Seeing in tones of blues and yellows, blind to greens. More richness of hue and saturation of colour than Tajara.
diff --git a/code/modules/surgery/organs/subtypes/wryn.dm b/code/modules/surgery/organs/subtypes/wryn.dm
index f51adb6054e..ee1a12fd1ab 100644
--- a/code/modules/surgery/organs/subtypes/wryn.dm
+++ b/code/modules/surgery/organs/subtypes/wryn.dm
@@ -7,3 +7,7 @@
parent_organ = "head"
slot = "hivenode"
species = "Wryn"
+
+/obj/item/organ/internal/eyes/wryn
+ dark_view = 3
+ species = "Wryn"
diff --git a/code/modules/surgery/organs_internal.dm b/code/modules/surgery/organs_internal.dm
index f86cf41bcd0..73416045624 100644
--- a/code/modules/surgery/organs_internal.dm
+++ b/code/modules/surgery/organs_internal.dm
@@ -182,7 +182,7 @@
H.custom_pain("The pain in your [affected.name] is living hell!", 1)
else if(istype(tool, /obj/item/weapon/reagent_containers/food/snacks/organ))
- to_chat(user, "[tool] was biten by someone! It's too damaged to use!")
+ to_chat(user, "[tool] was bitten by someone! It's too damaged to use!")
return -1
..()
@@ -244,6 +244,8 @@
thing.forceMove(get_turf(target))
else
user.put_in_hands(thing)
+
+ target.update_icons()
else
user.visible_message("[user] can't seem to extract anything from [target]'s [parse_zone(target_zone)]!",
"You can't extract anything from [target]'s [parse_zone(target_zone)]!")
diff --git a/icons/obj/surgery.dmi b/icons/obj/surgery.dmi
index 88161a20b5c..db3343f1ca2 100644
Binary files a/icons/obj/surgery.dmi and b/icons/obj/surgery.dmi differ
diff --git a/paradise.dme b/paradise.dme
index 93d922f35fc..e79a7499e65 100644
--- a/paradise.dme
+++ b/paradise.dme
@@ -2057,6 +2057,7 @@
#include "code\modules\surgery\organs\robolimbs.dm"
#include "code\modules\surgery\organs\skeleton.dm"
#include "code\modules\surgery\organs\wound.dm"
+#include "code\modules\surgery\organs\subtypes\abductor.dm"
#include "code\modules\surgery\organs\subtypes\diona.dm"
#include "code\modules\surgery\organs\subtypes\drask.dm"
#include "code\modules\surgery\organs\subtypes\grey.dm"
@@ -2064,6 +2065,7 @@
#include "code\modules\surgery\organs\subtypes\machine.dm"
#include "code\modules\surgery\organs\subtypes\misc.dm"
#include "code\modules\surgery\organs\subtypes\nucleation.dm"
+#include "code\modules\surgery\organs\subtypes\shadow.dm"
#include "code\modules\surgery\organs\subtypes\skrell.dm"
#include "code\modules\surgery\organs\subtypes\standard.dm"
#include "code\modules\surgery\organs\subtypes\tajaran.dm"