diff --git a/ATTRIBUTIONS.md b/ATTRIBUTIONS.md index 3e5639a5217..abaf97a0b98 100644 --- a/ATTRIBUTIONS.md +++ b/ATTRIBUTIONS.md @@ -80,3 +80,9 @@ **Creator:** VerySoft (https://github.com/TS-Rogue-Star/Rogue-Star/pull/435)
**URL:** [Website](https://rogue-star.net/)
**License:** Permission granting in writing for use by Virgo and Chomp with proper attribution +
+**File:** `icons/mob/turkey.dmi` +**Title:** Turkey
+**Creator:** VerySoft (https://github.com/TS-Rogue-Star/Rogue-Star/pull/669)
+**URL:** [Website](https://rogue-star.net/)
+**License:** Permission granted in writing for use by Virgo and Chomp with proper attribution diff --git a/code/__defines/chemistry.dm b/code/__defines/chemistry.dm index 63ea0e136f6..8213aa200f5 100644 --- a/code/__defines/chemistry.dm +++ b/code/__defines/chemistry.dm @@ -41,6 +41,7 @@ #define CE_DARKSIGHT "darksight" // Gives perfect vision in dark #define REAGENTS_PER_SHEET 20 +#define REAGENTS_PER_ORE 20 // Attached to CE_ANTIBIOTIC #define ANTIBIO_NORM 1 diff --git a/code/__defines/items_clothing.dm b/code/__defines/items_clothing.dm index a7dba8be88c..2a0b2ce9dea 100644 --- a/code/__defines/items_clothing.dm +++ b/code/__defines/items_clothing.dm @@ -40,6 +40,9 @@ #define ACCESSORY_SLOT_ARMOR_M 0x8000 #define ACCESSORY_SLOT_HELM_C 0x10000 //24 bit - higher than 0x80000 will overflow +#define ACCESSORY_SLOT_RING 0x20000 //rings, knuckledusters +#define ACCESSORY_SLOT_WRIST 0x40000 //wristwatches, wrist PDA maybe? + // Bitmasks for the /obj/item/var/flags_inv variable. These determine when a piece of clothing hides another, i.e. a helmet hiding glasses. // WARNING: The following flags apply only to the external suit! #define HIDEGLOVES 0x1 diff --git a/code/__defines/jobs.dm b/code/__defines/jobs.dm index c20f5e3cd98..70e38c6876d 100644 --- a/code/__defines/jobs.dm +++ b/code/__defines/jobs.dm @@ -201,6 +201,7 @@ #define JOB_ALT_CONSTRUCTION_ENGINEER "Construction Engineer" #define JOB_ALT_ENGINEERING_CONTRACTOR "Engineering Contractor" #define JOB_ALT_COMPUTER_TECHNICIAN "Computer Technician" + #define JOB_ALT_SALVAGE_TECHNICIAN "Salvage Technician" #define JOB_ATMOSPHERIC_TECHNICIAN "Atmospheric Technician" // Atmospheric Technician alt titles diff --git a/code/_helpers/game.dm b/code/_helpers/game.dm index 1f76dcac9a3..80d66f555da 100644 --- a/code/_helpers/game.dm +++ b/code/_helpers/game.dm @@ -172,7 +172,7 @@ if(ismob(I)) if(!sight_check || isInSight(I, O)) - L |= recursive_content_check(I, L, recursion_limit - 1, client_check, sight_check, include_mobs, include_objects) + L |= recursive_content_check(I, L, recursion_limit - 1, client_check, sight_check, include_mobs, include_objects, ignore_show_messages) if(include_mobs) if(client_check) var/mob/M = I @@ -185,7 +185,7 @@ var/obj/check_obj = I if(ignore_show_messages || check_obj.show_messages) if(!sight_check || isInSight(I, O)) - L |= recursive_content_check(I, L, recursion_limit - 1, client_check, sight_check, include_mobs, include_objects) + L |= recursive_content_check(I, L, recursion_limit - 1, client_check, sight_check, include_mobs, include_objects, ignore_show_messages) if(include_objects) L |= I diff --git a/code/_helpers/text.dm b/code/_helpers/text.dm index 520b98d39ad..3357116d308 100644 --- a/code/_helpers/text.dm +++ b/code/_helpers/text.dm @@ -620,3 +620,8 @@ return json_decode(data) catch return null + +/// Removes all non-alphanumerics from the text, keep in mind this can lead to id conflicts +/proc/sanitize_css_class_name(name) + var/static/regex/regex = new(@"[^a-zA-Z0-9]","g") + return replacetext(name, regex, "") diff --git a/code/datums/autolathe/arms.dm b/code/datums/autolathe/arms.dm index 9bceaf27e6d..41caf5a74d9 100644 --- a/code/datums/autolathe/arms.dm +++ b/code/datums/autolathe/arms.dm @@ -443,7 +443,7 @@ /datum/category_item/autolathe/arms/knuckledusters name = "knuckle dusters" - path =/obj/item/clothing/gloves/knuckledusters + path =/obj/item/clothing/accessory/knuckledusters hidden = 1 /datum/category_item/autolathe/arms/tacknife diff --git a/code/datums/diseases/_MobProcs.dm b/code/datums/diseases/_MobProcs.dm index a24fa9264f8..b664a349a61 100644 --- a/code/datums/diseases/_MobProcs.dm +++ b/code/datums/diseases/_MobProcs.dm @@ -177,19 +177,21 @@ if(!is_admin()) return FALSE - var/datum/disease/D = tgui_input_list(usr, "Choose virus", "Viruses", subtypesof(/datum/disease), subtypesof(/datum/disease)) - var/mob/living/carbon/human/H = null + var/disease = tgui_input_list(usr, "Choose virus", "Viruses", subtypesof(/datum/disease), subtypesof(/datum/disease)) + var/mob/living/carbon/human/H = tgui_input_list(usr, "Choose infectee", human_mob_list) - if(isnull(D)) + var/datum/disease/D = new disease + + if(isnull(D) || isnull(H)) return FALSE - for(var/thing in shuffle(human_mob_list)) - H = thing - if(H.stat == DEAD) - continue - if(!H.HasDisease(D)) - H.ForceContractDisease(D) - break + if(H.stat == DEAD) + return FALSE - message_admins("[key_name_admin(usr)] has triggered a virus outbreak of [D.name]! Affected mob: [key_name_admin(H)]") - log_admin("[key_name_admin(usr)] infected [key_name_admin(H)] with [D.name]") + if(!H.HasDisease(D)) + H.ForceContractDisease(D) + + message_admins("[key_name_admin(usr)] has triggered a virus outbreak of [D.name]! Affected mob: [key_name_admin(H)]") + log_admin("[key_name_admin(usr)] infected [key_name_admin(H)] with [D.name]") + + return TRUE diff --git a/code/datums/diseases/advance/advance.dm b/code/datums/diseases/advance/advance.dm index 73ef6649988..4e593ea7f13 100644 --- a/code/datums/diseases/advance/advance.dm +++ b/code/datums/diseases/advance/advance.dm @@ -354,20 +354,20 @@ GLOBAL_LIST_INIT(advance_cures, list( var/new_name = tgui_input_text(usr, "Name your new disease.", "New Name") if(!new_name) - return + return FALSE D.AssignName(new_name) D.Refresh() for(var/datum/disease/advance/AD in active_diseases) AD.Refresh() - for(var/thing in shuffle(human_mob_list)) - H = thing - if(H.stat == DEAD) - continue - if(!H.HasDisease(D)) - H.ForceContractDisease(D) - break + H = tgui_input_list(usr, "Choose infectee", human_mob_list) + + if(isnull(H)) + return FALSE + + if(!H.HasDisease(D)) + H.ForceContractDisease(D) var/list/name_symptoms = list() for(var/datum/symptom/S in D.symptoms) @@ -375,6 +375,8 @@ GLOBAL_LIST_INIT(advance_cures, list( message_admins("[key_name_admin(usr)] has triggered a custom virus outbreak of [D.name]! It has these symptoms: [english_list(name_symptoms)]") log_admin("[key_name_admin(usr)] infected [key_name_admin(H)] with [D.name]. It has these symptoms: [english_list(name_symptoms)]") + return TRUE + /datum/disease/advance/proc/totalStageSpeed() var/total_stage_speed = 0 for(var/i in symptoms) diff --git a/code/datums/diseases/advance/symptoms/fever.dm b/code/datums/diseases/advance/symptoms/fever.dm index a9e027da9cd..6e252e56cd9 100644 --- a/code/datums/diseases/advance/symptoms/fever.dm +++ b/code/datums/diseases/advance/symptoms/fever.dm @@ -35,6 +35,6 @@ Bonus return /datum/symptom/fever/proc/Heat(var/mob/living/M, var/datum/disease/advance/A) - var/get_heat = (sqrt(21+A.totalTransmittable()*2))+(sqrt(20+A.totalStageSpeed()*3)) + var/get_heat = (sqrtor0(21+A.totalTransmittable()*2))+(sqrtor0(20+A.totalStageSpeed()*3)) M.bodytemperature = min(M.bodytemperature + (get_heat * A.stage), BODYTEMP_HEAT_DAMAGE_LIMIT - 1) return TRUE diff --git a/code/datums/diseases/advance/symptoms/flesh_eating.dm b/code/datums/diseases/advance/symptoms/flesh_eating.dm index 28c9002c3a1..e91efab1c7c 100644 --- a/code/datums/diseases/advance/symptoms/flesh_eating.dm +++ b/code/datums/diseases/advance/symptoms/flesh_eating.dm @@ -37,6 +37,6 @@ Bonus return /datum/symptom/flesh_eating/proc/Flesheat(mob/living/M, datum/disease/advance/A) - var/get_damage = ((sqrt(16-A.totalStealth()))*5) + var/get_damage = ((sqrtor0(16-A.totalStealth()))*5) M.adjustBruteLoss(get_damage) return 1 diff --git a/code/datums/diseases/advance/symptoms/heal.dm b/code/datums/diseases/advance/symptoms/heal.dm index 1c219598722..f02ad95c32f 100644 --- a/code/datums/diseases/advance/symptoms/heal.dm +++ b/code/datums/diseases/advance/symptoms/heal.dm @@ -33,7 +33,7 @@ Bonus return /datum/symptom/heal/proc/Heal(mob/living/M, datum/disease/advance/A) - var/get_damage = (sqrt(20+A.totalStageSpeed())*(1+rand())) + var/get_damage = (sqrtor0(20+A.totalStageSpeed())*(1+rand())) M.adjustToxLoss(-get_damage) return TRUE @@ -144,7 +144,7 @@ Bonus level = 5 /datum/symptom/heal/dna/Heal(var/mob/living/carbon/M, var/datum/disease/advance/A) - var/amt_healed = (sqrt(20+A.totalStageSpeed()*(3+rand())))-(sqrt(16+A.totalStealth()*rand())) + var/amt_healed = (sqrtor0(20+A.totalStageSpeed()*(3+rand())))-(sqrtor0(16+A.totalStealth()*rand())) M.adjustBrainLoss(-amt_healed) M.radiation = max(M.radiation - 3, 0) return TRUE diff --git a/code/datums/diseases/advance/symptoms/macrophage.dm b/code/datums/diseases/advance/symptoms/macrophage.dm index 5769fadaa6c..a04a3fc50fe 100644 --- a/code/datums/diseases/advance/symptoms/macrophage.dm +++ b/code/datums/diseases/advance/symptoms/macrophage.dm @@ -70,4 +70,4 @@ BONUS phage.viruses += D M.visible_message(span_danger("A strange crearure bursts out of [M]!"), span_userdanger("A slimy creature bursts forth from your flesh!")) - addtimer(CALLBACK(phage, TYPE_PROC_REF(/mob/living/simple_mob/vore/aggressive/macrophage, dust)), 3000) + addtimer(CALLBACK(phage, TYPE_PROC_REF(/mob/living/simple_mob/vore/aggressive/macrophage, deathcheck)), 3000) diff --git a/code/datums/diseases/advance/symptoms/shivering.dm b/code/datums/diseases/advance/symptoms/shivering.dm index 375850ef40f..f4a3059d7c9 100644 --- a/code/datums/diseases/advance/symptoms/shivering.dm +++ b/code/datums/diseases/advance/symptoms/shivering.dm @@ -34,6 +34,6 @@ Bonus return /datum/symptom/shivering/proc/Chill(mob/living/M, datum/disease/advance/A) - var/get_cold = (sqrt(16+A.totalStealth()*2))+(sqrt(21+A.totalResistance()*2)) + var/get_cold = (sqrtor0(16+A.totalStealth()*2))+(sqrtor0(21+A.totalResistance()*2)) M.bodytemperature = max(M.bodytemperature - (get_cold * A.stage), BODYTEMP_COLD_DAMAGE_LIMIT + 1) return 1 diff --git a/code/datums/supplypacks/misc.dm b/code/datums/supplypacks/misc.dm index d03ab2b6207..bc1690c7d8c 100644 --- a/code/datums/supplypacks/misc.dm +++ b/code/datums/supplypacks/misc.dm @@ -80,6 +80,7 @@ /obj/item/toy/plushie/slimeplushie, /obj/item/toy/plushie/box, /obj/item/toy/plushie/borgplushie, + /obj/item/toy/plushie/borgplushie/drake/eng, /obj/item/toy/plushie/borgplushie/medihound, /obj/item/toy/plushie/borgplushie/scrubpuppy, /obj/item/toy/plushie/foxbear, diff --git a/code/datums/supplypacks/supply.dm b/code/datums/supplypacks/supply.dm index 68a6b420c0b..b8bcd3f7ba5 100644 --- a/code/datums/supplypacks/supply.dm +++ b/code/datums/supplypacks/supply.dm @@ -175,7 +175,7 @@ /obj/item/material/knife/tacknife/survival, /obj/item/material/knife/machete, /obj/item/clothing/accessory/holster/machete, - /obj/item/clothing/gloves/watch/survival + /obj/item/clothing/accessory/watch/survival ) cost=25 containertype = /obj/structure/closet/crate/secure/xion @@ -200,7 +200,7 @@ /obj/item/clothing/head/pilot_vr, /obj/item/clothing/under/rank/pilot1, /obj/item/gun/energy/gun/protector/pilotgun/locked, - /obj/item/clothing/gloves/watch/survival + /obj/item/clothing/accessory/watch/survival ) cost=20 containertype = /obj/structure/closet/crate/secure/xion @@ -236,7 +236,7 @@ /obj/item/clothing/accessory/holster/machete, /obj/item/storage/box/explorerkeys, /obj/item/mapping_unit, - /obj/item/clothing/gloves/watch/survival + /obj/item/clothing/accessory/watch/survival ) cost = 75 containertype = /obj/structure/closet/crate/secure/xion diff --git a/code/datums/uplink/stealthy_weapons.dm b/code/datums/uplink/stealthy_weapons.dm index 29c80092113..39cc3bf9ae2 100644 --- a/code/datums/uplink/stealthy_weapons.dm +++ b/code/datums/uplink/stealthy_weapons.dm @@ -58,12 +58,6 @@ item_cost = 20 path = /obj/item/pen/blade/fountain -/datum/uplink_item/item/stealthy_weapons/angrybuzzer - name = "Morphium Shock Ring" - desc = "An enigmatic ring used to create powerful electric shocks when punching. Can be used as a brute-force method of defibrillation." - item_cost = 40 - path = /obj/item/clothing/gloves/ring/buzzer - /datum/uplink_item/item/stealthy_weapons/huntingtrap name = "Camonetted Beartraps" desc = "A box of unique beartraps which will partially cloak when deployed, allowing for more effective hunting." diff --git a/code/game/jobs/job/engineering_vr.dm b/code/game/jobs/job/engineering_vr.dm index 17b70731dbd..bb784a8c961 100644 --- a/code/game/jobs/job/engineering_vr.dm +++ b/code/game/jobs/job/engineering_vr.dm @@ -48,6 +48,10 @@ title = JOB_ALT_COMPUTER_TECHNICIAN title_blurb = "A " + JOB_ALT_COMPUTER_TECHNICIAN + " fulfills similar duties to other engineers, but specializes in working with software and computers. They also often deal with integrated circuits." +/datum/alt_title/salvage_tech + title = JOB_ALT_SALVAGE_TECHNICIAN + title_blurb = "A " + JOB_ALT_SALVAGE_TECHNICIAN + " is responsible for breaking down debris and obsolete equipment to recover useful components and materials." + /datum/job/atmos spawn_positions = 3 pto_type = PTO_ENGINEERING diff --git a/code/game/machinery/camera/camera.dm b/code/game/machinery/camera/camera.dm index 383a96868b5..1f89fdbe980 100644 --- a/code/game/machinery/camera/camera.dm +++ b/code/game/machinery/camera/camera.dm @@ -254,19 +254,19 @@ if (!(src.status)) if(user) visible_message(span_notice(" [user] has deactivated [src]!")) + add_hiddenprint(user) else visible_message(span_notice(" [src] clicks and shuts down. ")) playsound(src, 'sound/items/Wirecutter.ogg', 100, 1) icon_state = "[initial(icon_state)]1" - add_hiddenprint(user) else if(user) visible_message(span_notice(" [user] has reactivated [src]!")) + add_hiddenprint(user) else visible_message(span_notice(" [src] clicks and reactivates itself. ")) playsound(src, 'sound/items/Wirecutter.ogg', 100, 1) icon_state = initial(icon_state) - add_hiddenprint(user) /obj/machinery/camera/take_damage(var/force, var/message) //prob(25) gives an average of 3-4 hits diff --git a/code/game/machinery/computer/arcade_vr.dm b/code/game/machinery/computer/arcade_vr.dm index a1d4ebb069e..80daaceb524 100644 --- a/code/game/machinery/computer/arcade_vr.dm +++ b/code/game/machinery/computer/arcade_vr.dm @@ -22,7 +22,6 @@ /obj/item/toy/redbutton = 2, /obj/item/toy/gnome = 2, /obj/item/toy/AI = 2, - /obj/item/clothing/gloves/ring/buzzer/toy = 2, /obj/item/storage/box/handcuffs/fake = 2, /obj/item/toy/nuke = 2, /obj/item/toy/minigibber = 2, diff --git a/code/game/machinery/contraband_scanner.dm b/code/game/machinery/contraband_scanner.dm new file mode 100644 index 00000000000..265cad9bd8c --- /dev/null +++ b/code/game/machinery/contraband_scanner.dm @@ -0,0 +1,67 @@ +/obj/machinery/contraband_scanner + name = "contraband scanner" + gender = PLURAL + icon = 'icons/obj/atm_fieldgen.dmi' + icon_state = "arfg_off" + desc = "A simple scanner that analyzes those who pass over it, and sounds an alarm if it detects any items that are programmed into its contraband list." + anchored = TRUE + opacity = FALSE + density = FALSE + power_channel = EQUIP + use_power = USE_POWER_IDLE + idle_power_usage = 10 + active_power_usage = 250 + + var/deep_scan = TRUE //check more than just their hands/pockets? + var/contraband_count = 0 //how many items have we detected? only one actually needs to be found to set off the alarm + var/area_lockdown = TRUE //do we set off the fire alarm for our area when triggered? + var/close_blastdoors = TRUE //close all blast doors in the area when triggered? + var/power_fields = TRUE //do we activate all ARFs when triggered? use w/ impassable fieldgens. requires area_lockdown = TRUE to do anything. + + var/last_trigger //when were we last triggered? combined with the cooldown below for sanity reasons + var/cooldown = 15 SECONDS //minimum time between retriggers, so people can't spam trigger the scanner to be obnoxious + var/auto_cancel = TRUE //automatically cancel alarm states after a delay? same duration as the cooldown for sanity + var/trigger_message = "The contraband scanner has been tripped!" + var/trigger_sound = 'sound/machines/airalarm.ogg' //sound that plays when we're set off + + var/list/contraband = list(/obj/item/melee,/obj/item/gun,/obj/item/material) + +/obj/machinery/contraband_scanner/Crossed(mob/living/M as mob) + if(M.is_incorporeal()) + return + if(isliving(M)) + var/area/A = src.loc.loc + if(last_trigger > world.time - cooldown) + return + for(var/obj/O in M.contents) + if(is_type_in_list(O,contraband)) + contraband_count++ + if(deep_scan) + for(var/obj/O2 in O.contents) //one layer deep is fine for now I think + if(is_type_in_list(O2,contraband)) + contraband_count++ + if(contraband_count && last_trigger < world.time - cooldown) + visible_message(span_danger(trigger_message)) + playsound(src, trigger_sound, 25, 0, 4, volume_channel = VOLUME_CHANNEL_ALARMS) + for(var/obj/machinery/contraband_scanner/CS in A) + CS.last_trigger = world.time //set everyone's trigger time at once, to cut down on spam + CS.contraband_count = 0 //clear all our contraband counts too + if(area_lockdown) + if(close_blastdoors) + for(var/obj/machinery/door/blast/B in A) + if(!B.density) + spawn(0) + B.close() + if(power_fields) + A.arfgs_activate() + if(auto_cancel) + spawn(cooldown) + if(close_blastdoors) + for(var/obj/machinery/door/blast/B in A) + if(B.density) + spawn(0) + B.open() + if(power_fields) + A.arfgs_deactivate() + + ..() diff --git a/code/game/objects/effects/decals/Cleanable/humans.dm b/code/game/objects/effects/decals/Cleanable/humans.dm index 84b47051aa1..184bee8bede 100644 --- a/code/game/objects/effects/decals/Cleanable/humans.dm +++ b/code/game/objects/effects/decals/Cleanable/humans.dm @@ -112,6 +112,10 @@ var/global/list/image/splatter_cache=list() var/obj/structure/bed/chair/wheelchair/W = perp.buckled W.bloodiness = 4 + if(viruses) + for(var/datum/disease/D in viruses) + perp.ContractDisease(D) + amount-- /obj/effect/decal/cleanable/blood/proc/dry() @@ -124,6 +128,11 @@ var/global/list/image/splatter_cache=list() ..() if (amount && istype(user)) add_fingerprint(user) + + if(viruses) + for(var/datum/disease/D in viruses) + user.ContractDisease(D) + if (user.gloves) return var/taken = rand(1,amount) @@ -258,4 +267,14 @@ var/global/list/image/splatter_cache=list() viruses.Cut() return ..() +/obj/effect/decal/cleanable/mucus/Crossed(mob/living/carbon/human/perp) + if(viruses) + for(var/datum/disease/D in viruses) + perp.ContractDisease(D) + +/obj/effect/decal/cleanable/vomit/Crossed(mob/living/carbon/human/perp) + if(viruses) + for(var/datum/disease/D in viruses) + perp.ContractDisease(D) + #undef DRYING_TIME diff --git a/code/game/objects/items/antag_spawners.dm b/code/game/objects/items/antag_spawners.dm index 8371f5b0175..28817531895 100644 --- a/code/game/objects/items/antag_spawners.dm +++ b/code/game/objects/items/antag_spawners.dm @@ -118,7 +118,6 @@ to speak with your team, and learn what their plan is for today.")) R.key = C.key -// R.Namepick() // Apparnetly making someone a merc lets them pick a name, so this isn't needed. spawn(1) mercs.add_antagonist(R.mind, FALSE, TRUE, FALSE, FALSE, FALSE) diff --git a/code/game/objects/items/devices/chameleonproj.dm b/code/game/objects/items/devices/chameleonproj.dm index 14cd916ea89..e85308b5dda 100644 --- a/code/game/objects/items/devices/chameleonproj.dm +++ b/code/game/objects/items/devices/chameleonproj.dm @@ -28,10 +28,10 @@ disrupt() ..() -/obj/item/chameleon/attack_self() - toggle() +/obj/item/chameleon/attack_self(mob/user) + toggle(user) -/obj/item/chameleon/afterattack(atom/target, mob/user , proximity) +/obj/item/chameleon/afterattack(atom/target, mob/user, proximity) if(!proximity) return if(!active_dummy) if(istype(target,/obj/item) && !istype(target, /obj/item/disk/nuclear)) @@ -42,30 +42,32 @@ saved_icon_state = target.icon_state saved_overlays = target.overlays -/obj/item/chameleon/proc/toggle() +/obj/item/chameleon/proc/toggle(mob/user) if(!can_use || !saved_item) return if(active_dummy) eject_all() playsound(src, 'sound/effects/pop.ogg', 100, 1, -6) qdel(active_dummy) active_dummy = null - to_chat(usr, span_notice("You deactivate the [src].")) + to_chat(user, span_notice("You deactivate the [src].")) var/obj/effect/overlay/T = new /obj/effect/overlay(get_turf(src)) T.icon = 'icons/effects/effects.dmi' flick("emppulse",T) - spawn(8) qdel(T) + addtimer(CALLBACK(GLOBAL_PROC, GLOBAL_PROC_REF(qdel), T), 0.8 SECONDS, TIMER_DELETE_ME) else playsound(src, 'sound/effects/pop.ogg', 100, 1, -6) var/obj/O = new saved_item(src) if(!O) return - var/obj/effect/dummy/chameleon/C = new /obj/effect/dummy/chameleon(usr.loc) - C.activate(O, usr, saved_icon, saved_icon_state, saved_overlays, src) + if(istype(user.loc, /obj/item/holder)) // This doesn't go well... + return + var/obj/effect/dummy/chameleon/C = new /obj/effect/dummy/chameleon(user.loc) + C.activate(O, user, saved_icon, saved_icon_state, saved_overlays, src) qdel(O) - to_chat(usr, span_notice("You activate the [src].")) + to_chat(user, span_notice("You activate the [src].")) var/obj/effect/overlay/T = new/obj/effect/overlay(get_turf(src)) T.icon = 'icons/effects/effects.dmi' flick("emppulse",T) - spawn(8) qdel(T) + addtimer(CALLBACK(GLOBAL_PROC, GLOBAL_PROC_REF(qdel), T), 0.8 SECONDS, TIMER_DELETE_ME) /obj/item/chameleon/proc/disrupt(var/delete_dummy = 1) if(active_dummy) @@ -78,7 +80,10 @@ qdel(active_dummy) active_dummy = null can_use = 0 - spawn(50) can_use = 1 + addtimer(CALLBACK(src, PROC_REF(allow_use)), 5 SECONDS, TIMER_DELETE_ME) + +/obj/item/chameleon/proc/allow_use() + can_use = 1 /obj/item/chameleon/proc/eject_all() for(var/atom/movable/A in active_dummy) @@ -127,6 +132,9 @@ ..() master.disrupt() +/obj/effect/dummy/chameleon/proc/allow_move() + can_move = 1 + /obj/effect/dummy/chameleon/relaymove(var/mob/user, direction) if(istype(loc, /turf/space)) return //No magical space movement! @@ -134,15 +142,15 @@ can_move = 0 switch(user.bodytemperature) if(300 to INFINITY) - spawn(10) can_move = 1 + addtimer(CALLBACK(src, PROC_REF(allow_move)), 1 SECOND, TIMER_DELETE_ME) if(295 to 300) - spawn(13) can_move = 1 + addtimer(CALLBACK(src, PROC_REF(allow_move)), 1.3 SECONDS, TIMER_DELETE_ME) if(280 to 295) - spawn(16) can_move = 1 + addtimer(CALLBACK(src, PROC_REF(allow_move)), 1.6 SECONDS, TIMER_DELETE_ME) if(260 to 280) - spawn(20) can_move = 1 + addtimer(CALLBACK(src, PROC_REF(allow_move)), 2 SECONDS, TIMER_DELETE_ME) else - spawn(25) can_move = 1 + addtimer(CALLBACK(src, PROC_REF(allow_move)), 2.5 SECONDS, TIMER_DELETE_ME) step(src, direction) return diff --git a/code/game/objects/items/devices/radio/headset.dm b/code/game/objects/items/devices/radio/headset.dm index bc676341d3a..ead212defab 100644 --- a/code/game/objects/items/devices/radio/headset.dm +++ b/code/game/objects/items/devices/radio/headset.dm @@ -576,6 +576,18 @@ syndie = 1 ks1type = /obj/item/encryptionkey/syndicate +/obj/item/radio/headset/alt/syndicate + origin_tech = list(TECH_ILLEGAL = 3) + icon_state = "syndie_headset_alt" + syndie = 1 + ks1type = /obj/item/encryptionkey/syndicate + +/obj/item/radio/headset/earbud/syndicate + origin_tech = list(TECH_ILLEGAL = 3) + icon_state = "syndie_earbud" + syndie = 1 + ks1type = /obj/item/encryptionkey/syndicate + /obj/item/radio/headset/raider origin_tech = list(TECH_ILLEGAL = 2) icon_state = "syndie_headset" diff --git a/code/game/objects/items/devices/scanners/health.dm b/code/game/objects/items/devices/scanners/health.dm index c9927024305..348d8b55e6e 100644 --- a/code/game/objects/items/devices/scanners/health.dm +++ b/code/game/objects/items/devices/scanners/health.dm @@ -248,7 +248,7 @@ else dat += span_warning("Unknown substance[(unknown > 1)?"s":""] found in subject's dermis.") dat += "
" - if(C.resistances.len) + if(LAZYLEN(C.resistances)) for (var/datum/disease/virus in C.GetViruses()) if(virus.visibility_flags & HIDDEN_SCANNER || virus.visibility_flags & HIDDEN_PANDEMIC) continue diff --git a/code/game/objects/items/lockpicks.dm b/code/game/objects/items/lockpicks.dm new file mode 100644 index 00000000000..0af583a1736 --- /dev/null +++ b/code/game/objects/items/lockpicks.dm @@ -0,0 +1,54 @@ +//For bypassing locked /obj/structure/simple_doors + +/obj/item/lockpick + name = "set of lockpicks" + desc = "A set of picks and tension wrenches, ideal for picking old-style mechanical locks... not that any of those exist on most NT facilities these days. Still, it might be useful elsewhere?" + icon = 'icons/obj/lockpicks.dmi' + icon_state = "lockpicks" + w_class = ITEMSIZE_SMALL + var/pick_type = "simple" + var/pick_time = 10 SECONDS + var/pick_verb = "pick" + +/obj/item/lockpick/afterattack(atom/A, mob/user) + if(!user.IsAdvancedToolUser()) //no lockpicking for monkeys + return + if(istype(A, /obj/structure/simple_door)) + var/obj/structure/simple_door/D = A + if(!D.locked) //you can pick your nose, but you can't pick an unlocked door + to_chat(user, span_notice("\The [D] isn't locked.")) + return + else if(D.lock_type != pick_type) //make sure our types match + to_chat(user, span_warning("\The [src] can't pick \the [D]. Another tool might work?")) + return + else if(!D.can_pick) //make sure we're actually allowed to bypass it at all + to_chat(user, span_warning("\The [D] can't be [pick_verb]ed.")) + return + else //finally, we can assume that they do match + to_chat(user, span_notice("You start to [pick_verb] the lock on \the [D]...")) + playsound(src, D.keysound,100, 1) + if(do_after(user, pick_time * D.lock_difficulty)) + to_chat(user, span_notice("Success!")) + D.locked = FALSE + else if(istype(A,/mob/living/carbon/human)) //you can pick your friends, and you can pick your nose, but you can't pick your friend's nose + var/mob/living/carbon/human/H = A + if(user.zone_sel.selecting == BP_HEAD) + if(H == user) + to_chat(user, span_notice("Your nose isn't locked. If you're feeling stuffy, maybe you should talk to a doctor..?")) + else + user.visible_message(span_notice("[user] tries to [pick_verb] [H]'s nose with \the [src]! They don't seem to be having much success."),span_notice("You try to [pick_verb] [H]'s nose. It doesn't seem to be working.")) + return + +/obj/item/lockpick/pick_gun + name = "pick gun" + desc = "A more sophisticated and automated alternative to traditional lockpicking methods. Contains a dazzling array of tools in a simple-to-use housing: just press the face plate against the lock face and hold the trigger down until it goes click." + icon_state = "pick_gun" + pick_time = 3 SECONDS + +/obj/item/lockpick/mag_sequencer + name = "magnetic sequencer" + desc = "A deceptively simple gadget that brute-forces magnetic locks using a small electromagnet. A predecessor to the cryptographic sequencer, a more complicated device that is considered contraband in most jurisdictions. Not that these aren't illegal either, mind you!" + icon_state = "mag_sequencer" + pick_type = "maglock" + pick_time = 5 SECONDS + pick_verb = "bypass" diff --git a/code/game/objects/items/robot/robot_parts.dm b/code/game/objects/items/robot/robot_parts.dm index 32af47b31af..2667b9d3f66 100644 --- a/code/game/objects/items/robot/robot_parts.dm +++ b/code/game/objects/items/robot/robot_parts.dm @@ -225,7 +225,6 @@ feedback_inc("cyborg_birth",1) callHook("borgify", list(O)) - O.namepick() qdel(src) else diff --git a/code/game/objects/items/toys/toys_vr.dm b/code/game/objects/items/toys/toys_vr.dm index b6df0bcafd8..6a9b66f0c66 100644 --- a/code/game/objects/items/toys/toys_vr.dm +++ b/code/game/objects/items/toys/toys_vr.dm @@ -556,35 +556,6 @@ /obj/item/toy/AI/proc/cooldownreset() cooldown = 0 -/* - * Hand buzzer - */ -/obj/item/clothing/gloves/ring/buzzer/toy - name = "steel ring" - desc = "Torus shaped finger decoration. It has a small piece of metal on the palm-side." - icon_state = "seal-signet" - drop_sound = 'sound/items/drop/ring.ogg' - -/obj/item/clothing/gloves/ring/buzzer/toy/Touch(var/atom/A, var/proximity) - if(proximity && istype(usr, /mob/living/carbon/human)) - - return zap(usr, A, proximity) - return 0 - -/obj/item/clothing/gloves/ring/buzzer/toy/zap(var/mob/living/carbon/human/user, var/atom/movable/target, var/proximity) - . = FALSE - if(user.a_intent == I_HELP && battery.percent() >= 50) - if(isliving(target)) - var/mob/living/L = target - - to_chat(L, span_warning("You feel a powerful shock!")) - if(!.) - playsound(L, 'sound/effects/sparks7.ogg', 40, 1) - L.electrocute_act(battery.percent() * 0, src) - return . - - return 0 - /* * Toy cuffs */ diff --git a/code/game/objects/items/weapons/joke.dm b/code/game/objects/items/weapons/joke.dm index feba68dbc72..efe530e5f94 100644 --- a/code/game/objects/items/weapons/joke.dm +++ b/code/game/objects/items/weapons/joke.dm @@ -16,4 +16,24 @@ else M.ClearTransform() M.update_transform() - return ..() \ No newline at end of file + return ..() + +// Do not ever just leave this laying about, it will go horribly wrong! +/obj/item/squishhammer/dark + name = "The Dark Short Stacker" + desc = "Wield the power of this weapon with responsibility (God knows you won't)." + icon = 'icons/obj/items.dmi' + icon_state = "dark_hammer" + attack_verb = list("stacked") + force = 0 + throwforce = 0 + +/obj/item/squishhammer/dark/attack(mob/M as mob, mob/user as mob) + ..() + var/mob/living/carbon/human/H = M + if(istype(H)) + for(var/obj/item/organ/external/E in H.organs) + E.fracture() // Oof, ouch, owie + var/turf/T = M.loc + if(isturf(T)) + new /obj/effect/gibspawner/generic(T) diff --git a/code/game/objects/items/weapons/material/kitchen.dm b/code/game/objects/items/weapons/material/kitchen.dm index 43c524b51fa..cb5458c936d 100644 --- a/code/game/objects/items/weapons/material/kitchen.dm +++ b/code/game/objects/items/weapons/material/kitchen.dm @@ -108,12 +108,12 @@ if(M == user) if(!M.can_eat(loaded)) return - M.visible_message(span_bold("\The [user]") + "eats some of [loaded] with \the [src].") + M.visible_message(span_bold("\The [user]") + " eats some of [loaded] with \the [src].") else user.visible_message(span_warning("\The [user] begins to feed \the [M]!")) if(!(M.can_force_feed(user, loaded) && do_mob(user, M, 5 SECONDS))) return - M.visible_message(span_bold("\The [user]") + "feeds some of [loaded] to \the [M] with \the [src].") + M.visible_message(span_bold("\The [user]") + " feeds some of [loaded] to \the [M] with \the [src].") playsound(src,'sound/items/eatfood.ogg', rand(10,40), 1) loaded = null update_icon() diff --git a/code/game/objects/items/weapons/material/shards.dm b/code/game/objects/items/weapons/material/shards.dm index ecd8df84568..3095bce5845 100644 --- a/code/game/objects/items/weapons/material/shards.dm +++ b/code/game/objects/items/weapons/material/shards.dm @@ -65,8 +65,7 @@ var/light_glove_d = rand(2, 4) var/no_glove_d = rand(4, 6) var/list/forbidden_gloves = list( - /obj/item/clothing/gloves/sterile, - /obj/item/clothing/gloves/knuckledusters + /obj/item/clothing/gloves/sterile ) if(src == user.l_hand) diff --git a/code/game/objects/items/weapons/melee/misc_vr.dm b/code/game/objects/items/weapons/melee/misc_vr.dm index 5e9f318aa6d..092ec058919 100644 --- a/code/game/objects/items/weapons/melee/misc_vr.dm +++ b/code/game/objects/items/weapons/melee/misc_vr.dm @@ -13,4 +13,42 @@ sharp = TRUE edge = FALSE attack_verb = list("stabbed", "lunged at", "dextrously struck", "sliced", "lacerated", "impaled", "diced", "charioted") - hitsound = 'sound/weapons/bladeslice.ogg' \ No newline at end of file + hitsound = 'sound/weapons/bladeslice.ogg' + +/obj/item/melee/hammer + name = "claw hammer" + desc = "A simple claw hammer for hitting things or people with, and the claw part probably does something too." + icon = 'icons/obj/weapons.dmi' + icon_state = "claw_hammer" + force = 15 + throwforce = 10 + w_class = ITEMSIZE_SMALL + attack_verb = list("smashed", "swung at", "pummelled", "nailed", "crushed", "bonked", "hammered", "cracked") + defend_chance = 0 + +/obj/item/melee/hammer/apply_hit_effect(mob/living/target, mob/living/user, var/hit_zone, var/attack_modifier) + if(istype(target,/mob/living/carbon/human)) + var/mob/living/carbon/human/H = target + if(prob(50)) + var/obj/item/organ/external/affecting = H.get_organ(hit_zone) + affecting.fracture() + return ..() + +/obj/item/melee/hammer/afterattack(atom/A as mob|obj|turf|area, mob/user as mob, proximity) + if(!proximity) return + ..() + if(A) + if(istype(A,/obj/structure/window)) + var/obj/structure/window/W = A + if(prob(50)) + W.visible_message(span_warning("\The [W] shatters under the force of the impact!")) + W.shatter() + else if(istype(A,/obj/structure/barricade)) + var/obj/structure/barricade/B = A + if(prob(50)) + B.visible_message(span_warning("\The [B] is broken apart with ease!")) + B.dismantle() + else if(istype(A,/obj/structure/grille)) + if(prob(50)) + A.visible_message(span_warning("\The [A] is smashed open!")) + qdel(A) diff --git a/code/game/objects/items/weapons/storage/bags.dm b/code/game/objects/items/weapons/storage/bags.dm index 0e51b19eec8..ad934b0d035 100644 --- a/code/game/objects/items/weapons/storage/bags.dm +++ b/code/game/objects/items/weapons/storage/bags.dm @@ -141,7 +141,7 @@ to_chat(user, span_notice("\the [src] is too full to possibly fit anything else inside of it.")) return - if (istype(W, /obj/item/ore)) + if (istype(W, /obj/item/ore) && !istype(W, /obj/item/ore/slag)) var/obj/item/ore/ore = W stored_ore[ore.material]++ current_capacity++ @@ -178,6 +178,8 @@ if(current_pickup >= max_pickup) max_pickup_reached = 1 break + if(istype(O, /obj/item/ore/slag)) + continue var/obj/item/ore/ore = O stored_ore[ore.material]++ current_capacity++ diff --git a/code/game/objects/random/misc.dm b/code/game/objects/random/misc.dm index adc52260937..51c745c1cec 100644 --- a/code/game/objects/random/misc.dm +++ b/code/game/objects/random/misc.dm @@ -263,7 +263,7 @@ prob(6);/obj/item/material/butterflyblade, prob(6);/obj/item/material/butterflyhandle, prob(2);/obj/item/material/butterfly/switchblade, - prob(2);/obj/item/clothing/gloves/knuckledusters, + prob(2);/obj/item/clothing/accessory/knuckledusters, prob(1);/obj/item/material/knife/tacknife, prob(1);/obj/item/clothing/suit/storage/vest/heavy/merc, prob(1);/obj/item/beartrap, diff --git a/code/game/objects/random/mob_vr.dm b/code/game/objects/random/mob_vr.dm index 6b7dfa39679..e13801e1497 100644 --- a/code/game/objects/random/mob_vr.dm +++ b/code/game/objects/random/mob_vr.dm @@ -154,7 +154,7 @@ prob(4);/obj/item/storage/pill_bottle/zoom, prob(4);/obj/item/material/butterfly, prob(2);/obj/item/material/butterfly/switchblade, - prob(2);/obj/item/clothing/gloves/knuckledusters, + prob(2);/obj/item/clothing/accessory/knuckledusters, prob(2);/obj/item/reagent_containers/syringe/drugs, prob(1);/obj/item/material/knife/tacknife, prob(1);/obj/item/clothing/suit/storage/vest/heavy/merc, diff --git a/code/game/objects/structures/crates_lockers/closets/misc_vr.dm b/code/game/objects/structures/crates_lockers/closets/misc_vr.dm index 1aba1626ec6..f001c78f45b 100644 --- a/code/game/objects/structures/crates_lockers/closets/misc_vr.dm +++ b/code/game/objects/structures/crates_lockers/closets/misc_vr.dm @@ -211,7 +211,7 @@ /obj/item/radio, /obj/item/gps/explorer, /obj/item/gun/energy/gun/protector/pilotgun/locked, - /obj/item/clothing/gloves/watch/survival, + /obj/item/clothing/accessory/watch/survival, /obj/item/clothing/accessory/storage/webbing/pilot1, /obj/item/clothing/accessory/storage/webbing/pilot2, /obj/item/emergency_beacon diff --git a/code/game/objects/structures/ghost_pods/silicon.dm b/code/game/objects/structures/ghost_pods/silicon.dm index 64ac8f5674b..4f50784aed2 100644 --- a/code/game/objects/structures/ghost_pods/silicon.dm +++ b/code/game/objects/structures/ghost_pods/silicon.dm @@ -31,7 +31,6 @@ from the pod is not a crewmember.")) R.ckey = M.ckey visible_message(span_warning("As \the [src] opens, the eyes of the robot flicker as it is activated.")) - R.namepick() log_and_message_admins("successfully opened \a [src] and got a Lost Drone.") ..() @@ -57,7 +56,6 @@ definiton of 'your gravesite' is where your pod is.")) R.ckey = M.ckey visible_message(span_warning("As \the [src] opens, the eyes of the robot flicker as it is activated.")) - R.namepick() ..() /obj/structure/ghost_pod/ghost_activated/swarm_drone diff --git a/code/game/objects/structures/ghost_pods/silicon_vr.dm b/code/game/objects/structures/ghost_pods/silicon_vr.dm index cfc3b781d2f..1039349f2e1 100644 --- a/code/game/objects/structures/ghost_pods/silicon_vr.dm +++ b/code/game/objects/structures/ghost_pods/silicon_vr.dm @@ -21,7 +21,6 @@ from the pod is not a crewmember.")) R.ckey = M.ckey visible_message(span_warning("As \the [src] opens, the eyes of the robot flicker as it is activated.")) - R.namepick() log_and_message_admins("successfully opened \a [src] and got a Lost Drone.") used = TRUE return TRUE diff --git a/code/game/objects/structures/props/machines.dm b/code/game/objects/structures/props/machines.dm index 9e9e0d7714c..a7aa684edff 100644 --- a/code/game/objects/structures/props/machines.dm +++ b/code/game/objects/structures/props/machines.dm @@ -556,9 +556,9 @@ * This one is a bit more fancy than others. Anything in the contents (PLEASE LIMIT TO ONE THING) * will show up inside it! Also if you map in an item on it, it will grab that at mapload and start * in the 'closed, full of fluid' state, so you can put a body on it or whatever. - * + * * As an aghost you can also dragdrop something into it (you have to be ghosted next to it) - * + * * Possible 'state' options for change_state(state) are: * open: Open, no fluid or anything. At the end the contents are ejected. * closed: Closed, full of liquid @@ -582,7 +582,7 @@ /obj/structure/prop/machine/nt_pod/Initialize(mapload) // Our non-map-preview state icon_state = "nt_pod" - + // Alpha mask to make sure things don't sneak out var/obj/effect/overlay/vis/mask = new mask.icon = icon @@ -607,7 +607,7 @@ // Save old settings contents_vis_flags = AM.vis_flags contents_original_pixel_y = AM.pixel_y - + // Arrange AM.add_filter("podmask", 1, alpha_mask_filter(render_source = "nt_podmask[REF(src)]", flags = MASK_INVERSE)) AM.pixel_y = 12 @@ -616,7 +616,7 @@ if(ismob(AM)) var/mob/M = AM buckle_mob(M, TRUE, FALSE) - + // TRAP THEM change_state("closed") @@ -639,7 +639,7 @@ return if(!user.client?.holder) return - + AM.forceMove(src) /obj/structure/prop/machine/nt_pod/change_state(state) @@ -648,17 +648,17 @@ if("open") cut_overlay("nt_pod_top_on") cut_overlay("nt_pod_under") - + // Fluid drains fluid.icon_state = "nothing" flick("nt_pod_emptying", fluid) // 8ds sleep(8) - + // Door opens door.icon_state = "nothing" flick("nt_pod_opening", door) // 9ds sleep(9) - + // GET OUT outside.layer = BELOW_MOB_LAYER if(contents.len) @@ -670,7 +670,7 @@ cut_overlay("nt_pod_top_on") add_overlay("nt_pod_top_on") add_overlay("nt_pod_under") - + // Door closes door.icon_state = "nt_pod_glass" flick("nt_pod_closing", door) // 9ds @@ -683,4 +683,90 @@ cut_overlay("nt_pod_panel") add_overlay("nt_pod_panel") if("panel_closed") - cut_overlay("nt_pod_panel") \ No newline at end of file + cut_overlay("nt_pod_panel") + +// Old Virology stuff + +/obj/structure/prop/machine/centrifuge + name = "centrifuge" + desc = "Used to separate things with different weight. Spin 'em round, round, right round." + icon = 'icons/obj/virology_vr.dmi' + icon_state = "centrifuge" + var/on = FALSE + +/obj/structure/prop/machine/centrifuge/attack_hand(mob/user as mob) + ..() + + if(!on) + on = TRUE + user.visible_message("\The [user] turns on \the [src].") + icon_state = "centrifuge_moving" + else + on = FALSE + user.visible_message("\The [user] turns off \the [src].") + icon_state = "centrifuge" + + update_icon() + +/obj/structure/prop/machine/incubator + name = "incubator" + desc = "Encourages the growth of diseases. This model comes with a dispenser system and a small radiation generator." + icon = 'icons/obj/virology_vr.dmi' + icon_state = "incubator" + var/on = FALSE + +/obj/structure/prop/machine/incubator/attack_hand(mob/user as mob) + ..() + + if(!on) + on = TRUE + user.visible_message("\The [user] turns on \the [src].") + icon_state = "incubator_on" + else + on = FALSE + user.visible_message("\The [user] turns off \the [src].") + icon_state = "incubator" + + update_icon() + +/obj/structure/prop/machine/disease_analyser + name = "disease analyser" + desc = "Analyzes diseases to find out information about them!" + icon = 'icons/obj/virology_vr.dmi' + icon_state = "analyser" + var/on = FALSE + +/obj/structure/prop/machine/disease_analyser/attack_hand(mob/user as mob) + ..() + + if(!on) + on = TRUE + user.visible_message("\The [user] turns on \the [src].") + icon_state = "analyser_" + else + on = FALSE + user.visible_message("\The [user] turns off \the [src].") + icon_state = "analyser" + + update_icon() + +/obj/structure/prop/machine/isolator + name = "disease isolator" + desc = "Used to isolate and identify diseases, allowing for comparison with a remote database." + icon = 'icons/obj/virology_vr.dmi' + icon_state = "isolator_in" + var/on = FALSE + +/obj/structure/prop/machine/isolator/attack_hand(mob/user as mob) + ..() + + if(!on) + on = TRUE + user.visible_message("\The [user] turns on \the [src].") + icon_state = "isolator_" + else + on = FALSE + user.visible_message("\The [user] turns off \the [src].") + icon_state = "isolator_in" + + update_icon() diff --git a/code/game/objects/structures/simple_doors.dm b/code/game/objects/structures/simple_doors.dm index db06f7fea8e..c68d08208bf 100644 --- a/code/game/objects/structures/simple_doors.dm +++ b/code/game/objects/structures/simple_doors.dm @@ -18,6 +18,9 @@ var/locked = FALSE //has the door been locked? var/lock_id = null //does the door have an associated key? + var/lock_type = "simple" //string matched to "pick_type" on /obj/item/lockpick + var/can_pick = TRUE //can it be picked/bypassed? + var/lock_difficulty = 1 //multiplier to picking/bypassing time var/keysound = 'sound/items/toolbelt_equip.ogg' /obj/structure/simple_door/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume) diff --git a/code/game/objects/structures/trash_pile_vr.dm b/code/game/objects/structures/trash_pile_vr.dm index 26d9b82066c..c53a14b659b 100644 --- a/code/game/objects/structures/trash_pile_vr.dm +++ b/code/game/objects/structures/trash_pile_vr.dm @@ -292,7 +292,7 @@ prob(3);/obj/item/cracker, prob(3);/obj/item/material/butterfly, prob(3);/obj/item/material/butterfly/switchblade, - prob(3);/obj/item/clothing/gloves/knuckledusters, + prob(3);/obj/item/clothing/accessory/knuckledusters, prob(3);/obj/item/clothing/gloves/heavy_engineer, prob(3);/obj/item/reagent_containers/syringe/drugs, prob(2);/obj/item/implanter/sizecontrol, diff --git a/code/modules/admin/modify_robot.dm b/code/modules/admin/modify_robot.dm index f2847943f35..64f486824d7 100644 --- a/code/modules/admin/modify_robot.dm +++ b/code/modules/admin/modify_robot.dm @@ -43,9 +43,16 @@ qdel(source) . = ..() +/datum/eventkit/modify_robot/ui_assets(mob/user) + return list( + get_asset_datum(/datum/asset/spritesheet/robot_icons) + ) + /datum/eventkit/modify_robot/tgui_data(mob/user) . = list() // Target section for general data + var/datum/asset/spritesheet/robot_icons/spritesheet = get_asset_datum(/datum/asset/spritesheet/robot_icons) + if(target) .["target"] = list() .["target"]["name"] = target.name @@ -62,10 +69,8 @@ // Target section for options once a module has been selected if(target.module) .["target"]["active"] = target.icon_selected - .["target"]["front"] = icon2base64(get_flat_icon(target,dir=SOUTH,no_anim=TRUE)) - .["target"]["side"] = icon2base64(get_flat_icon(target,dir=WEST,no_anim=TRUE)) - .["target"]["side_alt"] = icon2base64(get_flat_icon(target,dir=EAST,no_anim=TRUE)) - .["target"]["back"] = icon2base64(get_flat_icon(target,dir=NORTH,no_anim=TRUE)) + .["target"]["sprite"] = sanitize_css_class_name("[target.sprite_datum.type]") + .["target"]["sprite_size"] = spritesheet.icon_size_id(.["target"]["sprite"] + "S") .["target"]["modules"] = get_target_items(user) var/list/module_options = list() for(var/module in robot_modules) @@ -110,7 +115,7 @@ .["access_options"] = access_options // Section for source data for the module we might want to salvage if(source) - .["source"] += get_module_source(user) + .["source"] += get_module_source(user, spritesheet) var/list/all_robots = list() for(var/mob/living/silicon/robot/R in silicon_mob_list) if(!R.loc) @@ -573,10 +578,11 @@ target_items += list(list("name" = item.name, "ref" = "\ref[item]", "icon" = icon2html(item, user, sourceonly=TRUE), "desc" = item.desc)) return target_items -/datum/eventkit/modify_robot/proc/get_module_source(var/mob/user) +/datum/eventkit/modify_robot/proc/get_module_source(var/mob/user, var/datum/asset/spritesheet/robot_icons/spritesheet) var/list/source_list = list() source_list["model"] = source.module - source_list["front"] = icon2base64(get_flat_icon(source,dir=SOUTH,no_anim=TRUE)) + source_list["sprite"] = sanitize_css_class_name("[source.sprite_datum.type]") + source_list["sprite_size"] = spritesheet.icon_size_id(source_list["sprite"] + "S") var/list/source_items = list() for(var/obj/item in (source.module.modules | source.module.emag)) var/exists diff --git a/code/modules/asset_cache/asset_list_items.dm b/code/modules/asset_cache/asset_list_items.dm index 572c1a5d26e..564b0879488 100644 --- a/code/modules/asset_cache/asset_list_items.dm +++ b/code/modules/asset_cache/asset_list_items.dm @@ -437,6 +437,45 @@ Insert("bottle-[i]", 'icons/obj/chemical.dmi', "bottle-[i]") +// Robot UI sprites +/datum/asset/spritesheet/robot_icons + name = "robot_icons" + +/datum/asset/spritesheet/robot_icons/create_spritesheets() + for(var/datum/robot_sprite/S as anything in typesof(/datum/robot_sprite)) + if(!S.name || !S.sprite_icon_state) // snowflake out those customs... they suck + continue + var/icon/I_N = icon(S.sprite_icon, S.sprite_icon_state, NORTH) + var/icon/I_S = icon(S.sprite_icon, S.sprite_icon_state, SOUTH) + var/icon/I_W = icon(S.sprite_icon, S.sprite_icon_state, WEST) + var/icon/I_E = icon(S.sprite_icon, S.sprite_icon_state, EAST) + if(S.has_eye_sprites) + var/icon/I_NE = icon(S.sprite_icon, "[S.sprite_icon_state]-eyes", NORTH) + if(I_NE) + I_N.Blend(I_NE, ICON_OVERLAY) + if(S.has_eye_sprites) + var/icon/I_SE = icon(S.sprite_icon, "[S.sprite_icon_state]-eyes", SOUTH) + if(I_SE) + I_S.Blend(I_SE, ICON_OVERLAY) + if(S.has_eye_sprites) + var/icon/I_WE = icon(S.sprite_icon, "[S.sprite_icon_state]-eyes", WEST) + if(I_WE) + I_W.Blend(I_WE, ICON_OVERLAY) + if(S.has_eye_sprites) + var/icon/I_EE = icon(S.sprite_icon, "[S.sprite_icon_state]-eyes", EAST) + if(I_EE) + I_E.Blend(I_EE, ICON_OVERLAY) + var/imgid = sanitize_css_class_name("[S.type]") + I_N.Scale(120, 120) + I_S.Scale(120, 120) + I_W.Scale(120, 120) + I_E.Scale(120, 120) + Insert(imgid + "N", I_N) + Insert(imgid + "S", I_S) + Insert(imgid + "W", I_W) + Insert(imgid + "E", I_E) + + //Cloning pod sprites for UIs /datum/asset/simple/cloning assets = list( diff --git a/code/modules/client/preference_setup/loadout/loadout_accessories.dm b/code/modules/client/preference_setup/loadout/loadout_accessories.dm index d22bdcc20e9..dcd8cf03c38 100644 --- a/code/modules/client/preference_setup/loadout/loadout_accessories.dm +++ b/code/modules/client/preference_setup/loadout/loadout_accessories.dm @@ -360,18 +360,18 @@ /datum/gear/accessory/wristband_collection display_name = "wristbands (selection)" - path = /obj/item/clothing/accessory/wristbandcollection + path = /obj/item/clothing/accessory/wristband/collection /datum/gear/accessory/wristband_collection/New() ..() var/list/wristband_lists = list( - "Green, Blue and Yellow" = /obj/item/clothing/accessory/wristbandcollection, - "Pink, Black and Red" = /obj/item/clothing/accessory/wristbandcollection/pink, - "Red and Orange" = /obj/item/clothing/accessory/wristbandcollection/les, - "White, Pink and Blue" = /obj/item/clothing/accessory/wristbandcollection/trans, - "Blue, Purple and Pink" = /obj/item/clothing/accessory/wristbandcollection/bi, - "Black, White and Grey" = /obj/item/clothing/accessory/wristbandcollection/ace, - "Spiked" = /obj/item/clothing/accessory/wristband_spiked + "Green, Blue and Yellow" = /obj/item/clothing/accessory/wristband/collection, + "Pink, Black and Red" = /obj/item/clothing/accessory/wristband/collection/pink, + "Red and Orange" = /obj/item/clothing/accessory/wristband/collection/les, + "White, Pink and Blue" = /obj/item/clothing/accessory/wristband/collection/trans, + "Blue, Purple and Pink" = /obj/item/clothing/accessory/wristband/collection/bi, + "Black, White and Grey" = /obj/item/clothing/accessory/wristband/collection/ace, + "Spiked" = /obj/item/clothing/accessory/wristband/spiked ) gear_tweaks += new/datum/gear_tweak/path(wristband_lists) diff --git a/code/modules/client/preference_setup/loadout/loadout_fluffitems_vr.dm b/code/modules/client/preference_setup/loadout/loadout_fluffitems_vr.dm index c63f709505c..17030caab04 100644 --- a/code/modules/client/preference_setup/loadout/loadout_fluffitems_vr.dm +++ b/code/modules/client/preference_setup/loadout/loadout_fluffitems_vr.dm @@ -271,7 +271,7 @@ // C CKEYS /datum/gear/fluff/cappy_watch - path = /obj/item/clothing/accessory/watch + path = /obj/item/clothing/accessory/watch/custom display_name = "Cappy's Pocket Watch" ckeywhitelist = list("cappycat") character_name = list("Cappy Fuzzlyfeathers") @@ -528,7 +528,7 @@ character_name = list("Elizabeth Bayou") /datum/gear/fluff/mercury_vopal_ring - path = /obj/item/clothing/gloves/ring/material/void_opal/fluff/mercury + path = /obj/item/clothing/accessory/ring/material/void_opal/fluff/mercury display_name = "Mercury's Mate Ring" ckeywhitelist = list("haloren") character_name = list("Mercury") @@ -694,6 +694,12 @@ ckeywhitelist = list("john.wayne9392") character_name = list("Harmony Pretchl") +/datum/gear/fluff/vox_dylo_pills + path = /obj/item/storage/pill_bottle/dylovene + display_name = "Dylovene pill bottle" + ckeywhitelist = list("jparker890") + character_name = list("Krey-Timinine") + /datum/gear/fluff/koyo_box path = /obj/item/storage/box/fluff/koyoakimomi display_name = "Koyo's Box" @@ -1239,6 +1245,13 @@ ckeywhitelist = list("satinisle") character_name = list("Parriz Tavakdavi") +/datum/gear/fluff/dark_tarot + path = /obj/item/deck/dark_tarot + display_name = "dark rose tarot deck" + ckeywhitelist = list("satinisle") + character_name = list("Millie Orlen") + + // T CKEYS /datum/gear/fluff/ascian_medal path = /obj/item/clothing/accessory/medal/silver/unity/tabiranth diff --git a/code/modules/client/preference_setup/loadout/loadout_general_vr.dm b/code/modules/client/preference_setup/loadout/loadout_general_vr.dm index 3909acf199a..86a89ddfa83 100644 --- a/code/modules/client/preference_setup/loadout/loadout_general_vr.dm +++ b/code/modules/client/preference_setup/loadout/loadout_general_vr.dm @@ -56,7 +56,6 @@ toytype["Big Red Button"] = /obj/item/toy/redbutton toytype["Garden gnome"] = /obj/item/toy/gnome toytype["Toy AI"] = /obj/item/toy/AI - toytype["Hand buzzer"] = /obj/item/clothing/gloves/ring/buzzer/toy toytype["Toy nuke"] = /obj/item/toy/nuke toytype["Toy gibber"] = /obj/item/toy/minigibber toytype["Toy xeno"] = /obj/item/toy/toy_xeno diff --git a/code/modules/client/preference_setup/loadout/loadout_gloves.dm b/code/modules/client/preference_setup/loadout/loadout_gloves.dm index 859d6a0c4cd..fa712ecd276 100644 --- a/code/modules/client/preference_setup/loadout/loadout_gloves.dm +++ b/code/modules/client/preference_setup/loadout/loadout_gloves.dm @@ -74,27 +74,27 @@ /datum/gear/gloves/ring display_name = "ring selection" description = "Choose from a number of rings." - path = /obj/item/clothing/gloves/ring + path = /obj/item/clothing/accessory/ring cost = 1 /datum/gear/gloves/ring/New() ..() var/ringtype = list() - ringtype["CTI ring"] = /obj/item/clothing/gloves/ring/cti - ringtype["Mariner University ring"] = /obj/item/clothing/gloves/ring/mariner - ringtype["engagement ring"] = /obj/item/clothing/gloves/ring/engagement - ringtype["signet ring"] = /obj/item/clothing/gloves/ring/seal/signet - ringtype["masonic ring"] = /obj/item/clothing/gloves/ring/seal/mason - ringtype["ring, glass"] = /obj/item/clothing/gloves/ring/material/glass - ringtype["ring, wood"] = /obj/item/clothing/gloves/ring/material/wood - ringtype["ring, plastic"] = /obj/item/clothing/gloves/ring/material/plastic - ringtype["ring, iron"] = /obj/item/clothing/gloves/ring/material/iron - ringtype["ring, bronze"] = /obj/item/clothing/gloves/ring/material/bronze - ringtype["ring, steel"] = /obj/item/clothing/gloves/ring/material/steel - ringtype["ring, copper"] = /obj/item/clothing/gloves/ring/material/copper - ringtype["ring, silver"] = /obj/item/clothing/gloves/ring/material/silver - ringtype["ring, gold"] = /obj/item/clothing/gloves/ring/material/gold - ringtype["ring, platinum"] = /obj/item/clothing/gloves/ring/material/platinum + ringtype["CTI ring"] = /obj/item/clothing/accessory/ring/cti + ringtype["Mariner University ring"] = /obj/item/clothing/accessory/ring/mariner + ringtype["engagement ring"] = /obj/item/clothing/accessory/ring/engagement + ringtype["signet ring"] = /obj/item/clothing/accessory/ring/seal/signet + ringtype["masonic ring"] = /obj/item/clothing/accessory/ring/seal/mason + ringtype["ring, glass"] = /obj/item/clothing/accessory/ring/material/glass + ringtype["ring, wood"] = /obj/item/clothing/accessory/ring/material/wood + ringtype["ring, plastic"] = /obj/item/clothing/accessory/ring/material/plastic + ringtype["ring, iron"] = /obj/item/clothing/accessory/ring/material/iron + ringtype["ring, bronze"] = /obj/item/clothing/accessory/ring/material/bronze + ringtype["ring, steel"] = /obj/item/clothing/accessory/ring/material/steel + ringtype["ring, copper"] = /obj/item/clothing/accessory/ring/material/copper + ringtype["ring, silver"] = /obj/item/clothing/accessory/ring/material/silver + ringtype["ring, gold"] = /obj/item/clothing/accessory/ring/material/gold + ringtype["ring, platinum"] = /obj/item/clothing/accessory/ring/material/platinum gear_tweaks += new/datum/gear_tweak/path(ringtype) @@ -105,14 +105,14 @@ /datum/gear/gloves/watch display_name = "wristwatch selector" description = "Pick from a range of wristwatches." - path = /obj/item/clothing/gloves/watch + path = /obj/item/clothing/accessory/watch /datum/gear/gloves/watch/New() ..() var/list/selector_watches = list( - "plain plastic"=/obj/item/clothing/gloves/watch, - "silver"=/obj/item/clothing/gloves/watch/silver, - "gold"=/obj/item/clothing/gloves/watch/gold, - "survival"=/obj/item/clothing/gloves/watch/survival + "plain plastic"=/obj/item/clothing/accessory/watch, + "silver"=/obj/item/clothing/accessory/watch/silver, + "gold"=/obj/item/clothing/accessory/watch/gold, + "survival"=/obj/item/clothing/accessory/watch/survival ) gear_tweaks += new/datum/gear_tweak/path(sortAssoc(selector_watches)) diff --git a/code/modules/client/preference_setup/loadout/loadout_gloves_vr.dm b/code/modules/client/preference_setup/loadout/loadout_gloves_vr.dm index cfc0a6b1053..fd25064e85b 100644 --- a/code/modules/client/preference_setup/loadout/loadout_gloves_vr.dm +++ b/code/modules/client/preference_setup/loadout/loadout_gloves_vr.dm @@ -1,10 +1,10 @@ /datum/gear/gloves/goldring display_name = "wedding ring, gold" - path = /obj/item/clothing/gloves/ring/wedding + path = /obj/item/clothing/accessory/ring/wedding /datum/gear/gloves/silverring display_name = "wedding ring, silver" - path = /obj/item/clothing/gloves/ring/wedding/silver + path = /obj/item/clothing/accessory/ring/wedding/silver /datum/gear/gloves/colored display_name = "gloves, colorable" diff --git a/code/modules/client/verbs/advanced_who.dm b/code/modules/client/verbs/advanced_who.dm index 4c4af542a48..3e39936cf5d 100644 --- a/code/modules/client/verbs/advanced_who.dm +++ b/code/modules/client/verbs/advanced_who.dm @@ -7,7 +7,7 @@ var/list/Lines = list() - if(holder) + if(check_rights(R_ADMIN|R_SERVER|R_MOD,FALSE,src)) for(var/client/C in GLOB.clients) var/entry = "[C.key]" if(C.holder && C.holder.fakekey) diff --git a/code/modules/clothing/under/accessories/accessory.dm b/code/modules/clothing/accessories/accessory.dm similarity index 80% rename from code/modules/clothing/under/accessories/accessory.dm rename to code/modules/clothing/accessories/accessory.dm index 7c4b968b093..7610687a9a0 100644 --- a/code/modules/clothing/under/accessories/accessory.dm +++ b/code/modules/clothing/accessories/accessory.dm @@ -12,6 +12,8 @@ var/image/inv_overlay = null // Overlay used when attached to clothing. var/image/mob_overlay = null var/overlay_state = null + var/punch_force = 0 // added melee damage + var/punch_damtype = BRUTE // added melee damage type var/concealed_holster = 0 var/mob/living/carbon/human/wearer = null // To check if the wearer changes, so species spritesheets change properly. var/list/on_rolled = list() // Used when jumpsuit sleevels are rolled ("rolled" entry) or it's rolled down ("down"). Set to "none" to hide in those states. @@ -82,6 +84,11 @@ src.forceMove(S) has_suit.add_overlay(get_inv_overlay()) + has_suit.force += force + if(istype(S,/obj/item/clothing/gloves)) + var/obj/item/clothing/gloves/has_gloves = S + has_gloves.punch_force = has_gloves.punch_force + punch_force + if(user) to_chat(user, span_notice("You attach \the [src] to \the [has_suit].")) add_fingerprint(user) @@ -90,6 +97,10 @@ if(!has_suit) return has_suit.cut_overlay(get_inv_overlay()) + has_suit.force = initial(has_suit.force) + if(istype(has_suit,/obj/item/clothing/gloves)) + var/obj/item/clothing/gloves/has_gloves = has_suit + has_gloves.punch_force = initial(has_gloves.punch_force) has_suit = null if(user) usr.put_in_hands(src) @@ -376,85 +387,6 @@ icon_state = "tesh_neckscarf" species_restricted = list(SPECIES_TESHARI) -//bracelets - -/obj/item/clothing/accessory/bracelet - name = "bracelet" - desc = "A simple silver bracelet with a clasp." - icon = 'icons/inventory/accessory/item.dmi' - icon_state = "bracelet" - w_class = ITEMSIZE_TINY - slot_flags = SLOT_TIE - slot = ACCESSORY_SLOT_DECOR - -/obj/item/clothing/accessory/bracelet/friendship - name = "friendship bracelet" - desc = "A beautiful friendship bracelet in all the colors of the rainbow." - icon_state = "friendbracelet" - -/obj/item/clothing/accessory/bracelet/friendship/verb/dedicate_bracelet() - set name = "Dedicate Bracelet" - set category = "Object" - set desc = "Dedicate your friendship bracelet to a special someone." - var/mob/M = usr - if(!M.mind) - return 0 - - var/input = sanitizeSafe(input(usr, "Who do you want to dedicate the bracelet to?", ,""), MAX_NAME_LEN) - - if(src && input && !M.stat && in_range(M,src)) - desc = "A beautiful friendship bracelet in all the colors of the rainbow. It's dedicated to [input]." - to_chat(M, "You dedicate the bracelet to [input], remembering the times you've had together.") - return 1 - - -/obj/item/clothing/accessory/bracelet/material - icon_state = "materialbracelet" - -/obj/item/clothing/accessory/bracelet/material/New(var/newloc, var/new_material) - ..(newloc) - if(!new_material) - new_material = MAT_STEEL - material = get_material_by_name(new_material) - if(!istype(material)) - qdel(src) - return - name = "[material.display_name] bracelet" - desc = "A bracelet made from [material.display_name]." - color = material.icon_colour - -/obj/item/clothing/accessory/bracelet/material/get_material() - return material - -/obj/item/clothing/accessory/bracelet/material/wood/New(var/newloc) - ..(newloc, "wood") - -/obj/item/clothing/accessory/bracelet/material/plastic/New(var/newloc) - ..(newloc, "plastic") - -/obj/item/clothing/accessory/bracelet/material/iron/New(var/newloc) - ..(newloc, "iron") - -/obj/item/clothing/accessory/bracelet/material/steel/New(var/newloc) - ..(newloc, "steel") - -/obj/item/clothing/accessory/bracelet/material/silver/New(var/newloc) - ..(newloc, "silver") - -/obj/item/clothing/accessory/bracelet/material/gold/New(var/newloc) - ..(newloc, "gold") - -/obj/item/clothing/accessory/bracelet/material/platinum/New(var/newloc) - ..(newloc, "platinum") - -/obj/item/clothing/accessory/bracelet/material/phoron/New(var/newloc) - ..(newloc, "phoron") - -/obj/item/clothing/accessory/bracelet/material/glass/New(var/newloc) - ..(newloc, "glass") - - ..() - /obj/item/clothing/accessory/halfcape name = "half cape" desc = "A tasteful half-cape, suitible for European nobles and retro anime protagonists." @@ -473,78 +405,6 @@ icon_state = "sash" slot = ACCESSORY_SLOT_OVER -/obj/item/clothing/accessory/wristband - name = "wristband" - desc = "A simple plastic wristband." - icon = 'icons/inventory/accessory/item.dmi' - icon_state = "wristband" - w_class = ITEMSIZE_TINY - slot_flags = SLOT_TIE - slot = ACCESSORY_SLOT_DECOR - -/obj/item/clothing/accessory/wristbandcollection - name = "wristband collection" - desc = "A mix of colourable plastic wristbands." - icon = 'icons/inventory/accessory/item.dmi' - icon_state = "wristband_collection" - w_class = ITEMSIZE_TINY - slot_flags = SLOT_TIE - slot = ACCESSORY_SLOT_DECOR - -/obj/item/clothing/accessory/wristbandcollection/pink - name = "wristband collection" - desc = "A mix of colourable plastic wristbands." - icon = 'icons/inventory/accessory/item.dmi' - icon_state = "wristband_collection2" - w_class = ITEMSIZE_TINY - slot_flags = SLOT_TIE - slot = ACCESSORY_SLOT_DECOR - -/obj/item/clothing/accessory/wristbandcollection/les - name = "wristband collection" - desc = "A mix of colourable plastic wristbands." - icon = 'icons/inventory/accessory/item.dmi' - icon_state = "wristband_collection3" - w_class = ITEMSIZE_TINY - slot_flags = SLOT_TIE - slot = ACCESSORY_SLOT_DECOR - -/obj/item/clothing/accessory/wristbandcollection/trans - name = "wristband collection" - desc = "A mix of colourable plastic wristbands." - icon = 'icons/inventory/accessory/item.dmi' - icon_state = "wristband_collection4" - w_class = ITEMSIZE_TINY - slot_flags = SLOT_TIE - slot = ACCESSORY_SLOT_DECOR - -/obj/item/clothing/accessory/wristbandcollection/bi - name = "wristband collection" - desc = "A mix of colourable plastic wristbands." - icon = 'icons/inventory/accessory/item.dmi' - icon_state = "wristband_collection5" - w_class = ITEMSIZE_TINY - slot_flags = SLOT_TIE - slot = ACCESSORY_SLOT_DECOR - -/obj/item/clothing/accessory/wristbandcollection/ace - name = "wristband collection" - desc = "A mix of colourable plastic wristbands." - icon = 'icons/inventory/accessory/item.dmi' - icon_state = "wristband_collection6" - w_class = ITEMSIZE_TINY - slot_flags = SLOT_TIE - slot = ACCESSORY_SLOT_DECOR - -/obj/item/clothing/accessory/wristband_spiked - name = "wristband (spiked)" - desc = "A black wristband with short spikes around it." - icon = 'icons/inventory/accessory/item.dmi' - icon_state = "wristband_spiked" - w_class = ITEMSIZE_TINY - slot_flags = SLOT_TIE - slot = ACCESSORY_SLOT_DECOR - //Gaiter scarves /obj/item/clothing/accessory/gaiter name = "red neck gaiter" diff --git a/code/modules/clothing/under/accessories/accessory_vr.dm b/code/modules/clothing/accessories/accessory_vr.dm similarity index 97% rename from code/modules/clothing/under/accessories/accessory_vr.dm rename to code/modules/clothing/accessories/accessory_vr.dm index 4c8e2c61432..db12dc815cc 100644 --- a/code/modules/clothing/under/accessories/accessory_vr.dm +++ b/code/modules/clothing/accessories/accessory_vr.dm @@ -5,7 +5,7 @@ /obj/item/clothing/accessory/choker //A colorable, tagless choker name = "plain choker" slot_flags = SLOT_TIE | SLOT_OCLOTHING - desc = "A simple, plain choker. Or maybe it's a collar? Use in-hand to customize it." + desc = "A simple, plain choker. Or maybe it's a collar?" icon = 'icons/inventory/accessory/item_vr.dmi' icon_override = 'icons/inventory/accessory/mob_vr.dmi' icon_state = "choker_cst" @@ -44,18 +44,6 @@ /obj/item/clothing/accessory/choker/dropped() icon_override = icon_previous_override -/obj/item/clothing/accessory/choker/attack_self(mob/user as mob) - if(!customized) - var/design = tgui_input_list(user,"Descriptor?","Pick descriptor","Descriptor", list("plain","simple","ornate","elegant","opulent")) - var/material = tgui_input_list(user,"Material?","Pick material","Material", list("leather","velvet","lace","fabric","latex","plastic","metal","chain","silver","gold","platinum","steel","bead","ruby","sapphire","emerald","diamond")) - var/type = tgui_input_list(user,"Type?","Pick type","Type", list("choker","collar","necklace")) - name = "[design] [material] [type]" - desc = "A [type], made of [material]. It's rather [design]." - customized = 1 - to_chat(usr,span_notice("[src] has now been customized.")) - else - to_chat(usr,span_notice("[src] has already been customized!")) - /obj/item/clothing/accessory/collar slot_flags = SLOT_TIE | SLOT_OCLOTHING icon = 'icons/inventory/accessory/item_vr.dmi' diff --git a/code/modules/clothing/under/accessories/altevian_vr.dm b/code/modules/clothing/accessories/altevian_vr.dm similarity index 100% rename from code/modules/clothing/under/accessories/altevian_vr.dm rename to code/modules/clothing/accessories/altevian_vr.dm diff --git a/code/modules/clothing/under/accessories/armband.dm b/code/modules/clothing/accessories/armband.dm similarity index 100% rename from code/modules/clothing/under/accessories/armband.dm rename to code/modules/clothing/accessories/armband.dm diff --git a/code/modules/clothing/under/accessories/armor.dm b/code/modules/clothing/accessories/armor.dm similarity index 100% rename from code/modules/clothing/under/accessories/armor.dm rename to code/modules/clothing/accessories/armor.dm diff --git a/code/modules/clothing/under/accessories/badges.dm b/code/modules/clothing/accessories/badges.dm similarity index 100% rename from code/modules/clothing/under/accessories/badges.dm rename to code/modules/clothing/accessories/badges.dm diff --git a/code/modules/clothing/under/accessories/badges_vr.dm b/code/modules/clothing/accessories/badges_vr.dm similarity index 100% rename from code/modules/clothing/under/accessories/badges_vr.dm rename to code/modules/clothing/accessories/badges_vr.dm diff --git a/code/modules/clothing/under/accessories/clothing.dm b/code/modules/clothing/accessories/clothing.dm similarity index 100% rename from code/modules/clothing/under/accessories/clothing.dm rename to code/modules/clothing/accessories/clothing.dm diff --git a/code/modules/clothing/under/accessories/clothing_vr.dm b/code/modules/clothing/accessories/clothing_vr.dm similarity index 100% rename from code/modules/clothing/under/accessories/clothing_vr.dm rename to code/modules/clothing/accessories/clothing_vr.dm diff --git a/code/modules/clothing/accessories/hands.dm b/code/modules/clothing/accessories/hands.dm new file mode 100644 index 00000000000..befe128fc71 --- /dev/null +++ b/code/modules/clothing/accessories/hands.dm @@ -0,0 +1,141 @@ +/obj/item/clothing/accessory/knuckledusters + name = "knuckle dusters" + desc = "A pair of brass knuckles. Generally used to enhance the user's punches." + icon_state = "knuckledusters" + slot = ACCESSORY_SLOT_RING + slot_flags = SLOT_GLOVES + matter = list(MAT_STEEL = 500) + attack_verb = list("punched", "beaten", "struck") + siemens_coefficient = 1 + force = 10 //base punch strength is 5 + punch_force = 5 //added to base punch strength when added as a glove accessory + icon = 'icons/inventory/hands/item.dmi' + item_icons = list( + slot_l_hand_str = 'icons/mob/items/lefthand_gloves.dmi', + slot_r_hand_str = 'icons/mob/items/righthand_gloves.dmi', + ) + drop_sound = 'sound/items/drop/metalboots.ogg' + pickup_sound = 'sound/items/pickup/toolbox.ogg' + +//bracelets + +/obj/item/clothing/accessory/bracelet + name = "bracelet" + desc = "A simple silver bracelet with a clasp." + icon = 'icons/inventory/accessory/item.dmi' + icon_state = "bracelet" + w_class = ITEMSIZE_TINY + slot_flags = SLOT_GLOVES + slot = ACCESSORY_SLOT_WRIST + +/obj/item/clothing/accessory/bracelet/friendship + name = "friendship bracelet" + desc = "A beautiful friendship bracelet in all the colors of the rainbow." + icon_state = "friendbracelet" + +/obj/item/clothing/accessory/bracelet/friendship/verb/dedicate_bracelet() + set name = "Dedicate Bracelet" + set category = "Object" + set desc = "Dedicate your friendship bracelet to a special someone." + var/mob/M = usr + if(!M.mind) + return 0 + + var/input = sanitizeSafe(input(usr, "Who do you want to dedicate the bracelet to?", ,""), MAX_NAME_LEN) + + if(src && input && !M.stat && in_range(M,src)) + desc = "A beautiful friendship bracelet in all the colors of the rainbow. It's dedicated to [input]." + to_chat(M, "You dedicate the bracelet to [input], remembering the times you've had together.") + return 1 + + +/obj/item/clothing/accessory/bracelet/material + icon_state = "materialbracelet" + +/obj/item/clothing/accessory/bracelet/material/New(var/newloc, var/new_material) + ..(newloc) + if(!new_material) + new_material = MAT_STEEL + material = get_material_by_name(new_material) + if(!istype(material)) + qdel(src) + return + name = "[material.display_name] bracelet" + desc = "A bracelet made from [material.display_name]." + color = material.icon_colour + +/obj/item/clothing/accessory/bracelet/material/get_material() + return material + +/obj/item/clothing/accessory/bracelet/material/wood/New(var/newloc) + ..(newloc, "wood") + +/obj/item/clothing/accessory/bracelet/material/plastic/New(var/newloc) + ..(newloc, "plastic") + +/obj/item/clothing/accessory/bracelet/material/iron/New(var/newloc) + ..(newloc, "iron") + +/obj/item/clothing/accessory/bracelet/material/steel/New(var/newloc) + ..(newloc, "steel") + +/obj/item/clothing/accessory/bracelet/material/silver/New(var/newloc) + ..(newloc, "silver") + +/obj/item/clothing/accessory/bracelet/material/gold/New(var/newloc) + ..(newloc, "gold") + +/obj/item/clothing/accessory/bracelet/material/platinum/New(var/newloc) + ..(newloc, "platinum") + +/obj/item/clothing/accessory/bracelet/material/phoron/New(var/newloc) + ..(newloc, "phoron") + +/obj/item/clothing/accessory/bracelet/material/glass/New(var/newloc) + ..(newloc, "glass") + +//wristbands + +/obj/item/clothing/accessory/wristband + name = "wristband" + desc = "A simple plastic wristband." + icon = 'icons/inventory/accessory/item.dmi' + icon_state = "wristband" + w_class = ITEMSIZE_TINY + slot_flags = SLOT_GLOVES + slot = ACCESSORY_SLOT_WRIST + +/obj/item/clothing/accessory/wristband/spiked + name = "wristband (spiked)" + desc = "A black wristband with short spikes around it." + icon_state = "wristband_spiked" + +/obj/item/clothing/accessory/wristband/collection + name = "wristband collection" + desc = "A mix of colourable plastic wristbands." + icon_state = "wristband_collection" + +/obj/item/clothing/accessory/wristband/collection/pink + name = "wristband collection" + desc = "A mix of colourable plastic wristbands." + icon_state = "wristband_collection2" + +/obj/item/clothing/accessory/wristband/collection/les + name = "wristband collection" + desc = "A mix of colourable plastic wristbands." + icon_state = "wristband_collection3" + +/obj/item/clothing/accessory/wristband/collection/trans + name = "wristband collection" + desc = "A mix of colourable plastic wristbands." + icon_state = "wristband_collection4" + +/obj/item/clothing/accessory/wristband/collection/bi + name = "wristband collection" + desc = "A mix of colourable plastic wristbands." + icon_state = "wristband_collection5" + +/obj/item/clothing/accessory/wristband/collection/ace + name = "wristband collection" + desc = "A mix of colourable plastic wristbands." + icon_state = "wristband_collection6" diff --git a/code/modules/clothing/under/accessories/holster.dm b/code/modules/clothing/accessories/holster.dm similarity index 100% rename from code/modules/clothing/under/accessories/holster.dm rename to code/modules/clothing/accessories/holster.dm diff --git a/code/modules/clothing/under/accessories/holster_vr.dm b/code/modules/clothing/accessories/holster_vr.dm similarity index 100% rename from code/modules/clothing/under/accessories/holster_vr.dm rename to code/modules/clothing/accessories/holster_vr.dm diff --git a/code/modules/clothing/under/accessories/lockets.dm b/code/modules/clothing/accessories/lockets.dm similarity index 100% rename from code/modules/clothing/under/accessories/lockets.dm rename to code/modules/clothing/accessories/lockets.dm diff --git a/code/modules/clothing/under/accessories/permits.dm b/code/modules/clothing/accessories/permits.dm similarity index 100% rename from code/modules/clothing/under/accessories/permits.dm rename to code/modules/clothing/accessories/permits.dm diff --git a/code/modules/clothing/under/accessories/permits_vr.dm b/code/modules/clothing/accessories/permits_vr.dm similarity index 100% rename from code/modules/clothing/under/accessories/permits_vr.dm rename to code/modules/clothing/accessories/permits_vr.dm diff --git a/code/modules/clothing/accessories/rings.dm b/code/modules/clothing/accessories/rings.dm new file mode 100644 index 00000000000..361c87c854d --- /dev/null +++ b/code/modules/clothing/accessories/rings.dm @@ -0,0 +1,204 @@ +//Generic Ring + +/obj/item/clothing/accessory/ring + name = "generic ring" + desc = "Torus shaped finger decoration." + icon_state = "material" + drop_sound = 'sound/items/drop/ring.ogg' + slot = ACCESSORY_SLOT_RING + slot_flags = SLOT_GLOVES + item_icons = list( + slot_l_hand_str = 'icons/mob/items/lefthand_gloves.dmi', + slot_r_hand_str = 'icons/mob/items/righthand_gloves.dmi', + ) + gender = PLURAL + w_class = ITEMSIZE_SMALL + icon = 'icons/inventory/hands/item.dmi' + drop_sound = 'sound/items/drop/ring.ogg' + pickup_sound = 'sound/items/pickup/ring.ogg' + force = 7 //base punch strength is 5 + punch_force = 2 //added to base punch strength when added as a glove accessory + siemens_coefficient = 1 + +///////////////////////////////////////// +//Standard Rings +/obj/item/clothing/accessory/ring/engagement + name = "engagement ring" + desc = "An engagement ring. It certainly looks expensive." + icon_state = "diamond" + +/obj/item/clothing/accessory/ring/engagement/attack_self(mob/user) + user.visible_message(span_warning("\The [user] gets down on one knee, presenting \the [src]."),span_warning("You get down on one knee, presenting \the [src].")) + +/obj/item/clothing/accessory/ring/cti + name = "CTI ring" + desc = "A ring commemorating graduation from CTI." + icon_state = "cti-grad" + +/obj/item/clothing/accessory/ring/mariner + name = "Mariner University ring" + desc = "A ring commemorating graduation from Mariner University." + icon_state = "mariner-grad" + + +///////////////////////////////////////// +//Reagent Rings + +/obj/item/clothing/accessory/ring/reagent + flags = OPENCONTAINER + origin_tech = list(TECH_MATERIAL = 2, TECH_ILLEGAL = 4) + +/obj/item/clothing/accessory/ring/reagent/Initialize() + . = ..() + create_reagents(15) + +/obj/item/clothing/accessory/ring/reagent/equipped(var/mob/living/carbon/human/H) + ..() + if(istype(H) && H.gloves==src) + + if(reagents.total_volume) + to_chat(H, span_danger("You feel a prick as you slip on \the [src].")) + if(H.reagents) + var/contained = reagents.get_reagents() + var/trans = reagents.trans_to_mob(H, 15, CHEM_BLOOD) + add_attack_logs(usr, H, "Injected with [name] containing [contained] transferred [trans] units") + return + +//Sleepy Ring +/obj/item/clothing/accessory/ring/reagent/sleepy + name = "silver ring" + desc = "A ring made from what appears to be silver." + icon_state = "material" + origin_tech = list(TECH_MATERIAL = 2, TECH_ILLEGAL = 5) + +/obj/item/clothing/accessory/ring/reagent/sleepy/Initialize() + . = ..() + reagents.add_reagent("chloralhydrate", 15) // Less than a sleepy-pen, but still enough to knock someone out + +///////////////////////////////////////// +//Seals and Signet Rings + +/obj/item/clothing/accessory/ring/seal + var/stamptext = null + +/obj/item/clothing/accessory/ring/seal/secgen + name = "Secretary-General's official seal" + desc = "The official seal of the Secretary-General of the Sol Central Government, featured prominently on a silver ring." + icon_state = "seal-secgen" + +/obj/item/clothing/accessory/ring/seal/mason + name = "\improper Masonic ring" + desc = "The Square and Compasses feature prominently on this Masonic ring." + icon_state = "seal-masonic" + +/obj/item/clothing/accessory/ring/seal/signet + name = "signet ring" + desc = "A signet ring, for when you're too sophisticated to sign letters." + icon_state = "seal-signet" + var/nameset = FALSE + +/obj/item/clothing/accessory/ring/seal/signet/attack_self(mob/user) + if(nameset) + to_chat(user, span_notice("The [src] has already been claimed!")) + return + + to_chat(user, span_notice("You claim the [src] as your own!")) + change_name(user) + nameset = TRUE + +/obj/item/clothing/accessory/ring/seal/signet/proc/change_name(var/signet_name = "Unknown") + name = "[signet_name]'s signet ring" + desc = "A signet ring belonging to [signet_name], for when you're too sophisticated to sign letters." + +/obj/item/clothing/accessory/ring/wedding + name = "golden wedding ring" + desc = "For showing your devotion to another person. It has a golden glimmer to it." + icon = 'icons/inventory/hands/item_vr.dmi' + icon_state = "wedring_g" + item_state = "wedring_g" + var/partnername = "" + +/obj/item/clothing/accessory/ring/wedding/attack_self(mob/user) + partnername = copytext(sanitize(input(user, "Would you like to change the holoengraving on the ring?", "Name your spouse", "Bae") as null|text),1,MAX_NAME_LEN) + name = "[initial(name)] - [partnername]" + +/obj/item/clothing/accessory/ring/wedding/silver + name = "silver wedding ring" + desc = "For showing your devotion to another person. It has a silver glimmer to it." + icon_state = "wedring_s" + item_state = "wedring_s" + +///////////////////////////////////////// +//Material Rings +/obj/item/clothing/accessory/ring/material + icon = 'icons/inventory/hands/item.dmi' + icon_state = "material" + +/obj/item/clothing/accessory/ring/material/New(var/newloc, var/new_material) + ..(newloc) + if(!new_material) + new_material = MAT_STEEL + material = get_material_by_name(new_material) + if(!istype(material)) + qdel(src) + return + name = "[material.display_name] ring" + desc = "A ring made from [material.display_name]." + color = material.icon_colour + +/obj/item/clothing/accessory/ring/material/get_material() + return material + +/obj/item/clothing/accessory/ring/material/wood/New(var/newloc) + ..(newloc, MAT_WOOD) + +/obj/item/clothing/accessory/ring/material/plastic/New(var/newloc) + ..(newloc, MAT_PLASTIC) + +/obj/item/clothing/accessory/ring/material/iron/New(var/newloc) + ..(newloc, MAT_IRON) + +/obj/item/clothing/accessory/ring/material/glass/New(var/newloc) + ..(newloc, MAT_GLASS) + +/obj/item/clothing/accessory/ring/material/steel/New(var/newloc) + ..(newloc, MAT_STEEL) + +/obj/item/clothing/accessory/ring/material/silver/New(var/newloc) + ..(newloc, MAT_SILVER) + +/obj/item/clothing/accessory/ring/material/gold/New(var/newloc) + ..(newloc, MAT_GOLD) + +/obj/item/clothing/accessory/ring/material/platinum/New(var/newloc) + ..(newloc, MAT_PLATINUM) + +/obj/item/clothing/accessory/ring/material/phoron/New(var/newloc) + ..(newloc, MAT_PHORON) + +/obj/item/clothing/accessory/ring/material/titanium/New(var/newloc) + ..(newloc, MAT_TITANIUM) + +/obj/item/clothing/accessory/ring/material/copper/New(var/newloc) + ..(newloc, MAT_COPPER) + +/obj/item/clothing/accessory/ring/material/bronze/New(var/newloc) + ..(newloc, MAT_BRONZE) + +/obj/item/clothing/accessory/ring/material/uranium/New(var/newloc) + ..(newloc, MAT_URANIUM) + +/obj/item/clothing/accessory/ring/material/osmium/New(var/newloc) + ..(newloc, MAT_OSMIUM) + +/obj/item/clothing/accessory/ring/material/lead/New(var/newloc) + ..(newloc, MAT_LEAD) + +/obj/item/clothing/accessory/ring/material/diamond/New(var/newloc) + ..(newloc, MAT_DIAMOND) + +/obj/item/clothing/accessory/ring/material/tin/New(var/newloc) + ..(newloc, MAT_TIN) + +/obj/item/clothing/accessory/ring/material/void_opal/New(var/newloc) + ..(newloc, MAT_VOPAL) diff --git a/code/modules/clothing/under/accessories/shiny_vr.dm b/code/modules/clothing/accessories/shiny_vr.dm similarity index 100% rename from code/modules/clothing/under/accessories/shiny_vr.dm rename to code/modules/clothing/accessories/shiny_vr.dm diff --git a/code/modules/clothing/under/accessories/storage.dm b/code/modules/clothing/accessories/storage.dm similarity index 100% rename from code/modules/clothing/under/accessories/storage.dm rename to code/modules/clothing/accessories/storage.dm diff --git a/code/modules/clothing/under/accessories/storage_vr.dm b/code/modules/clothing/accessories/storage_vr.dm similarity index 100% rename from code/modules/clothing/under/accessories/storage_vr.dm rename to code/modules/clothing/accessories/storage_vr.dm diff --git a/code/modules/clothing/under/accessories/temperature/poncho.dm b/code/modules/clothing/accessories/temperature/poncho.dm similarity index 100% rename from code/modules/clothing/under/accessories/temperature/poncho.dm rename to code/modules/clothing/accessories/temperature/poncho.dm diff --git a/code/modules/clothing/under/accessories/torch.dm b/code/modules/clothing/accessories/torch.dm similarity index 100% rename from code/modules/clothing/under/accessories/torch.dm rename to code/modules/clothing/accessories/torch.dm diff --git a/code/modules/clothing/under/accessories/torch_vr.dm b/code/modules/clothing/accessories/torch_vr.dm similarity index 100% rename from code/modules/clothing/under/accessories/torch_vr.dm rename to code/modules/clothing/accessories/torch_vr.dm diff --git a/code/modules/clothing/accessories/watches.dm b/code/modules/clothing/accessories/watches.dm new file mode 100644 index 00000000000..5a93cb94f0e --- /dev/null +++ b/code/modules/clothing/accessories/watches.dm @@ -0,0 +1,72 @@ +/obj/item/clothing/accessory/watch + name = "wristwatch" + desc = "A cheap plastic quartz-based wristwatch. Painfully archaic by modern standards, but there's something charming about it all the same." + icon_state = "wristwatch_basic" + siemens_coefficient = 1 + gender = "neuter" + slot = ACCESSORY_SLOT_WRIST + slot_flags = SLOT_GLOVES + icon = 'icons/inventory/hands/item.dmi' + item_icons = list( + slot_l_hand_str = 'icons/mob/items/lefthand_gloves.dmi', + slot_r_hand_str = 'icons/mob/items/righthand_gloves.dmi', + ) + sprite_sheets = list( + SPECIES_TESHARI = 'icons/inventory/hands/mob_teshari.dmi', + SPECIES_VOX = 'icons/inventory/hands/mob_vox.dmi' + ) + +/obj/item/clothing/accessory/watch/examine(mob/user) + . = ..() + + if(Adjacent(user)) + . += span_notice("The current station time is [stationtime2text()].") + +/obj/item/clothing/accessory/watch/silver + name = "silver wristwatch" + desc = "A humble silver (or maybe chrome) plated wristwatch. It's quite archaic, but nonetheless classy in its own way." + icon_state = "wristwatch_silver" + +/obj/item/clothing/accessory/watch/gold + name = "gold wristwatch" + desc = "A very fancy gold-plated wristwatch. For when you want to casually show off just how wealthy you are. It even tells the time!" + icon_state = "wristwatch_gold" + +/obj/item/clothing/accessory/watch/survival + name = "survival watch" + desc = "An overengineered wristwatch that purports to be both space and water proof, and includes a compass, micro GPS beacon, and temperature and pressure sensors. The beacon is off by default, and can only transmit its location: it cannot scan for other signals." + description_fluff = "Hold ALT whilst left-clicking on the survival watch to toggle the status of its micro-beacon." + icon_state = "wristwatch_survival" + + var/obj/item/gps/gps = null + +/obj/item/clothing/accessory/watch/survival/examine(mob/user) + . = ..() + + if(Adjacent(user)) + . += span_notice("You are currently facing [dir2text(user.dir)]. The micro beacon is [gps.tracking ? "on" : "off"].") + var/TB = user.loc + if(istype(TB, /turf/)) //no point returning light level if we're not on a turf (might be *in* someone!) + var/turf/TL = TB + var/light_level = TL.get_lumcount() + if(light_level) + . += span_notice("Light Level: [TL.get_lumcount()]") + else + . += span_notice("It's too dark to see the light level!") + if(istype(TB, /turf/simulated)) //no point returning atmospheric data from unsimulated tiles (they don't track pressure anyway, only temperature) + var/turf/simulated/T = TB + var/datum/gas_mixture/env = T.return_air() + . += span_notice("Pressure: [env.return_pressure()]kPa / Temperature: [env.temperature]K ") + +/obj/item/clothing/accessory/watch/survival/New() + gps = new/obj/item/gps/watch(src) + +/obj/item/gps/watch + gps_tag = "SRV-WTCH" + +/obj/item/clothing/accessory/watch/survival/AltClick(mob/user) + . = ..() + + if(Adjacent(user)) + gps.tracking = !gps.tracking + to_chat(user,span_notice("You turn the micro beacon [gps.tracking ? "on" : "off"].")) diff --git a/code/modules/clothing/clothing.dm b/code/modules/clothing/clothing.dm index 45f808a1488..a69ddf2ab0e 100644 --- a/code/modules/clothing/clothing.dm +++ b/code/modules/clothing/clothing.dm @@ -326,6 +326,13 @@ drop_sound = 'sound/items/drop/gloves.ogg' pickup_sound = 'sound/items/pickup/gloves.ogg' + valid_accessory_slots = (\ + ACCESSORY_SLOT_RING\ + |ACCESSORY_SLOT_WRIST) + restricted_accessory_slots = (\ + ACCESSORY_SLOT_RING\ + |ACCESSORY_SLOT_WRIST) + /obj/item/clothing/proc/set_clothing_index() return @@ -422,8 +429,6 @@ if(special_attack_type && ispath(special_attack_type)) special_attack = new special_attack_type - - ///////////////////////////////////////////////////////////////////// //Rings diff --git a/code/modules/clothing/gloves/antagonist.dm b/code/modules/clothing/gloves/antagonist.dm index 83e595a0ddd..34574e2e538 100644 --- a/code/modules/clothing/gloves/antagonist.dm +++ b/code/modules/clothing/gloves/antagonist.dm @@ -88,70 +88,3 @@ if(proximity && istype(usr, /mob/living/carbon/human) && do_after(usr, 1 SECOND, A)) return pickpocket(usr, A, proximity) return 0 - -// Buzzer Ring - Traitor, Merc. -/obj/item/clothing/gloves/ring/buzzer - name = "ring" - desc = "A plain metal band." - description_antag = "This morphium-alloy ring continually generates an electric field, capable of electrocuting a target while not injuring the wearer.\ - The device is also capable of 'frankenstein'-ing a corpse, long after normal technology would be able to save them. The body will still be tied to the\ - normal damage limits for survival, however, so care must be taken." - icon_state = "material" - var/battery_type = /obj/item/cell/device/weapon/recharge - var/obj/item/cell/battery = null - -/obj/item/clothing/gloves/ring/buzzer/get_cell() - return battery - -/obj/item/clothing/gloves/ring/buzzer/Initialize() - . = ..() - if(!battery) - battery = new battery_type(src) - -/obj/item/clothing/gloves/ring/buzzer/Touch(var/atom/A, var/proximity) - if(proximity && istype(usr, /mob/living/carbon/human)) - return zap(usr, A, proximity) - return 0 - -/obj/item/clothing/gloves/ring/buzzer/proc/zap(var/mob/living/carbon/human/user, var/atom/movable/target, var/proximity) - . = FALSE - if(user.a_intent == I_HURT && battery.percent() >= 50) - if(isliving(target)) - var/mob/living/L = target - - if(ishuman(L) && battery.percent() >= 90) // Silent text-wise, for maximum potential for gimmicks. - var/mob/living/carbon/human/H = L - - if(H.stat == DEAD) - . = TRUE - - do_defib(H) - - to_chat(L, span_warning("You feel a powerful shock!")) - if(!.) - playsound(L, 'sound/effects/sparks7.ogg', 40, 1) - L.electrocute_act(battery.percent() * 0.25, src) - battery.emp_act(2) - return . - - return 0 - -/obj/item/clothing/gloves/ring/buzzer/proc/do_defib(var/mob/living/carbon/human/H = null) - if(!istype(H)) - return 0 - - dead_mob_list.Remove(H) - if((H in living_mob_list) || (H in dead_mob_list)) - WARNING("Mob [H] was ring-defibbed but already in the living or dead list still!") - living_mob_list += H - - H.timeofdeath = 0 - H.set_stat(UNCONSCIOUS) - H.failed_last_breath = 0 - H.reload_fullscreen() - - H.emote("gasp") - H.Weaken(rand(10,25)) - H.updatehealth() - - battery.emp_act(1) diff --git a/code/modules/clothing/gloves/miscellaneous.dm b/code/modules/clothing/gloves/miscellaneous.dm index 3862469c857..31e641348a5 100644 --- a/code/modules/clothing/gloves/miscellaneous.dm +++ b/code/modules/clothing/gloves/miscellaneous.dm @@ -121,21 +121,6 @@ heat_protection = HANDS max_heat_protection_temperature = GLOVES_MAX_HEAT_PROTECTION_TEMPERATURE -/obj/item/clothing/gloves/knuckledusters - name = "knuckle dusters" - desc = "A pair of brass knuckles. Generally used to enhance the user's punches." - icon_state = "knuckledusters" - matter = list(MAT_STEEL = 500) - attack_verb = list("punched", "beaten", "struck") - flags = THICKMATERIAL // Stops rings from increasing hit strength - siemens_coefficient = 1 - fingerprint_chance = 100 - overgloves = 1 - force = 5 - punch_force = 5 - drop_sound = 'sound/items/drop/metalboots.ogg' - pickup_sound = 'sound/items/pickup/toolbox.ogg' - /obj/item/clothing/gloves/ranger var/glovecolor = "white" name = "ranger gloves" @@ -172,65 +157,3 @@ name = "water wings" desc = "Swim aids designed to help a wearer float in water and learn to swim." icon_state = "waterwings" - -/obj/item/clothing/gloves/watch - name = "wristwatch" - desc = "A cheap plastic quartz-based wristwatch. Painfully archaic by modern standards, but there's something charming about it all the same." - icon_state = "wristwatch_basic" - siemens_coefficient = 1 - gender = "neuter" - -/obj/item/clothing/gloves/watch/examine(mob/user) - . = ..() - - if(Adjacent(user)) - . += span_notice("The current station time is [stationtime2text()].") - -/obj/item/clothing/gloves/watch/silver - name = "silver wristwatch" - desc = "A humble silver (or maybe chrome) plated wristwatch. It's quite archaic, but nonetheless classy in its own way." - icon_state = "wristwatch_silver" - -/obj/item/clothing/gloves/watch/gold - name = "gold wristwatch" - desc = "A very fancy gold-plated wristwatch. For when you want to casually show off just how wealthy you are. It even tells the time!" - icon_state = "wristwatch_gold" - -/obj/item/clothing/gloves/watch/survival - name = "survival watch" - desc = "An overengineered wristwatch that purports to be both space and water proof, and includes a compass, micro GPS beacon, and temperature and pressure sensors. The beacon is off by default, and can only transmit its location: it cannot scan for other signals." - description_fluff = "Hold ALT whilst left-clicking on the survival watch to toggle the status of its micro-beacon." - icon_state = "wristwatch_survival" - - var/obj/item/gps/gps = null - -/obj/item/clothing/gloves/watch/survival/examine(mob/user) - . = ..() - - if(Adjacent(user) && src.loc == user) - . += span_notice("You are currently facing [dir2text(user.dir)]. The micro beacon is [gps.tracking ? "on" : "off"].") - var/TB = src.loc.loc - if(istype(TB, /turf/)) //no point returning light level if we're not on a turf (might be *in* someone!) - var/turf/TL = TB - var/light_level = TL.get_lumcount() - if(light_level) - . += span_notice("Light Level: [TL.get_lumcount()]") - else - . += span_notice("It's too dark to see the light level!") - if(istype(TB, /turf/simulated)) //no point returning atmospheric data from unsimulated tiles (they don't track pressure anyway, only temperature) - var/turf/simulated/T = TB - var/datum/gas_mixture/env = T.return_air() - . += span_notice("Pressure: [env.return_pressure()]kPa / Temperature: [env.temperature]K ") - -/obj/item/clothing/gloves/watch/survival/New() - gps = new/obj/item/gps/watch(src) - -/obj/item/gps/watch - gps_tag = "SRV-WTCH" - -/obj/item/clothing/gloves/watch/survival/AltClick(mob/user) - . = ..() - - if(Adjacent(user)) - gps.tracking = !gps.tracking - to_chat(user,span_notice("You turn the micro beacon [gps.tracking ? "on" : "off"].")) diff --git a/code/modules/clothing/rings/material.dm b/code/modules/clothing/rings/material.dm deleted file mode 100644 index 30242fef66e..00000000000 --- a/code/modules/clothing/rings/material.dm +++ /dev/null @@ -1,74 +0,0 @@ -///////////////////////////////////////// -//Material Rings -/obj/item/clothing/gloves/ring/material - icon = 'icons/inventory/hands/item.dmi' - icon_state = "material" - -/obj/item/clothing/gloves/ring/material/New(var/newloc, var/new_material) - ..(newloc) - if(!new_material) - new_material = MAT_STEEL - material = get_material_by_name(new_material) - if(!istype(material)) - qdel(src) - return - name = "[material.display_name] ring" - desc = "A ring made from [material.display_name]." - color = material.icon_colour - -/obj/item/clothing/gloves/ring/material/get_material() - return material - -/obj/item/clothing/gloves/ring/material/wood/New(var/newloc) - ..(newloc, MAT_WOOD) - -/obj/item/clothing/gloves/ring/material/plastic/New(var/newloc) - ..(newloc, MAT_PLASTIC) - -/obj/item/clothing/gloves/ring/material/iron/New(var/newloc) - ..(newloc, MAT_IRON) - -/obj/item/clothing/gloves/ring/material/glass/New(var/newloc) - ..(newloc, MAT_GLASS) - -/obj/item/clothing/gloves/ring/material/steel/New(var/newloc) - ..(newloc, MAT_STEEL) - -/obj/item/clothing/gloves/ring/material/silver/New(var/newloc) - ..(newloc, MAT_SILVER) - -/obj/item/clothing/gloves/ring/material/gold/New(var/newloc) - ..(newloc, MAT_GOLD) - -/obj/item/clothing/gloves/ring/material/platinum/New(var/newloc) - ..(newloc, MAT_PLATINUM) - -/obj/item/clothing/gloves/ring/material/phoron/New(var/newloc) - ..(newloc, MAT_PHORON) - -/obj/item/clothing/gloves/ring/material/titanium/New(var/newloc) - ..(newloc, MAT_TITANIUM) - -/obj/item/clothing/gloves/ring/material/copper/New(var/newloc) - ..(newloc, MAT_COPPER) - -/obj/item/clothing/gloves/ring/material/bronze/New(var/newloc) - ..(newloc, MAT_BRONZE) - -/obj/item/clothing/gloves/ring/material/uranium/New(var/newloc) - ..(newloc, MAT_URANIUM) - -/obj/item/clothing/gloves/ring/material/osmium/New(var/newloc) - ..(newloc, MAT_OSMIUM) - -/obj/item/clothing/gloves/ring/material/lead/New(var/newloc) - ..(newloc, MAT_LEAD) - -/obj/item/clothing/gloves/ring/material/diamond/New(var/newloc) - ..(newloc, MAT_DIAMOND) - -/obj/item/clothing/gloves/ring/material/tin/New(var/newloc) - ..(newloc, MAT_TIN) - -/obj/item/clothing/gloves/ring/material/void_opal/New(var/newloc) - ..(newloc, MAT_VOPAL) \ No newline at end of file diff --git a/code/modules/clothing/rings/rings.dm b/code/modules/clothing/rings/rings.dm deleted file mode 100644 index 34678198e74..00000000000 --- a/code/modules/clothing/rings/rings.dm +++ /dev/null @@ -1,96 +0,0 @@ -//Generic Ring - -/obj/item/clothing/gloves/ring - name = "generic ring" - desc = "Torus shaped finger decoration." - icon_state = "material" - drop_sound = 'sound/items/drop/ring.ogg' - -///////////////////////////////////////// -//Standard Rings -/obj/item/clothing/gloves/ring/engagement - name = "engagement ring" - desc = "An engagement ring. It certainly looks expensive." - icon_state = "diamond" - -/obj/item/clothing/gloves/ring/engagement/attack_self(mob/user) - user.visible_message(span_warning("\The [user] gets down on one knee, presenting \the [src]."),span_warning("You get down on one knee, presenting \the [src].")) - -/obj/item/clothing/gloves/ring/cti - name = "CTI ring" - desc = "A ring commemorating graduation from CTI." - icon_state = "cti-grad" - -/obj/item/clothing/gloves/ring/mariner - name = "Mariner University ring" - desc = "A ring commemorating graduation from Mariner University." - icon_state = "mariner-grad" - - -///////////////////////////////////////// -//Reagent Rings - -/obj/item/clothing/gloves/ring/reagent - flags = OPENCONTAINER - origin_tech = list(TECH_MATERIAL = 2, TECH_ILLEGAL = 4) - -/obj/item/clothing/gloves/ring/reagent/New() - ..() - create_reagents(15) - -/obj/item/clothing/gloves/ring/reagent/equipped(var/mob/living/carbon/human/H) - ..() - if(istype(H) && H.gloves==src) - - if(reagents.total_volume) - to_chat(H, span_danger("You feel a prick as you slip on \the [src].")) - if(H.reagents) - var/contained = reagents.get_reagents() - var/trans = reagents.trans_to_mob(H, 15, CHEM_BLOOD) - add_attack_logs(usr, H, "Injected with [name] containing [contained] transferred [trans] units") - return - -//Sleepy Ring -/obj/item/clothing/gloves/ring/reagent/sleepy - name = "silver ring" - desc = "A ring made from what appears to be silver." - icon_state = "material" - origin_tech = list(TECH_MATERIAL = 2, TECH_ILLEGAL = 5) - -/obj/item/clothing/gloves/ring/reagent/sleepy/New() - ..() - reagents.add_reagent("chloralhydrate", 15) // Less than a sleepy-pen, but still enough to knock someone out - -///////////////////////////////////////// -//Seals and Signet Rings - -/obj/item/clothing/gloves/ring/seal - var/stamptext = null -/obj/item/clothing/gloves/ring/seal/secgen - name = "Secretary-General's official seal" - desc = "The official seal of the Secretary-General of the Sol Central Government, featured prominently on a silver ring." - icon_state = "seal-secgen" - -/obj/item/clothing/gloves/ring/seal/mason - name = "\improper Masonic ring" - desc = "The Square and Compasses feature prominently on this Masonic ring." - icon_state = "seal-masonic" - -/obj/item/clothing/gloves/ring/seal/signet - name = "signet ring" - desc = "A signet ring, for when you're too sophisticated to sign letters." - icon_state = "seal-signet" - var/nameset = FALSE - -/obj/item/clothing/gloves/ring/seal/signet/attack_self(mob/user) - if(nameset) - to_chat(user, span_notice("The [src] has already been claimed!")) - return - - to_chat(user, span_notice("You claim the [src] as your own!")) - change_name(user) - nameset = TRUE - -/obj/item/clothing/gloves/ring/seal/signet/proc/change_name(var/signet_name = "Unknown") - name = "[signet_name]'s signet ring" - desc = "A signet ring belonging to [signet_name], for when you're too sophisticated to sign letters." diff --git a/code/modules/clothing/rings/rings_vr.dm b/code/modules/clothing/rings/rings_vr.dm deleted file mode 100644 index 45306a7acc1..00000000000 --- a/code/modules/clothing/rings/rings_vr.dm +++ /dev/null @@ -1,17 +0,0 @@ -/obj/item/clothing/gloves/ring/wedding - name = "golden wedding ring" - desc = "For showing your devotion to another person. It has a golden glimmer to it." - icon = 'icons/inventory/hands/item_vr.dmi' - icon_state = "wedring_g" - item_state = "wedring_g" - var/partnername = "" - -/obj/item/clothing/gloves/ring/wedding/attack_self(mob/user) - partnername = copytext(sanitize(input(user, "Would you like to change the holoengraving on the ring?", "Name your spouse", "Bae") as null|text),1,MAX_NAME_LEN) - name = "[initial(name)] - [partnername]" - -/obj/item/clothing/gloves/ring/wedding/silver - name = "silver wedding ring" - desc = "For showing your devotion to another person. It has a silver glimmer to it." - icon_state = "wedring_s" - item_state = "wedring_s" diff --git a/code/modules/economy/vending_machines.dm b/code/modules/economy/vending_machines.dm index 052cab2a26d..4663e9bb54f 100644 --- a/code/modules/economy/vending_machines.dm +++ b/code/modules/economy/vending_machines.dm @@ -415,7 +415,12 @@ /obj/item/stack/medical/advanced/ointment = 6, /obj/item/stack/medical/splint = 4, /obj/item/storage/pill_bottle/carbon = 2, - /obj/item/clothing/mask/chewable/candy/lolli = 15) + /obj/item/clothing/mask/chewable/candy/lolli = 15, + /obj/item/storage/box/khcrystal = 4, + /obj/item/backup_implanter = 3, + /obj/item/clothing/glasses/omnihud/med = 4, + /obj/item/glasses_kit = 1, + /obj/item/storage/quickdraw/syringe_case = 4) contraband = list(/obj/item/reagent_containers/pill/tox = 3, /obj/item/reagent_containers/pill/stox = 4, /obj/item/reagent_containers/pill/antitox = 6) @@ -448,7 +453,8 @@ products = list(/obj/item/stack/medical/bruise_pack = 2, /obj/item/stack/medical/ointment = 2, /obj/item/reagent_containers/hypospray/autoinjector = 4, - /obj/item/healthanalyzer = 1) + /obj/item/healthanalyzer = 1, + /obj/item/bodybag/cryobag = 2) contraband = list(/obj/item/reagent_containers/syringe/antitoxin = 4, /obj/item/reagent_containers/syringe/antiviral = 4, /obj/item/reagent_containers/pill/tox = 1) @@ -467,14 +473,19 @@ /obj/item/reagent_containers/syringe/antitoxin = 3, /obj/item/stack/medical/bruise_pack = 3, /obj/item/stack/medical/ointment =3, - /obj/item/healthanalyzer = 3) + /obj/item/healthanalyzer = 3, + /obj/item/bodybag/cryobag = 3) contraband = list(/obj/item/reagent_containers/pill/tox = 3) req_log_access = access_cmo has_logs = 1 can_rotate = 0 /obj/machinery/vending/wallmed1/public - products = list(/obj/item/stack/medical/bruise_pack = 8,/obj/item/stack/medical/ointment = 8,/obj/item/reagent_containers/hypospray/autoinjector = 16,/obj/item/healthanalyzer = 4) + products = list(/obj/item/stack/medical/bruise_pack = 8, + /obj/item/stack/medical/ointment = 8, + /obj/item/reagent_containers/hypospray/autoinjector = 16, + /obj/item/healthanalyzer = 4, + /obj/item/bodybag/cryobag = 4) /obj/machinery/vending/security name = "SecTech" @@ -488,9 +499,15 @@ /obj/item/flash = 5, /obj/item/reagent_containers/food/snacks/donut/plain = 6, /obj/item/reagent_containers/food/snacks/donut/plain/jelly = 6, - /obj/item/storage/box/evidence = 6) + /obj/item/storage/box/evidence = 6, + /obj/item/gun/energy/taser = 8, + /obj/item/gun/energy/stunrevolver = 4, + /obj/item/reagent_containers/spray/pepper = 6, + /obj/item/taperoll/police = 6, + /obj/item/clothing/glasses/omnihud/sec = 6) contraband = list(/obj/item/clothing/glasses/sunglasses = 2, - /obj/item/storage/box/donut = 2) + /obj/item/storage/box/donut = 2, + /obj/item/implanter/compliance = 1) req_log_access = access_armory has_logs = 1 @@ -553,7 +570,9 @@ /obj/item/seeds/pumpkinseed = 3, /obj/item/seeds/cherryseed = 3, /obj/item/seeds/plastiseed = 3, - /obj/item/seeds/riceseed = 3) + /obj/item/seeds/riceseed = 3, + /obj/item/seeds/shrinkshroom = 3, + /obj/item/seeds/megashroom = 3) contraband = list(/obj/item/seeds/amanitamycelium = 2, /obj/item/seeds/glowshroom = 2, /obj/item/seeds/libertymycelium = 2, @@ -652,7 +671,8 @@ /obj/item/flashlight/glowstick/red = 3, /obj/item/flashlight/glowstick/blue = 3, /obj/item/flashlight/glowstick/orange =3, - /obj/item/flashlight/glowstick/yellow = 3) + /obj/item/flashlight/glowstick/yellow = 3, + /obj/item/reagent_containers/spray/windowsealant = 5) contraband = list(/obj/item/weldingtool/hugetank = 2, /obj/item/clothing/gloves/fyellow = 2) premium = list(/obj/item/clothing/gloves/heavy_engineer = 1) //VOREStation Edit - yellow gloves are common in engineering, let's make "premium" actually mean something @@ -695,8 +715,10 @@ /obj/item/circuitboard/body_scanner, /obj/item/circuitboard/medical_kiosk, /obj/item/circuitboard/sleeper, - /obj/item/circuitboard/dna_analyzer) - contraband = list(/obj/item/cell/potato = 3) + /obj/item/circuitboard/dna_analyzer, + /obj/item/clothing/glasses/omnihud/eng = 6) + contraband = list(/obj/item/cell/potato = 3, + /obj/item/rms = 5) premium = list(/obj/item/storage/belt/utility = 3) product_records = list() req_log_access = access_ce diff --git a/code/modules/economy/vending_machines_vr.dm b/code/modules/economy/vending_machines_vr.dm index fa8331cc348..2daee26fa91 100644 --- a/code/modules/economy/vending_machines_vr.dm +++ b/code/modules/economy/vending_machines_vr.dm @@ -1,41 +1,3 @@ -//Tweaked existing vendors -/obj/machinery/vending/hydroseeds/Initialize() - . = ..() - products += list(/obj/item/seeds/shrinkshroom = 3,/obj/item/seeds/megashroom = 3) - -/obj/machinery/vending/security/Initialize() - . = ..() - products += list(/obj/item/gun/energy/taser = 8,/obj/item/gun/energy/stunrevolver = 4, - /obj/item/reagent_containers/spray/pepper = 6,/obj/item/taperoll/police = 6, - /obj/item/clothing/glasses/omnihud/sec = 6) - contraband += list(/obj/item/implanter/compliance = 1) - -/obj/machinery/vending/tool/Initialize() - . = ..() - products += list(/obj/item/reagent_containers/spray/windowsealant = 5) - -/obj/machinery/vending/engivend/Initialize() - . = ..() - products += list(/obj/item/clothing/glasses/omnihud/eng = 6) - contraband += list(/obj/item/rms = 5) - -/obj/machinery/vending/medical/Initialize() - . = ..() - products += list(/obj/item/storage/box/khcrystal = 4,/obj/item/backup_implanter = 3, - /obj/item/clothing/glasses/omnihud/med = 4, /obj/item/glasses_kit = 1, /obj/item/storage/quickdraw/syringe_case = 4) - -/obj/machinery/vending/wallmed1/Initialize() - . = ..() - products += list(/obj/item/bodybag/cryobag = 2) - -/obj/machinery/vending/wallmed2/Initialize() - . = ..() - products += list(/obj/item/bodybag/cryobag = 3) - -/obj/machinery/vending/wallmed1/public/Initialize() - . = ..() - products += list(/obj/item/bodybag/cryobag = 4) - // Food Machines (for event/away maps) //I want this not just as part of the zoo. ;v @@ -519,7 +481,7 @@ /obj/item/clothing/under/color/yellow = 5, /obj/item/clothing/shoes/black = 20, /obj/item/clothing/shoes/white = 20, - /obj/item/clothing/gloves/watch = 20 + /obj/item/clothing/accessory/watch = 20 ) prices = list() @@ -614,13 +576,13 @@ /obj/item/clothing/accessory/wcoat/swvest/blue = 5, /obj/item/clothing/accessory/wcoat/swvest/red = 5, /obj/item/clothing/accessory/wristband = 5, - /obj/item/clothing/accessory/wristbandcollection = 5, - /obj/item/clothing/accessory/wristbandcollection/pink = 5, - /obj/item/clothing/accessory/wristbandcollection/les = 5, - /obj/item/clothing/accessory/wristbandcollection/bi = 5, - /obj/item/clothing/accessory/wristbandcollection/trans = 5, - /obj/item/clothing/accessory/wristbandcollection/ace = 5, - /obj/item/clothing/accessory/wristband_spiked = 5, + /obj/item/clothing/accessory/wristband/collection = 5, + /obj/item/clothing/accessory/wristband/collection/pink = 5, + /obj/item/clothing/accessory/wristband/collection/les = 5, + /obj/item/clothing/accessory/wristband/collection/bi = 5, + /obj/item/clothing/accessory/wristband/collection/trans = 5, + /obj/item/clothing/accessory/wristband/collection/ace = 5, + /obj/item/clothing/accessory/wristband/spiked = 5, /obj/item/clothing/accessory/belt = 5, /obj/item/clothing/accessory/belt/thick = 5, /obj/item/clothing/accessory/belt/strap = 5, @@ -636,13 +598,13 @@ /obj/item/clothing/ears/earmuffs/headphones = 5, /obj/item/clothing/ears/earring/stud = 5, /obj/item/clothing/ears/earring/dangle = 5, - /obj/item/clothing/gloves/ring/mariner = 5, - /obj/item/clothing/gloves/ring/engagement = 5, - /obj/item/clothing/gloves/ring/seal/signet = 5, - /obj/item/clothing/gloves/ring/seal/mason = 5, - /obj/item/clothing/gloves/ring/material/plastic = 5, - /obj/item/clothing/gloves/ring/material/steel = 5, - /obj/item/clothing/gloves/ring/material/gold = 5, + /obj/item/clothing/accessory/ring/mariner = 5, + /obj/item/clothing/accessory/ring/engagement = 5, + /obj/item/clothing/accessory/ring/seal/signet = 5, + /obj/item/clothing/accessory/ring/seal/mason = 5, + /obj/item/clothing/accessory/ring/material/plastic = 5, + /obj/item/clothing/accessory/ring/material/steel = 5, + /obj/item/clothing/accessory/ring/material/gold = 5, /obj/item/clothing/glasses/eyepatch = 5, /obj/item/clothing/glasses/gglasses = 5, /obj/item/clothing/glasses/regular/hipster = 5, @@ -670,9 +632,9 @@ /obj/item/clothing/accessory/pride/lesbian = 5, /obj/item/clothing/accessory/pride/intersex = 5, /obj/item/clothing/accessory/pride/vore = 5, - /obj/item/clothing/gloves/watch = 5, - /obj/item/clothing/gloves/watch/silver = 5, - /obj/item/clothing/gloves/watch/gold = 5 + /obj/item/clothing/accessory/watch = 5, + /obj/item/clothing/accessory/watch/silver = 5, + /obj/item/clothing/accessory/watch/gold = 5 ) prices = list(/obj/item/clothing/accessory = 50, /obj/item/clothing/accessory/armband/med/color = 50, @@ -759,13 +721,13 @@ /obj/item/clothing/accessory/wcoat/swvest/blue = 50, /obj/item/clothing/accessory/wcoat/swvest/red = 50, /obj/item/clothing/accessory/wristband = 10, - /obj/item/clothing/accessory/wristbandcollection = 30, - /obj/item/clothing/accessory/wristbandcollection/pink = 30, - /obj/item/clothing/accessory/wristbandcollection/les = 30, - /obj/item/clothing/accessory/wristbandcollection/bi = 30, - /obj/item/clothing/accessory/wristbandcollection/trans = 30, - /obj/item/clothing/accessory/wristbandcollection/ace = 30, - /obj/item/clothing/accessory/wristband_spiked = 20, + /obj/item/clothing/accessory/wristband/collection = 30, + /obj/item/clothing/accessory/wristband/collection/pink = 30, + /obj/item/clothing/accessory/wristband/collection/les = 30, + /obj/item/clothing/accessory/wristband/collection/bi = 30, + /obj/item/clothing/accessory/wristband/collection/trans = 30, + /obj/item/clothing/accessory/wristband/collection/ace = 30, + /obj/item/clothing/accessory/wristband/spiked = 20, /obj/item/clothing/accessory/belt = 50, /obj/item/clothing/accessory/belt/thick = 50, /obj/item/clothing/accessory/belt/strap = 50, @@ -781,13 +743,13 @@ /obj/item/clothing/ears/earmuffs/headphones = 50, /obj/item/clothing/ears/earring/stud = 50, /obj/item/clothing/ears/earring/dangle = 50, - /obj/item/clothing/gloves/ring/mariner = 50, - /obj/item/clothing/gloves/ring/engagement = 50, - /obj/item/clothing/gloves/ring/seal/signet = 50, - /obj/item/clothing/gloves/ring/seal/mason = 50, - /obj/item/clothing/gloves/ring/material/plastic = 50, - /obj/item/clothing/gloves/ring/material/steel = 50, - /obj/item/clothing/gloves/ring/material/gold = 100, + /obj/item/clothing/accessory/ring/mariner = 50, + /obj/item/clothing/accessory/ring/engagement = 50, + /obj/item/clothing/accessory/ring/seal/signet = 50, + /obj/item/clothing/accessory/ring/seal/mason = 50, + /obj/item/clothing/accessory/ring/material/plastic = 50, + /obj/item/clothing/accessory/ring/material/steel = 50, + /obj/item/clothing/accessory/ring/material/gold = 100, /obj/item/clothing/glasses/eyepatch = 50, /obj/item/clothing/glasses/gglasses = 50, /obj/item/clothing/glasses/regular/hipster = 50, @@ -811,9 +773,9 @@ /obj/item/clothing/accessory/pride/lesbian = 50, /obj/item/clothing/accessory/pride/intersex = 50, /obj/item/clothing/accessory/pride/vore = 50, - /obj/item/clothing/gloves/watch = 50, - /obj/item/clothing/gloves/watch/silver = 100, - /obj/item/clothing/gloves/watch/gold = 200 + /obj/item/clothing/accessory/watch = 50, + /obj/item/clothing/accessory/watch/silver = 100, + /obj/item/clothing/accessory/watch/gold = 200 ) premium = list(/obj/item/bedsheet/rainbow = 1) contraband = list(/obj/item/clothing/mask/gas/clown_hat = 1, @@ -2001,13 +1963,13 @@ /obj/item/clothing/ears/earmuffs/headphones = 5, /obj/item/clothing/ears/earring/stud = 5, /obj/item/clothing/ears/earring/dangle = 5, - /obj/item/clothing/gloves/ring/mariner = 5, - /obj/item/clothing/gloves/ring/engagement = 5, - /obj/item/clothing/gloves/ring/seal/signet = 5, - /obj/item/clothing/gloves/ring/seal/mason = 5, - /obj/item/clothing/gloves/ring/material/plastic = 5, - /obj/item/clothing/gloves/ring/material/steel = 5, - /obj/item/clothing/gloves/ring/material/gold = 5, + /obj/item/clothing/accessory/ring/mariner = 5, + /obj/item/clothing/accessory/ring/engagement = 5, + /obj/item/clothing/accessory/ring/seal/signet = 5, + /obj/item/clothing/accessory/ring/seal/mason = 5, + /obj/item/clothing/accessory/ring/material/plastic = 5, + /obj/item/clothing/accessory/ring/material/steel = 5, + /obj/item/clothing/accessory/ring/material/gold = 5, /obj/item/clothing/glasses/eyepatch = 5, /obj/item/clothing/glasses/gglasses = 5, /obj/item/clothing/glasses/regular/hipster = 5, diff --git a/code/modules/games/cards.dm b/code/modules/games/cards.dm index 448ea34b5f3..df4e50d63ba 100644 --- a/code/modules/games/cards.dm +++ b/code/modules/games/cards.dm @@ -211,8 +211,8 @@ ..() -/obj/item/deck/attack_self() - shuffle() +/obj/item/deck/attack_self(mob/user) + shuffle(user) /obj/item/deck/verb/verb_shuffle() @@ -220,10 +220,9 @@ set name = "Shuffle" set desc = "Shuffle the cards in the deck." set src in view(1) - shuffle() + shuffle(usr) -/obj/item/deck/proc/shuffle() - var/mob/living/user = usr +/obj/item/deck/proc/shuffle(mob/user) if (cooldown < world.time - 10) // 15 ticks cooldown var/list/newcards = list() while(cards.len) diff --git a/code/modules/games/tarot.dm b/code/modules/games/tarot.dm index 44407c9ca2d..5489bb05fd5 100644 --- a/code/modules/games/tarot.dm +++ b/code/modules/games/tarot.dm @@ -41,3 +41,58 @@ cooldown = world.time else return + +///Fluff item, using a separate item rather than a subitem to customise New() + +/obj/item/deck/dark_tarot + name = "dark rose tarot deck" + desc = "A limited edition tarot deck for the scene-girl inclined!" + icon_state = "dark_tarot" + +/obj/item/deck/dark_tarot/New() + ..() + + var/datum/playingcard/P + for(var/name in list("fool","magician","high priestess","empress","emperor","hierophant","lovers","chariot","strength","hermit","wheel of fortune","justice","hanged man","death","temperance","devil","tower","star","moon","sun","judgement","world","white dragon with blue eyes","charred lizard","dark lotus","bash","reverse","rules","acid","abyss","maw")) + P = new() + P.name = "[name]" + if(name == "high priestess") + P.card_icon = "dark_high_priestess" + else if(name == "wheel of fortune") + P.card_icon = "dark_wheel" + else if(name == "hanged man") + P.card_icon = "dark_hanged" + else if(name == "white dragon with blue eyes") + P.card_icon = "dark_dragon" + else if(name == "charred lizard") + P.card_icon = "dark_lizard" + else if(name == "dark lotus") + P.card_icon = "dark_lotus" + else + P.card_icon = "dark_[name]" + P.back_icon = "dark_back_tarot" + cards += P + for(var/suit in list("wands","pentacles","cups","swords")) + for(var/number in list("ace","two","three","four","five","six","seven","eight","nine","ten","page","knight","queen","king")) + P = new() + P.name = "[number] of [suit]" + P.card_icon = "dark_[suit]" + P.back_icon = "dark_back_tarot" + cards += P + +/obj/item/deck/dark_tarot/shuffle(mob/user) + if (cooldown < world.time - 10) + var/list/newcards = list() + while(cards.len) + var/datum/playingcard/P = pick(cards) + P.name = replacetext(P.name," reversed","") + if(prob(50)) + P.name += " reversed" + newcards += P + cards -= P + cards = newcards + playsound(src, 'sound/items/cardshuffle.ogg', 50, 1) + user.visible_message("\The [user] shuffles [src].") + cooldown = world.time + else + return diff --git a/code/modules/materials/materials/_materials.dm b/code/modules/materials/materials/_materials.dm index ca710cb04f1..322e5d7beaf 100644 --- a/code/modules/materials/materials/_materials.dm +++ b/code/modules/materials/materials/_materials.dm @@ -361,7 +361,7 @@ var/list/name_to_material new /datum/stack_recipe("[display_name] armor plate", /obj/item/material/armor_plating, 1, time = 20, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE), new /datum/stack_recipe("[display_name] armor plate insert", /obj/item/material/armor_plating/insert, 2, time = 40, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE), new /datum/stack_recipe("[display_name] grave marker", /obj/item/material/gravemarker, 5, time = 50, supplied_material = "[name]", pass_stack_color = TRUE), - new /datum/stack_recipe("[display_name] ring", /obj/item/clothing/gloves/ring/material, 1, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE), + new /datum/stack_recipe("[display_name] ring", /obj/item/clothing/accessory/ring/material, 1, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE), new /datum/stack_recipe("[display_name] bracelet", /obj/item/clothing/accessory/bracelet/material, 1, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE) ) diff --git a/code/modules/materials/materials/organic/leather.dm b/code/modules/materials/materials/organic/leather.dm index fe291e4d8d5..607361d07e2 100644 --- a/code/modules/materials/materials/organic/leather.dm +++ b/code/modules/materials/materials/organic/leather.dm @@ -33,7 +33,7 @@ new /datum/stack_recipe("pouch, melee", /obj/item/storage/pouch/baton, 10, time = 20 SECONDS, pass_stack_color = FALSE, recycle_material = "[name]"), //vorestation Add new /datum/stack_recipe("crude [display_name] bandage", /obj/item/stack/medical/crude_pack, 1, time = 2 SECONDS, pass_stack_color = TRUE, recycle_material = "[name]"), new /datum/stack_recipe("[display_name] net", /obj/item/material/fishing_net, 10, time = 5 SECONDS, supplied_material = "[name]", pass_stack_color = TRUE), - new /datum/stack_recipe("[display_name] ring", /obj/item/clothing/gloves/ring/material, 1, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE), + new /datum/stack_recipe("[display_name] ring", /obj/item/clothing/accessory/ring/material, 1, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE), new /datum/stack_recipe("[display_name] bracelet", /obj/item/clothing/accessory/bracelet/material, 1, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE), new /datum/stack_recipe("[display_name] armor plate", /obj/item/material/armor_plating, 1, time = 20, on_floor = 1, supplied_material = "[name]", pass_stack_color = TRUE), new /datum/stack_recipe("empty sandbag", /obj/item/stack/emptysandbag, 2, time = 2 SECONDS, pass_stack_color = TRUE, supplied_material = "[name]"), diff --git a/code/modules/mob/dead/observer/observer.dm b/code/modules/mob/dead/observer/observer.dm index 83a81d2c36d..d0f1f66f9e6 100644 --- a/code/modules/mob/dead/observer/observer.dm +++ b/code/modules/mob/dead/observer/observer.dm @@ -223,7 +223,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp announce_ghost_joinleave(ghostize(1)) else var/response - if(src.client && src.client.holder) + if(check_rights(R_ADMIN|R_SERVER|R_MOD,FALSE,src)) //No need to sanity check for client and holder here as that is part of check_rights response = tgui_alert(src, "You have the ability to Admin-Ghost. The regular Ghost verb will announce your presence to dead chat. Both variants will allow you to return to your body using 'aghost'.\n\nWhat do you wish to do?", "Are you sure you want to ghost?", list("Admin Ghost", "Ghost", "Stay in body")) if(response == "Admin Ghost") if(!src.client) diff --git a/code/modules/mob/living/carbon/human/ai_controlled/ai_controlled.dm b/code/modules/mob/living/carbon/human/ai_controlled/ai_controlled.dm index 82243467c8b..54df0bdb0b8 100644 --- a/code/modules/mob/living/carbon/human/ai_controlled/ai_controlled.dm +++ b/code/modules/mob/living/carbon/human/ai_controlled/ai_controlled.dm @@ -22,7 +22,7 @@ var/to_wear_r_radio = null var/to_wear_uniform = /obj/item/clothing/under/color/grey var/to_wear_suit = /obj/item/clothing/suit/armor/material/makeshift/glass - var/to_wear_gloves = /obj/item/clothing/gloves/ring/material/platinum + var/to_wear_gloves = /obj/item/clothing/accessory/ring/material/platinum var/to_wear_shoes = /obj/item/clothing/shoes/galoshes var/to_wear_belt = /obj/item/storage/belt/utility/full var/to_wear_l_pocket = /obj/item/soap diff --git a/code/modules/mob/living/carbon/human/examine.dm b/code/modules/mob/living/carbon/human/examine.dm index 73913ba2951..80dabf789d2 100644 --- a/code/modules/mob/living/carbon/human/examine.dm +++ b/code/modules/mob/living/carbon/human/examine.dm @@ -107,12 +107,10 @@ if(w_uniform && !(skip_gear & EXAMINE_SKIPJUMPSUIT) && w_uniform.show_examine) //Ties var/tie_msg - var/tie_msg_warn if(istype(w_uniform,/obj/item/clothing/under) && !(skip_gear & EXAMINE_SKIPTIE)) var/obj/item/clothing/under/U = w_uniform if(LAZYLEN(U.accessories)) tie_msg += ". Attached to it is" - tie_msg_warn += "! Attached to it is" var/list/accessory_descs = list() if(skip_gear & EXAMINE_SKIPHOLSTER) for(var/obj/item/clothing/accessory/A in U.accessories) @@ -139,12 +137,10 @@ //suit/armour if(wear_suit) var/tie_msg - var/tie_msg_warn if(istype(wear_suit,/obj/item/clothing/suit)) var/obj/item/clothing/suit/U = wear_suit if(LAZYLEN(U.accessories)) tie_msg += ". Attached to it is" - tie_msg_warn += "! Attached to it is" var/list/accessory_descs = list() for(var/accessory in U.accessories) accessory_descs += "\a [accessory]" @@ -185,10 +181,21 @@ //gloves if(gloves && !(skip_gear & EXAMINE_SKIPGLOVES) && gloves.show_examine) + var/gloves_acc_msg + if(istype(gloves,/obj/item/clothing/gloves)) + var/obj/item/clothing/gloves/G = gloves + if(LAZYLEN(G.accessories)) + gloves_acc_msg += ". Attached to it is" + var/list/accessory_descs = list() + for(var/obj/item/clothing/accessory/A in G.accessories) + accessory_descs += "\a [A]" + + gloves_acc_msg += " [lowertext(english_list(accessory_descs))]." if(gloves.blood_DNA) - msg += span_warning("[T.He] [T.has] [icon2html(gloves,user.client)] [gloves.gender==PLURAL?"some":"a"] [(gloves.blood_color != "#030303") ? "blood" : "oil"]-stained [gloves.name] on [T.his] hands!") + msg += span_warning("[T.He] [T.has] [icon2html(gloves,user.client)] [gloves.gender==PLURAL?"some":"a"] [(gloves.blood_color != "#030303") ? "blood" : "oil"]-stained [gloves.name] on [T.his] hands![gloves_acc_msg]") else - msg += "[T.He] [T.has] [icon2html(gloves,user.client)] \a [gloves] on [T.his] hands." + msg += "[T.He] [T.has] [icon2html(gloves,user.client)] \a [gloves] on [T.his] hands.[gloves_acc_msg]" + else if(blood_DNA && !(skip_body & EXAMINE_SKIPHANDS)) msg += span_warning("[T.He] [T.has] [(hand_blood_color != SYNTH_BLOOD_COLOUR) ? "blood" : "oil"]-stained hands!") diff --git a/code/modules/mob/living/carbon/human/human_attackhand.dm b/code/modules/mob/living/carbon/human/human_attackhand.dm index 542dafb6f68..7911b330397 100644 --- a/code/modules/mob/living/carbon/human/human_attackhand.dm +++ b/code/modules/mob/living/carbon/human/human_attackhand.dm @@ -272,8 +272,12 @@ var/obj/item/clothing/gloves/G = H.gloves real_damage += G.punch_force hit_dam_type = G.punch_damtype - if(H.pulling_punches && !attack.sharp && !attack.edge) //SO IT IS DECREED: PULLING PUNCHES WILL PREVENT THE ACTUAL DAMAGE FROM RINGS AND KNUCKLES, BUT NOT THE ADDED PAIN, BUT YOU CAN'T "PULL" A KNIFE - hit_dam_type = AGONY + else if(istype(H.gloves, /obj/item/clothing/accessory)) + var/obj/item/clothing/accessory/G = H.gloves + real_damage += G.punch_force + hit_dam_type = G.punch_damtype + if(H.pulling_punches && !attack.sharp && !attack.edge) //SO IT IS DECREED: PULLING PUNCHES WILL PREVENT THE ACTUAL DAMAGE FROM RINGS AND KNUCKLES, BUT NOT THE ADDED PAIN, BUT YOU CAN'T "PULL" A KNIFE + hit_dam_type = AGONY real_damage *= damage_multiplier rand_damage *= damage_multiplier if(HULK in H.mutations) diff --git a/code/modules/mob/living/carbon/human/species/species.dm b/code/modules/mob/living/carbon/human/species/species.dm index 72b4396d61a..863e6cd0a99 100644 --- a/code/modules/mob/living/carbon/human/species/species.dm +++ b/code/modules/mob/living/carbon/human/species/species.dm @@ -212,6 +212,9 @@ var/can_space_freemove = FALSE // Can we freely move in space? var/can_zero_g_move = FALSE // What about just in zero-g non-space? + var/swim_mult = 1 //multiplier to our z-movement rate for swimming + var/climb_mult = 1 //multiplier to our z-movement rate for lattices/catwalks + var/item_slowdown_mod = 1 // How affected by item slowdown the species is. var/primitive_form // Lesser form, if any (ie. monkey for humans) var/greater_form // Greater form, if any, ie. human for monkeys. diff --git a/code/modules/mob/living/carbon/human/species/station/station.dm b/code/modules/mob/living/carbon/human/species/station/station.dm index c2d52b273b9..cce23f93615 100644 --- a/code/modules/mob/living/carbon/human/species/station/station.dm +++ b/code/modules/mob/living/carbon/human/species/station/station.dm @@ -242,6 +242,8 @@ reagent_tag = IS_TAJARA allergens = ALLERGEN_STIMULANT + climb_mult = 0.75 + move_trail = /obj/effect/decal/cleanable/blood/tracks/paw heat_discomfort_level = 292 diff --git a/code/modules/mob/living/carbon/human/species/station/station_special_vr.dm b/code/modules/mob/living/carbon/human/species/station/station_special_vr.dm index e2a346158a3..997aac129f9 100644 --- a/code/modules/mob/living/carbon/human/species/station/station_special_vr.dm +++ b/code/modules/mob/living/carbon/human/species/station/station_special_vr.dm @@ -384,6 +384,8 @@ silk_reserve = 500 silk_max_reserve = 1000 + climb_mult = 0.75 + /datum/species/spider/handle_environment_special(var/mob/living/carbon/human/H) if(H.stat == DEAD) // If they're dead they won't need anything. return diff --git a/code/modules/mob/living/carbon/human/species/station/station_vr.dm b/code/modules/mob/living/carbon/human/species/station/station_vr.dm index e623591f576..6532e7c7492 100644 --- a/code/modules/mob/living/carbon/human/species/station/station_vr.dm +++ b/code/modules/mob/living/carbon/human/species/station/station_vr.dm @@ -110,6 +110,7 @@ water_breather = TRUE water_movement = -4 //Negates shallow. Halves deep. + swim_mult = 0.5 flesh_color = "#AFA59E" base_color = "#777777" diff --git a/code/modules/mob/living/carbon/human/species/station/traits_vr/negative.dm b/code/modules/mob/living/carbon/human/species/station/traits_vr/negative.dm index 84fba1d1cba..ffd9f10b88b 100644 --- a/code/modules/mob/living/carbon/human/species/station/traits_vr/negative.dm +++ b/code/modules/mob/living/carbon/human/species/station/traits_vr/negative.dm @@ -188,7 +188,9 @@ /datum/trait/negative/bad_swimmer name = "Bad Swimmer" - desc = "You can't swim very well, all water slows you down a lot and you drown in deep water." + desc = "You can't swim very well, all water slows you down a lot and you drown in deep water. You also swim up and down 25% slower." cost = -1 custom_only = FALSE - var_changes = list("bad_swimmer" = 1, "water_movement" = 4) + var_changes = list("bad_swimmer" = 1, "water_movement" = 4, "swim_mult" = 1.25) + varchange_type = TRAIT_VARCHANGE_LESS_BETTER + excludes = list(/datum/trait/positive/good_swimmer) diff --git a/code/modules/mob/living/carbon/human/species/station/traits_vr/positive.dm b/code/modules/mob/living/carbon/human/species/station/traits_vr/positive.dm index 7551915c9dc..d3df8f312a9 100644 --- a/code/modules/mob/living/carbon/human/species/station/traits_vr/positive.dm +++ b/code/modules/mob/living/carbon/human/species/station/traits_vr/positive.dm @@ -121,6 +121,7 @@ name = "Winged Flight" desc = "Allows you to fly by using your wings. Don't forget to bring them!" cost = 0 + custom_only = FALSE has_preferences = list("flight_vore" = list(TRAIT_PREF_TYPE_BOOLEAN, "Flight Vore enabled on spawn", TRAIT_VAREDIT_TARGET_MOB, FALSE)) /datum/trait/positive/winged_flight/apply(var/datum/species/S,var/mob/living/carbon/human/H) @@ -241,12 +242,9 @@ cost = 1 var_changes = list("throwforce_absorb_threshold" = 10) - - - /datum/trait/positive/wall_climber name = "Climber, Amateur" - desc = "You can climb certain walls without tools! This is likely a personal skill you developed." + desc = "You can climb certain walls without tools! This is likely a personal skill you developed. You can also climb lattices and ladders a little bit faster than everyone else." tutorial = "You must approach a wall and right click it and select the \ 'climb wall' verb to climb it. You suffer from a movement delay of 1.5 with this trait.\n \ Your total climb time is expected to be 17.5 seconds. Tools may reduce this. \n\n \ @@ -255,12 +253,12 @@ cost = 1 custom_only = FALSE banned_species = list(SPECIES_TAJ, SPECIES_VASILISSAN) // They got unique climbing delay. - var_changes = list("can_climb" = TRUE) + var_changes = list("can_climb" = TRUE, "climb_mult" = 0.75) excludes = list(/datum/trait/positive/wall_climber_pro, /datum/trait/positive/wall_climber_natural) /datum/trait/positive/wall_climber_natural name = "Climber, Natural" - desc = "You can climb certain walls without tools! This is likely due to the unique anatomy of your species. CUSTOM AND XENOCHIM ONLY" + desc = "You can climb certain walls without tools! This is likely due to the unique anatomy of your species. You can climb lattices and ladders slightly faster than everyone else. CUSTOM AND XENOCHIM ONLY" tutorial = "You must approach a wall and right click it and select the \ 'climb wall' verb to climb it. You suffer from a movement delay of 1.5 with this trait.\n \ Your total climb time is expected to be 17.5 seconds. Tools may reduce this. \n\n \ @@ -268,13 +266,13 @@ a climbable wall. To climbe like so, use the verb 'Climb Down Wall' in IC tab!" cost = 0 custom_only = FALSE - var_changes = list("can_climb" = TRUE) + var_changes = list("can_climb" = TRUE, "climb_mult" = 0.75) allowed_species = list(SPECIES_XENOCHIMERA, SPECIES_CUSTOM) //So that we avoid needless bloat for xenochim excludes = list(/datum/trait/positive/wall_climber_pro, /datum/trait/positive/wall_climber) /datum/trait/positive/wall_climber_pro name = "Climber, Professional" - desc = "You can climb certain walls without tools! You are a professional rock climber at this, letting you climb almost twice as fast!" + desc = "You can climb certain walls without tools! You are a professional rock climber at this, letting you climb almost twice as fast! You can also climb lattices and ladders a fair bit faster than everyone else!" tutorial = "You must approach a wall and right click it and select the \ 'climb wall' verb to climb it. Your movement delay is just 1.25 with this trait.\n \ Your climb time is expected to be 9 seconds. Tools may reduce this. \n\n \ @@ -282,7 +280,7 @@ a climbable wall. To climbe like so, use the verb 'Climb Down Wall' in IC tab!" cost = 2 custom_only = FALSE - var_changes = list("climbing_delay" = 1.25) + var_changes = list("climbing_delay" = 1.25, "climb_mult" = 0.5) varchange_type = TRAIT_VARCHANGE_LESS_BETTER excludes = list(/datum/trait/positive/wall_climber,/datum/trait/positive/wall_climber_natural) @@ -292,3 +290,14 @@ /datum/trait/positive/wall_climber_pro/apply(var/datum/species/S,var/mob/living/carbon/human/H) ..() S.can_climb = TRUE + +/datum/trait/positive/good_swimmer + name = "Pro Swimmer" + desc = "You were top of your group in swimming class! This is of questionable usefulness on most planets, but hey, maybe you'll get to visit a nice beach world someday?" + tutorial = "You move faster in water, and can move up and down z-levels faster than other swimmers!" + cost = 1 + custom_only = FALSE + var_changes = list("water_movement" = -2, "swim_mult" = 0.5) + varchange_type = TRAIT_VARCHANGE_LESS_BETTER + excludes = list(/datum/trait/negative/bad_swimmer) + banned_species = list(SPECIES_AKULA) // They already swim better than this diff --git a/code/modules/mob/living/silicon/robot/drone/drone.dm b/code/modules/mob/living/silicon/robot/drone/drone.dm index fd1132d05a8..c7c1a1a2fbc 100644 --- a/code/modules/mob/living/silicon/robot/drone/drone.dm +++ b/code/modules/mob/living/silicon/robot/drone/drone.dm @@ -203,9 +203,6 @@ var/list/mob_hat_cache = list() can_pick_shell = FALSE update_icon() -/mob/living/silicon/robot/drone/choose_icon() - return - /mob/living/silicon/robot/drone/pick_module() return diff --git a/code/modules/mob/living/silicon/robot/login.dm b/code/modules/mob/living/silicon/robot/login.dm index 89a136223e2..ef25b1bece0 100644 --- a/code/modules/mob/living/silicon/robot/login.dm +++ b/code/modules/mob/living/silicon/robot/login.dm @@ -11,11 +11,6 @@ repick_laws() // Forces synths to select an icon relevant to their module - if(!icon_selected) - icon_selection_tries = SSrobot_sprites.get_module_sprites_len(modtype, src) + 1 - choose_icon(icon_selection_tries) - - if(sprite_datum && module) - sprite_datum.do_equipment_glamour(module) + pick_module() plane_holder.set_vis(VIS_AUGMENTED, TRUE) diff --git a/code/modules/mob/living/silicon/robot/robot.dm b/code/modules/mob/living/silicon/robot/robot.dm index a79310c02be..d10451a5201 100644 --- a/code/modules/mob/living/silicon/robot/robot.dm +++ b/code/modules/mob/living/silicon/robot/robot.dm @@ -31,8 +31,7 @@ //Icon stuff var/datum/robot_sprite/sprite_datum // Sprite datum, holding all our sprite data - var/icon_selected = 1 // If icon selection has been completed yet - var/icon_selection_tries = 0 // Remaining attempts to select icon before a selection is forced + var/icon_selected = FALSE // If icon selection has been completed yet var/list/sprite_extra_customization = list() var/rest_style = "Default" var/notransform @@ -47,6 +46,9 @@ var/shown_robot_modules = 0 //Used to determine whether they have the module menu shown or not var/obj/screen/robot_modules_background + var/ui_theme + var/selecting_module = FALSE + //3 Modules can be activated at any one time. var/obj/item/robot_module/module = null var/module_active = null @@ -336,46 +338,17 @@ return module_sprites */ /mob/living/silicon/robot/proc/pick_module() + if(icon_selected) + return if(module) - return - var/list/modules = list() - //VOREStatation Edit Start: shell restrictions - if(shell) - if(restrict_modules_to.len > 0) - modules.Add(restrict_modules_to) - else - modules.Add(shell_module_types) - else - if(restrict_modules_to.len > 0) - modules.Add(restrict_modules_to) - else - modules.Add(robot_module_types) - if(crisis || security_level == SEC_LEVEL_RED || crisis_override) - to_chat(src, span_red("Crisis mode active. Combat module available.")) - modules |= emergency_module_types - for(var/module_name in whitelisted_module_types) - if(is_borg_whitelisted(src, module_name)) - modules |= module_name - //VOREStatation Edit End: shell restrictions - modtype = tgui_input_list(usr, "Please, select a module!", "Robot module", modules) - - if(module) - return - if(!(modtype in robot_modules)) - return - if(!is_borg_whitelisted(src, modtype)) - return - - var/module_type = robot_modules[modtype] - transform_with_anim() //VOREStation edit: sprite animation - new module_type(src) - - hands.icon_state = get_hud_module_icon() - feedback_inc("cyborg_[lowertext(modtype)]",1) - updatename() - hud_used.update_robot_modules_display() - notify_ai(ROBOT_NOTIFICATION_NEW_MODULE, module.name) - robotact?.update_static_data_for_all_viewers() + var/list/module_sprites = SSrobot_sprites.get_module_sprites(module, src) + if(module_sprites.len == 1 || !client) + sprite_datum = module_sprites[1] + sprite_datum.do_equipment_glamour(module) + return + if(!selecting_module) + var/datum/tgui_module/robot_ui_module/ui = new(src) + ui.tgui_interact(src) /mob/living/silicon/robot/proc/update_braintype() if(istype(mmi, /obj/item/mmi/digital/posibrain)) @@ -436,15 +409,12 @@ to_chat(usr, "You can't pick another custom name. [isshell(src) ? "" : "Go ask for a name change."]") return 0 - spawn(0) - var/newname - newname = sanitizeSafe(tgui_input_text(src,"You are a robot. Enter a name, or leave blank for the default name.", "Name change","", MAX_NAME_LEN), MAX_NAME_LEN) - if (newname) - custom_name = newname - sprite_name = newname + var/newname = sanitizeSafe(tgui_input_text(src,"You are a robot. Enter a name, or leave blank for the default name.", "Name change","", MAX_NAME_LEN), MAX_NAME_LEN) + if (newname) + custom_name = newname + sprite_name = newname - updatename() - update_icon() + updatename() /mob/living/silicon/robot/verb/extra_customization() set name = "Customize Appearance" @@ -744,6 +714,8 @@ to_chat(usr, span_filter_notice("You must access the borgs internals!")) else if(!src.module && U.require_module) to_chat(usr, span_filter_notice("The borg must choose a module before it can be upgraded!")) + else if(user == src && istype(W,/obj/item/borg/upgrade/utility/reset)) + to_chat(usr, span_warning("You are restricted from reseting your own module.")) else if(U.locked) to_chat(usr, span_filter_notice("The upgrade is locked and cannot be used yet!")) else @@ -796,6 +768,7 @@ notify_ai(ROBOT_NOTIFICATION_MODULE_RESET, module.name) module.Reset(src) qdel(module) + icon_selected = FALSE module = null updatename("Default") has_recoloured = FALSE @@ -903,7 +876,7 @@ else if(istype(M, /mob/living/silicon/robot)) var/mob/living/silicon/robot/R = M if(check_access(R.get_active_hand()) || istype(R.get_active_hand(), /obj/item/card/robot)) - return 1 + return TRUE return 0 /mob/living/silicon/robot/proc/check_access(obj/item/I) @@ -1088,60 +1061,6 @@ return -/mob/living/silicon/robot/proc/choose_icon(var/triesleft) - var/robot_species = null - if(!SSrobot_sprites) - to_chat(src, "Robot Sprites have not been initialized yet. How are you choosing a sprite? Harass a coder.") - return - - var/list/module_sprites = SSrobot_sprites.get_module_sprites(modtype, src) - if(!module_sprites || !module_sprites.len) - to_chat(src, "Your module appears to have no sprite options. Harass a coder.") - return - - icon_selected = 0 - icon_selection_tries = triesleft - if(module_sprites.len == 1 || !client) - if(!(sprite_datum in module_sprites)) - sprite_datum = module_sprites[1] - else - var/selection = tgui_input_list(src, "Select an icon! [triesleft ? "You have [triesleft] more chance\s." : "This is your last try."]", "Robot Icon", module_sprites) - if(selection) - sprite_datum = selection - else - sprite_datum = module_sprites[1] - if(!istype(src,/mob/living/silicon/robot/drone)) - robot_species = sprite_datum.name - if(notransform) - to_chat(src, "Your current transformation has not finished yet!") - choose_icon(icon_selection_tries) - return - else - transform_with_anim() - - var/tempheight = vis_height - update_icon() - // This is bad but I dunno other way to 'reset' our resize offset based on vis_height changes other than resizing to normal and back. - if(tempheight != vis_height) - var/tempsize = size_multiplier - resize(1) - resize(tempsize) - - - if (module_sprites.len > 1 && triesleft >= 1 && client) - icon_selection_tries-- - var/choice = tgui_alert(usr, "Look at your icon - is this what you want?", "Icon Choice", list("Yes","No")) - if(choice == "No") - choose_icon(icon_selection_tries) - return - - icon_selected = 1 - icon_selection_tries = 0 - sprite_type = robot_species - if(hands) - update_hud() - to_chat(src, span_filter_notice("Your icon has been set. You now require a module reset to change it.")) - /mob/living/silicon/robot/proc/set_default_module_icon() if(!SSrobot_sprites) return diff --git a/code/modules/mob/living/silicon/robot/robot_modules/station.dm b/code/modules/mob/living/silicon/robot/robot_modules/station.dm index 8f8c0757e0c..bc54a72e638 100644 --- a/code/modules/mob/living/silicon/robot/robot_modules/station.dm +++ b/code/modules/mob/living/silicon/robot/robot_modules/station.dm @@ -73,7 +73,7 @@ var/global/list/robot_modules = list( R.radio.recalculateChannels() R.set_default_module_icon() - R.choose_icon(SSrobot_sprites.get_module_sprites_len(R.modtype, R) + 1) + R.pick_module() if(!R.client) R.icon_selected = FALSE // It wasnt a player selecting icon? Let them do it later! @@ -93,7 +93,7 @@ var/global/list/robot_modules = list( if(R.radio) R.radio.recalculateChannels() - R.choose_icon(0) + R.set_default_module_icon() R.scrubbing = FALSE diff --git a/code/modules/mob/living/silicon/robot/robot_ui.dm b/code/modules/mob/living/silicon/robot/robot_ui.dm index 7262f45364a..11027cc20da 100644 --- a/code/modules/mob/living/silicon/robot/robot_ui.dm +++ b/code/modules/mob/living/silicon/robot/robot_ui.dm @@ -52,6 +52,10 @@ var/mob/living/silicon/robot/R = host data["module_name"] = R.module ? "[R.module]" : null + if(R.emagged) + data["theme"] = "syndicate" + else if (R.ui_theme) + data["theme"] = R.ui_theme if(!R.module) return data diff --git a/code/modules/mob/living/silicon/robot/robot_ui_module.dm b/code/modules/mob/living/silicon/robot/robot_ui_module.dm new file mode 100644 index 00000000000..1554549633e --- /dev/null +++ b/code/modules/mob/living/silicon/robot/robot_ui_module.dm @@ -0,0 +1,179 @@ +// Robot module selection +/datum/tgui_module/robot_ui_module + name = "Robot Module Configurator" + tgui_id = "RobotChoose" + var/selected_module + var/new_name + var/datum/robot_sprite/sprite_datum + +/datum/tgui_module/robot_ui_module/tgui_state(mob/user) + return GLOB.tgui_self_state + +/datum/tgui_module/robot_ui_module/tgui_close(mob/user) + . = ..() + if(isrobot(user)) + var/mob/living/silicon/robot/R = user + R.selecting_module = FALSE + +/datum/tgui_module/robot_ui_module/tgui_interact(mob/user, datum/tgui/ui, datum/tgui/parent_ui) + . = ..() + if(isrobot(user) && ui) + var/mob/living/silicon/robot/R = user + R.selecting_module = TRUE + +/datum/tgui_module/robot_ui_module/ui_assets(mob/user) + return list( + get_asset_datum(/datum/asset/spritesheet/robot_icons) + ) + +/datum/tgui_module/robot_ui_module/tgui_static_data() + var/list/data = ..() + + var/mob/living/silicon/robot/R = host + + var/list/modules = list() + if(R.module) + modules = list(R.modtype) + selected_module = R.modtype + else + if(LAZYLEN(R.restrict_modules_to) > 0) + modules.Add(R.restrict_modules_to) + else if(R.shell) + modules.Add(shell_module_types) + else + modules.Add(robot_module_types) + if(R.crisis || security_level == SEC_LEVEL_RED || R.crisis_override) + to_chat(R, span_red("Crisis mode active. Combat module available.")) + modules |= emergency_module_types + for(var/module_name in whitelisted_module_types) + if(is_borg_whitelisted(R, module_name)) + modules |= module_name + data["possible_modules"] = modules + if(R.emagged) + data["theme"] = "syndicate" + else if (R.ui_theme) + data["theme"] = R.ui_theme + + return data + +/datum/tgui_module/robot_ui_module/tgui_data() + var/list/data = ..() + + var/mob/living/silicon/robot/R = host + var/datum/asset/spritesheet/robot_icons/spritesheet = get_asset_datum(/datum/asset/spritesheet/robot_icons) + + data["currentName"] = new_name ? new_name : R.name + data["isDefaultName"] = !new_name + + if(selected_module) + data["selected_module"] = selected_module + if(!SSrobot_sprites) + to_chat(R, span_warning("Robot Sprites have not been initialized yet. How are you choosing a sprite? Harass a coder.")) + selected_module = null + return + + var/list/module_sprites = SSrobot_sprites.get_module_sprites(selected_module, R) + if(!module_sprites || !module_sprites.len) + to_chat(R, span_warning("Your module appears to have no sprite options. Harass a coder.")) + selected_module = null + return + var/list/available_sprites = list() + for(var/datum/robot_sprite/S in module_sprites) + var/model_type = "def" + if(istype(S, /datum/robot_sprite/dogborg)) + model_type = "wide" + if(istype(S, /datum/robot_sprite/dogborg/tall)) + model_type = "tall" + available_sprites += list(list("sprite" = S.name, "belly" = S.has_vore_belly_sprites, "type" = model_type)) + + data["possible_sprites"] = available_sprites + data["sprite_datum"] = sprite_datum + data["sprite_datum_class"] = null + data["sprite_datum_size"] = null + if(sprite_datum) + data["sprite_datum_class"] = sanitize_css_class_name("[sprite_datum.type]") + data["sprite_datum_size"] = spritesheet.icon_size_id(data["sprite_datum_class"] + "S") // just get the south icon's size, the rest will be the same + + return data + +/datum/tgui_module/robot_ui_module/tgui_act(action, params) + . = ..() + if(.) + return + + var/mob/living/silicon/robot/R = host + + switch(action) + if("pick_module") + if(R.module) + return + var/new_module = params["value"] + if(!(new_module in robot_modules)) + return + if(!is_borg_whitelisted(R, new_module)) + return + selected_module = new_module + if(sprite_datum) + var/new_datum + var/list/module_sprites = SSrobot_sprites.get_module_sprites(selected_module, R) + for(var/datum/robot_sprite/S in module_sprites) + if(S.name == sprite_datum.name) + new_datum = S + break + sprite_datum = new_datum + . = TRUE + if("pick_icon") + var/sprite = params["value"] + if(!sprite) + return + var/list/module_sprites = SSrobot_sprites.get_module_sprites(selected_module, R) + for(var/datum/robot_sprite/S in module_sprites) + if(S.name == sprite) + sprite_datum = S + break + . = TRUE + if("rename") + var/name = params["value"] + if(name) + new_name = sanitizeSafe(name, MAX_NAME_LEN) + . = TRUE + if("confirm") + R.apply_name(new_name) + R.apply_module(sprite_datum, selected_module) + R.transform_module() + close_ui() + . = TRUE + +/mob/living/silicon/robot/proc/apply_name(var/new_name) + if(!custom_name) + if (new_name) + custom_name = new_name + sprite_name = new_name + +/mob/living/silicon/robot/proc/apply_module(var/datum/robot_sprite/new_datum, var/new_module) + icon_selected = TRUE + var/module_type = robot_modules[new_module] + modtype = new_module + module = new module_type(src) + feedback_inc("cyborg_[lowertext(new_module)]",1) + updatename() + hud_used.update_robot_modules_display() + notify_ai(ROBOT_NOTIFICATION_NEW_MODULE, module.name) + robotact?.update_static_data_for_all_viewers() + sprite_datum = new_datum + if(!istype(src,/mob/living/silicon/robot/drone)) + sprite_type = sprite_datum.name + +/mob/living/silicon/robot/proc/transform_module() + transform_with_anim() + var/tempheight = vis_height + update_icon() + // This is bad but I dunno other way to 'reset' our resize offset based on vis_height changes other than resizing to normal and back. + if(tempheight != vis_height) + var/tempsize = size_multiplier + resize(1) + resize(tempsize) + if(hands) + update_hud() + sprite_datum.do_equipment_glamour(module) + to_chat(src, span_filter_notice("Your icon has been set. You now require a module reset to change it.")) diff --git a/code/modules/mob/living/silicon/robot/subtypes/gravekeeper.dm b/code/modules/mob/living/silicon/robot/subtypes/gravekeeper.dm index 73357c10711..ccf1908c166 100644 --- a/code/modules/mob/living/silicon/robot/subtypes/gravekeeper.dm +++ b/code/modules/mob/living/silicon/robot/subtypes/gravekeeper.dm @@ -9,6 +9,7 @@ icon_selected = FALSE can_be_antagged = FALSE restrict_modules_to = list("Gravekeeper") + ui_theme = "malfunction" /mob/living/silicon/robot/gravekeeper/init() aiCamera = new/obj/item/camera/siliconcam/robot_camera(src) diff --git a/code/modules/mob/living/silicon/robot/subtypes/lost_drone.dm b/code/modules/mob/living/silicon/robot/subtypes/lost_drone.dm index 24e449c411c..9f0aa11446c 100644 --- a/code/modules/mob/living/silicon/robot/subtypes/lost_drone.dm +++ b/code/modules/mob/living/silicon/robot/subtypes/lost_drone.dm @@ -9,6 +9,7 @@ icon_selected = FALSE restrict_modules_to = list("Lost") var/law_retries = 5 + ui_theme = "malfunction" /mob/living/silicon/robot/lost/init() aiCamera = new/obj/item/camera/siliconcam/robot_camera(src) diff --git a/code/modules/mob/living/silicon/robot/subtypes/syndicate.dm b/code/modules/mob/living/silicon/robot/subtypes/syndicate.dm index 5dd72332e44..15a8257a499 100644 --- a/code/modules/mob/living/silicon/robot/subtypes/syndicate.dm +++ b/code/modules/mob/living/silicon/robot/subtypes/syndicate.dm @@ -8,6 +8,7 @@ idcard_type = /obj/item/card/id/syndicate icon_selected = FALSE restrict_modules_to = list("Protector", "Mechanist", "Combat Medic") + ui_theme = "syndicate" /mob/living/silicon/robot/syndicate/init() aiCamera = new/obj/item/camera/siliconcam/robot_camera(src) diff --git a/code/modules/mob/living/simple_mob/subtypes/animal/turkeygirl.dm b/code/modules/mob/living/simple_mob/subtypes/animal/turkeygirl.dm new file mode 100644 index 00000000000..7f2ddba2201 --- /dev/null +++ b/code/modules/mob/living/simple_mob/subtypes/animal/turkeygirl.dm @@ -0,0 +1,101 @@ +//turkey - sprites and writing done by VerySoft +/mob/living/simple_mob/vore/turkeygirl + name = "turkeygirl" + desc = "A feathered woman! She looks like some kind of plump turkey!" + tt_desc = "Meleagris gallopian" + icon = 'icons/mob/turkey.dmi' + icon_state = "turkeygirl" + icon_living = "turkeygirl" + icon_dead = "turkeygirl-dead" + + health = 100 + maxHealth = 100 + + has_hands = TRUE + + faction = "turkey" + + response_help = "hugs" + response_disarm = "pushes" + response_harm = "punches" + attacktext = list("pecked") + + has_langs = list(LANGUAGE_GALCOM , LANGUAGE_ANIMAL) + + meat_amount = 100 + meat_type = /obj/item/reagent_containers/food/snacks/meat/chicken + + ai_holder_type = /datum/ai_holder/simple_mob/passive + + say_list_type = /datum/say_list/turkey + + vore_active = 1 + vore_capacity = 2 + vore_bump_chance = 10 + vore_pounce_chance = 10 + vore_pounce_maxhealth = 999 + vore_ignores_undigestable = 0 + vore_default_mode = DM_SELECT + vore_icons = SA_ICON_LIVING + vore_stomach_name = "Stomach" + vore_default_contamination_flavor = "Wet" + vore_default_contamination_color = "grey" + vore_default_item_mode = IM_DIGEST + vore_standing_too = TRUE + +/mob/living/simple_mob/vore/turkeygirl/init_vore() + ..() + var/obj/belly/B = vore_selected + B.name = "stomach" + B.desc = "The hot churning stomach of a turkey girl! The doughy flesh presses inward to form to your figure, thick slime coating everything, and very shortly that includes you as well! There isn't any escaping that constant full body motion, as her body works to ball yours up into a tight little package. Gurgling and glubbing with every shifting movement, while her pulse throbs through the flesh all around you with every beat of her heart. All in all, one thing is for certain! You've become turkey stuffing! Oh no..." + B.mode_flags = DM_FLAG_THICKBELLY | DM_FLAG_NUMBING + B.belly_fullscreen = "anibelly" + B.digest_brute = 1 + B.digest_burn = 6 + B.digestchance = 0 + B.absorbchance = 0 + B.escapechance = 15 + B.colorization_enabled = TRUE + B.belly_fullscreen_color = "#521717" + +/datum/say_list/turkey + speak = list("Gobble!", "Gobble gobble!", "Gobble gobble gobble!", "Give me something to be thankful for~", "Could use something to gobble~", "Why don't you make a pilgrimage over here and give me something good to eat?", "I want a treat... I could bite you too if you like~", "What's your favorite time of year?", "Autumn is the best time of year~", "You just gonna let a girl go hungry?") + +/mob/living/simple_mob/vore/turkeygirl/update_icon() + . = ..() + if(stat == DEAD) + return + if(vore_fullness == 2 || nutrition >= 5000) + icon_state = "[icon_living]-2" + + else if(vore_fullness == 1 || nutrition >= 2500) + icon_state = "[icon_living]-1" + if(resting) + icon_state = "[icon_state]-resting" + +/mob/living/simple_mob/vore/turkeygirl/attackby(var/obj/item/reagent_containers/food/snacks/O as obj, var/mob/user as mob) + if(stat) + return ..() + + if(!istype(O, /obj/item/reagent_containers/food/snacks)) + return ..() + + if(nutrition >= max_nutrition) + if(user == src) + to_chat(src, "You're too full to eat another bite.") + return + to_chat(user, "\The [src] seems too full to eat.") + return + + user.setClickCooldown(user.get_attack_speed(O)) + if(O.reagents) + O.reagents.trans_to_mob(src, O.bitesize, CHEM_INGEST) + adjust_nutrition(O.bitesize * 20) + O.bitecount ++ + O.On_Consume(src) + if(O) + to_chat(user, "\The [src] takes a bite of \the [O].") + if(user != src) + to_chat(src, "\The [user] feeds \the [O] to you.") + playsound(src, 'sound/items/eatfood.ogg', 75, 1) + update_icon() diff --git a/code/modules/mob/living/simple_mob/subtypes/vore/macrophage.dm b/code/modules/mob/living/simple_mob/subtypes/vore/macrophage.dm index dacbebb57da..3e340e0abca 100644 --- a/code/modules/mob/living/simple_mob/subtypes/vore/macrophage.dm +++ b/code/modules/mob/living/simple_mob/subtypes/vore/macrophage.dm @@ -32,6 +32,12 @@ ai_holder_type = /datum/ai_holder/simple_mob/melee +/mob/living/simple_mob/vore/aggressive/macrophage/proc/deathcheck() + if(locate(/mob/living/carbon/human) in vore_selected) + addtimer(CALLBACK(src, TYPE_PROC_REF(/mob/living/simple_mob/vore/aggressive/macrophage, deathcheck)), 3000) + else + dust() + /mob/living/simple_mob/vore/aggressive/macrophage/green icon_state = "macrophage-2" @@ -47,7 +53,7 @@ contamination_color = "green" vore_verb = "absorb" escapable = TRUE - escapable = 5 + escapable = 20 desc = "In an attempt to get away from the giant virus, it's oversized envelope proteins dragged you right past it's matrix, encapsulating you deep inside it's capsid... The strange walls kneading and keeping you tight along within it's nucleoprotein." belly_fullscreen = "VBO_gematically_angular" belly_fullscreen_color = "#87d8d8" diff --git a/code/modules/mob/transform_procs.dm b/code/modules/mob/transform_procs.dm index a686e35de7b..5d018586f1d 100644 --- a/code/modules/mob/transform_procs.dm +++ b/code/modules/mob/transform_procs.dm @@ -190,7 +190,6 @@ O.custom_speech_bubble = B.custom_speech_bubble callHook("borgify", list(O)) - O.namepick() spawn(0) // Mobs still instantly del themselves, thus we need to spawn or O will never be returned qdel(src) diff --git a/code/modules/multiz/ladders.dm b/code/modules/multiz/ladders.dm index db56742c036..7822a87d80f 100644 --- a/code/modules/multiz/ladders.dm +++ b/code/modules/multiz/ladders.dm @@ -107,7 +107,12 @@ target_ladder.audible_message(span_notice("You hear something coming [direction] \the [src]"), runemessage = "clank clank") - if(do_after(M, climb_time, src)) + var/climb_modifier = 1 + if(istype(M, /mob/living/carbon/human)) + var/mob/living/carbon/human/MS = M + climb_modifier = MS.species.climb_mult + + if(do_after(M, (climb_time * climb_modifier), src)) var/turf/T = get_turf(target_ladder) for(var/atom/A in T) if(!A.CanPass(M, M.loc, 1.5, 0)) diff --git a/code/modules/multiz/movement.dm b/code/modules/multiz/movement.dm index 41c026076f6..98f5b27fa9b 100644 --- a/code/modules/multiz/movement.dm +++ b/code/modules/multiz/movement.dm @@ -19,6 +19,13 @@ var/obj/mecha/mech = loc return mech.relaymove(src,direction) + var/swim_modifier = 1 + var/climb_modifier = 1 + if(istype(src,/mob/living/carbon/human)) + var/mob/living/carbon/human/MS = src + swim_modifier = MS.species.swim_mult + climb_modifier = MS.species.climb_mult + if(!can_ztravel()) to_chat(src, span_warning("You lack means of travel in that direction.")) return @@ -49,7 +56,7 @@ if(direction == DOWN) var/turf/simulated/floor/water/deep/ocean/diving/sink = start if(istype(sink) && !destination.density) - var/pull_up_time = max(3 SECONDS + (src.movement_delay() * 10), 1) + var/pull_up_time = max((3 SECONDS + (src.movement_delay() * 10) * swim_modifier), 1) to_chat(src, span_notice("You start diving underwater...")) src.audible_message(span_notice("[src] begins to dive under the water."), runemessage = "splish splosh") if(do_after(src, pull_up_time)) @@ -75,7 +82,7 @@ var/turf/simulated/floor/water/deep/ocean/diving/surface = destination if(lattice) - var/pull_up_time = max(5 SECONDS + (src.movement_delay() * 10), 1) + var/pull_up_time = max((5 SECONDS + (src.movement_delay() * 10) * climb_modifier), 1) to_chat(src, span_notice("You grab \the [lattice] and start pulling yourself upward...")) src.audible_message(span_notice("[src] begins climbing up \the [lattice]."), runemessage = "clank clang") if(do_after(src, pull_up_time)) @@ -85,7 +92,7 @@ return 0 else if(istype(surface)) - var/pull_up_time = max(5 SECONDS + (src.movement_delay() * 10), 1) + var/pull_up_time = max((5 SECONDS + (src.movement_delay() * 10) * swim_modifier), 1) to_chat(src, span_notice("You start swimming upwards...")) src.audible_message(span_notice("[src] begins to swim towards the surface."), runemessage = "splish splosh") if(do_after(src, pull_up_time)) @@ -95,7 +102,7 @@ return 0 else if(catwalk?.hatch_open) - var/pull_up_time = max(5 SECONDS + (src.movement_delay() * 10), 1) + var/pull_up_time = max((5 SECONDS + (src.movement_delay() * 10) * climb_modifier), 1) to_chat(src, span_notice("You grab the edge of \the [catwalk] and start pulling yourself upward...")) var/old_dest = destination destination = get_step(destination, dir) // mob's dir diff --git a/code/modules/organs/blood.dm b/code/modules/organs/blood.dm index 72b24602f9e..3364d330680 100644 --- a/code/modules/organs/blood.dm +++ b/code/modules/organs/blood.dm @@ -250,7 +250,7 @@ var/const/CE_STABLE_THRESHOLD = 0.5 B.data["viruses"] = list() for(var/datum/disease/D in GetViruses()) - if(D.spread_flags & SPECIAL || D.spread_flags & NON_CONTAGIOUS) + if(D.spread_flags & SPECIAL) continue B.data["viruses"] |= D.Copy() diff --git a/code/modules/paperwork/paper.dm b/code/modules/paperwork/paper.dm index 0b11efd1303..883a4bd6626 100644 --- a/code/modules/paperwork/paper.dm +++ b/code/modules/paperwork/paper.dm @@ -597,7 +597,7 @@ user << browse("[name][info_links][stamps]", "window=[name]") return - else if(istype(P, /obj/item/stamp) || istype(P, /obj/item/clothing/gloves/ring/seal)) + else if(istype(P, /obj/item/stamp) || istype(P, /obj/item/clothing/accessory/ring/seal)) if(istype(P, /obj/item/stamp)) var/obj/item/stamp/the_stamp = P if(the_stamp.stamptext) @@ -605,7 +605,7 @@ else stamps += (stamps=="" ? "
" : "
") + span_italics("This paper has been stamped with the [the_stamp.name].") else - var/obj/item/clothing/gloves/ring/seal/the_stamp = P + var/obj/item/clothing/accessory/ring/seal/the_stamp = P if(the_stamp.stamptext) stamps += (stamps=="" ? "
" : "
") + span_italics("[the_stamp.stamptext]") else diff --git a/code/modules/power/singularity/singularity.dm b/code/modules/power/singularity/singularity.dm index e8ffacc8f52..6d7da776df6 100644 --- a/code/modules/power/singularity/singularity.dm +++ b/code/modules/power/singularity/singularity.dm @@ -445,10 +445,10 @@ GLOBAL_LIST_BOILERPLATE(all_singularities, /obj/singularity) /obj/singularity/proc/smwave() for(var/mob/living/M in view(10, src.loc)) if(prob(67)) - to_chat(M, span_warning("You hear an uneartly ringing, then what sounds like a shrilling kettle as you are washed with a wave of heat.")) + to_chat(M, span_warning("You hear an unearthly ringing, then what sounds like a shrilling kettle as you are washed with a wave of heat.")) to_chat(M, span_notice("Miraculously, it fails to kill you.")) else - to_chat(M, span_danger("You hear an uneartly ringing, then what sounds like a shrilling kettle as you are washed with a wave of heat.")) + to_chat(M, span_danger("You hear an unearthly ringing, then what sounds like a shrilling kettle as you are washed with a wave of heat.")) to_chat(M, span_danger("You don't even have a moment to react as you are reduced to ashes by the intense radiation.")) M.dust() SSradiation.radiate(src, rand(energy)) diff --git a/code/modules/reagents/machinery/dispenser/reagent_tank.dm b/code/modules/reagents/machinery/dispenser/reagent_tank.dm index 058cbe26ea8..9e823fb51a2 100644 --- a/code/modules/reagents/machinery/dispenser/reagent_tank.dm +++ b/code/modules/reagents/machinery/dispenser/reagent_tank.dm @@ -1,6 +1,7 @@ /obj/structure/reagent_dispensers name = "Dispenser" desc = "..." + description_info = "The input can be opened by Alt-clicking it, allowing you to pour reagents inside." icon = 'icons/obj/chemical_tanks.dmi' icon_state = "tank" layer = TABLE_LAYER @@ -16,6 +17,8 @@ var/amount_per_transfer_from_this = 10 var/possible_transfer_amounts = list(10,25,50,100) + var/open_top = FALSE + /obj/structure/reagent_dispensers/attackby(obj/item/W as obj, mob/user as mob) return @@ -79,6 +82,19 @@ /obj/structure/reagent_dispensers/blob_act() qdel(src) +/obj/structure/reagent_dispensers/AltClick(mob/user) + if(!Adjacent(user)) + return + + if(flags & OPENCONTAINER) + to_chat(user, span_notice("You close the input on \the [src]")) + flags -= OPENCONTAINER + open_top = FALSE + else + to_chat(user, span_notice("You open the input on \the [src], allowing you to pour reagents in.")) + flags |= OPENCONTAINER + open_top = TRUE + /* * Tanks */ diff --git a/code/modules/reagents/machinery/grinder.dm b/code/modules/reagents/machinery/grinder.dm index 096e89a9434..a20920fc7eb 100644 --- a/code/modules/reagents/machinery/grinder.dm +++ b/code/modules/reagents/machinery/grinder.dm @@ -1,3 +1,55 @@ +// Don't need a new list for every grinder in the game +var/global/list/sheet_reagents = list( //have a number of reagents divisible by REAGENTS_PER_SHEET (default 20) unless you like decimals. + /obj/item/stack/material/plastic = list("carbon","carbon","oxygen","chlorine","sulfur"), + /obj/item/stack/material/copper = list("copper"), + /obj/item/stack/material/wood = list("carbon","woodpulp","nitrogen","potassium","sodium"), + /obj/item/stack/material/stick = list("carbon","woodpulp","nitrogen","potassium","sodium"), + /obj/item/stack/material/log = list("carbon","woodpulp","nitrogen","potassium","sodium"), + /obj/item/stack/material/algae = list("carbon","nitrogen","nitrogen","phosphorus","phosphorus"), + /obj/item/stack/material/graphite = list("carbon"), + /obj/item/stack/material/aluminium = list("aluminum"), // The material is aluminium, but the reagent is aluminum... + /obj/item/stack/material/glass/reinforced = list("silicon","silicon","silicon","iron","carbon"), + /obj/item/stack/material/leather = list("carbon","carbon","protein","protein","triglyceride"), + /obj/item/stack/material/cloth = list("carbon","carbon","carbon","protein","sodium"), + /obj/item/stack/material/fiber = list("carbon","carbon","carbon","protein","sodium"), + /obj/item/stack/material/fur = list("carbon","carbon","carbon","sulfur","sodium"), + /obj/item/stack/material/deuterium = list("hydrogen"), + /obj/item/stack/material/glass/phoronrglass = list("silicon","silicon","silicon","phoron","phoron"), + /obj/item/stack/material/diamond = list("carbon"), + /obj/item/stack/material/durasteel = list("iron","iron","carbon","carbon","platinum"), + /obj/item/stack/material/wax = list("ethanol","triglyceride"), + /obj/item/stack/material/iron = list("iron"), + /obj/item/stack/material/uranium = list("uranium"), + /obj/item/stack/material/phoron = list("phoron"), + /obj/item/stack/material/gold = list("gold"), + /obj/item/stack/material/silver = list("silver"), + /obj/item/stack/material/platinum = list("platinum"), + /obj/item/stack/material/mhydrogen = list("hydrogen"), + /obj/item/stack/material/steel = list("iron", "carbon"), + /obj/item/stack/material/plasteel = list("iron", "iron", "carbon", "carbon", "platinum"), //8 iron, 8 carbon, 4 platinum, + /obj/item/stack/material/snow = list("water"), + /obj/item/stack/material/sandstone = list("silicon", "oxygen"), + /obj/item/stack/material/glass = list("silicon"), + /obj/item/stack/material/glass/phoronglass = list("platinum", "silicon", "silicon", "silicon"), //5 platinum, 15 silicon, + /obj/item/stack/material/supermatter = list("supermatter") + ) +var/global/list/ore_reagents = list( //have a number of reageents divisible by REAGENTS_PER_ORE (default 20) unless you like decimals. + /obj/item/ore/glass = list("silicon"), + /obj/item/ore/iron = list("iron"), + /obj/item/ore/coal = list("carbon"), + /obj/item/ore/phoron = list("phoron"), + /obj/item/ore/silver = list("silver"), + /obj/item/ore/gold = list("gold"), + /obj/item/ore/marble = list("silicon","aluminum","aluminum","sodium","calcium"), // Some nice variety here + /obj/item/ore/uranium = list("uranium"), + /obj/item/ore/diamond = list("carbon"), + /obj/item/ore/osmium = list("platinum"), // should contain osmium + /obj/item/ore/lead = list("lead"), + /obj/item/ore/hydrogen = list("hydrogen"), + /obj/item/ore/verdantium = list("radium","phoron","nitrogen","phosphorus","sodium"), // Some fun stuff to be useful with + /obj/item/ore/rutile = list("tungsten","oxygen") // Should be titanium +) + /obj/machinery/reagentgrinder name = "All-In-One Grinder" @@ -14,22 +66,6 @@ var/obj/item/reagent_containers/beaker = null var/limit = 10 var/list/holdingitems = list() - var/list/sheet_reagents = list( //have a number of reageents divisible by REAGENTS_PER_SHEET (default 20) unless you like decimals, - /obj/item/stack/material/iron = list("iron"), - /obj/item/stack/material/uranium = list("uranium"), - /obj/item/stack/material/phoron = list("phoron"), - /obj/item/stack/material/gold = list("gold"), - /obj/item/stack/material/silver = list("silver"), - /obj/item/stack/material/platinum = list("platinum"), - /obj/item/stack/material/mhydrogen = list("hydrogen"), - /obj/item/stack/material/steel = list("iron", "carbon"), - /obj/item/stack/material/plasteel = list("iron", "iron", "carbon", "carbon", "platinum"), //8 iron, 8 carbon, 4 platinum, - /obj/item/stack/material/snow = list("water"), - /obj/item/stack/material/sandstone = list("silicon", "oxygen"), - /obj/item/stack/material/glass = list("silicon"), - /obj/item/stack/material/glass/phoronglass = list("platinum", "silicon", "silicon", "silicon"), //5 platinum, 15 silicon, - /obj/item/stack/material/supermatter = list("supermatter") - ) var/static/radial_examine = image(icon = 'icons/mob/radial.dmi', icon_state = "radial_examine") var/static/radial_eject = image(icon = 'icons/mob/radial.dmi', icon_state = "radial_eject") @@ -137,7 +173,7 @@ return 0 - if(!sheet_reagents[O.type] && (!O.reagents || !O.reagents.total_volume)) + if(!global.sheet_reagents[O.type] && !global.ore_reagents[O.type] && (!O.reagents || !O.reagents.total_volume)) to_chat(user, "\The [O] is not suitable for blending.") return 1 @@ -228,10 +264,10 @@ if(remaining_volume <= 0) break - if(sheet_reagents[O.type]) + if(global.sheet_reagents[O.type]) var/obj/item/stack/stack = O if(istype(stack)) - var/list/sheet_components = sheet_reagents[stack.type] + var/list/sheet_components = global.sheet_reagents[stack.type] var/amount_to_take = max(0,min(stack.get_amount(),round(remaining_volume/REAGENTS_PER_SHEET))) if(amount_to_take) stack.use(amount_to_take) @@ -245,6 +281,21 @@ beaker.reagents.add_reagent(sheet_components, (amount_to_take*REAGENTS_PER_SHEET)) continue + if(global.ore_reagents[O.type]) + var/obj/item/ore/R = O + if(istype(R)) + var/list/ore_components = global.ore_reagents[R.type] + if(remaining_volume >= REAGENTS_PER_ORE) + holdingitems -= R + qdel(R) + if(islist(ore_components)) + var/amount_to_take = (REAGENTS_PER_ORE/(ore_components.len)) + for(var/i in ore_components) + beaker.reagents.add_reagent(i, amount_to_take) + else + beaker.reagents.add_reagent(ore_components, REAGENTS_PER_ORE) + continue + if(O.reagents) O.reagents.trans_to_obj(beaker, min(O.reagents.total_volume, remaining_volume)) if(O.reagents.total_volume == 0) diff --git a/code/modules/reagents/reagent_containers/_reagent_containers.dm b/code/modules/reagents/reagent_containers/_reagent_containers.dm index 33128f94a1b..2c40ca03cc3 100644 --- a/code/modules/reagents/reagent_containers/_reagent_containers.dm +++ b/code/modules/reagents/reagent_containers/_reagent_containers.dm @@ -48,6 +48,9 @@ if(!istype(target)) return 0 + if(target.open_top) + return 0 + if(!target.reagents || !target.reagents.total_volume) to_chat(user, span_notice("[target] is empty.")) return 1 diff --git a/code/modules/reagents/reagents/virology.dm b/code/modules/reagents/reagents/virology.dm index 4556b1ed09c..de6e77e3049 100644 --- a/code/modules/reagents/reagents/virology.dm +++ b/code/modules/reagents/reagents/virology.dm @@ -20,7 +20,7 @@ /datum/reagent/mutagen/mutagenvirusfood name = "Mutagenic agar" id = "mutagenvirusfood" - description = "mutates blood" + description = "Mutates viruses when mixed in blood. This one seems rather alright." color = "#A3C00F" /datum/reagent/mutagen/mutagenvirusfood/sugar @@ -32,16 +32,17 @@ /datum/reagent/medicine/adranol/adranolvirusfood name = "Virus rations" id = "adranolvirusfood" - description = "mutates blood" + description = "Mutates viruses when mixed in blood. This one seems rather weak." color = "#D18AA5" -/datum/reagent/phoron_dust/phoronvirusfood +/datum/reagent/toxin/phoron/phoronvirusfood name = "Phoronic virus food" id = "phoronvirusfood" - description = "mutates blood" + description = "Mutates viruses when mixed in blood. This one seems to be the strongest." color = "#A69DA9" -/datum/reagent/phoron_dust/phoronvirusfood/weak +/datum/reagent/toxin/phoron/phoronvirusfood/weak name = "Weakened phoronic virus food" id = "weakphoronvirusfood" + description = "Mutates viruses when mixed in blood. This one seems to have been weakened, but still strong." color = "#CEC3C6" diff --git a/code/modules/vehicles/rover_vr.dm b/code/modules/vehicles/rover_vr.dm index 12094f58c62..9ad03c25bfa 100644 --- a/code/modules/vehicles/rover_vr.dm +++ b/code/modules/vehicles/rover_vr.dm @@ -292,12 +292,15 @@ if(!istype(C, /mob/living/carbon/human)) return 0 + . = ..(C) + + if(!.) + return + if(ismob(C)) buckle_mob(C) C.alpha = 0 - return ..() - /obj/vehicle/train/rover/engine/unload(var/mob/user, var/direction) var/mob/living/carbon/human/C = load diff --git a/code/modules/vehicles/vehicle.dm b/code/modules/vehicles/vehicle.dm index 97e9dfa7469..963faa32f8a 100644 --- a/code/modules/vehicles/vehicle.dm +++ b/code/modules/vehicles/vehicle.dm @@ -340,7 +340,7 @@ C.pixel_y += load_offset_y C.layer = layer + 0.1 - if(ismob(C)) + if(ismob(C) && user) user_buckle_mob(C, user) return 1 diff --git a/code/modules/vore/fluffstuff/custom_boxes_vr.dm b/code/modules/vore/fluffstuff/custom_boxes_vr.dm index 741d3055a12..1ff0dbeada2 100644 --- a/code/modules/vore/fluffstuff/custom_boxes_vr.dm +++ b/code/modules/vore/fluffstuff/custom_boxes_vr.dm @@ -198,7 +198,7 @@ name = "Phi's Personal Items" has_items = list( /obj/item/clothing/accessory/medal/bronze_heart, - /obj/item/clothing/gloves/ring/seal/signet/fluff/phi) + /obj/item/clothing/accessory/ring/seal/signet/fluff/phi) // Tabiranth: Ascian /obj/item/grenade/spawnergrenade/spirit diff --git a/code/modules/vore/fluffstuff/custom_clothes_vr.dm b/code/modules/vore/fluffstuff/custom_clothes_vr.dm index 6a19ad9ec27..dcab0fdc8a1 100644 --- a/code/modules/vore/fluffstuff/custom_clothes_vr.dm +++ b/code/modules/vore/fluffstuff/custom_clothes_vr.dm @@ -1687,14 +1687,14 @@ Departamental Swimsuits, for general use item_state = "kilanosuit_p_mob" //Mewchild: Phi Vietsi -/obj/item/clothing/gloves/ring/seal/signet/fluff/phi +/obj/item/clothing/accessory/ring/seal/signet/fluff/phi name = "Phi's Bone Signet Ring" desc = "A signet ring belonging to Phi, carved from the bones of something long extinct, as a ward against bad luck." icon = 'icons/vore/custom_clothes_vr.dmi' icon_state = "phi_ring" -/obj/item/clothing/gloves/ring/seal/signet/fluff/phi/change_name(var/signet_name = "Unknown") +/obj/item/clothing/accessory/ring/seal/signet/fluff/phi/change_name(var/signet_name = "Unknown") name = "[signet_name]'s Bone Signet Ring" desc = "A signet ring belonging to [signet_name], carved from the bones of something long extinct, as a ward against bad luck." @@ -1951,12 +1951,13 @@ Departamental Swimsuits, for general use icon_override = 'icons/vore/custom_clothes_vr.dmi' //CappyCat:Cappy Fuzzlyfeathers -/obj/item/clothing/accessory/watch +/obj/item/clothing/accessory/watch/custom name = "silver pocket watch" desc = "A fancy silver-plated digital pocket watch. Looks expensive." icon = 'icons/obj/deadringer.dmi' icon_state = "deadringer" w_class = ITEMSIZE_SMALL + slot = ACCESSORY_SLOT_INSIGNIA slot_flags = SLOT_ID | SLOT_BELT | SLOT_TIE //Pimientopyro:Zaku Fyodorovna @@ -2708,7 +2709,7 @@ Departamental Swimsuits, for general use //Halored: Mercury -/obj/item/clothing/gloves/ring/material/void_opal/fluff/mercury +/obj/item/clothing/accessory/ring/material/void_opal/fluff/mercury name = "Mercury's Mate Ring" desc = "A band of void opal, given to Mercury by Lumen" diff --git a/code/modules/xenoarcheaology/artifacts/replicator_vr.dm b/code/modules/xenoarcheaology/artifacts/replicator_vr.dm index 144f51bd767..e8b1ff662a8 100644 --- a/code/modules/xenoarcheaology/artifacts/replicator_vr.dm +++ b/code/modules/xenoarcheaology/artifacts/replicator_vr.dm @@ -347,7 +347,7 @@ var/list/created_items = list() var/list/tgui_vore_selection = list() var/list/viable_items = list( - /obj/item/clothing/gloves/ring, + /obj/item/clothing/accessory/ring, /obj/item/clothing/gloves/evening, /obj/item/clothing/gloves/black, /obj/item/clothing/under/swimsuit/black, diff --git a/code/modules/xenoarcheaology/finds/find_spawning.dm b/code/modules/xenoarcheaology/finds/find_spawning.dm index 7c262bd3507..af11c748e72 100644 --- a/code/modules/xenoarcheaology/finds/find_spawning.dm +++ b/code/modules/xenoarcheaology/finds/find_spawning.dm @@ -576,7 +576,7 @@ apply_image_decorations = TRUE if(prob(25)) apply_material_decorations = FALSE - new_item = new /obj/item/clothing/gloves/ring/material(src.loc) + new_item = new /obj/item/clothing/accessory/ring/material(src.loc) item_type = new_item.name if(ARCHAEO_CLUB) diff --git a/config/alienwhitelist.txt b/config/alienwhitelist.txt index 9da41e180fa..e604fe5f39a 100644 --- a/config/alienwhitelist.txt +++ b/config/alienwhitelist.txt @@ -79,6 +79,7 @@ jademanique - Protean jademanique - Teppi jademanique - Xenochimera joltze - Black-Eyed Shadekin +jparker890 - Vox juney7 - Hanner kered2 - Protean khanivore - Protean @@ -221,3 +222,4 @@ yeehawguvnah - Xenochimera zalvine - Shadekin Empathy zammyman215 - Vox zeracyfr - Xenochimera +zwadstheiguana - Diona diff --git a/icons/inventory/accessory/mob.dmi b/icons/inventory/accessory/mob.dmi index 8b67d7d7dec..9c30c1c501d 100644 Binary files a/icons/inventory/accessory/mob.dmi and b/icons/inventory/accessory/mob.dmi differ diff --git a/icons/inventory/ears/mob.dmi b/icons/inventory/ears/mob.dmi index 016c3d081d2..6071bf0efaa 100644 Binary files a/icons/inventory/ears/mob.dmi and b/icons/inventory/ears/mob.dmi differ diff --git a/icons/inventory/hands/item.dmi b/icons/inventory/hands/item.dmi index 228d7999239..3adca7d964f 100644 Binary files a/icons/inventory/hands/item.dmi and b/icons/inventory/hands/item.dmi differ diff --git a/icons/inventory/hands/mob.dmi b/icons/inventory/hands/mob.dmi index e1825ca97c7..bf041c8a023 100644 Binary files a/icons/inventory/hands/mob.dmi and b/icons/inventory/hands/mob.dmi differ diff --git a/icons/mob/items/lefthand_melee.dmi b/icons/mob/items/lefthand_melee.dmi index da3401ccedf..bc4ea4cdc34 100644 Binary files a/icons/mob/items/lefthand_melee.dmi and b/icons/mob/items/lefthand_melee.dmi differ diff --git a/icons/mob/items/righthand_melee.dmi b/icons/mob/items/righthand_melee.dmi index fc8851a610a..a9e83e3046d 100644 Binary files a/icons/mob/items/righthand_melee.dmi and b/icons/mob/items/righthand_melee.dmi differ diff --git a/icons/mob/macrophage.dmi b/icons/mob/macrophage.dmi index 4b7518bfc64..3d8d5fdeabc 100644 Binary files a/icons/mob/macrophage.dmi and b/icons/mob/macrophage.dmi differ diff --git a/icons/mob/robot/janitor.dmi b/icons/mob/robot/janitor.dmi index 7410b353a75..3dbaa27a420 100644 Binary files a/icons/mob/robot/janitor.dmi and b/icons/mob/robot/janitor.dmi differ diff --git a/icons/mob/turkey.dmi b/icons/mob/turkey.dmi new file mode 100644 index 00000000000..8f7d1db729a Binary files /dev/null and b/icons/mob/turkey.dmi differ diff --git a/icons/obj/items.dmi b/icons/obj/items.dmi index b09963ba6db..80566ece9e4 100644 Binary files a/icons/obj/items.dmi and b/icons/obj/items.dmi differ diff --git a/icons/obj/lockpicks.dmi b/icons/obj/lockpicks.dmi new file mode 100644 index 00000000000..11880cd0f52 Binary files /dev/null and b/icons/obj/lockpicks.dmi differ diff --git a/icons/obj/playing_cards.dmi b/icons/obj/playing_cards.dmi index 0f2e51923a7..fd1679a3235 100644 Binary files a/icons/obj/playing_cards.dmi and b/icons/obj/playing_cards.dmi differ diff --git a/icons/obj/radio_vr.dmi b/icons/obj/radio_vr.dmi index a4e69892f60..482f9c09f03 100644 Binary files a/icons/obj/radio_vr.dmi and b/icons/obj/radio_vr.dmi differ diff --git a/icons/obj/weapons.dmi b/icons/obj/weapons.dmi index d54a4e1e416..23ca616c029 100644 Binary files a/icons/obj/weapons.dmi and b/icons/obj/weapons.dmi differ diff --git a/maps/offmap_vr/common_offmaps.dm b/maps/offmap_vr/common_offmaps.dm index 2d7bacc46b3..b0bac955da0 100644 --- a/maps/offmap_vr/common_offmaps.dm +++ b/maps/offmap_vr/common_offmaps.dm @@ -226,6 +226,29 @@ ////////////////////////////////////////////////////////////////////////////////////// +#ifdef AWAY_MISSION_TEST +#include "../redgate/falls/falls.dmm" +#include "../redgate/abandonedisland.dmm" +#include "../redgate/cybercity.dmm" +#include "../redgate/darkadventure.dmm" +#include "../redgate/eggnogtown.dmm" +#include "../redgate/eggnogtownunderground.dmm" +#include "../redgate/facility.dmm" +#include "../redgate/fantasy_dungeon.dmm" +#include "../redgate/fantasy.dmm" +#include "../redgate/hotsprings.dmm" +#include "../redgate/innland.dmm" +#include "../redgate/islands_underwater.dmm" +#include "../redgate/islands.dmm" +#include "../redgate/jungle_underground.dmm" +#include "../redgate/jungle.dmm" +#include "../redgate/laserdome.dmm" +#include "../redgate/stardog.dmm" +#include "../redgate/teppiranch.dmm" +#include "../redgate/train_upper.dmm" +#include "../redgate/train.dmm" +#endif + /datum/map_template/common_lateload/redgate name = "Redgate Submap" desc = "Please do not use this." diff --git a/maps/redgate/cybercity.dmm b/maps/redgate/cybercity.dmm index b6ee0422167..b5b094ca1b1 100644 --- a/maps/redgate/cybercity.dmm +++ b/maps/redgate/cybercity.dmm @@ -3641,10 +3641,8 @@ /turf/simulated/floor/water/digestive_enzymes, /area/redgate/city/waterworks) "eSM" = ( -/obj/machinery/disease2/incubator, -/obj/machinery/light{ - dir = 1 - }, +/obj/structure/table/standard, +/obj/item/book/manual/virology, /turf/simulated/floor/tiled/white, /area/redgate/city/science) "eTR" = ( @@ -9085,7 +9083,7 @@ /turf/simulated/floor/tiled/white, /area/redgate/city/supermarket) "lXc" = ( -/obj/item/clothing/gloves/knuckledusters, +/obj/item/clothing/accessory/knuckledusters, /turf/simulated/floor/wood/alt/tile, /area/redgate/city/fightclub) "lXi" = ( @@ -9486,7 +9484,7 @@ /obj/structure/closet/wardrobe, /obj/random/maintenance/cargo, /obj/item/clothing/glasses/goggles, -/obj/item/clothing/gloves/ring/material/plastic, +/obj/item/clothing/accessory/ring/material/plastic, /obj/item/clothing/under/cuttop/red, /turf/simulated/floor/wood, /area/redgate/city/apartments) @@ -11034,6 +11032,13 @@ /obj/structure/undies_wardrobe, /turf/simulated/floor/tiled/freezer, /area/redgate/city/laundry) +"ozN" = ( +/obj/machinery/light{ + dir = 1 + }, +/obj/structure/prop/machine/disease_analyser, +/turf/simulated/floor/tiled/white, +/area/redgate/city/science) "ozW" = ( /obj/machinery/light{ dir = 1 @@ -14361,8 +14366,8 @@ /turf/simulated/floor/tiled/neutral, /area/redgate/city/house10) "sLw" = ( -/obj/machinery/computer/centrifuge, /obj/machinery/light, +/obj/machinery/computer/pandemic, /turf/simulated/floor/tiled/white, /area/redgate/city/science) "sLB" = ( @@ -17015,7 +17020,7 @@ /turf/simulated/floor/tiled/eris/dark/gray_platform, /area/redgate/city/engine) "wgN" = ( -/obj/machinery/disease2/diseaseanalyser, +/obj/structure/prop/machine/centrifuge, /turf/simulated/floor/tiled/white, /area/redgate/city/science) "wgO" = ( @@ -17388,7 +17393,10 @@ /turf/simulated/floor/tiled/steel_dirty, /area/redgate/city/dodgypharmacy) "wIw" = ( -/obj/machinery/computer/diseasesplicer, +/obj/structure/reagent_dispensers/virusfood{ + pixel_y = 29 + }, +/obj/structure/prop/machine/incubator, /turf/simulated/floor/tiled/white, /area/redgate/city/science) "wIy" = ( @@ -23051,10 +23059,10 @@ lyJ jNE kfL rdM +ozN +fpI +fpI eSM -fpI -fpI -uEa rdM btI kWt diff --git a/maps/redgate/eggnogtown.dmm b/maps/redgate/eggnogtown.dmm index 9dc3ed22d03..3771a88096d 100644 --- a/maps/redgate/eggnogtown.dmm +++ b/maps/redgate/eggnogtown.dmm @@ -4090,7 +4090,7 @@ "XK" = ( /obj/effect/map_effect/perma_light/gateway{ light_color = "#fc8c03"; - light_power = .5 + light_power = 0.5 }, /turf/simulated/floor/wood, /area/redgate/eggnogtown/bar) diff --git a/maps/redgate/facility.dmm b/maps/redgate/facility.dmm index bff1c55fc63..5c0259ff98e 100644 --- a/maps/redgate/facility.dmm +++ b/maps/redgate/facility.dmm @@ -3246,10 +3246,6 @@ /obj/item/bone, /turf/simulated/floor/grass, /area/redgate/facility/cell27) -"eFo" = ( -/obj/machinery/computer/centrifuge, -/turf/simulated/floor/tiled/white, -/area/redgate/facility/cell20) "eGK" = ( /turf/simulated/wall/tgmc/whitewall, /area/redgate/facility/cell27) @@ -4471,7 +4467,7 @@ /turf/simulated/floor/tiled/white, /area/redgate/facility/cell2) "gmR" = ( -/obj/machinery/computer/centrifuge, +/obj/structure/prop/machine/disease_analyser, /turf/simulated/floor/tiled/white, /area/redgate/facility/sw) "gmU" = ( @@ -4913,13 +4909,6 @@ /obj/random/forgotten_tram, /turf/simulated/floor/tiled/white, /area/redgate/facility/nw) -"gQm" = ( -/obj/machinery/disease2/isolator, -/obj/machinery/light{ - dir = 1 - }, -/turf/simulated/floor/tiled/white, -/area/redgate/facility/sw) "gQy" = ( /obj/effect/floor_decal/corner/black/border{ dir = 4 @@ -11648,7 +11637,7 @@ /turf/simulated/floor/tiled/white, /area/redgate/facility/cell15) "qsU" = ( -/obj/machinery/disease2/diseaseanalyser, +/obj/structure/prop/machine/centrifuge, /turf/simulated/floor/tiled/white, /area/redgate/facility/sw) "qtt" = ( @@ -11908,7 +11897,7 @@ /turf/simulated/floor/tiled/techfloor, /area/redgate/facility/cell9) "qMo" = ( -/obj/machinery/disease2/incubator, +/obj/structure/closet/l3closet/virology, /turf/simulated/floor/tiled/white, /area/redgate/facility/sw) "qNh" = ( @@ -11950,10 +11939,10 @@ /turf/simulated/floor/tiled/white, /area/redgate/facility/sw) "qQL" = ( -/obj/machinery/computer/diseasesplicer, /obj/machinery/light{ dir = 1 }, +/obj/machinery/computer/pandemic, /turf/simulated/floor/tiled/white, /area/redgate/facility/sw) "qQY" = ( @@ -14775,12 +14764,7 @@ "uMq" = ( /obj/structure/closet/walllocker_double/science/east, /obj/item/book/manual/virology, -/obj/item/antibody_scanner, -/obj/item/antibody_scanner, /obj/item/reagent_containers/glass/beaker, -/obj/item/virusdish/random, -/obj/item/virusdish/random, -/obj/item/virusdish/random, /turf/simulated/floor/tiled/white, /area/redgate/facility/sw) "uNl" = ( @@ -19788,7 +19772,7 @@ pLg fPE mzU aOv -gQm +xRG vrp oWf aOv @@ -30193,7 +30177,7 @@ aKz ehw lnw sCO -eFo +ehw hgj hgj hgj diff --git a/maps/redgate/fantasy.dmm b/maps/redgate/fantasy.dmm index 55252e07c65..072d62751c1 100644 --- a/maps/redgate/fantasy.dmm +++ b/maps/redgate/fantasy.dmm @@ -550,7 +550,7 @@ /area/redgate/fantasy/butcher) "dw" = ( /obj/structure/table/woodentable, -/obj/item/clothing/gloves/ring/material/silver, +/obj/item/clothing/accessory/ring/material/silver, /obj/structure/window/basic{ dir = 4 }, @@ -2067,7 +2067,7 @@ /area/redgate/fantasy/redgate) "mW" = ( /obj/structure/table/woodentable, -/obj/item/clothing/gloves/ring/material/diamond, +/obj/item/clothing/accessory/ring/material/diamond, /obj/structure/window/basic{ dir = 4 }, @@ -2507,7 +2507,7 @@ /area/redgate/fantasy/grocery) "pq" = ( /obj/structure/table/woodentable, -/obj/item/clothing/gloves/ring/material/gold, +/obj/item/clothing/accessory/ring/material/gold, /obj/structure/window/basic{ dir = 4 }, @@ -2906,7 +2906,7 @@ /area/redgate/fantasy/church) "rO" = ( /obj/structure/table/woodentable, -/obj/item/clothing/gloves/ring/material/wood, +/obj/item/clothing/accessory/ring/material/wood, /turf/simulated/floor/wood/alt, /area/redgate/fantasy/jewler) "rP" = ( @@ -3465,7 +3465,7 @@ /area/redgate/fantasy/butcher) "vl" = ( /obj/structure/table/rack/shelf/wood, -/obj/item/clothing/gloves/ring/material/silver, +/obj/item/clothing/accessory/ring/material/silver, /obj/machinery/light/small/torch{ dir = 8 }, @@ -3489,7 +3489,7 @@ /area/redgate/fantasy/castle) "vp" = ( /obj/structure/table/woodentable, -/obj/item/clothing/gloves/ring/material/void_opal, +/obj/item/clothing/accessory/ring/material/void_opal, /obj/structure/window/basic{ dir = 4 }, @@ -5126,7 +5126,7 @@ /area/redgate/fantasy/house) "FQ" = ( /obj/structure/table/woodentable, -/obj/item/clothing/gloves/knuckledusters, +/obj/item/clothing/accessory/knuckledusters, /turf/simulated/floor/wood/alt, /area/redgate/fantasy/house) "FS" = ( @@ -7836,7 +7836,7 @@ /area/redgate/fantasy/butcher) "WW" = ( /obj/structure/table/rack/shelf/wood, -/obj/item/clothing/gloves/ring/material/gold, +/obj/item/clothing/accessory/ring/material/gold, /turf/simulated/floor/wood/alt, /area/redgate/fantasy/jewler) "WZ" = ( @@ -8255,7 +8255,7 @@ /area/redgate/fantasy/bard) "ZP" = ( /obj/structure/table/woodentable, -/obj/item/clothing/gloves/ring/material/iron, +/obj/item/clothing/accessory/ring/material/iron, /turf/simulated/floor/wood/alt, /area/redgate/fantasy/jewler) "ZS" = ( diff --git a/maps/redgate/fantasy_dungeon.dmm b/maps/redgate/fantasy_dungeon.dmm index 64436653a2a..44cc56930bf 100644 --- a/maps/redgate/fantasy_dungeon.dmm +++ b/maps/redgate/fantasy_dungeon.dmm @@ -209,7 +209,7 @@ /turf/simulated/floor/concrete, /area/redgate/fantasy/castle) "ez" = ( -/obj/item/clothing/gloves/ring/material/gold, +/obj/item/clothing/accessory/ring/material/gold, /turf/simulated/mineral/floor/ignore_cavegen/cave, /area/redgate/fantasy/caves) "eP" = ( diff --git a/maps/redgate/hotsprings.dmm b/maps/redgate/hotsprings.dmm index 725aafba2a2..4a8eaccc540 100644 --- a/maps/redgate/hotsprings.dmm +++ b/maps/redgate/hotsprings.dmm @@ -1209,7 +1209,7 @@ /obj/random/mouseray, /obj/random/cash/huge, /obj/item/clothing/ears/earring/dangle/diamond, -/obj/item/clothing/gloves/ring/material/diamond, +/obj/item/clothing/accessory/ring/material/diamond, /obj/structure/closet/grave/dirthole, /obj/random/coin, /turf/simulated/floor/outdoors/dirt{ diff --git a/maps/redgate/islands_underwater.dmm b/maps/redgate/islands_underwater.dmm index 834ec9585ae..5f25f246f3c 100644 --- a/maps/redgate/islands_underwater.dmm +++ b/maps/redgate/islands_underwater.dmm @@ -848,7 +848,7 @@ /turf/simulated/floor/water/underwater/sand, /area/redgate/islands/ruins) "qY" = ( -/obj/item/clothing/gloves/ring/material/gold, +/obj/item/clothing/accessory/ring/material/gold, /turf/simulated/floor/water/underwater/sand, /area/redgate/islands/ruins) "rk" = ( diff --git a/maps/redgate/train_upper.dmm b/maps/redgate/train_upper.dmm index f5921a71d0a..56b08472297 100644 --- a/maps/redgate/train_upper.dmm +++ b/maps/redgate/train_upper.dmm @@ -3121,8 +3121,8 @@ /obj/structure/closet/cabinet, /obj/item/clothing/under/suit_jacket, /obj/item/clothing/shoes/dress, -/obj/item/clothing/gloves/ring/wedding, -/obj/item/clothing/gloves/ring/wedding, +/obj/item/clothing/accessory/ring/wedding, +/obj/item/clothing/accessory/ring/wedding, /obj/item/clothing/accessory/bowtie/black, /turf/simulated/floor/wood, /area/redgate/train/dorm6) diff --git a/maps/submaps/admin_use_vr/kk_mercship.dmm b/maps/submaps/admin_use_vr/kk_mercship.dmm index 899fd7f7369..7a8048d4fa4 100644 --- a/maps/submaps/admin_use_vr/kk_mercship.dmm +++ b/maps/submaps/admin_use_vr/kk_mercship.dmm @@ -9996,8 +9996,8 @@ /obj/machinery/recharger/wallcharger{ pixel_y = 20 }, -/obj/item/clothing/gloves/knuckledusters, -/obj/item/clothing/gloves/knuckledusters, +/obj/item/clothing/accessory/knuckledusters, +/obj/item/clothing/accessory/knuckledusters, /obj/item/flash, /obj/item/flash, /obj/item/laser_pointer/upgraded, diff --git a/maps/submaps/depreciated_vr/mercbase.dmm b/maps/submaps/depreciated_vr/mercbase.dmm index ca3b40f71b9..234417b727d 100644 --- a/maps/submaps/depreciated_vr/mercbase.dmm +++ b/maps/submaps/depreciated_vr/mercbase.dmm @@ -2463,11 +2463,11 @@ }, /area/antag/antag_base) "dM" = ( -/obj/item/clothing/gloves/knuckledusters, -/obj/item/clothing/gloves/knuckledusters, -/obj/item/clothing/gloves/knuckledusters, -/obj/item/clothing/gloves/knuckledusters, -/obj/item/clothing/gloves/knuckledusters, +/obj/item/clothing/accessory/knuckledusters, +/obj/item/clothing/accessory/knuckledusters, +/obj/item/clothing/accessory/knuckledusters, +/obj/item/clothing/accessory/knuckledusters, +/obj/item/clothing/accessory/knuckledusters, /obj/structure/table/steel, /obj/effect/floor_decal/borderfloorblack{ dir = 6 diff --git a/maps/submaps/surface_submaps/wilderness/drgnplateu.dmm b/maps/submaps/surface_submaps/wilderness/drgnplateu.dmm index 2f202bffdac..7043f0230ea 100644 --- a/maps/submaps/surface_submaps/wilderness/drgnplateu.dmm +++ b/maps/submaps/surface_submaps/wilderness/drgnplateu.dmm @@ -41,7 +41,7 @@ /obj/structure/flora/grass/green{ pixel_x = -8 }, -/obj/item/clothing/gloves/ring/material/gold, +/obj/item/clothing/accessory/ring/material/gold, /obj/item/clothing/ears/earring/stud/gold, /obj/item/gun/projectile/deagle/gold{ pixel_x = -11; diff --git a/maps/~map_system/_map_selection.dm b/maps/~map_system/_map_selection.dm index 47ff0d984d0..879f058f545 100644 --- a/maps/~map_system/_map_selection.dm +++ b/maps/~map_system/_map_selection.dm @@ -5,8 +5,8 @@ /* FOR LIVE SERVER */ /*********************/ -//#define USE_MAP_TETHER -#define USE_MAP_STELLARDELIGHT +#define USE_MAP_TETHER +//#define USE_MAP_STELLARDELIGHT //#define USE_MAP_GROUNDBASE // Debug diff --git a/tgui/packages/tgui/interfaces/ModifyRobot/ModifyRobotTabs/ModifyRobotComponent.tsx b/tgui/packages/tgui/interfaces/ModifyRobot/ModifyRobotTabs/ModifyRobotComponent.tsx index 293db7da7de..165b95af2e7 100644 --- a/tgui/packages/tgui/interfaces/ModifyRobot/ModifyRobotTabs/ModifyRobotComponent.tsx +++ b/tgui/packages/tgui/interfaces/ModifyRobot/ModifyRobotTabs/ModifyRobotComponent.tsx @@ -2,16 +2,17 @@ import { capitalize } from 'common/string'; import { useState } from 'react'; import { useBackend } from 'tgui/backend'; import { + Box, Button, Divider, Flex, Icon, - Image, Input, Section, Stack, Tabs, } from 'tgui/components'; +import { classes } from 'tgui-core/react'; import { NoSpriteWarning } from '../components'; import { @@ -163,15 +164,18 @@ export const ModifyRobotComponent = (props: { - + + + + + + + diff --git a/tgui/packages/tgui/interfaces/ModifyRobot/ModifyRobotTabs/ModifyRobotModules.tsx b/tgui/packages/tgui/interfaces/ModifyRobot/ModifyRobotTabs/ModifyRobotModules.tsx index 045025ccd56..85ad5a6da4c 100644 --- a/tgui/packages/tgui/interfaces/ModifyRobot/ModifyRobotTabs/ModifyRobotModules.tsx +++ b/tgui/packages/tgui/interfaces/ModifyRobot/ModifyRobotTabs/ModifyRobotModules.tsx @@ -13,6 +13,7 @@ import { Section, Stack, } from 'tgui/components'; +import { classes } from 'tgui-core/react'; import { NoSpriteWarning } from '../components'; import { prepareSearch } from '../functions'; @@ -47,7 +48,8 @@ export const ModifyRobotModules = (props: { /> {!!source && ( - + + + + + + + { /> - + + + + + + + { /> - + + + + + + + { + const { act } = useBackend(); + const { currentName, isDefaultName, sprite, size } = props; + + return ( +
act('confirm')}> + Confirm + + } + > + + + + Name: + + + + act('rename', { value })} + maxLength={52} + textColor={isDefaultName ? 'red' : undefined} + /> + + + + + {!!sprite && !!size && ( + <> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + )} +
+ ); +}; diff --git a/tgui/packages/tgui/interfaces/RobotChoose/ModuleSection.tsx b/tgui/packages/tgui/interfaces/RobotChoose/ModuleSection.tsx new file mode 100644 index 00000000000..c90dbbe7be5 --- /dev/null +++ b/tgui/packages/tgui/interfaces/RobotChoose/ModuleSection.tsx @@ -0,0 +1,47 @@ +import { createSearch } from 'common/string'; +import { useState } from 'react'; +import { Input, Section, Stack } from 'tgui-core/components'; + +import { SelectorElement } from './SelectorElement'; + +export const ModuleSection = (props: { + title: string; + sortable?: string[]; + selected?: string; +}) => { + const { title, sortable, selected } = props; + + const [searchText, setSearchText] = useState(''); + + const searcher = createSearch(searchText, (element: string) => { + return element; + }); + + const filtered = sortable?.filter(searcher); + + return ( +
+ + setSearchText(value)} + /> + + + + {!!filtered && + filtered.map((filter) => ( + + ))} + + +
+ ); +}; diff --git a/tgui/packages/tgui/interfaces/RobotChoose/SelectorElement.tsx b/tgui/packages/tgui/interfaces/RobotChoose/SelectorElement.tsx new file mode 100644 index 00000000000..3279ce78829 --- /dev/null +++ b/tgui/packages/tgui/interfaces/RobotChoose/SelectorElement.tsx @@ -0,0 +1,34 @@ +import { useBackend } from 'tgui/backend'; +import { Button, Flex, Icon, Stack } from 'tgui-core/components'; + +export const SelectorElement = (props: { + option: string; + action: string; + selected?: string | null; + belly?: boolean; +}) => { + const { act } = useBackend(); + const { option, action, selected, belly } = props; + + return ( + + + + ); +}; diff --git a/tgui/packages/tgui/interfaces/RobotChoose/SpriteSection.tsx b/tgui/packages/tgui/interfaces/RobotChoose/SpriteSection.tsx new file mode 100644 index 00000000000..d287792d025 --- /dev/null +++ b/tgui/packages/tgui/interfaces/RobotChoose/SpriteSection.tsx @@ -0,0 +1,80 @@ +import { useState } from 'react'; +import { Button, Input, Section, Stack } from 'tgui-core/components'; + +import { robotSpriteSearcher } from './functions'; +import { SelectorElement } from './SelectorElement'; +import { spriteOption } from './types'; + +export const SpriteSection = (props: { + title: string; + selected?: string | null; + sortable?: spriteOption[]; +}) => { + const { title, sortable, selected } = props; + + const [searchText, setSearchText] = useState(''); + const [includeDefault, setIncludeDefault] = useState(false); + const [includeWide, setInclideDog] = useState(false); + const [includeTall, setIncludeTall] = useState(false); + + const filtered = robotSpriteSearcher( + searchText, + includeDefault, + includeWide, + includeTall, + sortable, + ); + return ( +
+ setIncludeDefault(!includeDefault)} + > + Def + + setInclideDog(!includeWide)} + > + Wide + + setIncludeTall(!includeTall)} + > + Tall + + + } + > + + setSearchText(value)} + /> + + + + {!!filtered && + filtered.map((filter) => ( + + ))} + + +
+ ); +}; diff --git a/tgui/packages/tgui/interfaces/RobotChoose/functions.ts b/tgui/packages/tgui/interfaces/RobotChoose/functions.ts new file mode 100644 index 00000000000..db60717e88e --- /dev/null +++ b/tgui/packages/tgui/interfaces/RobotChoose/functions.ts @@ -0,0 +1,47 @@ +import { filter } from 'common/collections'; +import { flow } from 'common/fp'; +import { createSearch } from 'common/string'; + +import { spriteOption } from './types'; + +export function robotSpriteSearcher( + searchText: string, + includeDefault: boolean, + includeWide: boolean, + includeTall: boolean, + sprites?: spriteOption[], +): spriteOption[] { + const testSearch = createSearch( + searchText, + (sprite: spriteOption) => sprite.sprite, + ); + if (!sprites) { + return []; + } + let subtypes: string[] = []; + if (includeDefault) { + subtypes.push('def'); + } + if (includeWide) { + subtypes.push('wide'); + } + if (includeTall) { + subtypes.push('tall'); + } + return flow([ + (sprites: spriteOption[]) => { + if (!searchText) { + return sprites; + } else { + return filter(sprites, testSearch); + } + }, + (sprites: spriteOption[]) => { + if (!subtypes.length) { + return sprites; + } else { + return filter(sprites, (sprite) => subtypes.includes(sprite.type)); + } + }, + ])(sprites); +} diff --git a/tgui/packages/tgui/interfaces/RobotChoose/index.tsx b/tgui/packages/tgui/interfaces/RobotChoose/index.tsx new file mode 100644 index 00000000000..91d8dcb7d57 --- /dev/null +++ b/tgui/packages/tgui/interfaces/RobotChoose/index.tsx @@ -0,0 +1,49 @@ +import { useBackend } from 'tgui/backend'; +import { Window } from 'tgui/layouts'; +import { Stack } from 'tgui-core/components'; + +import { IconSection } from './IconSection'; +import { ModuleSection } from './ModuleSection'; +import { SpriteSection } from './SpriteSection'; +import { Data } from './types'; + +export const RobotChoose = (props) => { + const { data } = useBackend(); + + const { + possible_modules, + possible_sprites, + selected_module, + sprite_datum, + theme, + currentName, + isDefaultName, + sprite_datum_class, + sprite_datum_size, + } = data; + + return ( + + + + + + + + + + ); +}; diff --git a/tgui/packages/tgui/interfaces/RobotChoose/types.ts b/tgui/packages/tgui/interfaces/RobotChoose/types.ts new file mode 100644 index 00000000000..06d691c5893 --- /dev/null +++ b/tgui/packages/tgui/interfaces/RobotChoose/types.ts @@ -0,0 +1,13 @@ +export type Data = { + possible_modules: string[]; + possible_sprites?: spriteOption[]; + currentName: string; + isDefaultName: boolean; + theme?: string; + selected_module?: string; + sprite_datum?: string | null; + sprite_datum_class?: string | null; + sprite_datum_size?: string | null; +}; + +export type spriteOption = { sprite: string; belly: boolean; type: string }; diff --git a/tgui/packages/tgui/interfaces/Robotact/index.tsx b/tgui/packages/tgui/interfaces/Robotact/index.tsx index 94b97253342..1ab5ea486aa 100644 --- a/tgui/packages/tgui/interfaces/Robotact/index.tsx +++ b/tgui/packages/tgui/interfaces/Robotact/index.tsx @@ -18,7 +18,7 @@ export const Robotact = (props) => { } return ( - + {content} ); diff --git a/tgui/packages/tgui/interfaces/Robotact/types.ts b/tgui/packages/tgui/interfaces/Robotact/types.ts index bd33676d99d..b4232ff6e43 100644 --- a/tgui/packages/tgui/interfaces/Robotact/types.ts +++ b/tgui/packages/tgui/interfaces/Robotact/types.ts @@ -31,6 +31,7 @@ export type Data = { max_health: number; light_color: string; + theme?: string; // Modules modules_static: Module[]; diff --git a/tgui/packages/tgui/interfaces/SmartVend.tsx b/tgui/packages/tgui/interfaces/SmartVend.tsx index 7c8eeba29d3..29a2cf76713 100644 --- a/tgui/packages/tgui/interfaces/SmartVend.tsx +++ b/tgui/packages/tgui/interfaces/SmartVend.tsx @@ -1,8 +1,18 @@ -import { map } from 'common/collections'; import { BooleanLike } from 'common/react'; +import { createSearch } from 'common/string'; +import { useState } from 'react'; import { useBackend } from '../backend'; -import { Box, Button, NoticeBox, Section, Table } from '../components'; +import { + Box, + Button, + Dropdown, + Flex, + Input, + NoticeBox, + Section, + Table, +} from '../components'; import { Window } from '../layouts'; type Data = { @@ -14,8 +24,28 @@ type Data = { type content = { name: string; index: number; amount: number }; +const sortTypes = { + Alphabetical: (a: content, b: content) => a.name > b.name, + 'By amount': (a: content, b: content) => -(a.amount - b.amount), +}; + export const SmartVend = (props) => { - const { act, config, data } = useBackend(); + const { config, data } = useBackend(); + const [searchText, setSearchText] = useState(''); + const [sortOrder, setSortOrder] = useState('Alphabetical'); + const [descending, setDescending] = useState(false); + + function handleSearchText(value: string) { + setSearchText(value); + } + + function handleSortOrder(value: string) { + setSortOrder(value); + } + + function handleDescending(value: boolean) { + setDescending(value); + } const { secure, locked, contents } = data; @@ -39,100 +69,191 @@ export const SmartVend = (props) => { {(contents.length === 0 && ( Unfortunately, this {config.title} is empty. )) || ( - - - Item - - Amount - - - Dispense - - - {map(contents, (value: content, key) => ( - - - {value.name} - - - {value.amount} in stock - - - - - - - - - - - ))} -
+ <> + + + )}
); }; + +const SheetSearch = (props: { + searchText: string; + sortOrder: string; + descending: boolean; + onSearchText: Function; + onSortOrder: Function; + onDescending: Function; +}) => { + const { + searchText, + sortOrder, + descending, + onSearchText, + onSortOrder, + onDescending, + } = props; + return ( + + + + onSearchText(value)} + /> + + + onSortOrder(v)} + /> + + +