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
+2 -1
View File
@@ -109,7 +109,8 @@ GLOBAL_LIST_INIT(admin_verbs_event, list(
/client/proc/outfit_manager,
/client/proc/cmd_admin_headset_message,
/client/proc/change_human_appearance_admin, /* Allows an admin to change the basic appearance of human-based mobs */
/client/proc/change_human_appearance_self /* Allows the human-based mob itself to change its basic appearance */
/client/proc/change_human_appearance_self, /* Allows the human-based mob itself to change its basic appearance */
/datum/admins/proc/station_traits_panel
))
GLOBAL_LIST_INIT(admin_verbs_spawn, list(
@@ -47,6 +47,8 @@
var/light_range_on = 1
var/light_power_on = 0.5
/// Do we drop contents on destroy?
var/drop_contents_on_delete = TRUE
/obj/machinery/smartfridge/Initialize(mapload)
. = ..()
@@ -92,8 +94,9 @@
/obj/machinery/smartfridge/Destroy()
SStgui.close_uis(wires)
QDEL_NULL(wires)
for(var/atom/movable/A in contents)
A.forceMove(loc)
if(drop_contents_on_delete)
for(var/atom/movable/A in contents)
A.forceMove(loc)
return ..()
/obj/machinery/smartfridge/process()
@@ -527,6 +530,9 @@
/obj/machinery/smartfridge/secure/circuits/aiupload/Initialize(mapload)
. = ..()
req_access_txt = "[ACCESS_AI_UPLOAD]"
if(mapload && HAS_TRAIT(SSstation, STATION_TRAIT_UNIQUE_AI) && is_station_level(z))
drop_contents_on_delete = FALSE
return INITIALIZE_HINT_QDEL
/obj/machinery/smartfridge/secure/circuits/aiupload/experimental
name = "\improper Experimental Laws Storage"
@@ -138,3 +138,6 @@
/obj/item/organ/internal/regenerative_core/legion/preserved(implanted = 0)
..()
desc = "[src] has been stabilized. It is preserved, allowing you to use it to heal completely without danger of decay."
/obj/item/organ/internal/regenerative_core/legion/already_preserved
preserved = TRUE
@@ -126,7 +126,9 @@
laws.sort_laws()
/mob/living/silicon/proc/make_laws()
if(GLOB.configuration.general.random_ai_lawset)
if(HAS_TRAIT(SSstation, STATION_TRAIT_UNIQUE_AI))
laws = pick_unique_lawset()
else if(GLOB.configuration.general.random_ai_lawset)
laws = get_random_lawset()
else
laws = new /datum/ai_laws/crewsimov()
@@ -140,3 +142,15 @@
continue
law_options += L
return pick(law_options)
///returns a random non starting / kill crew lawset if the station has a unique ai lawset
/proc/pick_unique_lawset()
var/list/law_options = list()
var/paths = subtypesof(/datum/ai_laws)
for(var/law in paths)
var/datum/ai_laws/L = new law
if(!L.unique_ai)
continue
law_options += L
return pick(law_options)
@@ -55,6 +55,8 @@
deploy_the_cats()
/mob/living/simple_animal/pet/cat/Runtime/persistent_save()
if(SEND_SIGNAL(src, COMSIG_LIVING_WRITE_MEMORY) & COMPONENT_DONT_WRITE_MEMORY)
return FALSE
write_memory(FALSE)
/mob/living/simple_animal/pet/cat/Runtime/make_babies()
@@ -486,6 +486,8 @@
turns_per_move = 20
/mob/living/simple_animal/pet/dog/corgi/Ian/persistent_save()
if(SEND_SIGNAL(src, COMSIG_LIVING_WRITE_MEMORY) & COMPONENT_DONT_WRITE_MEMORY)
return FALSE
write_memory(FALSE)
/mob/living/simple_animal/pet/dog/corgi/Ian/proc/read_memory()
+7 -5
View File
@@ -369,12 +369,14 @@ GLOBAL_LIST_EMPTY(PDAs)
/obj/item/pda/proc/play_ringtone()
var/S
if(ttone in ttone_sound)
S = ttone_sound[ttone]
if(HAS_TRAIT(SSstation, STATION_TRAIT_PDA_GLITCHED))
playsound(src, pick('sound/machines/twobeep_voice1.ogg', 'sound/machines/twobeep_voice2.ogg'), 50, TRUE)
else
S = 'sound/machines/twobeep_high.ogg'
playsound(loc, S, 50, 1)
if(ttone in ttone_sound)
S = ttone_sound[ttone]
else
S = 'sound/machines/twobeep_high.ogg'
playsound(loc, S, 50, TRUE)
for(var/mob/O in hearers(3, loc))
O.show_message(text("[bicon(src)] *[ttone]*"))
@@ -19,6 +19,11 @@
flight_x_offset = 17
flight_y_offset = 9
/obj/item/gun/energy/ionrifle/Initialize(mapload)
. = ..()
if(mapload && HAS_TRAIT(SSstation, STATION_TRAIT_CYBERNETIC_REVOLUTION) && is_station_level(z)) //No ion rifle when everyone has cybernetic organs, sorry!
return INITIALIZE_HINT_QDEL
/obj/item/gun/energy/ionrifle/emp_act(severity)
return
+8 -8
View File
@@ -104,7 +104,7 @@
"supply_type" = order.object.name,
"orderedby" = order.orderedby,
"department" = order.ordered_by_department?.department_name,
"cost" = order.object.cost,
"cost" = order.object.get_cost(),
"comment" = order.comment,
"req_cargo_approval" = order.requires_cargo_approval,
"req_head_approval" = order.requires_head_approval,
@@ -214,7 +214,7 @@
if((pack.hidden && hacked) || (pack.contraband && can_order_contraband) || (pack.special && pack.special_enabled) || (!pack.contraband && !pack.hidden && !pack.special))
packs_list.Add(list(list(
"name" = pack.name,
"cost" = pack.cost,
"cost" = pack.get_cost(),
"ref" = "[pack.UID()]",
"contents" = pack.ui_manifest,
"cat" = pack.group)))
@@ -333,12 +333,12 @@
order.orderedbyaccount = selected_account
if(attempt_account_authentification(selected_account, user))
var/paid_for = FALSE
if(!order.requires_cargo_approval && pay_with_account(selected_account, order.object.cost, "[order.object.name] Crate Purchase", "Cargo Requests Console", user, account_database.vendor_account))
if(!order.requires_cargo_approval && pay_with_account(selected_account, order.object.get_cost(), "[order.object.name] Crate Purchase", "Cargo Requests Console", user, account_database.vendor_account))
paid_for = TRUE
SSeconomy.process_supply_order(order, paid_for) //add order to shopping list
else //if its a department account with pin or higher security or need QM approval, go ahead and add this to the departments section in request list
SSeconomy.process_supply_order(order, FALSE)
if(order.ordered_by_department.crate_auto_approve && order.ordered_by_department.auto_approval_cap >= order.object.cost)
if(order.ordered_by_department.crate_auto_approve && order.ordered_by_department.auto_approval_cap >= order.object.get_cost())
approve_crate(user, order.ordernum)
investigate_log("| [key_name(user)] has placed an order for [order.object.amount] [order.object.name] with reason: '[order.comment]'", "cargo")
@@ -355,7 +355,7 @@
return FALSE
order.requires_cargo_approval = FALSE
if(account.account_type == ACCOUNT_TYPE_PERSONAL || isnull(order.ordered_by_department))
if(pay_with_account(account, order.object.cost, "[pack.name] Crate Purchase", "Cargo Requests Console", user, account_database.vendor_account))
if(pay_with_account(account, order.object.get_cost(), "[pack.name] Crate Purchase", "Cargo Requests Console", user, account_database.vendor_account))
SSeconomy.process_supply_order(order, TRUE) //send 'er back through
return TRUE
atom_say("ERROR: Account tied to order cannot pay, auto-denying order")
@@ -368,12 +368,12 @@
//if they do not have access to this account
if(!department_order.ordered_by_department.has_account_access(user.get_access(), user.get_worn_id_account()))
//and the dept account doesn't have auto approve enabled (or does and the crate is too expensive for auto approve)
if(!department_order.ordered_by_department.crate_auto_approve || department_order.ordered_by_department.auto_approval_cap < pack.cost)
if(!department_order.ordered_by_department.crate_auto_approve || department_order.ordered_by_department.auto_approval_cap < pack.get_cost())
return //no access!
///just give the account pin here, its too much work for players to get the department account pin number since approval is access locked anyway
if(attempt_account_authentification(account, user, account.account_pin))
if(pay_with_account(account, pack.cost, "[pack.name] Crate Purchase", "[src]", user, account_database.vendor_account))
if(pay_with_account(account, pack.get_cost(), "[pack.name] Crate Purchase", "[src]", user, account_database.vendor_account))
order.requires_head_approval = FALSE
SSeconomy.process_supply_order(order, TRUE)
investigate_log("| [key_name(user)] has authorized an order for [pack.name]. Remaining Cargo Balance: [cargo_account.credit_balance].", "cargo")
@@ -418,7 +418,7 @@
SSshuttle.supply.request(SSshuttle.getDock("supply_home"))
/obj/machinery/computer/supplycomp/proc/pay_for_crate(datum/money_account/customer_account, mob/user, datum/supply_order/order)
if(pay_with_account(customer_account, order.object.cost, "Purchase of [order.object.name]", "Cargo Requests Console", user, cargo_account, TRUE))
if(pay_with_account(customer_account, order.object.get_cost(), "Purchase of [order.object.name]", "Cargo Requests Console", user, cargo_account, TRUE))
return TRUE
return FALSE
+1 -1
View File
@@ -34,7 +34,7 @@
//create the manifest slip
var/obj/item/paper/manifest/slip = new
slip.points = object.cost
slip.points = object.get_cost()
slip.ordernumber = ordernum
var/stationName = station_name()
+3
View File
@@ -59,3 +59,6 @@
if(length(contains))
for(var/j in 1 to num_contained)
. += pick(contains)
/datum/supply_packs/proc/get_cost()
return cost * SSeconomy.pack_price_modifier
+6 -1
View File
@@ -387,7 +387,12 @@
user.changeNext_move(CLICK_CD_MELEE)
var/obj/machinery/power/apc/A = target
var/mob/living/carbon/human/H = user
if(H.get_int_organ(/obj/item/organ/internal/cell))
if(H.get_int_organ(/obj/item/organ/internal/cell) || H.get_int_organ(/obj/item/organ/internal/heart))
var/obj/item/organ/internal/heart/robotic = H.get_int_organ(/obj/item/organ/internal/heart)
if(robotic)
if(!(robotic.status & ORGAN_ROBOT) && !H.get_int_organ(/obj/item/organ/internal/heart/demon/pulse))
to_chat(user, "<span class='warning'>You lack a cell in which to store charge!</span>")
return
if(A.emagged || A.stat & BROKEN)
do_sparks(3, 1, A)
to_chat(H, "<span class='warning'>The APC power currents surge erratically, damaging your chassis!</span>")