Ports (most(ok like half)) station traits from tg. Ready for review into TM (#22334)

* no longer super sick time to port station traits in a 4 hour rush as you have lost control of your life

* some changes /fixes

* Apply suggestions from code review

Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com>
Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>

* more changes

* oh right, the murders (uplink price tweaks)

* Update code/controllers/subsystem/SSjobs.dm

Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com>

* compiles

* doesnt work but works better

* tgui dogs still sleep but I want to sleep

* it should finally compile now. Probably.

* Update tgui.bundle.js

* Sorry IAN, transfer components is shoddy as hell

* removes minor uneeded /tgui

* also extra line whoops

* final stuff

* reverting changes I made earlier is hard ok

* Weight change, uplink reference

* oh right, the hey fucko

* Update code/_globalvars/traits.dm

Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com>

* Update tgui.bundle.js

* pushes

* pulls it

* Apply suggestions from code review

Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>

* more changes, ion rifle blocked on cyb revolution

* dipshit remove the debug / tgui pritier and such

* tgui

* updates tgui again as nanomap was merged

* Apply suggestions from code review

Co-authored-by: Ryan <80364400+Sirryan2002@users.noreply.github.com>

* comment / tgui

* every day I worry all day

* Full TGUI rebuild + prettier

* ah fuck

* leave a customer feedback at the link below!

* tgui momenr

* tgui moment

* FUCK I am dumb

* vertical TGUI

* She T's on my GUI till I

* Update tgui.bundle.js

* Apply suggestions from code review

Co-authored-by: Gaxeer <44334376+Gaxeer@users.noreply.github.com>

* Update code/modules/supply/supply_pack.dm

Co-authored-by: Gaxeer <44334376+Gaxeer@users.noreply.github.com>

* IPC can now use robotic hearts / pulse demon hearts and charge

* fixes revert not working for hangover / arrivals

* tgui moment

* hhgreg

* fixes that one bug

* Every day I worry all day

* deconflicted for real this t ime

* Update code/datums/station_traits/postive_traits.dm

Co-authored-by: Ryan <80364400+Sirryan2002@users.noreply.github.com>

* ch-ch-ch-changes

* Update SSjobs.dm

* Update code/modules/supply/supply_pack.dm

Co-authored-by: Ryan <80364400+Sirryan2002@users.noreply.github.com>

* deconflicted but won't pass CI

* fixes double dipping on traits

* my le consoles, they le no work?

* Great Great Asset, Asset, Great Great Asset, Asset...

* sorry slime mains

* fixes borgs being punished heavier

* actually fixes it, I was dense

* hopefully fixes borg drunk further

* makes it compile?

* actually makes it compile god whyyyy

---------

Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com>
Co-authored-by: Contrabang <91113370+Contrabang@users.noreply.github.com>
Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com>
Co-authored-by: Ryan <80364400+Sirryan2002@users.noreply.github.com>
Co-authored-by: SteelSlayer <42044220+SteelSlayer@users.noreply.github.com>
Co-authored-by: Gaxeer <44334376+Gaxeer@users.noreply.github.com>
This commit is contained in:
Qwertytoforty
2024-01-08 14:07:09 -05:00
committed by GitHub
parent 2c7a9b3078
commit d668a29a60
51 changed files with 1632 additions and 47 deletions
@@ -168,6 +168,14 @@
"" = 61 // This should be a decently high number for chances where no loot will spawn
)
/obj/effect/spawner/lootdrop/maintenance/Initialize(mapload)
if(HAS_TRAIT(SSstation, STATION_TRAIT_EMPTY_MAINT) && prob(50))
return qdel(src)
if(HAS_TRAIT(SSstation, STATION_TRAIT_FILLED_MAINT) && prob(50))
lootcount = min(lootcount * 2, 12)
. = ..()
/obj/effect/spawner/lootdrop/maintenance/two
name = "maintenance loot spawner (2 items)"
icon_state = "doubleloot"
@@ -24,12 +24,20 @@ AI MODULES
/obj/item/aiModule/Initialize(mapload)
. = ..()
if(mapload && HAS_TRAIT(SSstation, STATION_TRAIT_UNIQUE_AI) && is_station_level(z))
var/delete_module = handle_unique_ai()
if(delete_module)
return INITIALIZE_HINT_QDEL
if(laws)
desc += "<br>"
for(var/datum/ai_law/current in laws.inherent_laws)
desc += current.law
desc += "<br>"
///what this module should do if it is mapload spawning on a unique AI station trait round.
/obj/item/aiModule/proc/handle_unique_ai()
return TRUE // If this returns true, it will be deleted on roundstart
/obj/item/aiModule/proc/install(obj/machinery/computer/C)
if(istype(C, /obj/machinery/computer/aiupload))
var/obj/machinery/computer/aiupload/comp = C
@@ -241,6 +249,9 @@ AI MODULES
to_chat(target, "<span class='boldnotice'>[sender.real_name] attempted to reset your laws using a reset module.</span>")
target.show_laws()
/obj/item/aiModule/reset/handle_unique_ai()
return FALSE
/******************** Purge ********************/
/obj/item/aiModule/purge // -- TLE
name = "\improper Purge AI module"
@@ -144,6 +144,7 @@
return
/obj/item/bio_chip/proc/activate(cause)
SEND_SIGNAL(src, COMSIG_IMPLANT_ACTIVATED, cause, imp_in)
return
/obj/item/bio_chip/ui_action_click()
@@ -200,6 +201,7 @@
if(user)
add_attack_logs(user, source, "Chipped with [src]")
SEND_SIGNAL(src, COMSIG_IMPLANT_IMPLANTED, source, user, force)
return 1
/**
@@ -237,6 +239,7 @@
unregister_emotes()
SEND_SIGNAL(src, COMSIG_IMPLANT_REMOVED, source)
return TRUE
/obj/item/bio_chip/dropped(mob/user)
@@ -0,0 +1,76 @@
/datum/deathrattle_group
var/name
var/list/implants = list()
/datum/deathrattle_group/New(name)
if(name)
src.name = name
else
// Give the group a unique name for debugging, and possible future
// use for making custom linked groups.
src.name = "[rand(100, 999)] [pick(GLOB.phonetic_alphabet)]"
/*
* Proc called by new implant being added to the group. Listens for the
* implant being implanted, removed and destroyed.
*
* If implant is already implanted in a person, then trigger the implantation
* code.
*/
/datum/deathrattle_group/proc/register(obj/item/bio_chip/deathrattle/implant)
if(implant in implants)
return
RegisterSignal(implant, COMSIG_PARENT_QDELETING, PROC_REF(on_implant_destruction))
RegisterSignal(implant, COMSIG_IMPLANT_ACTIVATED, PROC_REF(on_user_death))
implants += implant
/datum/deathrattle_group/proc/on_implant_destruction(obj/item/bio_chip/implant)
SIGNAL_HANDLER
implants -= implant
/datum/deathrattle_group/proc/on_user_death(obj/item/bio_chip/implant, source, mob/owner)
SIGNAL_HANDLER
var/victim_name = owner.mind ? owner.mind.name : owner.real_name
// All "hearers" hear the same sound.
var/sound = pick(
'sound/items/knell1.ogg',
'sound/items/knell2.ogg',
'sound/items/knell3.ogg',
'sound/items/knell4.ogg',
)
for(var/obj/item/bio_chip/deathrattle/other_implant as anything in implants)
// Skip the unfortunate soul, and any unimplanted implants
if(implant == other_implant || !implant.imp_in)
continue
var/mob/living/recipient = other_implant.imp_in
to_chat(recipient, "<i>You hear a strange, robotic voice in your head...</i> <span class='robot'>\"<b>[victim_name]</b> has died...\"</span>")
recipient.playsound_local(get_turf(recipient), sound, vol = 75, vary = FALSE, pressure_affected = FALSE, use_reverb = FALSE)
qdel(implant)
/obj/item/bio_chip/deathrattle
name = "deathrattle implant"
desc = "Hope no one else dies, prepare for when they do."
activated = BIOCHIP_ACTIVATED_PASSIVE
trigger_causes = BIOCHIP_TRIGGER_DEATH_ONCE
implant_data = /datum/implant_fluff/deathrattle
implant_state = "implant-nanotrasen"
actions_types = null
/obj/item/bio_chip/deathrattle/emp_act(severity)
activate("emp")
/obj/item/bio_chip/deathrattle/death_trigger(mob/source, gibbed)
activate("death")
/obj/item/bio_chip_case/deathrattle
name = "implant case - 'Deathrattle'"
desc = "A glass case containing a deathrattle implant."
implant_type = /obj/item/bio_chip/deathrattle
@@ -134,3 +134,8 @@
life = "Unknown. No collected sample has been active long enough to determine lifespan."
notes = "Manually activated by the user."
function = "Allows the user to summon a box from a bluespace pocket located inside the implant. The exterior of this box is lined with experimental cloaking panels which render the box invisible to the naked eye."
/datum/implant_fluff/deathrattle
name = "BioTech Solutions \"Dead Ringer\" Death Ratttle Bio-chip"
notes = "Alerts implanted crew to crewmember death."
function = "Contains a compact radio signaler that triggers when the host's lifesigns cease, only sent to other implanted in the group."
@@ -48,9 +48,15 @@
/obj/item/storage/box/survival/populate_contents()
new /obj/item/clothing/mask/breath(src)
new /obj/item/tank/internals/emergency_oxygen(src)
new /obj/item/reagent_containers/hypospray/autoinjector/epinephrine(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
if(HAS_TRAIT(SSstation, STATION_TRAIT_PREMIUM_INTERNALS))
new /obj/item/tank/internals/emergency_oxygen/engi(src)
new /obj/item/reagent_containers/hypospray/autoinjector/survival(src)
new /obj/item/flashlight/flare(src)
else
new /obj/item/tank/internals/emergency_oxygen(src)
new /obj/item/reagent_containers/hypospray/autoinjector/epinephrine(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
/obj/item/storage/box/survival_vox
icon_state = "vox_box"
@@ -58,8 +64,12 @@
/obj/item/storage/box/survival_vox/populate_contents()
new /obj/item/clothing/mask/breath/vox(src)
new /obj/item/tank/internals/emergency_oxygen/nitrogen(src)
new /obj/item/reagent_containers/hypospray/autoinjector/epinephrine(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
if(HAS_TRAIT(SSstation, STATION_TRAIT_PREMIUM_INTERNALS))
new /obj/item/reagent_containers/hypospray/autoinjector/survival(src)
new /obj/item/flashlight/flare(src)
else
new /obj/item/reagent_containers/hypospray/autoinjector/epinephrine(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
/obj/item/storage/box/survival_plasmaman
icon_state = "plasma_box"
@@ -67,26 +77,40 @@
/obj/item/storage/box/survival_plasmaman/populate_contents()
new /obj/item/clothing/mask/breath(src)
new /obj/item/tank/internals/emergency_oxygen/plasma(src)
new /obj/item/reagent_containers/hypospray/autoinjector/epinephrine(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
if(HAS_TRAIT(SSstation, STATION_TRAIT_PREMIUM_INTERNALS))
new /obj/item/reagent_containers/hypospray/autoinjector/survival(src)
new /obj/item/flashlight/flare(src)
else
new /obj/item/reagent_containers/hypospray/autoinjector/epinephrine(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
/obj/item/storage/box/engineer
icon_state = "eng_box"
/obj/item/storage/box/engineer/populate_contents()
new /obj/item/clothing/mask/breath(src)
new /obj/item/tank/internals/emergency_oxygen/engi(src)
new /obj/item/reagent_containers/hypospray/autoinjector/epinephrine(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
if(HAS_TRAIT(SSstation, STATION_TRAIT_PREMIUM_INTERNALS))
new /obj/item/tank/internals/emergency_oxygen/double(src)
new /obj/item/reagent_containers/hypospray/autoinjector/survival(src)
new /obj/item/flashlight/flare(src)
else
new /obj/item/tank/internals/emergency_oxygen/engi(src)
new /obj/item/reagent_containers/hypospray/autoinjector/epinephrine(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
/obj/item/storage/box/survival_mining
icon_state = "min_box"
/obj/item/storage/box/survival_mining/populate_contents()
new /obj/item/clothing/mask/gas/explorer(src)
new /obj/item/tank/internals/emergency_oxygen/engi(src)
new /obj/item/reagent_containers/hypospray/autoinjector/epinephrine(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
if(HAS_TRAIT(SSstation, STATION_TRAIT_PREMIUM_INTERNALS))
new /obj/item/tank/internals/emergency_oxygen/double(src)
new /obj/item/reagent_containers/hypospray/autoinjector/survival(src)
new /obj/item/flashlight/flare(src)
else
new /obj/item/tank/internals/emergency_oxygen/engi(src)
new /obj/item/reagent_containers/hypospray/autoinjector/epinephrine(src)
new /obj/item/flashlight/flare/glowstick/emergency(src)
/obj/item/storage/box/survival_syndi
icon_state = "syndi_box"