From fb1de565704ca19448db4f9fe92c6337c446cc7c Mon Sep 17 00:00:00 2001 From: Lexanx <61974560+Lexanx@users.noreply.github.com> Date: Thu, 1 Aug 2024 01:56:03 +0300 Subject: [PATCH] Fixes --- code/game/antagonist/antagonist.dm | 2 +- code/game/atoms.dm | 10 ++++++++ code/game/machinery/robotics_fabricator.dm | 2 +- code/modules/research/rdconsole.dm | 2 +- code/modules/surgery/robotics.dm | 13 +++++----- mods/ipc_mods/code/ipc.dm | 30 ++++++++++++---------- 6 files changed, 37 insertions(+), 22 deletions(-) diff --git a/code/game/antagonist/antagonist.dm b/code/game/antagonist/antagonist.dm index 9bed61b5f9f62..bd80849f1ee54 100644 --- a/code/game/antagonist/antagonist.dm +++ b/code/game/antagonist/antagonist.dm @@ -55,7 +55,7 @@ var/datum/language/required_language = null // Used for setting appearance. - var/list/valid_species = list(SPECIES_UNATHI,SPECIES_SKRELL,SPECIES_HUMAN,SPECIES_VOX) + var/list/valid_species = list(SPECIES_UNATHI,SPECIES_SKRELL,SPECIES_HUMAN,SPECIES_VOX,SPECIES_DIONA,SPECIES_IPC) var/min_player_age = 14 // Runtime vars. diff --git a/code/game/atoms.dm b/code/game/atoms.dm index 303f3d1cbc0c2..6df96f675fe02 100644 --- a/code/game/atoms.dm +++ b/code/game/atoms.dm @@ -362,6 +362,16 @@ return A.loc A = A.loc + + +/atom/proc/drop_location() + var/atom/L = loc + if(!L) + return null + return L.AllowDrop() ? L : L.drop_location() + + + /** * Called when a user examines the atom. This proc and its overrides handle displaying the text that appears in chat * during examines. diff --git a/code/game/machinery/robotics_fabricator.dm b/code/game/machinery/robotics_fabricator.dm index 7b0773770b6c1..c61a732440290 100644 --- a/code/game/machinery/robotics_fabricator.dm +++ b/code/game/machinery/robotics_fabricator.dm @@ -338,8 +338,8 @@ for(var/obj/machinery/computer/rdconsole/RDC in get_area_all_atoms(get_area(src))) if(!RDC.sync) continue - files.download_from(RDC.files) //[SIERRA-EDIT] - MODPACK_RND + files = RDC.files sync_message = "Sync complete." update_categories() //[/SIERRA-EDIT] - MODPACK_RND diff --git a/code/modules/research/rdconsole.dm b/code/modules/research/rdconsole.dm index 79554bc090033..95465f6293184 100644 --- a/code/modules/research/rdconsole.dm +++ b/code/modules/research/rdconsole.dm @@ -350,7 +350,7 @@ won't update every console in existence) but it's more of a hassle to do. Also, search_text = "" if(href_list["eject_disk"]) // User is ejecting the disk. if(disk) - disk.forceMove(src.loc) + disk.forceMove(drop_location()) disk = null if(href_list["delete_disk_file"]) // User is attempting to delete a file from the loaded disk. if(disk) diff --git a/code/modules/surgery/robotics.dm b/code/modules/surgery/robotics.dm index cb420de843231..a7360386ffb35 100644 --- a/code/modules/surgery/robotics.dm +++ b/code/modules/surgery/robotics.dm @@ -20,9 +20,9 @@ /singleton/surgery_step/robotics/success_chance(mob/living/user, mob/living/carbon/human/target, obj/item/tool) . = ..() - if(!user.skill_check(SKILL_DEVICES, SKILL_TRAINED)) + if(!user.skill_check(SKILL_DEVICES, SKILL_BASIC)) . -= 30 - if(!user.skill_check(SKILL_DEVICES, SKILL_EXPERIENCED)) + if(!user.skill_check(SKILL_DEVICES, SKILL_TRAINED)) . -= 20 if(user.skill_check(SKILL_DEVICES, SKILL_EXPERIENCED)) . += 35 @@ -398,10 +398,11 @@ for(var/obj/item/organ/I in affected.internal_organs) if(I && I.damage > 0) if(BP_IS_ROBOTIC(I)) - user.visible_message("[user] starts mending the damage to [target]'s [I.name]'s mechanisms.", \ - "You start mending the damage to [target]'s [I.name]'s mechanisms." ) - playsound(target.loc, 'sound/items/bonegel.ogg', 50, TRUE) - ..() + if(!((I.organ_tag == BP_BRAIN) && (I.status == ORGAN_DEAD))) + user.visible_message("[user] starts mending the damage to [target]'s [I.name]'s mechanisms.", \ + "You start mending the damage to [target]'s [I.name]'s mechanisms." ) + playsound(target.loc, 'sound/items/bonegel.ogg', 50, TRUE) + ..() /singleton/surgery_step/robotics/fix_organ_robotic/end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool) var/obj/item/organ/external/affected = target.get_organ(target_zone) diff --git a/mods/ipc_mods/code/ipc.dm b/mods/ipc_mods/code/ipc.dm index e9140a0d6c5ed..f11a177e29c9d 100644 --- a/mods/ipc_mods/code/ipc.dm +++ b/mods/ipc_mods/code/ipc.dm @@ -4,19 +4,23 @@ // Ремонт позитронного мозга /obj/item/organ/internal/posibrain/use_tool(obj/item/stack/nanopaste, mob/living/user, list/click_params) . = ..() - if(src.damage > src.max_damage) - to_chat(user, SPAN_WARNING("[src] is completely ruined.")) - return - if(src.damage > 0) - if(do_after(user, 40, src)) - src.damage -= (30) - if(src.damage < 0) - src.damage = 0 - nanopaste.use(1) - user.visible_message(SPAN_NOTICE("\The [user] applied some nanopaste on [src]'s damaged areas."),\ - SPAN_NOTICE("You apply some nanopaste at [src]'s damaged areas.")) - else - to_chat(user, SPAN_NOTICE("All [src]'s systems are nominal.")) + if(istype(nanopaste, /obj/item/stack/nanopaste)) + if(user.skill_check(SKILL_DEVICES, SKILL_TRAINED)) + if(src.damage >= src.max_damage) + to_chat(user, SPAN_WARNING("[src] is completely ruined.")) + return + if(src.damage > 0) + if(do_after(user, 40, src)) + src.damage -= (30) + if(src.damage < 0) + src.damage = 0 + nanopaste.use(1) + user.visible_message(SPAN_NOTICE("\The [user] applied some nanopaste on [src]'s damaged areas."),\ + SPAN_NOTICE("You apply some nanopaste at [src]'s damaged areas.")) + else + to_chat(user, SPAN_NOTICE("All [src]'s systems are nominal.")) + else + to_chat(user, SPAN_WARNING("You have no idea how to do that!")) /obj/item/organ/internal/posibrain/ipc name = "Positronic brain"