diff --git a/code/modules/antagonists/vampire/vamp_datum.dm b/code/modules/antagonists/vampire/vamp_datum.dm index f7b83ed0f60..1c67aee91cb 100644 --- a/code/modules/antagonists/vampire/vamp_datum.dm +++ b/code/modules/antagonists/vampire/vamp_datum.dm @@ -21,7 +21,8 @@ /obj/effect/proc_holder/spell/vampire/glare = 0, /datum/vampire_passive/vision = 100, /obj/effect/proc_holder/spell/vampire/self/specialize = 150, - /datum/vampire_passive/regen = 200) + /datum/vampire_passive/regen = 200, + /datum/vampire_passive/vision/advanced = 500) /// list of the peoples UIDs that we have drained, and how much blood from each one var/list/drained_humans = list() @@ -65,14 +66,13 @@ /datum/antagonist/vampire/proc/force_add_ability(path) var/spell = new path(owner) + powers += spell if(istype(spell, /obj/effect/proc_holder/spell)) owner.AddSpell(spell) if(istype(spell, /datum/vampire_passive)) var/datum/vampire_passive/passive = spell passive.owner = owner.current passive.on_apply(src) - powers += spell - owner.current.update_sight() // Life updates conditionally, so we need to update sight here in case the vamp gets new vision based on his powers. Maybe one day refactor to be more OOP and on the vampire's ability datum. /datum/antagonist/vampire/proc/get_ability(path) for(var/datum/power as anything in powers) diff --git a/code/modules/antagonists/vampire/vampire_powers/umbrae_powers.dm b/code/modules/antagonists/vampire/vampire_powers/umbrae_powers.dm index 2ff82ba5137..f00aa187994 100644 --- a/code/modules/antagonists/vampire/vampire_powers/umbrae_powers.dm +++ b/code/modules/antagonists/vampire/vampire_powers/umbrae_powers.dm @@ -324,5 +324,8 @@ if(!V.bloodusable || owner.stat == DEAD) V.remove_ability(src) -/datum/vampire_passive/xray +/datum/vampire_passive/vision/xray gain_desc = "You can now see through walls, incase you hadn't noticed." + lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE + see_in_dark = 8 + vision_flags = SEE_TURFS|SEE_MOBS|SEE_OBJS diff --git a/code/modules/antagonists/vampire/vampire_powers/vampire_powers.dm b/code/modules/antagonists/vampire/vampire_powers/vampire_powers.dm index ae23fbcb2d8..f086e274cf4 100644 --- a/code/modules/antagonists/vampire/vampire_powers/vampire_powers.dm +++ b/code/modules/antagonists/vampire/vampire_powers/vampire_powers.dm @@ -45,6 +45,7 @@ return ..() /datum/vampire_passive/proc/on_apply(datum/antagonist/vampire/V) + owner.update_sight() // Life updates conditionally, so we need to update sight here in case the vamp gets new vision based on his powers. Maybe one day refactor to be more OOP and on the vampire's ability datum. return /obj/effect/proc_holder/spell/vampire/self/rejuvenate @@ -256,9 +257,24 @@ /datum/vampire_passive/vision gain_desc = "Your vampiric vision has improved." + var/lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_VISIBLE + var/see_in_dark = 1 + var/vision_flags = SEE_MOBS + +/datum/vampire_passive/vision/advanced + gain_desc = "Your vampiric vision now allows you to see everything in the dark!" + lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_VISIBLE + see_in_dark = 3 + vision_flags = SEE_MOBS + +/datum/vampire_passive/vision/full + gain_desc = "Your vampiric vision has reached its full strength!" + lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE + see_in_dark = 6 + vision_flags = SEE_MOBS /datum/vampire_passive/full - gain_desc = "You have reached your full potential. You are no longer weak to the effects of anything holy and your vision has improved greatly." + gain_desc = "You have reached your full potential. You are no longer weak to the effects of anything holy." /obj/effect/proc_holder/spell/vampire/raise_vampires name = "Raise Vampires" diff --git a/code/modules/antagonists/vampire/vampire_subclasses.dm b/code/modules/antagonists/vampire/vampire_subclasses.dm index 2d05d0cb6b8..9d9282f1cc7 100644 --- a/code/modules/antagonists/vampire/vampire_subclasses.dm +++ b/code/modules/antagonists/vampire/vampire_subclasses.dm @@ -30,8 +30,9 @@ /obj/effect/proc_holder/spell/vampire/vamp_extinguish = 600, /obj/effect/proc_holder/spell/vampire/shadow_boxing = 800) fully_powered_abilities = list(/datum/vampire_passive/full, + /datum/vampire_passive/vision/full, /obj/effect/proc_holder/spell/vampire/self/eternal_darkness, - /datum/vampire_passive/xray) + /datum/vampire_passive/vision/xray) /datum/vampire_subclass/hemomancer name = "hemomancer" @@ -42,6 +43,7 @@ /obj/effect/proc_holder/spell/vampire/predator_senses = 600, /obj/effect/proc_holder/spell/vampire/blood_eruption = 800) fully_powered_abilities = list(/datum/vampire_passive/full, + /datum/vampire_passive/vision/full, /obj/effect/proc_holder/spell/vampire/self/blood_spill) /datum/vampire_subclass/gargantua @@ -53,6 +55,7 @@ /obj/effect/proc_holder/spell/vampire/self/overwhelming_force = 600, /obj/effect/proc_holder/spell/fireball/demonic_grasp = 800) fully_powered_abilities = list(/datum/vampire_passive/full, + /datum/vampire_passive/vision/full, /obj/effect/proc_holder/spell/vampire/charge) improved_rejuv_healing = TRUE @@ -69,6 +72,7 @@ /obj/effect/proc_holder/spell/vampire/self/share_damage = 800) fully_powered_abilities = list(/datum/vampire_passive/full, /obj/effect/proc_holder/spell/vampire/hysteria, + /datum/vampire_passive/vision/full, /datum/vampire_passive/increment_thrall_cap/three) @@ -100,11 +104,12 @@ /obj/effect/proc_holder/spell/fireball/demonic_grasp, /obj/effect/proc_holder/spell/vampire/shadow_boxing, /datum/vampire_passive/full, + /datum/vampire_passive/vision/full, /obj/effect/proc_holder/spell/vampire/self/blood_spill, /obj/effect/proc_holder/spell/vampire/charge, /obj/effect/proc_holder/spell/vampire/self/eternal_darkness, /obj/effect/proc_holder/spell/vampire/hysteria, /obj/effect/proc_holder/spell/vampire/raise_vampires, - /datum/vampire_passive/xray) + /datum/vampire_passive/vision/xray) improved_rejuv_healing = TRUE thrall_cap = 150 // can thrall high pop diff --git a/code/modules/mob/living/carbon/human/species/_species.dm b/code/modules/mob/living/carbon/human/species/_species.dm index d6060c0aa81..e301ae1ad82 100644 --- a/code/modules/mob/living/carbon/human/species/_species.dm +++ b/code/modules/mob/living/carbon/human/species/_species.dm @@ -948,18 +948,10 @@ It'll return null if the organ doesn't correspond, so include null checks when u var/datum/antagonist/vampire/V = H.mind?.has_antag_datum(/datum/antagonist/vampire) if(V) - if(V.get_ability(/datum/vampire_passive/xray)) - H.sight |= SEE_TURFS|SEE_MOBS|SEE_OBJS - H.see_in_dark += 8 - H.lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE - else if(V.get_ability(/datum/vampire_passive/full)) - H.sight |= SEE_MOBS - H.see_in_dark += 8 - H.lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_INVISIBLE - else if(V.get_ability(/datum/vampire_passive/vision)) - H.sight |= SEE_MOBS - H.see_in_dark += 1 // base of 2, 2+1 is 3 - H.lighting_alpha = LIGHTING_PLANE_ALPHA_MOSTLY_VISIBLE + for(var/datum/vampire_passive/vision/buffs in V.powers) + H.sight |= buffs.vision_flags + H.see_in_dark += buffs.see_in_dark + H.lighting_alpha = buffs.lighting_alpha // my glasses, I can't see without my glasses if(H.glasses)