mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-16 17:43:35 +01:00
Merge pull request #16311 from S34NW/does-anyone-else-hate-genetics
Replaces genetics xray vision with other vision genes
This commit is contained in:
@@ -164,6 +164,9 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
|
||||
#define TRAIT_BLOODCRAWL_EAT "bloodcrawl_eat"
|
||||
#define TRAIT_DWARF "dwarf"
|
||||
#define TRAIT_SILENT_FOOTSTEPS "silent_footsteps" //makes your footsteps completely silent
|
||||
#define TRAIT_MESON_VISION "meson_vision"
|
||||
#define TRAIT_FLASH_PROTECTION "flash_protection"
|
||||
#define TRAIT_NIGHT_VISION "night_vision"
|
||||
|
||||
#define TRAIT_COMIC_SANS "comic_sans"
|
||||
#define TRAIT_NOFINGERPRINTS "no_fingerprints"
|
||||
|
||||
@@ -5,7 +5,6 @@ GLOBAL_VAR_INIT(deafblock, 0)
|
||||
GLOBAL_VAR_INIT(hulkblock, 0)
|
||||
GLOBAL_VAR_INIT(teleblock, 0)
|
||||
GLOBAL_VAR_INIT(fireblock, 0)
|
||||
GLOBAL_VAR_INIT(xrayblock, 0)
|
||||
GLOBAL_VAR_INIT(clumsyblock, 0)
|
||||
GLOBAL_VAR_INIT(fakeblock, 0)
|
||||
GLOBAL_VAR_INIT(coughblock, 0)
|
||||
@@ -30,6 +29,9 @@ GLOBAL_VAR_INIT(hallucinationblock, 0)
|
||||
GLOBAL_VAR_INIT(noprintsblock, 0)
|
||||
GLOBAL_VAR_INIT(shockimmunityblock, 0)
|
||||
GLOBAL_VAR_INIT(smallsizeblock, 0)
|
||||
GLOBAL_VAR_INIT(mesonblock, 0)
|
||||
GLOBAL_VAR_INIT(noflashblock, 0)
|
||||
GLOBAL_VAR_INIT(nightvisionblock, 0)
|
||||
|
||||
///////////////////////////////
|
||||
// Goon Stuff
|
||||
|
||||
@@ -46,6 +46,9 @@ GLOBAL_LIST_INIT(traits_by_type, list(
|
||||
"TRAIT_DWARF" = TRAIT_DWARF,
|
||||
"TRAIT_SILENT_FOOTSTEPS" = TRAIT_SILENT_FOOTSTEPS,
|
||||
"TRAIT_ALCOHOL_TOLERANCE" = TRAIT_ALCOHOL_TOLERANCE,
|
||||
"TRAIT_MESON_VISION" = TRAIT_MESON_VISION,
|
||||
"TRAIT_FLASH_PROTECTION" = TRAIT_FLASH_PROTECTION,
|
||||
"TRAIT_NIGHT_VISION" = TRAIT_NIGHT_VISION,
|
||||
|
||||
"TRAIT_COMIC_SANS" = TRAIT_COMIC_SANS,
|
||||
"TRAIT_NOFINGERPRINTS" = TRAIT_NOFINGERPRINTS,
|
||||
|
||||
@@ -140,12 +140,16 @@
|
||||
/datum/mutation/disability/colourblindness/activate(mob/M)
|
||||
..()
|
||||
M.update_client_colour() //Handle the activation of the colourblindness on the mob.
|
||||
M.update_icons() //Apply eyeshine as needed.
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.update_misc_effects()
|
||||
|
||||
/datum/mutation/disability/colourblindness/deactivate(mob/M)
|
||||
..()
|
||||
M.update_client_colour() //Handle the deactivation of the colourblindness on the mob.
|
||||
M.update_icons() //Remove eyeshine as needed.
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.update_misc_effects()
|
||||
|
||||
/datum/mutation/disability/deaf
|
||||
name = "Deafness"
|
||||
|
||||
@@ -158,28 +158,6 @@
|
||||
M.status_flags |= CANSTUN | CANWEAKEN | CANPARALYSE | CANPUSH //temporary fix until the problem can be solved.
|
||||
to_chat(M, "<span class='danger'>You suddenly feel very weak.</span>")
|
||||
|
||||
/datum/mutation/xray
|
||||
name = "X-Ray Vision"
|
||||
activation_messages = list("The walls suddenly disappear.")
|
||||
deactivation_messages = list("The walls around you re-appear.")
|
||||
instability = GENE_INSTABILITY_MAJOR
|
||||
traits_to_add = list(TRAIT_XRAY_VISION)
|
||||
activation_prob = 15
|
||||
|
||||
/datum/mutation/xray/New()
|
||||
..()
|
||||
block = GLOB.xrayblock
|
||||
|
||||
/datum/mutation/xray/activate(mob/living/M)
|
||||
..()
|
||||
M.update_sight()
|
||||
M.update_icons() //Apply eyeshine as needed.
|
||||
|
||||
/datum/mutation/xray/deactivate(mob/living/M)
|
||||
..()
|
||||
M.update_sight()
|
||||
M.update_icons() //Remove eyeshine as needed.
|
||||
|
||||
/datum/mutation/tk
|
||||
name = "Telekenesis"
|
||||
activation_messages = list("You feel smarter.")
|
||||
@@ -1181,3 +1159,58 @@
|
||||
else
|
||||
H.remoteview_target = null
|
||||
H.reset_perspective()
|
||||
|
||||
/datum/mutation/meson_vision
|
||||
name = "Meson Vision"
|
||||
activation_messages = list("More information seems to reach your eyes...")
|
||||
deactivation_messages = list("The amount of information reaching your eyes fades...")
|
||||
instability = GENE_INSTABILITY_MINOR
|
||||
traits_to_add = list(TRAIT_MESON_VISION)
|
||||
|
||||
/datum/mutation/meson_vision/New()
|
||||
..()
|
||||
block = GLOB.mesonblock
|
||||
|
||||
/datum/mutation/meson_vision/activate(mob/living/M)
|
||||
..()
|
||||
M.update_sight()
|
||||
|
||||
/datum/mutation/meson_vision/deactivate(mob/living/M)
|
||||
..()
|
||||
M.update_sight()
|
||||
|
||||
/datum/mutation/night_vision
|
||||
name = "Night Vision"
|
||||
activation_messages = list("Were the lights always that bright?")
|
||||
deactivation_messages = list("The ambient light level returns to normal...")
|
||||
instability = GENE_INSTABILITY_MODERATE
|
||||
traits_to_add = list(TRAIT_NIGHT_VISION)
|
||||
|
||||
/datum/mutation/night_vision/New()
|
||||
..()
|
||||
block = GLOB.nightvisionblock
|
||||
|
||||
/datum/mutation/night_vision/activate(mob/living/M)
|
||||
..()
|
||||
M.update_sight()
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.update_misc_effects()
|
||||
|
||||
/datum/mutation/night_vision/deactivate(mob/living/M)
|
||||
..()
|
||||
M.update_sight()
|
||||
if(ishuman(M))
|
||||
var/mob/living/carbon/human/H = M
|
||||
H.update_misc_effects()
|
||||
|
||||
/datum/mutation/flash_protection
|
||||
name = "Flash Protection"
|
||||
activation_messages = list("You stop noticing the glare from lights...")
|
||||
deactivation_messages = list("Lights begin glaring again...")
|
||||
instability = GENE_INSTABILITY_MINOR
|
||||
traits_to_add = list(TRAIT_FLASH_PROTECTION)
|
||||
|
||||
/datum/mutation/flash_protection/New()
|
||||
..()
|
||||
block = GLOB.noflashblock
|
||||
|
||||
@@ -40,7 +40,6 @@
|
||||
GLOB.hulkblock = getAssignedBlock("HULK", numsToAssign, DNA_HARD_BOUNDS, good=1)
|
||||
GLOB.teleblock = getAssignedBlock("TELE", numsToAssign, DNA_HARD_BOUNDS, good=1)
|
||||
GLOB.fireblock = getAssignedBlock("FIRE", numsToAssign, DNA_HARDER_BOUNDS, good=1)
|
||||
GLOB.xrayblock = getAssignedBlock("XRAY", numsToAssign, DNA_HARDER_BOUNDS, good=1)
|
||||
GLOB.clumsyblock = getAssignedBlock("CLUMSY", numsToAssign)
|
||||
GLOB.fakeblock = getAssignedBlock("FAKE", numsToAssign)
|
||||
GLOB.coughblock = getAssignedBlock("COUGH", numsToAssign)
|
||||
@@ -49,6 +48,10 @@
|
||||
GLOB.twitchblock = getAssignedBlock("TWITCH", numsToAssign)
|
||||
GLOB.nervousblock = getAssignedBlock("NERVOUS", numsToAssign)
|
||||
GLOB.wingdingsblock = getAssignedBlock("WINGDINGS", numsToAssign)
|
||||
GLOB.mesonblock = getAssignedBlock("MESONS", numsToAssign, good=1)
|
||||
GLOB.noflashblock = getAssignedBlock("NOFLASH", numsToAssign, DNA_HARDER_BOUNDS, good=1)
|
||||
GLOB.nightvisionblock = getAssignedBlock("NIGHTVISION", numsToAssign, DNA_HARDER_BOUNDS, good=1)
|
||||
|
||||
|
||||
// Bay muts
|
||||
GLOB.breathlessblock = getAssignedBlock("BREATHLESS", numsToAssign, DNA_HARD_BOUNDS, good=1)
|
||||
@@ -62,7 +65,6 @@
|
||||
GLOB.noprintsblock = getAssignedBlock("NOPRINTS", numsToAssign, DNA_HARD_BOUNDS, good=1)
|
||||
GLOB.shockimmunityblock = getAssignedBlock("SHOCKIMMUNITY", numsToAssign, good=1)
|
||||
GLOB.smallsizeblock = getAssignedBlock("SMALLSIZE", numsToAssign, DNA_HARD_BOUNDS, good=1)
|
||||
|
||||
//
|
||||
// Goon muts
|
||||
/////////////////////////////////////////////
|
||||
|
||||
@@ -170,28 +170,6 @@
|
||||
block = GLOB.hulkblock
|
||||
..()
|
||||
|
||||
/obj/item/dnainjector/xraymut
|
||||
name = "DNA-Injector (Xray)"
|
||||
desc = "Finally you can see what the Captain does."
|
||||
datatype = DNA2_BUF_SE
|
||||
value = 0xFFF
|
||||
forcedmutation = TRUE
|
||||
|
||||
/obj/item/dnainjector/xraymut/Initialize()
|
||||
block = GLOB.xrayblock
|
||||
..()
|
||||
|
||||
/obj/item/dnainjector/antixray
|
||||
name = "DNA-Injector (Anti-Xray)"
|
||||
desc = "It will make you see harder."
|
||||
datatype = DNA2_BUF_SE
|
||||
value = 0x001
|
||||
forcedmutation = TRUE
|
||||
|
||||
/obj/item/dnainjector/antixray/Initialize()
|
||||
block = GLOB.xrayblock
|
||||
..()
|
||||
|
||||
/obj/item/dnainjector/firemut
|
||||
name = "DNA-Injector (Fire)"
|
||||
desc = "Gives you fire."
|
||||
|
||||
@@ -716,7 +716,6 @@
|
||||
new /obj/item/stack/cable_coil(src)
|
||||
|
||||
new /obj/item/restraints/handcuffs(src)
|
||||
new /obj/item/dnainjector/xraymut(src)
|
||||
new /obj/item/dnainjector/firemut(src)
|
||||
new /obj/item/dnainjector/telemut(src)
|
||||
new /obj/item/dnainjector/hulkmut(src)
|
||||
|
||||
@@ -25,9 +25,6 @@
|
||||
H.dna.SetSEState(GLOB.hulkblock, TRUE)
|
||||
singlemutcheck(H, GLOB.hulkblock, MUTCHK_FORCED)
|
||||
|
||||
H.dna.SetSEState(GLOB.xrayblock, TRUE)
|
||||
singlemutcheck(H, GLOB.xrayblock, MUTCHK_FORCED)
|
||||
|
||||
H.dna.SetSEState(GLOB.fireblock, TRUE)
|
||||
singlemutcheck(H, GLOB.fireblock, MUTCHK_FORCED)
|
||||
|
||||
|
||||
@@ -79,8 +79,6 @@
|
||||
ADD_TRAIT(user, TRAIT_LASEREYES, "ww_wishgranter")
|
||||
user.dna.SetSEState(GLOB.fireblock, TRUE)
|
||||
singlemutcheck(user, GLOB.fireblock, MUTCHK_FORCED)
|
||||
user.dna.SetSEState(GLOB.xrayblock, TRUE)
|
||||
singlemutcheck(user, GLOB.xrayblock, MUTCHK_FORCED)
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/human = user
|
||||
if(!isshadowperson(human))
|
||||
|
||||
@@ -104,21 +104,7 @@
|
||||
new /obj/item/toy/katana(src)
|
||||
if(85 to 86)
|
||||
new /obj/item/defibrillator/compact(src)
|
||||
if(87) //1% chance
|
||||
new /obj/item/weed_extract(src)
|
||||
if(88)
|
||||
new /obj/item/organ/internal/brain(src)
|
||||
if(89)
|
||||
new /obj/item/organ/internal/brain/xeno(src)
|
||||
if(90)
|
||||
new /obj/item/organ/internal/heart(src)
|
||||
if(91)
|
||||
new /obj/item/soulstone/anybody(src)
|
||||
if(92)
|
||||
new /obj/item/katana(src)
|
||||
if(93)
|
||||
new /obj/item/dnainjector/xraymut(src)
|
||||
if(94)
|
||||
if(87 to 88)
|
||||
new /obj/item/storage/backpack/clown(src)
|
||||
new /obj/item/clothing/under/rank/clown(src)
|
||||
new /obj/item/clothing/shoes/clown_shoes(src)
|
||||
@@ -128,6 +114,18 @@
|
||||
new /obj/item/toy/crayon/rainbow(src)
|
||||
new /obj/item/reagent_containers/spray/waterflower(src)
|
||||
new /obj/item/reagent_containers/food/drinks/bottle/bottleofbanana(src)
|
||||
if(89) //1% chance
|
||||
new /obj/item/weed_extract(src)
|
||||
if(90)
|
||||
new /obj/item/organ/internal/brain(src)
|
||||
if(91)
|
||||
new /obj/item/organ/internal/brain/xeno(src)
|
||||
if(92)
|
||||
new /obj/item/organ/internal/heart(src)
|
||||
if(93)
|
||||
new /obj/item/soulstone/anybody(src)
|
||||
if(94)
|
||||
new /obj/item/katana(src)
|
||||
if(95)
|
||||
new /obj/item/clothing/under/mime(src)
|
||||
new /obj/item/clothing/shoes/black(src)
|
||||
|
||||
@@ -1205,6 +1205,14 @@ so that different stomachs can handle things in different ways VB*/
|
||||
sight |= (SEE_TURFS|SEE_MOBS|SEE_OBJS)
|
||||
see_in_dark = max(see_in_dark, 8)
|
||||
|
||||
if(HAS_TRAIT(src, TRAIT_MESON_VISION))
|
||||
sight |= SEE_TURFS
|
||||
lighting_alpha = min(lighting_alpha, LIGHTING_PLANE_ALPHA_MOSTLY_VISIBLE)
|
||||
|
||||
if(HAS_TRAIT(src, TRAIT_NIGHT_VISION))
|
||||
see_in_dark = max(see_in_dark, 8)
|
||||
lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE
|
||||
|
||||
SEND_SIGNAL(src, COMSIG_MOB_UPDATE_SIGHT)
|
||||
sync_lighting_plane_alpha()
|
||||
|
||||
|
||||
@@ -894,13 +894,21 @@ It'll return null if the organ doesn't correspond, so include null checks when u
|
||||
if(!isnull(H.vision_type.lighting_alpha))
|
||||
H.lighting_alpha = min(H.vision_type.lighting_alpha, H.lighting_alpha)
|
||||
|
||||
if(HAS_TRAIT(src, TRAIT_THERMAL_VISION))
|
||||
if(HAS_TRAIT(H, TRAIT_MESON_VISION))
|
||||
H.sight |= SEE_TURFS
|
||||
H.lighting_alpha = min(H.lighting_alpha, LIGHTING_PLANE_ALPHA_MOSTLY_VISIBLE)
|
||||
|
||||
if(HAS_TRAIT(H, TRAIT_THERMAL_VISION))
|
||||
H.sight |= (SEE_MOBS)
|
||||
H.lighting_alpha = min(H.lighting_alpha, LIGHTING_PLANE_ALPHA_MOSTLY_VISIBLE)
|
||||
|
||||
if(HAS_TRAIT(H, TRAIT_XRAY_VISION))
|
||||
H.sight |= (SEE_TURFS|SEE_MOBS|SEE_OBJS)
|
||||
|
||||
if(HAS_TRAIT(H, TRAIT_NIGHT_VISION))
|
||||
H.see_in_dark = max(H.see_in_dark, 8)
|
||||
H.lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE
|
||||
|
||||
if(H.has_status_effect(STATUS_EFFECT_SUMMONEDGHOST))
|
||||
H.see_invisible = SEE_INVISIBLE_OBSERVER
|
||||
|
||||
|
||||
@@ -760,7 +760,7 @@
|
||||
|
||||
//called when the mob receives a bright flash
|
||||
/mob/living/proc/flash_eyes(intensity = 1, override_blindness_check = 0, affect_silicon = 0, visual = 0, type = /obj/screen/fullscreen/flash)
|
||||
if(check_eye_prot() < intensity && (override_blindness_check || !HAS_TRAIT(src, TRAIT_BLIND)))
|
||||
if(check_eye_prot() < intensity && (override_blindness_check || !HAS_TRAIT(src, TRAIT_BLIND)) && !HAS_TRAIT(src, TRAIT_FLASH_PROTECTION))
|
||||
overlay_fullscreen("flash", type)
|
||||
addtimer(CALLBACK(src, .proc/clear_fullscreen, "flash", 25), 25)
|
||||
return 1
|
||||
|
||||
@@ -221,7 +221,7 @@
|
||||
return
|
||||
var/mob/living/carbon/human/H = user
|
||||
var/immune = istype(H.glasses, /obj/item/clothing/glasses/meson)
|
||||
if(!immune && (get_dist(user, src) < HALLUCINATION_RANGE(power)))
|
||||
if(!immune && !HAS_TRAIT(H, TRAIT_MESON_VISION) && (get_dist(user, src) < HALLUCINATION_RANGE(power)))
|
||||
. += "<span class='danger'>You get headaches just from looking at it.</span>"
|
||||
|
||||
/obj/machinery/power/supermatter_crystal/detailed_examine()
|
||||
@@ -537,7 +537,7 @@
|
||||
|
||||
//Makes em go mad and accumulate rads.
|
||||
for(var/mob/living/carbon/human/l in view(src, HALLUCINATION_RANGE(power))) // If they can see it without mesons on. Bad on them.
|
||||
if(!istype(l.glasses, /obj/item/clothing/glasses/meson))
|
||||
if(!istype(l.glasses, /obj/item/clothing/glasses/meson) && !HAS_TRAIT(l, TRAIT_MESON_VISION))
|
||||
var/D = sqrt(1 / max(1, get_dist(l, src)))
|
||||
l.hallucination += power * hallucination_power * D
|
||||
l.hallucination = clamp(l.hallucination, 0, 200)
|
||||
|
||||
Reference in New Issue
Block a user