From 88df7b3993ccbc49911b0cd0ada1635e7a7fd9c3 Mon Sep 17 00:00:00 2001 From: Foopwo Date: Sat, 14 May 2022 19:41:26 -0700 Subject: [PATCH] Added donksoft gun and size gun upgrades for borgs --- code/datums/supplypacks/recreation.dm | 9 ++++ .../objects/items/robot/robot_upgrades_vr.dm | 48 ++++++++++++++++++ code/modules/projectiles/guns/toy.dm | 45 ++++++++++++++++ code/modules/research/prosfab_designs_vr.dm | 7 +++ icons/obj/module.dmi | Bin 1087 -> 1177 bytes 5 files changed, 109 insertions(+) diff --git a/code/datums/supplypacks/recreation.dm b/code/datums/supplypacks/recreation.dm index ba6a33d48cb..40caa4c405b 100644 --- a/code/datums/supplypacks/recreation.dm +++ b/code/datums/supplypacks/recreation.dm @@ -35,6 +35,15 @@ containertype = /obj/structure/closet/crate/allico containername = "foam weapon crate" +/datum/supply_pack/recreation/donksoftborg + name = "Donk-Soft Cyborg Blaster Crate" + contains = list( + /obj/item/borg/upgrade/toygun = 2, + ) + cost = 35 + containertype = /obj/structure/closet/crate/allico + containername = "foam weapon crate" + /datum/supply_pack/recreation/donksoftvend name = "Donk-Soft Vendor Crate" contains = list() diff --git a/code/game/objects/items/robot/robot_upgrades_vr.dm b/code/game/objects/items/robot/robot_upgrades_vr.dm index bd9f247ec7f..499d535a5cc 100644 --- a/code/game/objects/items/robot/robot_upgrades_vr.dm +++ b/code/game/objects/items/robot/robot_upgrades_vr.dm @@ -31,6 +31,30 @@ R.verbs += /mob/living/proc/set_size return 1 +//Robot size gun +/obj/item/borg/upgrade/sizegun + name = "robot mounted size gun" + desc = "A size gun adapted for installation in cyborgs, allows them to turn people pocket-sized among other uses. What could go wrong?" + icon_state = "cyborg_upgrade2" + item_state = "cyborg_upgrade" + require_module = 1 + +/obj/item/borg/upgrade/sizegun/action(var/mob/living/silicon/robot/R) + if(..()) return 0 + + var/obj/item/weapon/gun/energy/sizegun/mounted/T = locate() in R.module + if(!T) + T = locate() in R.module.contents + if(!T) + T = locate() in R.module.modules + if(!T) + R.module.modules += new/obj/item/weapon/gun/energy/sizegun/mounted(R.module) + return 1 + if(T) + to_chat(R, "Upgrade mounting error! No suitable hardpoint detected!") + to_chat(usr, "There's no mounting point for the module!") + return 0 + /obj/item/borg/upgrade/bellysizeupgrade name = "robohound capacity expansion module" desc = "Used to double a robohound's belly capacity. This only affects total volume, and won't allow support of more than one patient in case of sleeper bellies. Can only be applied once." @@ -152,6 +176,30 @@ if(!T) R.module.modules += new/obj/item/weapon/gun/energy/kinetic_accelerator/cyborg(R.module) return 1 + if(T) + to_chat(R, "Upgrade mounting error! No suitable hardpoint detected!") + to_chat(usr, "There's no mounting point for the module!") + return 0 + +//cyborg foam dart gun +/obj/item/borg/upgrade/toygun + name = "Donk-Soft Cyborg Blaster module" //Cyborg Blaster is capitalized because it's the brand name + desc = "A foam dart gun designed for mounting into cyborgs. It's Donk or Don't! DISCLAIMER: Donk-Soft bears no responsibility for incidents relating to cyborgs becoming too accustomed to shooting at crew. Installation of the Donk-Soft Cyborg Blaster must be performed only by a licensed roboticist." + icon_state = "cyborg_upgrade5" + item_state = "cyborg_upgrade" + require_module = 1 + +/obj/item/borg/upgrade/toygun/action(var/mob/living/silicon/robot/R) + if(..()) return 0 + + var/obj/item/weapon/gun/projectile/cyborgtoy/T = locate() in R.module + if(!T) + T = locate() in R.module.contents + if(!T) + T = locate() in R.module.modules + if(!T) + R.module.modules += new/obj/item/weapon/gun/projectile/cyborgtoy(R.module) + return 1 if(T) to_chat(R, "Upgrade mounting error! No suitable hardpoint detected!") to_chat(usr, "There's no mounting point for the module!") diff --git a/code/modules/projectiles/guns/toy.dm b/code/modules/projectiles/guns/toy.dm index e3b90bd1be0..a4ef0dbf3be 100644 --- a/code/modules/projectiles/guns/toy.dm +++ b/code/modules/projectiles/guns/toy.dm @@ -199,7 +199,52 @@ icon_state = initial(icon_state) else icon_state = "[initial(icon_state)]-e" +/* + * Cyborg + */ +/obj/item/weapon/gun/projectile/cyborgtoy + name = "\improper Donk-Soft Cyborg Blaster" + desc = "Donk-Soft Cyborg Blaster! It's Donk or Don't! Adult supervision required. Use to toggle between battle and cleanup mode." + icon = 'icons/obj/gun_toy.dmi' + icon_state = "smg" + caliber = "foam" + load_method = SINGLE_CASING + max_shells = 15 + var/cleanup = 0 + ammo_type = /obj/item/ammo_casing/afoam_dart + projectile_type = /obj/item/projectile/bullet/foam_dart + recoil = null + handle_casings = null +/obj/item/weapon/gun/projectile/cyborgtoy/attack_self(var/mob/user) + cleanup = !cleanup + to_chat(user, "The [src] is now on [cleanup ? "cleanup" : "battle"] mode.") + +/obj/item/weapon/gun/projectile/cyborgtoy/afterattack(atom/A, mob/living/user, adjacent, params) + if(cleanup) + if(!adjacent) + return 0 + collectammo(A, user) + return 0 + ..() + +/obj/item/weapon/gun/projectile/cyborgtoy/proc/collectammo(atom/A, user) + if(loaded.len >= max_shells) + to_chat(user, "The [src] is at max capacity.") + return + var/T = get_turf(A) + var/success = 0 + for(var/obj/item/ammo_casing/afoam_dart/D in T) + if(loaded.len >= max_shells) + break + D.loc = src + loaded.Insert(1, D) + success = 1 + if(success) + playsound(src, 'sound/machines/hiss.ogg', 50, 0) + to_chat(user, "The [src] vacuums in the darts!") + else + to_chat(user, "No Donk-Soft brand foam darts detected. Aborting.") /* * Laser Tag */ diff --git a/code/modules/research/prosfab_designs_vr.dm b/code/modules/research/prosfab_designs_vr.dm index bb15c848f81..8275a456c9e 100644 --- a/code/modules/research/prosfab_designs_vr.dm +++ b/code/modules/research/prosfab_designs_vr.dm @@ -7,6 +7,13 @@ materials = list(MAT_STEEL = 4000, MAT_GLASS = 4000) build_path = /obj/item/borg/upgrade/sizeshift +/datum/design/item/prosfab/robot_upgrade/sizegun + name = "Size Gun Module" + id = "borg_sizegun_module" + req_tech = list(TECH_COMBAT = 3, TECH_BLUESPACE = 3, TECH_MATERIAL = 3, TECH_POWER = 2) + materials = list(MAT_STEEL = 6000, MAT_GLASS = 4000) + build_path = /obj/item/borg/upgrade/sizegun + /datum/design/item/prosfab/robot_upgrade/bellysizeupgrade name = "Robohound Capacity Expansion Module" id = "borg_hound_capacity_module" diff --git a/icons/obj/module.dmi b/icons/obj/module.dmi index 087ceb08b7d2dc2a4b6e0787bbef53973fe474a0..517ce37d4b23bee87e07ae7b5d4d46e33a315df1 100644 GIT binary patch delta 1023 zcmV0x7Y=|30{{R3^x%>C0001cktKE>z`(%&%rpO)GvS<>TmS$70d!JM zQvg8b*k%9#0Jf2^BY*6;%TR`g`3h2Pre(F2w43bhS0?N>Y;XC89|?h^>{4HwmQ}Zg zz5uN>nw?pBI8w4o;U*u7oRSITIJqrY#~t`Gu}*Ze5eX$iqV=7Ok~{Jlw)*FK#q}dd z4jjWqE@lM`k}_=I%%$#)U%xL0qa7Nh0Qc{C_XfxAxs1pKM1S%u(&v%Bi1cNoKmGG5 ztJ~`PaUUl2!bF8G*O()8vlL)X$lHFN+~#9FgboREq`HN#|S{? z)}1b}@c=TeRDTZH(h?PY0n4SzZcBV3^6i4mDo`5#s-Y`1CnMrTVe;>mtMzKVJ{4ec zDvaOa6Loxlg-UCDP$xKXfQg%Y-hnE%4#X9aZx(1Tz?w;1p&oHS7bgFX6`-q1X%v7@ zj04JEq*9bcpK-wDv$x@v&PHZN6N9Iqy>kRlhG>-55Qm&(VMbPCk`CBEUHClsL9j z>4XAQS${I^iLgJQc8H38OcY=pNSdT+Hk&P3I@!Vn0tk96gZ%*@n@DaCG%J@*?SZa8;D0t@|6MTZz)1aW95BH$D~V_?|Lu3* zfq@1`kAD3Q<`&@bOP~bw^4};24ieQr^al>_AbiB1fpx%_zf}GHiFl#A845OT9H8SLk@*2Z5ClOG z1Yvf*VMIX${C@({G=Kl&d7nc-p69iz|3vY>nH;EH{f|m!bHLXB^*jR5fxK<&HgD&1 tAlK%%p3i~cT`*R^UmB_31wptT{sKbYJGz%)ZXo~w002ovPDHLkV1kfP*jxYr delta 932 zcmV;V16%x=3BL%C7Y<+u0{{R3;-rdu0001TktKE&T*yFF00001bW%=J06^y0W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