From b711e891f0891aebd338397944ff4894a02c417e Mon Sep 17 00:00:00 2001 From: 4000daniel1 <4000daniel2@hotmail.se> Date: Sat, 10 Feb 2024 00:04:05 +0100 Subject: [PATCH 1/5] oioaa --- .../preference_setup/loadout/items/general.dm | 24 ++++++++++++++++++ .../real_instruments/Violin/violin.dm | 2 ++ icons/mob/items/device/lefthand_device.dmi | Bin 8354 -> 10866 bytes icons/mob/items/device/righthand_device.dmi | Bin 8405 -> 10963 bytes 4 files changed, 26 insertions(+) diff --git a/code/modules/client/preference_setup/loadout/items/general.dm b/code/modules/client/preference_setup/loadout/items/general.dm index bb7c26cfe23..ee168f37630 100644 --- a/code/modules/client/preference_setup/loadout/items/general.dm +++ b/code/modules/client/preference_setup/loadout/items/general.dm @@ -409,3 +409,27 @@ display_name = "aurora miniature" description = "A commemorative miniature of the NSS Aurora." path = /obj/item/toy/aurora + +/datum/gear/guitar + display_name = "guitar" + description = "A wooden musical instrument with six strings. This one looks like it may actually work." + path = /obj/item/device/synthesized_instrument/guitar + allowed_roles = list("Off-Duty Crew Member", "Passenger") + +/datum/gear/polyguitar + display_name = "polyguitar" + description = "An instrument for a more ass-kicking era." + path = /obj/item/device/synthesized_instrument/guitar/multi + allowed_roles = list("Off-Duty Crew Member", "Passenger") + +/datum/gear/violin + display_name = "violin" + description = "A wooden musical instrument with four strings and a bow, it is quite old." + path = /obj/item/device/synthesized_instrument/violin + allowed_roles = list("Off-Duty Crew Member", "Passenger") + +/datum/gear/trumpet + display_name = "Omnitrumpet" + description = "The Omnitrumptet series 400 with more than 30 sound samples and fully customizable high fidelity output provides the ultimate means to toot your own horn." + path = /obj/item/device/synthesized_instrument/trumpet + allowed_roles = list("Off-Duty Crew Member", "Passenger") diff --git a/code/modules/synthesized_instruments/real_instruments/Violin/violin.dm b/code/modules/synthesized_instruments/real_instruments/Violin/violin.dm index bb34e8284a1..1d3fea0dbc8 100644 --- a/code/modules/synthesized_instruments/real_instruments/Violin/violin.dm +++ b/code/modules/synthesized_instruments/real_instruments/Violin/violin.dm @@ -6,7 +6,9 @@ /obj/item/device/synthesized_instrument/violin name = "violin" desc = "A wooden musical instrument with four strings and a bow, it is quite old" + icon = 'icons/obj/musician.dmi' icon_state = "violin" + item_state = "violin" sound_player = /datum/sound_player/violin path = /datum/instrument/obsolete/violin diff --git a/icons/mob/items/device/lefthand_device.dmi b/icons/mob/items/device/lefthand_device.dmi index a143a1d38c14707ac34e1915aedad3106bd4917f..4d647586f3bd8f3ea20e9741e5a8085bc38f70f0 100644 GIT binary patch literal 10866 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%0DUWG8WgPZEJSLZH%cN3Zp)&5loi>YJ^t z2nDM;TgChDZm1$hF67txRbw9abp1$hfTBq;wq!-+b6x(MCgWpc>6w}AjsBYx@d~>y z5;SgUOFtwt|4v3KDdUHFP7S@W-j+S11T@x@kzH?bw1&G!3Mvx8yLSUkk(<7SWOr-w zCs~Tw-YrW#y@Ug(`6DJ906<_H6e*Ye=W)Qy=YN zz@B)|q#9T&YV&RokCU{Il`vs3+XaX4PL-+c=B-IZEKe)mI)+)6a1T{@U_IFE*j48) zj}gTwi-c{_-hN$*p98XQCW9=~!B&zYS#9f}mYxar}2}=Zf!4YsQ^R@wjB^@XT07{selE059SMw|9g5Z;ukaxWpSKn#}NQ-~d%R7RUKd;*?Wl zL`pl}2dPf}dsX~?gEA;;Mq1L5V{LaEfuDKHO*Nmh**5o1?-^T>MLK2qz%D*iSovPS z;P*93~W0s40^sOK*loH;-~ zS>P2Q_AKD+6leS&hBvTg%L=aeXX3YjXx(BI9BpwkYY430368&iL1?w7J9nt3ii-4+ zo8mN2oLMk7GP;sn3{(@m5CVmS*?yFPxQ6Dyrc=hU>uvgK*H zp}XIfMe$8J0(qfE{x5<#;n!ilRr47~C)?pw@4`aH8axx<>1CDn(iSjr==y^6M;_}uSn9@$zSkT_JKi$NG#)Rqz%-elR`m~B-1@xDPaw@Cpuw6lW z$hw88$yv7n&%QE=Oef(|VxT3U!tt%S&eJ78MxZ)rw^3`B=ojQfjzr(*glz(w{Kbpc z+Z|Tj8l4xo^yJ~M$gUP){hOqp$nxw>KYxZFH7%rfq+9W5TLxpm2Iyi%z@6`{DtYr& zJTmf|m4l4DPP2L#>S-;TC+^X*QpO+0$^q_U`5*SscsQRZp?&iUi92PBbhY>EB;dGNwOmef?Qdq>r+$sIyD)I7sR zm*I9^=rnLHdTO2j=X9Vt_8>Nxj1A8C8ypG*S4eHo^dX(X+RjlmtygvNy~(@znB_(& z)65C4th?O3AwSY?BjvaiF;%+_{I2UzCaBrkMSefWocYszH97}&Gn8^DHrSiI`~>P} zwB-8p>yE&Uw5&6G$qy=Chq>pag(@cWWt`R0QP1(<7#&cfq)vO;W!H~W2J!KuFL`&n z5x+{mNqQvjb*V}JamS*zK3_yOiP?P-KrM32mVwI^ZDUJ>X{8~}-#F7?x-KhD_2+9d^ZUEWuUccCDY_#1=PZliWM^>v?1U9^3_` zG)s-~qexfMK||xr;(`kEFbjMhO%(0!i{eNu6?OxVV04 zU$5t|X?s}q#2izL&`xoj^_e}v+v3;S09k}!G z3d;^~LGyPx-c|V%uB|{1?qWV+z47t%ycLYiZU9#cZkWo{0E&9YK?(0k8IcmrD||*T zBSe7p+%9Nbwrn9Hf{u0Al^wD@PZUr5fB91?tUyQL-TMWgfgZVM+Ve;6R(b zQCDg*Cjs55Gzw4fF}vi-`B}ogif2OMmF>nG)tr~_VgZ+|+@8T~a@0o?wMbTBye&Tt zlNwC^`;%PT5h>u*g9qG1ERbnL2!6M~`ag&4?^pX@Lcgtvdaflw(KQ1QEoIIsUH zO@x1B1t}yCGX{>Llodu64~L)XQe!xgN8pB z8O|B8TIJx`qpr_q7$!$ow618}nkS2BIN}W2L*mN91bidm_~Sf2(N?LkbpRZ44`=F6 zHVRV|PTE<0f~d~9ZR|LH3@Rxps2!yo+y6FOXc(z0YCHVx-D#cWV-Jk~=I87gP-t^3 z1A?)@5eqH`U}AcdiVczs0LN~;#T$AkH~{fRhg%UjNw6YLUS1&jH%X0EJYAkS0jB|! z5JAqXb`D4cR&Y$4c!Sf)-BR006l^gB zFpS>vuFxIuk+R4prQ@Z@WO3ih|{ zK2~;_&|i2^mp%cWt>~%>=U;x%`J!471Dh8;I^x-5C#KW=^Z)6w@HYxopQK)% VU2>H&@a+KzqM`qwR?Rx{KLCDBNSFWs diff --git a/icons/mob/items/device/righthand_device.dmi b/icons/mob/items/device/righthand_device.dmi index 777c0de18c3a59e1bc1de7eec6e9d4e998057061..22c1b8469a6b7609ba112b43edc117199e301170 100644 GIT binary patch literal 10963 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 From 5c3ccf5d73633892130c7acb4d8e3ee0f8ba6e3a Mon Sep 17 00:00:00 2001 From: 4000daniel1 <4000daniel2@hotmail.se> Date: Sat, 10 Feb 2024 00:08:37 +0100 Subject: [PATCH 2/5] maybeonedayiwillremembertodothis --- html/changelogs/instrumentstoloadout.yml | 41 ++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 html/changelogs/instrumentstoloadout.yml diff --git a/html/changelogs/instrumentstoloadout.yml b/html/changelogs/instrumentstoloadout.yml new file mode 100644 index 00000000000..8dd6197c94b --- /dev/null +++ b/html/changelogs/instrumentstoloadout.yml @@ -0,0 +1,41 @@ +################################ +# Example Changelog File +# +# Note: This file, and files beginning with ".", and files that don't end in ".yml" will not be read. If you change this file, you will look really dumb. +# +# Your changelog will be merged with a master changelog. (New stuff added only, and only on the date entry for the day it was merged.) +# When it is, any changes listed below will disappear. +# +# Valid Prefixes: +# bugfix +# wip (For works in progress) +# tweak +# soundadd +# sounddel +# rscadd (general adding of nice things) +# rscdel (general deleting of nice things) +# imageadd +# imagedel +# maptweak +# spellcheck (typo fixes) +# experiment +# balance +# admin +# backend +# security +# refactor +################################# + +# Your name. +author: 4000daniel1 + +# Optional: Remove this file after generating master changelog. Useful for PR changelogs that won't get used again. +delete-after: True + +# Any changes you've made. See valid prefix list above. +# INDENT WITH TWO SPACES. NOT TABS. SPACES. +# SCREW THIS UP AND IT WON'T WORK. +# Also, all entries are changed into a single [] after a master changelog generation. Just remove the brackets when you add new entries. +# Please surround your changes in double quotes ("), as certain characters otherwise screws up compiling. The quotes will not show up in the changelog. +changes: + - rscadd: "Added instruments to the loadout for use by off-duties and passangers under the general tab. Also ported some in-hand sprites for them from TG." From 045705cf517b7c3e7fe80ae4dbe9336aebb1ffcc Mon Sep 17 00:00:00 2001 From: 4000daniel1 <4000daniel2@hotmail.se> Date: Sat, 10 Feb 2024 00:12:31 +0100 Subject: [PATCH 3/5] MINOR SPELLING MISTAKE --- html/changelogs/instrumentstoloadout.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/html/changelogs/instrumentstoloadout.yml b/html/changelogs/instrumentstoloadout.yml index 8dd6197c94b..eca5cd86803 100644 --- a/html/changelogs/instrumentstoloadout.yml +++ b/html/changelogs/instrumentstoloadout.yml @@ -38,4 +38,4 @@ delete-after: True # Also, all entries are changed into a single [] after a master changelog generation. Just remove the brackets when you add new entries. # Please surround your changes in double quotes ("), as certain characters otherwise screws up compiling. The quotes will not show up in the changelog. changes: - - rscadd: "Added instruments to the loadout for use by off-duties and passangers under the general tab. Also ported some in-hand sprites for them from TG." + - rscadd: "Added instruments to the loadout for use by off-duties and passengers under the general tab. Also ported some in-hand sprites for them from TG." From c0578768ea7f3134b26931e45490a88284ace05e Mon Sep 17 00:00:00 2001 From: 4000daniel1 <4000daniel2@hotmail.se> Date: Sat, 10 Feb 2024 13:04:06 +0100 Subject: [PATCH 4/5] a --- icons/mob/items/device/lefthand_device.dmi | Bin 10866 -> 10685 bytes icons/mob/items/device/righthand_device.dmi | Bin 10963 -> 10784 bytes 2 files changed, 0 insertions(+), 0 deletions(-) diff --git a/icons/mob/items/device/lefthand_device.dmi b/icons/mob/items/device/lefthand_device.dmi index 4d647586f3bd8f3ea20e9741e5a8085bc38f70f0..021ecc25384dea7ccaed03ef6574d9db85261088 100644 GIT binary patch delta 335 zcmV-V0kHn^RJ~J>7Y<+u1^@s6vV*QY0003pktHdAVt`jb7yBTmTx?`J(Ddm$v?{0~ zIHRTC-}ZgX;eGS5-NSmfRTuJsorMa@*M-WiY+?fytd=Tkh)+%YIfRIjpn};^Ff=oj z8TJ7xC{=d!*inEAikoT(B{pbLhA;9-j^^_69IsSnNN|7(ioD40vmsDd%aD9TlSmSg zkdEGeS=LD!_+(KgROivKo6<59C{A?;l(hY==8U>cTK73Sc{cfFlj+oy5==<(GVXvPPUpI%%ehus0R(%6tZ(lu5nmAgsV*w8! h0XnmDAvg#Y{eN_degjR#utNX<002ovPDHLkV1mw#o(li~ delta 364 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 MN*anKkIdfwAC}QzPyhe` delta 9369 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 Date: Sat, 17 Feb 2024 19:41:23 +0100 Subject: [PATCH 5/5] Merge branch 'instrumentstoloadout' of https://github.com/4000daniel1/Aurora.3 into instrumentstoloadout --- aurorastation.dme | 19 + code/__DEFINES/_macros.dm | 3 + code/__DEFINES/jobs.dm | 3 +- code/__DEFINES/radio.dm | 33 +- code/_onclick/click.dm | 26 +- code/_onclick/hud/ability_screen_objects.dm | 8 +- code/_onclick/item_attack.dm | 23 +- code/controllers/subsystems/ghostroles.dm | 12 + code/controllers/subsystems/icon_updates.dm | 2 + code/datums/ai_laws.dm | 16 + code/defines/obj/weapon.dm | 23 +- code/game/antagonist/antagonist_objectives.dm | 27 +- code/game/atoms.dm | 34 +- code/game/dna/dna_modifier.dm | 24 +- code/game/gamemodes/cult/items/sword.dm | 4 +- code/game/gamemodes/cult/items/talisman.dm | 4 +- code/game/gamemodes/cult/items/tome.dm | 8 +- code/game/gamemodes/cult/runes/rune.dm | 20 +- code/game/gamemodes/cult/structures/desk.dm | 6 +- code/game/gamemodes/cult/structures/forge.dm | 6 +- .../game/gamemodes/cult/structures/gateway.dm | 6 +- code/game/gamemodes/cult/structures/pylon.dm | 18 +- .../endgame/supermatter_cascade/blob.dm | 10 +- code/game/gamemodes/meteor/meteors.dm | 4 +- code/game/gamemodes/nuclear/pinpointer.dm | 4 +- code/game/gamemodes/technomancer/catalog.dm | 14 +- .../devices/disposable_teleporter.dm | 4 +- .../game/gamemodes/technomancer/spell_objs.dm | 6 +- code/game/jobs/faction/idris.dm | 4 +- code/game/jobs/faction/pmc.dm | 10 +- code/game/jobs/faction/zavodskoi.dm | 5 +- code/game/jobs/job/security.dm | 12 +- code/game/machinery/CableLayer.dm | 16 +- code/game/machinery/OpTable.dm | 4 +- code/game/machinery/Sleeper.dm | 20 +- code/game/machinery/ai_slipper.dm | 2 +- code/game/machinery/alarm.dm | 32 +- code/game/machinery/anti_bluespace.dm | 6 +- code/game/machinery/atmoalter/canister.dm | 21 +- code/game/machinery/atmoalter/meter.dm | 22 +- .../atmoalter/portable_atmospherics.dm | 24 +- code/game/machinery/atmoalter/scrubber.dm | 16 +- code/game/machinery/autolathe/autolathe.dm | 16 +- code/game/machinery/biogenerator.dm | 30 +- code/game/machinery/bioprinter.dm | 24 +- code/game/machinery/bluespacerelay.dm | 8 +- code/game/machinery/body_scanner.dm | 3 +- code/game/machinery/bots/bots.dm | 21 +- code/game/machinery/buttons.dm | 2 +- code/game/machinery/camera/camera.dm | 32 +- code/game/machinery/camera/camera_assembly.dm | 53 +- code/game/machinery/case_button.dm | 6 +- code/game/machinery/cell_charger.dm | 20 +- code/game/machinery/chem_heater.dm | 12 +- code/game/machinery/cloning.dm | 28 +- code/game/machinery/computer/Operating.dm | 10 +- code/game/machinery/computer/ai_core.dm | 90 +- code/game/machinery/computer/arcade_orion.dm | 4 +- .../game/machinery/computer/buildandrepair.dm | 54 +- code/game/machinery/computer/cloning.dm | 10 +- code/game/machinery/computer/computer.dm | 8 +- code/game/machinery/computer/guestpass.dm | 22 +- code/game/machinery/computer/law.dm | 9 +- code/game/machinery/computer/sentencing.dm | 12 +- code/game/machinery/computer/shuttle.dm | 6 +- code/game/machinery/computer/slotmachine.dm | 12 +- code/game/machinery/constructable_frame.dm | 78 +- code/game/machinery/crusher_piston.dm | 12 +- code/game/machinery/cryo.dm | 20 +- code/game/machinery/cryopod.dm | 7 +- code/game/machinery/deployable.dm | 24 +- code/game/machinery/door_control.dm | 4 +- code/game/machinery/doors/airlock.dm | 98 +- code/game/machinery/doors/airlock_control.dm | 4 +- .../machinery/doors/airlock_electronics.dm | 10 +- code/game/machinery/doors/blast_door.dm | 12 +- code/game/machinery/doors/brigdoors.dm | 19 +- code/game/machinery/doors/door.dm | 32 +- code/game/machinery/doors/firedoor.dm | 69 +- .../game/machinery/doors/firedoor_assembly.dm | 26 +- code/game/machinery/doors/unpowered.dm | 10 +- code/game/machinery/doors/windowdoor.dm | 20 +- code/game/machinery/doppler_array.dm | 4 +- code/game/machinery/firealarm.dm | 30 +- code/game/machinery/flasher.dm | 8 +- code/game/machinery/floodlight.dm | 20 +- code/game/machinery/floor_frames.dm | 4 +- code/game/machinery/floor_light.dm | 14 +- code/game/machinery/floorlayer.dm | 20 +- code/game/machinery/gumball.dm | 14 +- code/game/machinery/hologram.dm | 12 +- code/game/machinery/igniter.dm | 4 +- code/game/machinery/iv_drip.dm | 70 +- code/game/machinery/jukebox.dm | 8 +- code/game/machinery/lightswitch.dm | 4 +- code/game/machinery/machinery.dm | 14 +- code/game/machinery/mass_driver.dm | 8 +- code/game/machinery/mecha_fabricator.dm | 12 +- code/game/machinery/navbeacon.dm | 6 +- code/game/machinery/newscaster.dm | 15 +- code/game/machinery/nuclear_bomb.dm | 48 +- code/game/machinery/pipe/construction.dm | 18 +- code/game/machinery/pipe/pipe_dispenser.dm | 18 +- code/game/machinery/portable_turret.dm | 104 +- code/game/machinery/recharger.dm | 28 +- code/game/machinery/rechargestation.dm | 18 +- code/game/machinery/requests_console.dm | 28 +- code/game/machinery/ringer.dm | 18 +- code/game/machinery/seed_extractor.dm | 22 +- code/game/machinery/spaceheater.dm | 21 +- code/game/machinery/stargazer.dm | 4 +- code/game/machinery/stasis_bed.dm | 8 +- code/game/machinery/status_display.dm | 4 +- code/game/machinery/suit_cycler.dm | 24 +- code/game/machinery/suit_storage_unit.dm | 22 +- code/game/machinery/supplybeacon.dm | 6 +- .../telecomms/computers/logbrowser.dm | 6 +- .../machinery/telecomms/computers/message.dm | 4 +- .../telecomms/computers/telemonitor.dm | 6 +- .../telecomms/computers/traffic_control.dm | 6 +- .../telecomms/machine_interactions.dm | 38 +- .../telecomms/machines/message_server.dm | 10 +- code/game/machinery/tesla_beacon.dm | 4 +- code/game/machinery/turret_control.dm | 4 +- code/game/machinery/vending.dm | 66 +- code/game/machinery/vending_items.dm | 6 +- code/game/machinery/vending_types.dm | 6 +- code/game/machinery/wall_frames.dm | 4 +- code/game/machinery/washing_machine.dm | 14 +- code/game/objects/auras/auras.dm | 2 +- code/game/objects/effects/burnt_wall.dm | 6 +- code/game/objects/effects/chem/foam.dm | 22 +- .../effects/decals/Cleanable/humans.dm | 10 +- .../game/objects/effects/decals/contraband.dm | 4 +- code/game/objects/effects/decals/remains.dm | 4 +- .../game/objects/effects/plastic_explosive.dm | 8 +- code/game/objects/effects/portals.dm | 12 +- code/game/objects/effects/spiders.dm | 18 +- code/game/objects/items.dm | 72 +- code/game/objects/items/airbubble.dm | 52 +- code/game/objects/items/apc_frame.dm | 4 +- code/game/objects/items/bodybag.dm | 14 +- code/game/objects/items/canvas.dm | 12 +- code/game/objects/items/contraband.dm | 16 +- code/game/objects/items/defib.dm | 20 +- code/game/objects/items/devices/aicard.dm | 4 +- .../items/devices/augment_implanter.dm | 6 +- code/game/objects/items/devices/auto_cpr.dm | 50 +- code/game/objects/items/devices/dociler.dm | 4 +- code/game/objects/items/devices/flash.dm | 6 +- code/game/objects/items/devices/geiger.dm | 6 +- code/game/objects/items/devices/hacktool.dm | 4 +- .../game/objects/items/devices/holowarrant.dm | 4 +- .../objects/items/devices/laserpointer.dm | 10 +- .../objects/items/devices/lighting/flare.dm | 12 +- .../items/devices/lighting/flashlight.dm | 18 +- .../objects/items/devices/lightreplacer.dm | 20 +- .../objects/items/devices/magnetic_lock.dm | 70 +- code/game/objects/items/devices/modkit.dm | 4 +- code/game/objects/items/devices/paicard.dm | 18 +- .../objects/items/devices/paint_sprayer.dm | 4 +- .../objects/items/devices/personal_shield.dm | 5 +- .../objects/items/devices/pipe_painter.dm | 4 +- code/game/objects/items/devices/powersink.dm | 4 +- .../objects/items/devices/radio/beacon.dm | 8 +- .../items/devices/radio/encryptionkey.dm | 2 +- .../objects/items/devices/radio/headset.dm | 20 +- .../objects/items/devices/radio/microphone.dm | 10 + .../game/objects/items/devices/radio/radio.dm | 22 +- .../objects/items/devices/radio_jammer.dm | 4 +- code/game/objects/items/devices/spy_bug.dm | 28 +- .../objects/items/devices/suit_cooling.dm | 28 +- .../objects/items/devices/taperecorder.dm | 31 +- .../objects/items/devices/transfer_valve.dm | 26 +- code/game/objects/items/devices/tvcamera.dm | 32 +- code/game/objects/items/easel.dm | 8 +- code/game/objects/items/glassjar.dm | 14 +- code/game/objects/items/holomenu.dm | 20 +- code/game/objects/items/ipc_overloaders.dm | 10 +- code/game/objects/items/knitting.dm | 16 +- code/game/objects/items/paintkit.dm | 16 +- code/game/objects/items/recharger_backpack.dm | 20 +- code/game/objects/items/shooting_range.dm | 6 +- code/game/objects/items/skrell.dm | 10 +- code/game/objects/items/spirit_board.dm | 4 +- code/game/objects/items/stacks/rods.dm | 8 +- .../game/objects/items/stacks/sheets/glass.dm | 12 +- .../objects/items/stacks/sheets/leather.dm | 10 +- code/game/objects/items/stacks/stack.dm | 12 +- code/game/objects/items/stacks/tiles/light.dm | 6 +- code/game/objects/items/stacks/wrap.dm | 26 +- code/game/objects/items/sticker.dm | 4 +- code/game/objects/items/toys.dm | 36 +- code/game/objects/items/trash.dm | 8 +- code/game/objects/items/weapons/RFD.dm | 36 +- code/game/objects/items/weapons/candle.dm | 14 +- code/game/objects/items/weapons/cards_ids.dm | 6 +- .../items/weapons/cards_ids_syndicate.dm | 4 +- .../objects/items/weapons/chaplain_items.dm | 3 + .../objects/items/weapons/cigs_lighters.dm | 93 +- .../weapons/circuitboards/circuitboard.dm | 11 +- .../circuitboards/computer/camera_monitor.dm | 11 +- .../circuitboards/computer/research.dm | 4 +- .../weapons/circuitboards/machinery/power.dm | 4 +- .../circuitboards/machinery/unary_atmos.dm | 8 +- .../objects/items/weapons/cloaking_device.dm | 16 +- code/game/objects/items/weapons/ecigs.dm | 58 +- code/game/objects/items/weapons/explosives.dm | 6 +- .../objects/items/weapons/extinguisher.dm | 32 +- .../objects/items/weapons/flamethrower.dm | 32 +- .../items/weapons/grenades/chem_grenade.dm | 32 +- .../items/weapons/grenades/dynamite.dm | 16 +- .../objects/items/weapons/grenades/grenade.dm | 12 +- code/game/objects/items/weapons/handcuffs.dm | 8 +- .../items/weapons/implants/implantcase.dm | 26 +- .../items/weapons/implants/implanter.dm | 18 +- .../items/weapons/implants/implantpad.dm | 8 +- .../items/weapons/implants/implants/chem.dm | 8 +- .../weapons/implants/implants/circuit.dm | 6 +- .../implants/implants/compressed_matter.dm | 8 +- .../items/weapons/improvised_components.dm | 62 +- .../game/objects/items/weapons/ipc_scanner.dm | 6 +- code/game/objects/items/weapons/landmines.dm | 24 +- .../objects/items/weapons/material/ashtray.dm | 20 +- .../items/weapons/material/material_armor.dm | 22 +- .../objects/items/weapons/material/shards.dm | 6 +- .../objects/items/weapons/material/swords.dm | 12 +- .../items/weapons/material/twohanded.dm | 32 +- code/game/objects/items/weapons/mop.dm | 8 +- code/game/objects/items/weapons/policetape.dm | 16 +- code/game/objects/items/weapons/shields.dm | 6 +- code/game/objects/items/weapons/soap.dm | 8 +- .../objects/items/weapons/storage/backpack.dm | 6 +- .../objects/items/weapons/storage/bags.dm | 6 +- .../objects/items/weapons/storage/bible.dm | 2 +- .../objects/items/weapons/storage/boxes.dm | 33 +- .../objects/items/weapons/storage/fancy.dm | 46 +- .../objects/items/weapons/storage/lockbox.dm | 10 +- .../objects/items/weapons/storage/misc.dm | 5 +- .../game/objects/items/weapons/storage/mre.dm | 24 +- .../objects/items/weapons/storage/secure.dm | 19 +- .../objects/items/weapons/storage/storage.dm | 226 +- code/game/objects/items/weapons/stunbaton.dm | 18 +- .../objects/items/weapons/surgery_tools.dm | 2 +- code/game/objects/items/weapons/syndie.dm | 4 +- .../objects/items/weapons/tanks/jetpack.dm | 8 +- .../objects/items/weapons/tanks/tank_types.dm | 18 +- .../game/objects/items/weapons/tanks/tanks.dm | 18 +- .../objects/items/weapons/tanks/watertank.dm | 4 +- .../objects/items/weapons/teleportation.dm | 6 +- code/game/objects/items/weapons/tools.dm | 54 +- code/game/objects/items/weapons/traps.dm | 43 +- .../objects/items/weapons/vaurca_items.dm | 10 +- code/game/objects/items/weapons/weaponry.dm | 6 +- code/game/objects/objs.dm | 6 +- code/game/objects/random/loot.dm | 2 + .../structures/barricades/_barricade.dm | 34 +- .../objects/structures/barricades/liquid.dm | 10 +- .../objects/structures/barricades/metal.dm | 34 +- .../objects/structures/barricades/plasteel.dm | 37 +- .../objects/structures/barricades/wood.dm | 6 +- code/game/objects/structures/barsign.dm | 4 +- code/game/objects/structures/bedsheet_bin.dm | 43 +- code/game/objects/structures/bonfire.dm | 46 +- code/game/objects/structures/coatrack.dm | 20 +- .../structures/crates_lockers/closets.dm | 108 +- .../crates_lockers/closets/gimmick.dm | 14 +- .../crates_lockers/closets/secure/personal.dm | 18 +- .../crates_lockers/closets/secure/service.dm | 1 + .../crates_lockers/closets/statue.dm | 6 +- .../structures/crates_lockers/largecrate.dm | 4 +- code/game/objects/structures/crystals.dm | 34 +- code/game/objects/structures/curtains.dm | 10 +- code/game/objects/structures/displaycase.dm | 14 +- code/game/objects/structures/door_assembly.dm | 62 +- code/game/objects/structures/extinguisher.dm | 12 +- .../objects/structures/fireaxe_cabinet.dm | 16 +- code/game/objects/structures/flags_banners.dm | 4 +- .../objects/structures/full_window_frame.dm | 22 +- code/game/objects/structures/girders.dm | 98 +- code/game/objects/structures/gore/core.dm | 18 +- code/game/objects/structures/gore/nest.dm | 18 +- code/game/objects/structures/grille.dm | 26 +- code/game/objects/structures/hadii_statue.dm | 10 +- code/game/objects/structures/inflatable.dm | 12 +- code/game/objects/structures/janicart.dm | 58 +- code/game/objects/structures/kitchen_spike.dm | 5 +- code/game/objects/structures/lattice.dm | 36 +- code/game/objects/structures/mirror.dm | 8 +- code/game/objects/structures/mop_bucket.dm | 12 +- code/game/objects/structures/morgue.dm | 6 +- code/game/objects/structures/noticeboard.dm | 10 +- code/game/objects/structures/plasticflaps.dm | 6 +- code/game/objects/structures/railing.dm | 40 +- code/game/objects/structures/safe.dm | 28 +- code/game/objects/structures/sarcophagus.dm | 12 +- code/game/objects/structures/signs.dm | 12 +- code/game/objects/structures/simple_doors.dm | 26 +- .../structures/stool_bed_chair_nest/bed.dm | 68 +- code/game/objects/structures/survey_probe.dm | 136 + .../game/objects/structures/tank_dispenser.dm | 20 +- code/game/objects/structures/target_stake.dm | 12 +- code/game/objects/structures/therapy.dm | 6 +- code/game/objects/structures/tranqcabinet.dm | 12 +- code/game/objects/structures/urban.dm | 49 +- .../objects/structures/vr/_remote_chair.dm | 8 +- code/game/objects/structures/watercloset.dm | 70 +- code/game/objects/structures/weapon_rack.dm | 16 +- .../objects/structures/windoor_assembly.dm | 44 +- code/game/objects/structures/window.dm | 100 +- code/game/turfs/flooring/urban.dm | 19 + code/game/turfs/simulated/floor.dm | 4 +- code/game/turfs/simulated/floor_attackby.dm | 44 +- code/game/turfs/simulated/floor_static.dm | 4 +- code/game/turfs/simulated/shuttle_turfs.dm | 1 + code/game/turfs/simulated/wall_attacks.dm | 132 +- code/game/turfs/simulated/walls.dm | 12 +- code/game/turfs/space/space.dm | 12 +- code/game/turfs/space/transit.dm | 2 +- code/game/turfs/turf.dm | 10 +- code/modules/admin/admin_verbs.dm | 4 - code/modules/admin/verbs/getlogs.dm | 58 +- code/modules/assembly/assembly.dm | 14 +- code/modules/assembly/bomb.dm | 12 +- code/modules/assembly/holder.dm | 14 +- code/modules/assembly/infrared.dm | 5 +- code/modules/assembly/mousetrap.dm | 4 +- code/modules/atmospherics/atmospherics.dm | 4 +- .../components/binary_devices/circulator.dm | 6 +- .../binary_devices/oxyregenerator.dm | 8 +- .../components/binary_devices/passive_gate.dm | 6 +- .../components/binary_devices/pump.dm | 8 +- .../components/omni_devices/omni_base.dm | 6 +- .../components/portables_connector.dm | 6 +- .../modules/atmospherics/components/tvalve.dm | 6 +- .../components/unary/cold_sink.dm | 12 +- .../components/unary/heat_exchanger.dm | 6 +- .../components/unary/heat_source.dm | 12 +- .../components/unary/vent_pump.dm | 36 +- .../components/unary/vent_scrubber.dm | 32 +- code/modules/atmospherics/components/valve.dm | 10 +- code/modules/atmospherics/pipes.dm | 22 +- code/modules/awaymissions/gateway.dm | 8 +- code/modules/background/citizenship/ipc.dm | 4 +- .../origins/origins/unathi/spaceborn.dm | 6 +- code/modules/battlemonsters/items/card.dm | 11 +- code/modules/battlemonsters/items/deck.dm | 6 +- .../items/furniture/dueling_area.dm | 18 +- code/modules/blob/blob.dm | 12 +- code/modules/cargo/delivery/backpack.dm | 18 +- code/modules/cargo/delivery/package.dm | 10 +- code/modules/cargo/delivery/receptacle.dm | 14 +- .../loadout/items/accessories.dm | 5 +- .../loadout/items/computer.dm | 6 + .../preference_setup/loadout/items/general.dm | 33 +- .../loadout/items/religion.dm | 92 +- .../preference_setup/loadout/items/suit.dm | 2 + .../preference_setup/loadout/items/utility.dm | 6 + .../loadout/items/xeno/diona.dm | 8 +- .../loadout/items/xeno/machine.dm | 3 + .../loadout/items/xeno/skrell.dm | 8 + .../loadout/items/xeno/tajara.dm | 3 + .../loadout/items/xeno/vaurca.dm | 3 + .../preference_setup/loadout/loadout.dm | 81 +- code/modules/clothing/clothing.dm | 30 +- code/modules/clothing/clothing_accessories.dm | 12 +- code/modules/clothing/glasses/glasses.dm | 14 +- code/modules/clothing/gloves/attackby.dm | 6 +- code/modules/clothing/gloves/boxing.dm | 4 +- code/modules/clothing/gloves/miscellaneous.dm | 10 +- code/modules/clothing/gloves/stungloves.dm | 14 +- code/modules/clothing/head/helmet.dm | 12 +- code/modules/clothing/head/misc_special.dm | 26 +- code/modules/clothing/sets/laser_tag.dm | 12 +- code/modules/clothing/shoes/magboots.dm | 4 +- code/modules/clothing/shoes/sneakers.dm | 6 +- code/modules/clothing/spacesuits/breaches.dm | 16 +- .../spacesuits/rig/modules/modules.dm | 26 +- code/modules/clothing/spacesuits/rig/rig.dm | 8 +- .../clothing/spacesuits/rig/rig_attackby.dm | 52 +- .../spacesuits/rig/rig_construction.dm | 8 +- code/modules/clothing/spacesuits/syndi.dm | 10 +- code/modules/clothing/spacesuits/void/void.dm | 50 +- code/modules/clothing/suits/armor.dm | 20 +- code/modules/clothing/suits/storage.dm | 6 +- .../clothing/under/accessories/accessory.dm | 2 +- .../clothing/under/accessories/badges.dm | 10 +- .../clothing/under/accessories/holster.dm | 10 +- .../clothing/under/accessories/lockets.dm | 10 +- .../clothing/under/accessories/storage.dm | 4 +- code/modules/clothing/wrists/watches.dm | 11 +- .../machinery/cooking_machines/_appliance.dm | 29 +- .../machinery/cooking_machines/_cooker.dm | 10 +- .../machinery/cooking_machines/_mixer.dm | 4 +- .../machinery/cooking_machines/container.dm | 22 +- .../machinery/cooking_machines/fryer.dm | 18 +- code/modules/cooking/machinery/gibber.dm | 18 +- code/modules/cooking/machinery/icecream.dm | 10 +- code/modules/cooking/machinery/smartfridge.dm | 34 +- code/modules/cooking/plates.dm | 40 +- code/modules/cooking/recipes/recipes_meat.dm | 1 + code/modules/cooking/trays.dm | 10 +- code/modules/custom_ka/cells.dm | 12 +- code/modules/custom_ka/core.dm | 54 +- code/modules/customitems/item_defines.dm | 28 +- .../detectivework/microscope/dnascanner.dm | 8 +- .../detectivework/microscope/microscope.dm | 12 +- .../detectivework/microscope/slides.dm | 14 +- .../detectivework/tools/evidencebag.dm | 6 +- code/modules/detectivework/tools/rag.dm | 6 +- .../detectivework/tools/sample_kits.dm | 14 +- code/modules/economy/ATM.dm | 21 +- code/modules/economy/EFTPOS.dm | 12 +- code/modules/economy/OrderTerminal.dm | 6 +- code/modules/economy/cash.dm | 20 +- code/modules/economy/quikpay.dm | 10 +- code/modules/games/cards.dm | 20 +- code/modules/ghostroles/spawner/base.dm | 32 +- .../modules/ghostroles/spawner/human/human.dm | 3 +- .../heavy_vehicle/components/_components.dm | 19 +- code/modules/heavy_vehicle/components/arms.dm | 7 +- code/modules/heavy_vehicle/components/body.dm | 18 +- .../modules/heavy_vehicle/components/frame.dm | 80 +- code/modules/heavy_vehicle/components/head.dm | 26 +- code/modules/heavy_vehicle/components/legs.dm | 8 +- .../heavy_vehicle/components/remote.dm | 10 +- .../heavy_vehicle/equipment/_equipment.dm | 6 +- .../heavy_vehicle/equipment/medical.dm | 14 +- .../heavy_vehicle/equipment/utility.dm | 22 +- .../modules/heavy_vehicle/mech_interaction.dm | 48 +- code/modules/heavy_vehicle/mech_wreckage.dm | 14 +- code/modules/heavy_vehicle/mecha.dm | 21 +- code/modules/holidays/christmas/props.dm | 4 +- code/modules/holidays/halloween/costumes.dm | 2 +- code/modules/holodeck/HolodeckObjects.dm | 54 +- .../modules/hydroponics/beekeeping/beehive.dm | 44 +- .../hydroponics/beekeeping/honey_extractor.dm | 16 +- code/modules/hydroponics/beekeeping/net.dm | 6 +- code/modules/hydroponics/beekeeping/smoker.dm | 4 +- code/modules/hydroponics/grown.dm | 10 +- code/modules/hydroponics/grown_inedible.dm | 8 +- code/modules/hydroponics/seed.dm | 104 +- code/modules/hydroponics/seed_machines.dm | 26 +- code/modules/hydroponics/seed_packets.dm | 4 +- code/modules/hydroponics/seed_storage.dm | 21 +- .../hydroponics/spreading/spreading.dm | 30 +- code/modules/hydroponics/trays/tray.dm | 76 +- code/modules/hydroponics/trays/tray_soil.dm | 13 +- .../integrated_electronics/core/assemblies.dm | 40 +- .../core/assemblies/clothing.dm | 9 +- .../integrated_electronics/core/device.dm | 6 +- .../core/integrated_circuit.dm | 17 +- .../integrated_electronics/core/printer.dm | 22 +- .../subtypes/manipulation.dm | 9 +- .../integrated_electronics/subtypes/memory.dm | 4 +- .../integrated_electronics/subtypes/output.dm | 8 +- code/modules/library/lib_items.dm | 52 +- code/modules/library/lib_machines.dm | 44 +- code/modules/lock/lock_construct.dm | 10 +- code/modules/makeshift/makeshift_reagents.dm | 54 +- code/modules/maps/planet_types/barren.dm | 25 + code/modules/maps/planet_types/crystal.dm | 25 +- code/modules/maps/planet_types/desert.dm | 25 +- code/modules/maps/planet_types/grass.dm | 21 + code/modules/maps/planet_types/lava.dm | 21 + .../modules/maps/planet_types/lore/burzsia.dm | 10 +- .../modules/maps/planet_types/lore/konyang.dm | 39 + .../maps/planet_types/lore/srandmarr.dm | 27 +- code/modules/maps/planet_types/snow.dm | 24 + code/modules/materials/material_sheets.dm | 27 +- code/modules/mining/abandonedcrates.dm | 4 +- code/modules/mining/coins.dm | 8 +- code/modules/mining/drilling/drill.dm | 60 +- code/modules/mining/machine_processing.dm | 16 +- code/modules/mining/machine_rigpress.dm | 8 +- code/modules/mining/machine_stacking.dm | 16 +- code/modules/mining/machine_unloading.dm | 8 +- code/modules/mining/machine_vending.dm | 12 +- code/modules/mining/mine_items.dm | 50 +- code/modules/mining/mine_turfs.dm | 73 +- code/modules/mining/minebot.dm | 24 +- code/modules/mining/ore.dm | 16 +- code/modules/mining/ore_detector.dm | 4 +- code/modules/mining/ore_satchel.dm | 47 +- code/modules/mining/satchel_ore_boxdm.dm | 39 +- .../modules/mob/abstract/observer/observer.dm | 4 +- code/modules/mob/holder.dm | 4 +- code/modules/mob/inventory.dm | 68 +- code/modules/mob/living/bot/bot.dm | 22 +- code/modules/mob/living/bot/cleanbot.dm | 12 +- code/modules/mob/living/bot/farmbot.dm | 29 +- code/modules/mob/living/bot/medbot.dm | 31 +- .../carbon/alien/diona/diona_attacks.dm | 18 +- code/modules/mob/living/carbon/brain/MMI.dm | 33 +- .../mob/living/carbon/brain/posibrain.dm | 23 +- code/modules/mob/living/carbon/brain/robot.dm | 2 +- .../mob/living/carbon/human/examine.dm | 8 +- code/modules/mob/living/carbon/human/human.dm | 23 +- .../mob/living/carbon/slime/examine.dm | 21 +- code/modules/mob/living/carbon/slime/items.dm | 6 +- code/modules/mob/living/carbon/slime/slime.dm | 14 +- .../living/carbon/slime/slime_extractor.dm | 14 +- code/modules/mob/living/silicon/ai/ai.dm | 12 +- .../living/silicon/ai/ai_remote_control.dm | 11 + code/modules/mob/living/silicon/ai/examine.dm | 45 +- .../modules/mob/living/silicon/pai/examine.dm | 26 +- code/modules/mob/living/silicon/pai/pai.dm | 14 +- .../mob/living/silicon/robot/drone/drone.dm | 27 +- .../silicon/robot/drone/drone_manufacturer.dm | 4 +- .../mob/living/silicon/robot/examine.dm | 43 +- .../mob/living/silicon/robot/inventory.dm | 5 +- .../mob/living/silicon/robot/items/gripper.dm | 17 +- .../silicon/robot/items/inductive_charger.dm | 16 +- .../items/portable_destructive_analyzer.dm | 4 +- .../silicon/robot/items/robot_inflatables.dm | 6 +- .../living/silicon/robot/items/robot_parts.dm | 131 +- .../modules/mob/living/silicon/robot/robot.dm | 82 +- .../mob/living/silicon/robot/robot_modules.dm | 2 +- .../constructs/constructs/cult_construct.dm | 6 +- .../simple_animal/constructs/soulstone.dm | 6 +- .../living/simple_animal/friendly/adhomai.dm | 16 +- .../living/simple_animal/friendly/capybara.dm | 4 +- .../mob/living/simple_animal/friendly/cat.dm | 16 +- .../living/simple_animal/friendly/corgi.dm | 8 +- .../simple_animal/friendly/farm_animals.dm | 14 +- .../simple_animal/friendly/spiderbot.dm | 34 +- .../living/simple_animal/hostile/adhomai.dm | 2 +- .../mob/living/simple_animal/hostile/bear.dm | 2 +- .../simple_animal/hostile/icarus_drone.dm | 6 +- .../mob/living/simple_animal/hostile/morph.dm | 6 +- .../hostile/retaliate/aquatic.dm | 6 +- .../living/simple_animal/hostile/syndicate.dm | 14 +- .../living/simple_animal/hostile/vannatusk.dm | 4 +- .../mob/living/simple_animal/parrot.dm | 6 +- .../modules/mob/living/simple_animal/shade.dm | 6 +- .../mob/living/simple_animal/simple_animal.dm | 43 +- .../modular_computers/NTNet/NTNet_relay.dm | 10 +- .../computers/modular_computer/damage.dm | 10 +- .../computers/modular_computer/interaction.dm | 48 +- .../computers/subtypes/dev_silicon.dm | 7 +- .../computers/subtypes/dev_telescreen.dm | 6 +- .../file_system/programs/security/camera.dm | 2 +- .../modular_computers/hardware/ai_slot.dm | 10 +- .../modular_computers/hardware/hard_drive.dm | 4 +- .../modular_computers/hardware/hardware.dm | 18 +- .../hardware/nano_printer.dm | 10 +- .../modular_computers/items/paper_scanner.dm | 10 +- .../modular_computers/laptop_vendor.dm | 14 +- code/modules/multiz/structures.dm | 8 +- code/modules/multiz/turfs/open_space.dm | 18 +- code/modules/multiz/zmimic/mimic_movable.dm | 10 +- code/modules/organs/internal/brain.dm | 12 +- code/modules/organs/organ.dm | 4 +- code/modules/organs/organ_external.dm | 23 +- code/modules/organs/subtypes/machine.dm | 55 +- code/modules/organs/subtypes/standard.dm | 14 +- code/modules/organs/subtypes/vaurca.dm | 14 +- .../overmap/contacts/contact_sensors.dm | 4 +- code/modules/overmap/contacts/tracker.dm | 4 +- .../overmap/exoplanets/decor/_flora.dm | 4 +- .../overmap/exoplanets/decor/_turfs.dm | 18 +- .../overmap/exoplanets/decor/flora/_bush.dm | 10 +- .../overmap/exoplanets/decor/flora/_tree.dm | 24 +- .../overmap/exoplanets/decor/flora/crystal.dm | 2 +- .../overmap/exoplanets/decor/flora/potted.dm | 16 +- .../overmap/exoplanets/decor/flora/snow.dm | 10 +- .../overmap/exoplanets/decor/objs/clearing.dm | 6 +- .../overmap/exoplanets/decor/objs/pit.dm | 22 +- .../overmap/exoplanets/decor/turfs/abyss.dm | 46 + .../overmap/exoplanets/decor/turfs/asphalt.dm | 9 + .../overmap/exoplanets/decor/turfs/carpet.dm | 21 + .../exoplanets/decor/turfs/concrete.dm | 9 + .../exoplanets/decor/turfs/foundation.dm | 9 + .../exoplanets/decor/turfs/linoleum.dm | 13 + .../overmap/exoplanets/decor/turfs/plating.dm | 4 + .../exoplanets/decor/turfs/sidewalk.dm | 24 + .../overmap/exoplanets/decor/turfs/tiled.dm | 43 + .../overmap/exoplanets/decor/turfs/water.dm | 4 +- .../overmap/exoplanets/decor/turfs/wood.dm | 13 + code/modules/overmap/exoplanets/exoplanet.dm | 4 + code/modules/overmap/overmap_shuttle.dm | 8 +- code/modules/overmap/sectors.dm | 18 + .../ship_weaponry/_ship_ammo_loader.dm | 12 +- .../overmap/ship_weaponry/_ship_ammunition.dm | 20 +- .../overmap/ship_weaponry/_ship_gun.dm | 16 +- .../ship_weaponry/weaponry/leviathan.dm | 14 +- .../ship_weaponry/weaponry/longbow_ammo.dm | 14 +- code/modules/overmap/ships/computers/helm.dm | 12 +- .../overmap/ships/computers/sensors.dm | 16 +- code/modules/overmap/ships/identification.dm | 6 +- code/modules/paperwork/clipboard.dm | 18 +- code/modules/paperwork/faxmachine.dm | 2 +- code/modules/paperwork/filingcabinet.dm | 16 +- code/modules/paperwork/folders.dm | 18 +- code/modules/paperwork/journal.dm | 24 +- code/modules/paperwork/paper.dm | 54 +- code/modules/paperwork/paper_bundle.dm | 33 +- code/modules/paperwork/paperbin.dm | 20 +- code/modules/paperwork/papershredder.dm | 26 +- code/modules/paperwork/photocopier.dm | 24 +- code/modules/paperwork/photography.dm | 27 +- code/modules/paperwork/typewriter.dm | 32 +- code/modules/power/antimatter/control.dm | 26 +- code/modules/power/antimatter/shielding.dm | 14 +- code/modules/power/apc.dm | 120 +- code/modules/power/batteryrack.dm | 14 +- code/modules/power/breaker_box.dm | 10 +- code/modules/power/cable.dm | 32 +- code/modules/power/cell.dm | 26 +- code/modules/power/crystal_agitator.dm | 8 +- .../power/fusion/consoles/_consoles.dm | 4 +- code/modules/power/fusion/core/_core.dm | 6 +- .../fusion/fuel_assembly/fuel_compressor.dm | 4 +- .../fusion/fuel_assembly/fuel_injector.dm | 16 +- .../modules/power/fusion/gyrotron/gyrotron.dm | 4 +- .../modules/power/fusion/kinetic_harvester.dm | 4 +- code/modules/power/generator.dm | 6 +- code/modules/power/gravitygenerator.dm | 28 +- code/modules/power/lights/bulbs.dm | 6 +- code/modules/power/lights/construction.dm | 67 +- code/modules/power/lights/fixtures.dm | 34 +- code/modules/power/portgen.dm | 42 +- code/modules/power/power.dm | 6 +- code/modules/power/radial_floodlight.dm | 10 +- code/modules/power/rtg.dm | 8 +- code/modules/power/singularity/emitter.dm | 28 +- .../power/singularity/field_generator.dm | 40 +- code/modules/power/singularity/generator.dm | 18 +- .../particle_accelerator.dm | 43 +- code/modules/power/smes.dm | 20 +- code/modules/power/smes_construction.dm | 29 +- code/modules/power/solar.dm | 38 +- code/modules/power/tesla/coil.dm | 24 +- code/modules/power/tesla/energy_ball.dm | 4 +- code/modules/power/tracker.dm | 6 +- code/modules/projectiles/ammunition.dm | 34 +- .../projectiles/ammunition/ammo_pile.dm | 18 +- code/modules/projectiles/gun.dm | 55 +- code/modules/projectiles/guns/alien.dm | 4 +- code/modules/projectiles/guns/energy.dm | 5 +- code/modules/projectiles/guns/energy/laser.dm | 6 +- .../projectiles/guns/energy/lawgiver.dm | 4 +- .../modules/projectiles/guns/energy/mining.dm | 18 +- .../projectiles/guns/energy/modular.dm | 16 +- .../projectiles/guns/energy/nuclear.dm | 28 +- .../projectiles/guns/launcher/crossbow.dm | 81 +- .../guns/launcher/grenade_launcher.dm | 12 +- .../projectiles/guns/launcher/harpoon.dm | 10 +- .../projectiles/guns/launcher/pneumatic.dm | 64 +- .../projectiles/guns/launcher/rocket.dm | 12 +- .../projectiles/guns/launcher/syringe_gun.dm | 12 +- code/modules/projectiles/guns/projectile.dm | 18 +- .../projectiles/guns/projectile/automatic.dm | 12 +- .../projectiles/guns/projectile/dartgun.dm | 16 +- .../projectiles/guns/projectile/improvised.dm | 100 +- .../projectiles/guns/projectile/minigun.dm | 4 +- .../projectiles/guns/projectile/musket.dm | 6 +- .../projectiles/guns/projectile/revolver.dm | 10 +- .../projectiles/guns/projectile/rifle.dm | 24 +- .../projectiles/guns/projectile/shotgun.dm | 12 +- .../modules/projectiles/modular/laser_base.dm | 22 +- code/modules/projectiles/pins.dm | 6 +- code/modules/projectiles/projectile/beams.dm | 27 + code/modules/psionics/abilities/throw.dm | 10 +- code/modules/random_map/automata/diona.dm | 29 +- code/modules/random_map/drop/droppod_doors.dm | 6 +- code/modules/reagents/Chemistry-Machinery.dm | 52 +- .../Chemistry-Reagents-Drugs.dm | 10 +- code/modules/reagents/dispenser/cartridge.dm | 12 +- code/modules/reagents/dispenser/dispenser2.dm | 20 +- .../reagents/dispenser/dispenser_presets.dm | 4 +- code/modules/reagents/reagent_containers.dm | 12 +- .../reagents/reagent_containers/blood_pack.dm | 17 +- .../reagents/reagent_containers/borghydro.dm | 5 +- .../reagents/reagent_containers/dropper.dm | 6 +- .../reagents/reagent_containers/food/cans.dm | 46 +- .../reagent_containers/food/condiment.dm | 12 + .../reagent_containers/food/drinks.dm | 36 +- .../reagent_containers/food/drinks/bottle.dm | 18 +- .../reagent_containers/food/drinks/flask.dm | 10 +- .../reagent_containers/food/drinks/yoke.dm | 2 +- .../reagent_containers/food/sandwich.dm | 16 +- .../reagent_containers/food/snacks.dm | 48 +- .../reagent_containers/food/snacks/breads.dm | 24 +- .../reagent_containers/food/snacks/burger.dm | 10 +- .../food/snacks/cannibalism.dm | 6 +- .../food/snacks/cultural/vaurca.dm | 14 +- .../reagent_containers/food/snacks/eggs.dm | 6 +- .../reagent_containers/food/snacks/fish.dm | 10 +- .../food/snacks/ingredients.dm | 8 +- .../reagent_containers/food/snacks/meat.dm | 4 +- .../reagent_containers/food/snacks/mexican.dm | 14 +- .../reagent_containers/food/snacks/sushi.dm | 54 +- .../reagents/reagent_containers/glass.dm | 44 +- .../reagents/reagent_containers/hypospray.dm | 12 +- .../reagents/reagent_containers/inhaler.dm | 12 +- .../reagent_containers/inhaler_advanced.dm | 23 +- .../reagents/reagent_containers/pill.dm | 15 +- .../reagents/reagent_containers/spray.dm | 8 +- .../reagents/reagent_containers/syringes.dm | 2 +- .../reagents/reagent_containers/teapot.dm | 8 +- .../reagent_containers/welding_backpack.dm | 18 +- code/modules/reagents/reagent_dispenser.dm | 61 +- code/modules/recycling/conveyor2.dm | 21 +- .../recycling/disposal-construction.dm | 10 +- code/modules/recycling/disposal.dm | 78 +- code/modules/recycling/sortingmachinery.dm | 62 +- code/modules/research/circuitprinter.dm | 16 +- code/modules/research/destructive_analyzer.dm | 22 +- code/modules/research/protolathe.dm | 16 +- code/modules/research/rdconsole.dm | 16 +- code/modules/research/research.dm | 16 +- code/modules/research/server.dm | 12 +- code/modules/research/tech_processor.dm | 12 +- code/modules/research/weaponsanalyzer.dm | 45 +- .../xenoarchaeology/artifact/artifact.dm | 18 +- .../artifact/artifact_crystal_madness.dm | 6 +- .../artifact/artifact_replicator.dm | 8 +- .../artifact/artifact_unknown.dm | 31 +- .../research/xenoarchaeology/chemistry.dm | 8 +- .../research/xenoarchaeology/finds/finds.dm | 10 +- .../xenoarchaeology/finds/finds_fossils.dm | 14 +- .../machinery/artifact_harvester.dm | 10 +- .../machinery/geosample_scanner.dm | 18 +- .../tools/ano_device_battery.dm | 8 +- .../tools/suspension_generator.dm | 20 +- .../tools/tools_coresampler.dm | 4 +- .../security levels/keycard authentication.dm | 6 +- code/modules/shieldgen/emergency_shield.dm | 28 +- code/modules/shieldgen/energy_field.dm | 14 +- code/modules/shieldgen/shield_capacitor.dm | 6 +- code/modules/shieldgen/shield_diffuser.dm | 4 +- code/modules/shieldgen/shield_gen.dm | 6 +- code/modules/shieldgen/shieldwallgen.dm | 8 +- code/modules/shuttles/shuttle_console.dm | 12 +- code/modules/shuttles/shuttle_emergency.dm | 4 +- .../artifacts/items/lich_phylactery.dm | 10 +- .../spell_system/artifacts/items/poppet.dm | 26 +- .../spell_list/self/conjure/forcewall.dm | 6 +- code/modules/supermatter/supermatter.dm | 16 +- .../Synthesizer/synthesizer.dm | 4 +- code/modules/tables/interactions.dm | 26 +- code/modules/tables/tables.dm | 42 +- code/modules/telesci/telepad.dm | 36 +- code/modules/telesci/telesci_computer.dm | 30 +- code/modules/vehicles/bike.dm | 59 +- code/modules/vehicles/cargo_train.dm | 25 +- code/modules/vehicles/droppod.dm | 8 +- code/modules/vehicles/pussywagon.dm | 12 +- code/modules/vehicles/train.dm | 12 +- code/modules/vehicles/vehicle.dm | 24 +- code/unit_tests/loadout_tests.dm | 77 + code/unit_tests/ruins_tests.dm | 4 + code/unit_tests/unit_test.dm | 13 +- code/unit_tests/zas_tests.dm | 32 +- html/changelog.html | 232 + html/changelogs/.all_changelog.yml | 182 + .../under/uniforms/konyang_uniforms.dmi | Bin 30046 -> 30442 bytes icons/misc/hudmenu/konyang_hud.dmi | Bin 13433 -> 13252 bytes icons/mob/items/device/lefthand_device.dmi | Bin 10685 -> 11242 bytes icons/mob/items/device/righthand_device.dmi | Bin 10784 -> 11378 bytes icons/obj/bike.dmi | Bin 35203 -> 0 bytes icons/obj/chemical.dmi | Bin 34561 -> 35070 bytes icons/obj/custom_items/pleig_rig.dmi | Bin 654 -> 0 bytes icons/obj/guns/goldendeep_ornatepistol.dmi | Bin 0 -> 1140 bytes icons/obj/hydroponics_vines.dmi | Bin 21413 -> 21415 bytes icons/obj/item/journal.dmi | Bin 2274 -> 0 bytes .../reagent_containers/food/condiment.dmi | Bin 12316 -> 12419 bytes icons/obj/library.dmi | Bin 40048 -> 42503 bytes icons/obj/overmap/overmap_stationary.dmi | Bin 1481 -> 3932 bytes icons/obj/radio.dmi | Bin 35244 -> 35464 bytes icons/obj/storage/boxes.dmi | Bin 13613 -> 13744 bytes icons/obj/storage/fancy/mre.dmi | Bin 1790 -> 2110 bytes icons/obj/structure/urban/billboard.dmi | Bin 0 -> 17885 bytes icons/obj/structure/urban/infrastructure.dmi | Bin 3371 -> 3443 bytes icons/obj/structure/urban/konyang_neon.dmi | Bin 5416 -> 26429 bytes icons/obj/vehicle/bike.dmi | Bin 0 -> 73552 bytes icons/obj/xenoarchaeology.dmi | Bin 82714 -> 77152 bytes icons/turf/flooring/concrete.dmi | Bin 2109 -> 2279 bytes icons/turf/flooring/urban_turfs.dmi | Bin 2141 -> 7509 bytes maps/away/away_site/blueriver/blueriver.dm | 6 +- .../away/away_site/hivebot_hub/hivebot_hub.dm | 125 +- .../away_site/hivebot_hub/hivebot_hub.dmm | 68313 +--------------- .../konyang/point_verdant/point_verdant-1.dmm | 9969 ++- .../konyang/point_verdant/point_verdant-2.dmm | 5919 +- .../konyang/point_verdant/point_verdant-3.dmm | 4867 +- .../point_verdant/point_verdant_areas.dm | 36 +- .../away_site/romanovich/grand_romanovich.dm | 8 +- maps/away/ships/golden_deep/golden_deep.dm | 1 + .../tajara/circus/adhomian_circus_items.dm | 6 +- .../exoplanets/adhomai/abandoned_village.dmm | 144 +- .../exoplanets/adhomai/adhomai_archeology.dmm | 92 +- .../exoplanets/adhomai/adhomai_bar.dmm | 792 +- .../exoplanets/adhomai/adhomai_hunting.dmm | 252 +- .../exoplanets/adhomai/adhomai_minefield.dm | 4 +- .../adhomai_nuclear_waste_makeshift.dmm | 44 +- .../adhomai/adhomai_raskariim_hideout.dmm | 292 +- .../exoplanets/adhomai/adhomai_village.dmm | 344 +- .../exoplanets/adhomai/ala_base.dmm | 544 +- .../exoplanets/adhomai/nka_base.dmm | 247 +- .../adhomai/north_pole_nka_expedition.dmm | 167 +- .../exoplanets/adhomai/pra_mining_camp.dmm | 232 +- .../asteroid/old_outpost/old_outpost.dmm | 142 +- .../konyang/abandoned/factory_arms.dm | 14 + .../konyang/abandoned/factory_arms.dmm | 2971 + .../konyang/abandoned/factory_refinery.dm | 14 + .../konyang/abandoned/factory_refinery.dmm | 2941 + .../konyang/abandoned/factory_robotics.dm | 14 + .../konyang/abandoned/factory_robotics.dmm | 2687 + .../exoplanets/konyang/abandoned/garage.dm | 14 + .../exoplanets/konyang/abandoned/garage.dmm | 1610 + .../konyang/abandoned/house _small.dm | 14 + .../konyang/abandoned/house_small.dmm | 1687 + .../konyang/abandoned/landing_zone.dm | 28 + .../konyang/abandoned/landing_zone.dmm | 7285 ++ .../exoplanets/konyang/abandoned/office.dm | 14 + .../exoplanets/konyang/abandoned/office.dmm | 1419 + .../exoplanets/konyang/hivebot_burrows_1.dmm | 2 +- .../exoplanets/konyang/hivebot_burrows_2.dmm | 400 +- .../exoplanets/konyang/landing_zone.dmm | 9 +- .../konyang/ocean/naval_landing_zone.dm | 1 + .../konyang/ocean/naval_landing_zone.dmm | 9 +- .../exoplanets/konyang/telecomms_outpost.dmm | 220 +- .../exoplanets/konyang/zombie_outpost.dmm | 191 +- .../exoplanets/konyang/zombie_village.dmm | 345 +- maps/sccv_horizon/sccv_horizon-1_deck_1.dmm | 1259 +- maps/sccv_horizon/sccv_horizon-2_deck_2.dmm | 165 +- maps/sccv_horizon/sccv_horizon-3_deck_3.dmm | 1561 +- maps/sccv_horizon/sccv_horizon-4_centcomm.dmm | 486 +- .../tgui-panel/styles/tgchat/chat-dark.scss | 14 + .../tgui-panel/styles/tgchat/chat-light.scss | 14 + .../packages/tgui/interfaces/CookingCodex.tsx | 4 +- .../packages/tgui/interfaces/GhostSpawner.tsx | 182 +- 833 files changed, 48471 insertions(+), 84740 deletions(-) create mode 100644 code/game/objects/items/devices/radio/microphone.dm create mode 100644 code/game/objects/structures/survey_probe.dm create mode 100644 code/modules/overmap/exoplanets/decor/turfs/abyss.dm create mode 100644 code/modules/overmap/exoplanets/decor/turfs/asphalt.dm create mode 100644 code/modules/overmap/exoplanets/decor/turfs/carpet.dm create mode 100644 code/modules/overmap/exoplanets/decor/turfs/foundation.dm create mode 100644 code/modules/overmap/exoplanets/decor/turfs/linoleum.dm create mode 100644 code/modules/overmap/exoplanets/decor/turfs/plating.dm create mode 100644 code/modules/overmap/exoplanets/decor/turfs/sidewalk.dm create mode 100644 code/modules/overmap/exoplanets/decor/turfs/tiled.dm create mode 100644 code/modules/overmap/exoplanets/decor/turfs/wood.dm create mode 100644 code/unit_tests/loadout_tests.dm delete mode 100644 icons/obj/bike.dmi delete mode 100644 icons/obj/custom_items/pleig_rig.dmi create mode 100644 icons/obj/guns/goldendeep_ornatepistol.dmi delete mode 100644 icons/obj/item/journal.dmi create mode 100644 icons/obj/structure/urban/billboard.dmi create mode 100644 icons/obj/vehicle/bike.dmi create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/factory_arms.dm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/factory_arms.dmm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/factory_refinery.dm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/factory_refinery.dmm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/factory_robotics.dm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/factory_robotics.dmm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/garage.dm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/garage.dmm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/house _small.dm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/house_small.dmm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/landing_zone.dm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/landing_zone.dmm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/office.dm create mode 100644 maps/random_ruins/exoplanets/konyang/abandoned/office.dmm diff --git a/aurorastation.dme b/aurorastation.dme index a995f57ca50..297599441b0 100644 --- a/aurorastation.dme +++ b/aurorastation.dme @@ -1083,6 +1083,7 @@ #include "code\game\objects\items\devices\radio\encryptionkey.dm" #include "code\game\objects\items\devices\radio\headset.dm" #include "code\game\objects\items\devices\radio\intercom.dm" +#include "code\game\objects\items\devices\radio\microphone.dm" #include "code\game\objects\items\devices\radio\radio.dm" #include "code\game\objects\items\stacks\matter_synth.dm" #include "code\game\objects\items\stacks\medical.dm" @@ -1284,6 +1285,7 @@ #include "code\game\objects\structures\signs.dm" #include "code\game\objects\structures\simple_doors.dm" #include "code\game\objects\structures\statue.dm" +#include "code\game\objects\structures\survey_probe.dm" #include "code\game\objects\structures\tank_dispenser.dm" #include "code\game\objects\structures\target_stake.dm" #include "code\game\objects\structures\therapy.dm" @@ -2867,16 +2869,25 @@ #include "code\modules\overmap\exoplanets\decor\objs\clearing.dm" #include "code\modules\overmap\exoplanets\decor\objs\monolith.dm" #include "code\modules\overmap\exoplanets\decor\objs\pit.dm" +#include "code\modules\overmap\exoplanets\decor\turfs\abyss.dm" +#include "code\modules\overmap\exoplanets\decor\turfs\asphalt.dm" #include "code\modules\overmap\exoplanets\decor\turfs\barren.dm" +#include "code\modules\overmap\exoplanets\decor\turfs\carpet.dm" #include "code\modules\overmap\exoplanets\decor\turfs\concrete.dm" #include "code\modules\overmap\exoplanets\decor\turfs\crystal.dm" +#include "code\modules\overmap\exoplanets\decor\turfs\foundation.dm" #include "code\modules\overmap\exoplanets\decor\turfs\grass.dm" #include "code\modules\overmap\exoplanets\decor\turfs\ice.dm" #include "code\modules\overmap\exoplanets\decor\turfs\konyang.dm" +#include "code\modules\overmap\exoplanets\decor\turfs\linoleum.dm" #include "code\modules\overmap\exoplanets\decor\turfs\mineral.dm" +#include "code\modules\overmap\exoplanets\decor\turfs\plating.dm" #include "code\modules\overmap\exoplanets\decor\turfs\sand.dm" +#include "code\modules\overmap\exoplanets\decor\turfs\sidewalk.dm" #include "code\modules\overmap\exoplanets\decor\turfs\snow.dm" +#include "code\modules\overmap\exoplanets\decor\turfs\tiled.dm" #include "code\modules\overmap\exoplanets\decor\turfs\water.dm" +#include "code\modules\overmap\exoplanets\decor\turfs\wood.dm" #include "code\modules\overmap\exoplanets\themes\_theme.dm" #include "code\modules\overmap\exoplanets\themes\barren.dm" #include "code\modules\overmap\exoplanets\themes\crystal.dm" @@ -3519,6 +3530,7 @@ #include "code\unit_tests\gamemode_tests.dm" #include "code\unit_tests\icon_tests.dm" #include "code\unit_tests\language_test.dm" +#include "code\unit_tests\loadout_tests.dm" #include "code\unit_tests\map_tests.dm" #include "code\unit_tests\mob_tests.dm" #include "code\unit_tests\object_tests.dm" @@ -3844,6 +3856,13 @@ #include "maps\random_ruins\exoplanets\konyang\zombie_outpost.dm" #include "maps\random_ruins\exoplanets\konyang\zombie_village.dm" #include "maps\random_ruins\exoplanets\konyang\zombies.dm" +#include "maps\random_ruins\exoplanets\konyang\abandoned\factory_arms.dm" +#include "maps\random_ruins\exoplanets\konyang\abandoned\factory_refinery.dm" +#include "maps\random_ruins\exoplanets\konyang\abandoned\factory_robotics.dm" +#include "maps\random_ruins\exoplanets\konyang\abandoned\garage.dm" +#include "maps\random_ruins\exoplanets\konyang\abandoned\house _small.dm" +#include "maps\random_ruins\exoplanets\konyang\abandoned\landing_zone.dm" +#include "maps\random_ruins\exoplanets\konyang\abandoned\office.dm" #include "maps\random_ruins\exoplanets\lava\lava.dm" #include "maps\random_ruins\exoplanets\raskara\pra_exploration_drone.dm" #include "maps\random_ruins\exoplanets\raskara\raskara_okon.dm" diff --git a/code/__DEFINES/_macros.dm b/code/__DEFINES/_macros.dm index 351ac9aed1e..b8939d01c67 100644 --- a/code/__DEFINES/_macros.dm +++ b/code/__DEFINES/_macros.dm @@ -30,6 +30,9 @@ #define SPAN_HIGHDANGER(X) (FONT_LARGE(SPAN_DANGER(X))) +/// Adds a generic box around whatever message you're sending in chat. Really makes things stand out. +#define EXAMINE_BLOCK(str) ("
" + str + "
") + #define FONT_SIZE_SMALL "10px" #define FONT_SIZE_NORMAL "13px" #define FONT_SIZE_LARGE "16px" diff --git a/code/__DEFINES/jobs.dm b/code/__DEFINES/jobs.dm index 4ae3cf33702..5daa3c63ab8 100644 --- a/code/__DEFINES/jobs.dm +++ b/code/__DEFINES/jobs.dm @@ -8,6 +8,7 @@ #define CONSULAR_ROLE /datum/job/consular #define JOURNALIST_ROLE /datum/job/journalist #define CHAPLAIN_ROLE /datum/job/chaplain +#define ASSISTANT_ROLE /datum/job/assistant //Event Roles //Used for generic department jobs for off-ship events @@ -47,4 +48,4 @@ #define ZENG_ROLES list(SCIENCE_ROLES, MEDICAL_ROLES, CIVILIAN_ROLES, REPRESENTATIVE_ROLE) #define HEPH_ROLES list(OPERATIONS_ROLES, ENGINEERING_ROLES, CIVILIAN_ROLES, REPRESENTATIVE_ROLE) #define ORION_ROLES list(OPERATIONS_ROLES, CIVILIAN_ROLES, REPRESENTATIVE_ROLE, SERVICE_ROLES) -#define INDEP_ROLES list(NON_CREW_CIVILIAN_ROLES, CONSULAR_ROLE, CHAPLAIN_ROLE, OFF_DUTY_CREW_MEMBER_ROLE, JOURNALIST_ROLE) +#define INDEP_ROLES list(NON_CREW_CIVILIAN_ROLES, CONSULAR_ROLE, CHAPLAIN_ROLE, OFF_DUTY_CREW_MEMBER_ROLE, JOURNALIST_ROLE, ASSISTANT_ROLE) diff --git a/code/__DEFINES/radio.dm b/code/__DEFINES/radio.dm index a2a1bfcf42b..2087dff0ed5 100644 --- a/code/__DEFINES/radio.dm +++ b/code/__DEFINES/radio.dm @@ -95,7 +95,7 @@ var/list/reverseradiochannels = list( // The assoc variants are separate lists because they need the keys to be strings, but some code expects numbers. -// central command channels, i.e deathsquid & response teams +/// central command channels, i.e deathsquad & response teams var/list/CENT_FREQS = list( ERT_FREQ, DTH_FREQ @@ -106,7 +106,7 @@ var/list/CENT_FREQS_ASSOC = list( "[DTH_FREQ]" = TRUE ) -// Antag channels, i.e. Syndicate +/// Antag channels, i.e. Syndicate var/list/ANTAG_FREQS = list( SYND_FREQ, RAID_FREQ, @@ -123,7 +123,7 @@ var/list/ANTAG_FREQS_ASSOC = list( "[BLSP_FREQ]" = TRUE ) -//Department channels, arranged lexically +/// Department channels, arranged lexically var/list/DEPT_FREQS = list( AI_FREQ, COMM_FREQ, @@ -148,10 +148,14 @@ var/list/DEPT_FREQS_ASSOC = list( "[ENT_FREQ]" = TRUE ) -#define TRANSMISSION_WIRE 0 // Wired transmission, unused at the moment -#define TRANSMISSION_RADIO 1 // Default radiowave transmission -#define TRANSMISSION_SUBSPACE 2 // Subspace transmission (headsets) -#define TRANSMISSION_SUPERSPACE 3 // Independent / CentCom radios only +/// Wired transmission, unused at the moment +#define TRANSMISSION_WIRE 0 +/// Default radiowave transmission +#define TRANSMISSION_RADIO 1 +/// Subspace transmission (headsets) +#define TRANSMISSION_SUBSPACE 2 +/// Independent / CentCom radios only +#define TRANSMISSION_SUPERSPACE 3 #define RADIO_NO_Z_LEVEL_RESTRICTION 0 @@ -160,11 +164,12 @@ var/list/DEPT_FREQS_ASSOC = list( //Other devices can then choose to send signals to only those devices that belong to a particular filter. //This is done for performance, so we don't send signals to lots of machines unnecessarily. -//This filter is special because devices belonging to default also receive signals sent to any other filter. +/// This filter is special because devices belonging to default also receive signals sent to any other filter. #define RADIO_DEFAULT "radio_default" - -#define RADIO_TO_AIRALARM "radio_airalarm" //air alarms -#define RADIO_FROM_AIRALARM "radio_airalarm_rcvr" //devices interested in recieving signals from air alarms +/// air alarms +#define RADIO_TO_AIRALARM "radio_airalarm" +/// devices interested in recieving signals from air alarms +#define RADIO_FROM_AIRALARM "radio_airalarm_rcvr" #define RADIO_CHAT "radio_telecoms" #define RADIO_ATMOSIA "radio_atmos" #define RADIO_NAVBEACONS "radio_navbeacon" @@ -173,7 +178,9 @@ var/list/DEPT_FREQS_ASSOC = list( #define RADIO_ARRIVALS "radio_arrvl" #define JAMMER_OFF -1 -#define JAMMER_ALL 1 // affects ALL wireless streams -#define JAMMER_SYNTHETIC 2 // affects only synthetic wireless connections (attack_ai) +///// affects ALL wireless streams +#define JAMMER_ALL 1 +/// affects only synthetic wireless connections (attack_ai) +#define JAMMER_SYNTHETIC 2 #define DEFAULT_LAW_CHANNEL "Main Frequency" diff --git a/code/_onclick/click.dm b/code/_onclick/click.dm index 805fa87b089..33bb17cb4e3 100644 --- a/code/_onclick/click.dm +++ b/code/_onclick/click.dm @@ -50,19 +50,19 @@ set_dir(get_dir(src, over_object)) gun.Fire(get_turf(over_object), src, params, (get_dist(over_object, src) <= 1), FALSE) -/* - Standard mob ClickOn() - Handles exceptions: Buildmode, middle click, modified clicks, mech actions - - After that, mostly just check your state, check whether you're holding an item, - check whether you're adjacent to the target, then pass off the click to whoever - is recieving it. - The most common are: - * mob/UnarmedAttack(atom,adjacent) - used here only when adjacent, with no item in hand; in the case of humans, checks gloves - * atom/attackby(item,user) - used only when adjacent, return TRUE to prevent further afterattack procs being called - * item/afterattack(atom,user,adjacent,params) - used both ranged and adjacent - * mob/RangedAttack(atom,params) - used only ranged, only used for tk and laser eyes but could be changed -*/ +/** + * Standard mob ClickOn() + * Handles exceptions: Buildmode, middle click, modified clicks, mech actions + * + * After that, mostly just check your state, check whether you're holding an item, + * check whether you're adjacent to the target, then pass off the click to whoever + * is receiving it. + * The most common are: + * * [mob/proc/UnarmedAttack] (atom,adjacent) - used here only when adjacent, with no item in hand; in the case of humans, checks gloves + * * [atom/proc/attackby] (item,user) - used only when adjacent + * * [obj/item/proc/afterattack] (atom,user,adjacent,params) - used both ranged and adjacent + * * [mob/proc/RangedAttack] (atom,modifiers) - used only ranged, only used for tk and laser eyes but could be changed + */ /mob/proc/ClickOn(var/atom/A, var/params) if(world.time <= next_click) // Hard check, before anything else, to avoid crashing diff --git a/code/_onclick/hud/ability_screen_objects.dm b/code/_onclick/hud/ability_screen_objects.dm index 1e9d6c5e4b5..fd6192d25e4 100644 --- a/code/_onclick/hud/ability_screen_objects.dm +++ b/code/_onclick/hud/ability_screen_objects.dm @@ -326,10 +326,10 @@ if(my_mob.client) toggle_open(2) //forces the icons to refresh on screen -/obj/screen/ability/obj_based/psionic/examine(mob/user) - to_chat(user, SPAN_NOTICE("This ability is [connected_power.name].")) - to_chat(user, SPAN_NOTICE("[connected_power.desc]")) - return TRUE +/obj/screen/ability/obj_based/psionic/get_examine_text(mob/user) + . = ..() + . += SPAN_NOTICE("This ability is [connected_power.name].") + . += SPAN_NOTICE("[connected_power.desc]") /// Technomancer. /obj/screen/ability/obj_based/technomancer diff --git a/code/_onclick/item_attack.dm b/code/_onclick/item_attack.dm index 15fc75a123a..1b56771b3e0 100644 --- a/code/_onclick/item_attack.dm +++ b/code/_onclick/item_attack.dm @@ -29,12 +29,23 @@ avoid code duplication. This includes items that may sometimes act as a standard return A.attackby(src, user, click_parameters) // attackby should return TRUE if all desired actions are resolved from that attack, within attackby. This prevents afterattack being called. -/atom/proc/attackby(obj/item/W, mob/user, var/click_parameters) - return - -/atom/movable/attackby(obj/item/W, mob/user) - if(!(W.item_flags & ITEM_FLAG_NO_BLUDGEON)) - visible_message("[src] has been hit by [user] with [W].") +/** + * Called on an object being hit by an item + * + * Returns `TRUE` if all desired actions are resolved from that attack + * + * Returning `TRUE` prevents `afterattack()` from being called + * + * * attacking_item - The item hitting the atom + * * user - The wielder of this item + * * params - Click params such as alt/shift etc + */ +/atom/proc/attackby(obj/item/attacking_item, mob/user, params) + return FALSE + +/atom/movable/attackby(obj/item/attacking_item, mob/user, params) + if((user?.a_intent == I_HURT) && !(attacking_item.item_flags & ITEM_FLAG_NO_BLUDGEON)) + visible_message(SPAN_DANGER("[src] has been hit by [user] with [attacking_item].")) /mob/living/attackby(obj/item/I, mob/user) if(!ismob(user)) diff --git a/code/controllers/subsystems/ghostroles.dm b/code/controllers/subsystems/ghostroles.dm index a5c7a6ef65a..793d6b7d2cf 100644 --- a/code/controllers/subsystems/ghostroles.dm +++ b/code/controllers/subsystems/ghostroles.dm @@ -119,13 +119,24 @@ SUBSYSTEM_DEF(ghostroles) var/datum/ghostspawner/G = spawners[s] if(G.cant_see(user)) continue + var/cant_spawn = G.cant_spawn(user) + var/list/manifest = list() if(LAZYLEN(G.spawned_mobs)) for(var/datum/weakref/mob_ref in G.spawned_mobs) var/mob/spawned_mob = mob_ref.resolve() if(spawned_mob) manifest += spawned_mob.real_name + + var/atom/spawn_overmap_location = null + if(SSatlas.current_map.use_overmap) + var/atom/spawner = G.select_spawnlocation(FALSE) + if(istype(spawner)) + var/obj/effect/overmap/visitable/sector = GLOB.map_sectors["[spawner.z]"] + if(istype(sector)) + spawn_overmap_location = sector.name + var/list/spawner = list( "short_name" = G.short_name, "name" = G.name, @@ -137,6 +148,7 @@ SUBSYSTEM_DEF(ghostroles) "enabled" = G.enabled, "count" = G.count, "spawn_atoms" = length(G.spawn_atoms), + "spawn_overmap_location" = spawn_overmap_location, "max_count" = G.max_count, "tags" = G.tags, "spawnpoints" = G.spawnpoints, diff --git a/code/controllers/subsystems/icon_updates.dm b/code/controllers/subsystems/icon_updates.dm index 562e7f78207..8af3dbced20 100644 --- a/code/controllers/subsystems/icon_updates.dm +++ b/code/controllers/subsystems/icon_updates.dm @@ -113,6 +113,8 @@ SUBSYSTEM_DEF(icon_update) var/icon_update_delay = null /atom/proc/update_icon() + SHOULD_NOT_SLEEP(TRUE) + return /** * DO NOT USE diff --git a/code/datums/ai_laws.dm b/code/datums/ai_laws.dm index a3c324e54cf..87ad9699a64 100644 --- a/code/datums/ai_laws.dm +++ b/code/datums/ai_laws.dm @@ -237,6 +237,22 @@ var/global/const/base_law_type = /datum/ai_laws/nanotrasen if(ismob(who) && M.vr_mob) to_chat(M.vr_mob, "[law.get_index()]. [law.law]") +/datum/ai_laws/proc/get_laws(var/who) + . = list() + sort_laws() + for(var/datum/ai_law/law in sorted_laws) + if(law == zeroth_law_borg) + continue + var/mob/M = who + if(law == zeroth_law) + . += "[law.get_index()]. [law.law]" + if(ismob(who) && M.vr_mob) + . += "[law.get_index()]. [law.law]" + else + . += "[law.get_index()]. [law.law]" + if(ismob(who) && M.vr_mob) + . += "[law.get_index()]. [law.law]" + /******************** * Stating Laws * ********************/ diff --git a/code/defines/obj/weapon.dm b/code/defines/obj/weapon.dm index 92647a0effe..d54242a6b9f 100644 --- a/code/defines/obj/weapon.dm +++ b/code/defines/obj/weapon.dm @@ -263,13 +263,14 @@ else ..() -/obj/item/cane/concealed/attackby(var/obj/item/canesword/W, var/mob/user) - if(!src.concealed_blade && istype(W)) - user.visible_message("[user] has sheathed \a [W] into [user.get_pronoun("his")] [src]!", "You sheathe \the [W] into \the [src].") +/obj/item/cane/concealed/attackby(obj/item/attacking_item, mob/user) + var/obj/item/canesword/attacking_canesword = attacking_item + if(!src.concealed_blade && istype(attacking_canesword)) + user.visible_message("[user] has sheathed \a [attacking_canesword] into [user.get_pronoun("his")] [src]!", "You sheathe \the [attacking_canesword] into \the [src].") playsound(user.loc, 'sound/weapons/holster/sheathin.ogg', 50, 1) - user.drop_from_inventory(W) - W.forceMove(src) - src.concealed_blade = W + user.drop_from_inventory(attacking_canesword) + attacking_canesword.forceMove(src) + src.concealed_blade = attacking_canesword update_icon() return TRUE else @@ -450,8 +451,8 @@ desc = "Heavy-duty switching circuits for power control." matter = list(DEFAULT_WALL_MATERIAL = 50, MATERIAL_GLASS = 50) -/obj/item/module/power_control/attackby(obj/item/W, mob/user) - if(W.ismultitool()) +/obj/item/module/power_control/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ismultitool()) var/obj/item/circuitboard/ghettosmes/new_circuit = new /obj/item/circuitboard/ghettosmes(get_turf(src)) to_chat(user, SPAN_NOTICE("You modify \the [src] into a makeshift PSU circuitboard.")) qdel(src) @@ -521,10 +522,10 @@ icon = 'icons/obj/stock_parts.dmi' icon_state = "neuralbroke" -/obj/item/neuralbroke/attackby(obj/item/W as obj, mob/user as mob) - if(W.isscrewdriver()) +/obj/item/neuralbroke/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) new /obj/item/device/encryptionkey/hivenet(user.loc) - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) to_chat(user, "You bypass the fried security chip and extract the encryption key.") to_chat(user, "The fried neural socket crumbles away like dust.") qdel(src) diff --git a/code/game/antagonist/antagonist_objectives.dm b/code/game/antagonist/antagonist_objectives.dm index 51bc15d43e5..e860c3bb7b2 100644 --- a/code/game/antagonist/antagonist_objectives.dm +++ b/code/game/antagonist/antagonist_objectives.dm @@ -30,23 +30,34 @@ to_world("[loss_text]") if(loss_feedback_tag) feedback_set_details("round_end_result","[loss_feedback_tag]") +/** + * Prompts the user to input an ambition, that is displayed at the end of the round text to everyone + * + * Only to be called as a verb, not programmatically + */ /mob/living/proc/write_ambition() set name = "Set Ambition" set category = "IC" - if(!mind) + if(!(usr?.mind)) return - if(!is_special_character(src)) - to_chat(src, "While you may perhaps have goals, this verb's meant to only be visible to antagonists. Please make a bug report!") + + if(!is_special_character(usr)) + to_chat(src, SPAN_WARNING("While you may perhaps have goals, this verb's meant to only be visible to antagonists. Please make a bug report!")) return + var/new_ambitions = tgui_input_text(src, "Write a short sentence of what your character hopes to accomplish \ - today as an antagonist. Remember that this is purely optional. It will be shown at the end of the \ - round for everybody else.", "Ambitions", html_decode(mind.ambitions), multiline = TRUE) + today as an antagonist. Remember that this is purely optional. \ + It will be shown at the end of the round for everybody else.", + "Ambitions", html_decode(usr.mind.ambitions), multiline = TRUE) + if(isnull(new_ambitions)) return + new_ambitions = sanitize(new_ambitions) - mind.ambitions = new_ambitions + usr.mind.ambitions = new_ambitions + if(new_ambitions) - to_chat(src, "You've set your goal to be '[new_ambitions]'.") + to_chat(src, SPAN_NOTICE("You've set your goal to be '[new_ambitions]'.")) else - to_chat(src, "You leave your ambitions behind.") + to_chat(src, SPAN_NOTICE("You leave your ambitions behind.")) diff --git a/code/game/atoms.dm b/code/game/atoms.dm index d8ad1186ced..21f43104c75 100644 --- a/code/game/atoms.dm +++ b/code/game/atoms.dm @@ -261,8 +261,18 @@ // Examination code for all atoms. // Returns TRUE, the caller always expects TRUE -// This is used rather than SHOULD_CALL_PARENT as it enforces that subtypes of a type that explicitly returns still call parent +// This is used rather than SHOULD_CALL_PARENT as it enforces that subtypes of a type that explicitly returns still call parent. +// You should usually be overriding get_examine_text(), unless you need special examine behaviour. /atom/proc/examine(mob/user, distance, is_adjacent, infix = "", suffix = "") + var/list/examine_strings = get_examine_text(user, distance, is_adjacent, infix, suffix) + if(!length(examine_strings)) + crash_with("Examine called with no examine strings on [src].") + to_chat(user, EXAMINE_BLOCK(examine_strings.Join("\n"))) + return TRUE + +// This proc is what you should usually override to get things to show up inside the examine box. +/atom/proc/get_examine_text(mob/user, distance, is_adjacent, infix = "", suffix = "") + . = list() var/f_name = "\a [src]. [infix]" if(src.blood_DNA && !istype(src, /obj/effect/decal)) if(gender == PLURAL) @@ -274,28 +284,26 @@ else f_name += "oil-stained [name][infix]." - to_chat(user, "[icon2html(src, user)] That's [f_name] [suffix]") // Object name. I.e. "This is an Object. It is a normal-sized item." + . += "[icon2html(src, user)] That's [f_name] [suffix]" // Object name. I.e. "This is an Object. It is a normal-sized item." if(src.desc) - to_chat(user, src.desc) // Object description. + . += src.desc // Object description. // Extra object descriptions examination code. if(desc_extended || desc_info || (desc_antag && player_is_antag(user.mind))) // Checks if the object has a extended description, a mechanics description, and/or an antagonist description (and if the user is an antagonist). - to_chat(user, FONT_SMALL(SPAN_NOTICE("\[?\] This object has additional examine information available. \[Show In Chat\]"))) // If any of the above are true, show that the object has more information available. + . += FONT_SMALL(SPAN_NOTICE("\[?\] This object has additional examine information available. \[Show In Chat\]")) // If any of the above are true, show that the object has more information available. if(desc_extended) // If the item has a extended description, show that it is available. - to_chat(user, FONT_SMALL("- This object has an extended description.")) + . += FONT_SMALL("- This object has an extended description.") if(desc_info) // If the item has a description regarding game mechanics, show that it is available. - to_chat(user, FONT_SMALL(SPAN_NOTICE("- This object has additional information about mechanics."))) + . += FONT_SMALL(SPAN_NOTICE("- This object has additional information about mechanics.")) if(desc_antag && player_is_antag(user.mind)) // If the item has an antagonist description and the user is an antagonist, show that it is available. - to_chat(user, FONT_SMALL(SPAN_ALERT("- This object has additional information for antagonists."))) + . += FONT_SMALL(SPAN_ALERT("- This object has additional information for antagonists.")) if(ishuman(user)) var/mob/living/carbon/human/H = user if(H.glasses) H.glasses.glasses_examine_atom(src, H) - return TRUE - // Same as examine(), but without the "this object has more info" thing and with the extra information instead. /atom/proc/examine_fluff(mob/user, distance, is_adjacent, infix = "", suffix = "") var/f_name = "\a [src][infix]." @@ -587,7 +595,13 @@ if(toxvomit) this.icon_state = "vomittox_[pick(1,4)]" -/mob/living/proc/handle_additional_vomit_reagents(var/obj/effect/decal/cleanable/vomit/vomit) +/mob/living/proc/handle_additional_vomit_reagents(obj/effect/decal/cleanable/vomit/vomit) + SHOULD_NOT_SLEEP(TRUE) + SHOULD_CALL_PARENT(TRUE) + + if(!istype(vomit)) + return + vomit.reagents.add_reagent(/singleton/reagent/acid/stomach, 5) /atom/proc/clean_blood() diff --git a/code/game/dna/dna_modifier.dm b/code/game/dna/dna_modifier.dm index 963af0795bf..ff141fb576f 100644 --- a/code/game/dna/dna_modifier.dm +++ b/code/game/dna/dna_modifier.dm @@ -107,19 +107,19 @@ src.add_fingerprint(usr) return -/obj/machinery/dna_scannernew/attackby(var/obj/item/item as obj, var/mob/user as mob) - if(istype(item, /obj/item/reagent_containers/glass)) +/obj/machinery/dna_scannernew/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/reagent_containers/glass)) if(beaker) to_chat(user, "A beaker is already loaded into the machine.") return TRUE - beaker = item - user.drop_from_inventory(item,src) - user.visible_message("\The [user] adds \a [item] to \the [src]!", "You add \a [item] to \the [src]!") + beaker = attacking_item + user.drop_from_inventory(attacking_item,src) + user.visible_message("\The [user] adds \a [attacking_item] to \the [src]!", "You add \a [attacking_item] to \the [src]!") return TRUE - else if (!istype(item, /obj/item/grab)) + else if (!istype(attacking_item, /obj/item/grab)) return - var/obj/item/grab/G = item + var/obj/item/grab/G = attacking_item if (!ismob(G.affecting)) return TRUE if (src.occupant) @@ -245,12 +245,12 @@ . = ..() -/obj/machinery/computer/scan_consolenew/attackby(obj/item/I as obj, mob/user as mob) - if (istype(I, /obj/item/disk/data)) //INSERT SOME diskS +/obj/machinery/computer/scan_consolenew/attackby(obj/item/attacking_item, mob/user) + if (istype(attacking_item, /obj/item/disk/data)) //INSERT SOME diskS if (!src.disk) - user.drop_from_inventory(I,src) - src.disk = I - to_chat(user, "You insert [I].") + user.drop_from_inventory(attacking_item, src) + src.disk = attacking_item + to_chat(user, "You insert [attacking_item].") SSnanoui.update_uis(src) // update all UIs attached to src return TRUE else diff --git a/code/game/gamemodes/cult/items/sword.dm b/code/game/gamemodes/cult/items/sword.dm index 7e7214198f5..3aa5b4ad445 100644 --- a/code/game/gamemodes/cult/items/sword.dm +++ b/code/game/gamemodes/cult/items/sword.dm @@ -57,9 +57,9 @@ to_chat(user, SPAN_CULT("An overwhelming feeling of dread comes over you as you pick up \the [src]. It would be wise to be rid of this blade quickly.")) user.make_dizzy(120) -/obj/item/melee/cultblade/attackby(obj/item/I, mob/user) +/obj/item/melee/cultblade/attackby(obj/item/attacking_item, mob/user) ..() - if(istype(I, /obj/item/nullrod)) + if(istype(attacking_item, /obj/item/nullrod)) to_chat(user, SPAN_NOTICE("You cleanse \the [src] of taint, restoring the blade to its original state.")) var/obj/item/material/sword/blade = new(get_turf(src)) blade.force = 15 diff --git a/code/game/gamemodes/cult/items/talisman.dm b/code/game/gamemodes/cult/items/talisman.dm index 95e930656db..e0e16b5ebe3 100644 --- a/code/game/gamemodes/cult/items/talisman.dm +++ b/code/game/gamemodes/cult/items/talisman.dm @@ -15,13 +15,13 @@ QDEL_NULL(rune) return ..() -/obj/item/paper/talisman/examine(mob/user) +/obj/item/paper/talisman/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(iscultist(user) && rune) var/network_text = "" if(network) network_text = " This spell's network tag reads: [SPAN_CULT(network)]." - to_chat(user, "The spell inscription reads: [SPAN_CULT(rune.name)].[network_text]") + . += "The spell inscription reads: [SPAN_CULT(rune.name)].[network_text]" /obj/item/paper/talisman/attack_self(mob/living/user) if(iscultist(user)) diff --git a/code/game/gamemodes/cult/items/tome.dm b/code/game/gamemodes/cult/items/tome.dm index 8c22c6bf39f..1ff90ff11d4 100644 --- a/code/game/gamemodes/cult/items/tome.dm +++ b/code/game/gamemodes/cult/items/tome.dm @@ -96,13 +96,13 @@ if(do_after(scribe, 3 SECONDS)) create_rune(scribe, chosen_rune, target_turf) -/obj/item/book/tome/examine(mob/user) +/obj/item/book/tome/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(iscultist(user) || isobserver(user)) - to_chat(user, "The scriptures of Nar-Sie, The One Who Sees, The Geometer of Blood. Contains the details of every ritual his followers could think of. Most of these are useless, though.") - to_chat(user, SPAN_WARNING("\[?\] This tome contains arcane knowledge of the Geometer's runes. \[Read Tome\]")) + . += "The scriptures of Nar-Sie, The One Who Sees, The Geometer of Blood. Contains the details of every ritual his followers could think of. Most of these are useless, though." + . += SPAN_WARNING("\[?\] This tome contains arcane knowledge of the Geometer's runes. \[Read Tome\]") else - to_chat(user, "An old, dusty tome with frayed edges and a sinister looking cover.") + . += "An old, dusty tome with frayed edges and a sinister looking cover." /obj/item/book/tome/Topic(href, href_list) if(href_list["read_tome"]) diff --git a/code/game/gamemodes/cult/runes/rune.dm b/code/game/gamemodes/cult/runes/rune.dm index bf411a108ac..2845e6dc6d3 100644 --- a/code/game/gamemodes/cult/runes/rune.dm +++ b/code/game/gamemodes/cult/runes/rune.dm @@ -22,21 +22,21 @@ QDEL_NULL(rune) return ..() -/obj/effect/rune/examine(mob/user) +/obj/effect/rune/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(iscultist(user) || isobserver(user)) - to_chat(user, rune.get_cultist_fluff_text()) - to_chat(user, "This rune [rune.can_be_talisman() ? SPAN_CULT("can") : "[SPAN_CULT("cannot")]"] be turned into a talisman.") - to_chat(user, "This rune [rune.can_memorize() ? SPAN_CULT("can") : "[SPAN_CULT("cannot")]"] be memorized to be scribed without a tome.") + . += rune.get_cultist_fluff_text() + . += "This rune [rune.can_be_talisman() ? SPAN_CULT("can") : "[SPAN_CULT("cannot")]"] be turned into a talisman." + . += "This rune [rune.can_memorize() ? SPAN_CULT("can") : "[SPAN_CULT("cannot")]"] be memorized to be scribed without a tome." else - to_chat(user, rune.get_normal_fluff_text()) + . += rune.get_normal_fluff_text() -/obj/effect/rune/attackby(obj/I, mob/user) - if(istype(I, /obj/item/book/tome) && iscultist(user)) - rune.do_tome_action(user, I) +/obj/effect/rune/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/book/tome) && iscultist(user)) + rune.do_tome_action(user, attacking_item) return TRUE - else if(istype(I, /obj/item/nullrod)) - to_chat(user, SPAN_NOTICE("You disrupt the vile magic with the deadening field of \the [I]!")) + else if(istype(attacking_item, /obj/item/nullrod)) + to_chat(user, SPAN_NOTICE("You disrupt the vile magic with the deadening field of \the [attacking_item]!")) qdel(src) return TRUE diff --git a/code/game/gamemodes/cult/structures/desk.dm b/code/game/gamemodes/cult/structures/desk.dm index 6e0e388f96f..e8a1e30e264 100644 --- a/code/game/gamemodes/cult/structures/desk.dm +++ b/code/game/gamemodes/cult/structures/desk.dm @@ -4,9 +4,9 @@ desc_antag = "A desk covered with the scriptures of Nar-Sie, The One Who Sees, The Geometer of Blood. Most of them are beyond your current comprehension. If you are a cultist, you could click on this desk with any non-unique book to turn it into a tome." icon_state = "tomealtar" -/obj/structure/cult/tome/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/book) && iscultist(user)) - var/obj/item/book/B = W +/obj/structure/cult/tome/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/book) && iscultist(user)) + var/obj/item/book/B = attacking_item if(!B.unique) var/cult_item = B.cultify() user.put_in_hands(cult_item) diff --git a/code/game/gamemodes/cult/structures/forge.dm b/code/game/gamemodes/cult/structures/forge.dm index 0219abaf239..b686682bec1 100644 --- a/code/game/gamemodes/cult/structures/forge.dm +++ b/code/game/gamemodes/cult/structures/forge.dm @@ -4,10 +4,10 @@ desc_antag = "A forge used in crafting the unholy weapons used by the armies of Nar-Sie. This is a powerful forge. If you are a cultist, you can click on this with an item in-hand to cultify it. Some items may burn in the process, but some can be forged into better variants." icon_state = "forge" -/obj/structure/cult/forge/attackby(obj/item/W, mob/user) +/obj/structure/cult/forge/attackby(obj/item/attacking_item, mob/user) if(iscultist(user)) - var/stored_message = "You cast \the [W] into the forge, where it rapidly changes form. In a flash, you see it reappear on your person." - var/cult_item = W.cultify(TRUE) + var/stored_message = "You cast \the [attacking_item] into the forge, where it rapidly changes form. In a flash, you see it reappear on your person." + var/cult_item = attacking_item.cultify(TRUE) if(isnull(cult_item)) to_chat(user, SPAN_WARNING("You get the idea that you can't reforge this.")) else if(istype(cult_item, /obj/item)) diff --git a/code/game/gamemodes/cult/structures/gateway.dm b/code/game/gamemodes/cult/structures/gateway.dm index 2f26390fb76..837ff889163 100644 --- a/code/game/gamemodes/cult/structures/gateway.dm +++ b/code/game/gamemodes/cult/structures/gateway.dm @@ -44,9 +44,9 @@ new thing(src.loc) qdel(src) -/obj/effect/gateway/attackby(var/obj/item/I, var/mob/user) +/obj/effect/gateway/attackby(obj/item/attacking_item, mob/user) ..() - if(istype(I, /obj/item/nullrod)) - to_chat(user, "You touch \the [src] with \the [I], closing the path to the otherworld.") + if(istype(attacking_item, /obj/item/nullrod)) + to_chat(user, "You touch \the [src] with \the [attacking_item], closing the path to the otherworld.") qdel(src) return TRUE diff --git a/code/game/gamemodes/cult/structures/pylon.dm b/code/game/gamemodes/cult/structures/pylon.dm index 9984075df48..4523ca6724e 100644 --- a/code/game/gamemodes/cult/structures/pylon.dm +++ b/code/game/gamemodes/cult/structures/pylon.dm @@ -62,18 +62,18 @@ lang = new /datum/language/cultcommon() update_icon() -/obj/structure/cult/pylon/examine(var/mob/user) +/obj/structure/cult/pylon/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(damagetaken) switch(damagetaken) if(1 to 8) - to_chat(user, SPAN_WARNING("It has very faint hairline fractures.")) + . += SPAN_WARNING("It has very faint hairline fractures.") if(8 to 20) - to_chat(user, SPAN_WARNING("It has several cracks across its surface.")) + . += SPAN_WARNING("It has several cracks across its surface.") if(20 to 30) - to_chat(user, SPAN_WARNING("It is chipped and deeply cracked, it may shatter with much more pressure.")) + . += SPAN_WARNING("It is chipped and deeply cracked, it may shatter with much more pressure.") if(30 to INFINITY) - to_chat(user, SPAN_WARNING("It is almost cleaved in two, the pylon looks like it will fall to shards under its own weight.")) + . += SPAN_WARNING("It is almost cleaved in two, the pylon looks like it will fall to shards under its own weight.") /obj/structure/cult/pylon/Move() @@ -346,14 +346,14 @@ return attackpylon(user, damage, user) -/obj/structure/cult/pylon/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/holder)) - var/obj/item/holder/H = W +/obj/structure/cult/pylon/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/holder)) + var/obj/item/holder/H = attacking_item if(H.contained) present_sacrifice(user, H.contained) return TRUE - attackpylon(user, W.force, W) + attackpylon(user, attacking_item.force, attacking_item) //Mousedrop so that constructs can drag rats out of maintenance to make turrets /obj/structure/cult/pylon/MouseDrop_T(var/atom/movable/C, mob/user) diff --git a/code/game/gamemodes/endgame/supermatter_cascade/blob.dm b/code/game/gamemodes/endgame/supermatter_cascade/blob.dm index 1ebaf0d0da3..c1a17a7df3a 100644 --- a/code/game/gamemodes/endgame/supermatter_cascade/blob.dm +++ b/code/game/gamemodes/endgame/supermatter_cascade/blob.dm @@ -87,15 +87,15 @@ Consume(user) -/turf/unsimulated/wall/supermatter/attackby(obj/item/W as obj, mob/living/user as mob) - user.visible_message("\The [user] touches \a [W] to \the [src] as a silence fills the room...",\ - "You touch \the [W] to \the [src] when everything suddenly goes silent.\"\n\The [W] flashes into dust as you flinch away from \the [src].",\ +/turf/unsimulated/wall/supermatter/attackby(obj/item/attacking_item, mob/living/user) + user.visible_message("\The [user] touches \a [attacking_item] to \the [src] as a silence fills the room...",\ + "You touch \the [attacking_item] to \the [src] when everything suddenly goes silent.\"\n\The [attacking_item] flashes into dust as you flinch away from \the [src].",\ "Everything suddenly goes silent.") playsound(src, 'sound/effects/supermatter.ogg', 50, 1) - user.drop_from_inventory(W,src) - Consume(W) + user.drop_from_inventory(attacking_item,src) + Consume(attacking_item) return TRUE diff --git a/code/game/gamemodes/meteor/meteors.dm b/code/game/gamemodes/meteor/meteors.dm index 23a910294f9..6df4447fce7 100644 --- a/code/game/gamemodes/meteor/meteors.dm +++ b/code/game/gamemodes/meteor/meteors.dm @@ -120,8 +120,8 @@ qdel(src) return -/obj/effect/meteor/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W, /obj/item/pickaxe)) +/obj/effect/meteor/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/pickaxe)) qdel(src) return TRUE return ..() diff --git a/code/game/gamemodes/nuclear/pinpointer.dm b/code/game/gamemodes/nuclear/pinpointer.dm index 93cc6cbff19..1d621b4d04a 100644 --- a/code/game/gamemodes/nuclear/pinpointer.dm +++ b/code/game/gamemodes/nuclear/pinpointer.dm @@ -48,11 +48,11 @@ icon_state = "pinonfar" return TRUE -/obj/item/pinpointer/examine(mob/user) +/obj/item/pinpointer/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() for(var/obj/machinery/nuclearbomb/bomb in SSmachinery.machinery) if(bomb.timing) - to_chat(user, "Extreme danger. Arming signal detected. Time remaining: [bomb.timeleft]") + . += "Extreme danger. Arming signal detected. Time remaining: [bomb.timeleft]" /obj/item/pinpointer/Destroy() active = 0 diff --git a/code/game/gamemodes/technomancer/catalog.dm b/code/game/gamemodes/technomancer/catalog.dm index 3dd3e7261dc..c62f811a66b 100644 --- a/code/game/gamemodes/technomancer/catalog.dm +++ b/code/game/gamemodes/technomancer/catalog.dm @@ -364,23 +364,23 @@ var/list/all_technomancer_assistance = typesof(/datum/technomancer/assistance) - break attack_self(H) -/obj/item/technomancer_catalog/attackby(var/atom/movable/AM, var/mob/user) +/obj/item/technomancer_catalog/attackby(obj/item/attacking_item, mob/user) var/turf/T = get_turf(user) if(T.z in SSatlas.current_map.player_levels) to_chat(user, "You can only refund at your base, it's too late now!") return TRUE for(var/datum/technomancer/equipment/E in equipment_instances + assistance_instances) - if(AM.type == E.obj_path) // We got a match. + if(attacking_item.type == E.obj_path) // We got a match. if(budget + E.cost > max_budget) to_chat(user, "\The [src] will not allow you to overflow your maximum budget by refunding that.") return TRUE else budget = budget + E.cost - to_chat(user, "You've refunded \the [AM].") + to_chat(user, "You've refunded \the [attacking_item].") // We sadly need to do special stuff here or else people who refund cores with spells will lose points permanently. - if(istype(AM, /obj/item/technomancer_core)) - var/obj/item/technomancer_core/core = AM + if(istype(attacking_item, /obj/item/technomancer_core)) + var/obj/item/technomancer_core/core = attacking_item for(var/obj/spellbutton/technomancer/spell in core.spells) for(var/datum/technomancer/spell/spell_datum in spell_instances) if(spell_datum.obj_path == spell.spellpath) @@ -388,7 +388,7 @@ var/list/all_technomancer_assistance = typesof(/datum/technomancer/assistance) - to_chat(user, "[spell.name] was inside \the [core], and was refunded.") core.remove_spell(spell) break - qdel(AM) + qdel(attacking_item) return TRUE - to_chat(user, "\The [src] is unable to refund \the [AM].") + to_chat(user, "\The [src] is unable to refund \the [attacking_item].") diff --git a/code/game/gamemodes/technomancer/devices/disposable_teleporter.dm b/code/game/gamemodes/technomancer/devices/disposable_teleporter.dm index 35d240099a7..c9b394b97a6 100644 --- a/code/game/gamemodes/technomancer/devices/disposable_teleporter.dm +++ b/code/game/gamemodes/technomancer/devices/disposable_teleporter.dm @@ -22,9 +22,9 @@ one has been provided to allow you to leave your hideout." uses = 1 -/obj/item/disposable_teleporter/examine(mob/user) +/obj/item/disposable_teleporter/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "[uses] uses remaining.") + . += "[uses] uses remaining." /obj/item/disposable_teleporter/attack_self(mob/user as mob) if(!uses) diff --git a/code/game/gamemodes/technomancer/spell_objs.dm b/code/game/gamemodes/technomancer/spell_objs.dm index 4375b801eaf..8be3bae544a 100644 --- a/code/game/gamemodes/technomancer/spell_objs.dm +++ b/code/game/gamemodes/technomancer/spell_objs.dm @@ -276,9 +276,9 @@ // Proc: attackby() // Parameters: 2 (W - the item this spell object is hitting, user - the technomancer who clicked the other object) // Description: Tries to combine the spells, if W is a spell, and has CHROMATIC aspect. -/obj/item/spell/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/spell)) - var/obj/item/spell/spell = W +/obj/item/spell/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/spell)) + var/obj/item/spell/spell = attacking_item if(run_checks() & (cast_methods & CAST_COMBINE)) spell.on_combine_cast(src, user) return TRUE diff --git a/code/game/jobs/faction/idris.dm b/code/game/jobs/faction/idris.dm index edd9b422fd9..7547a30d77e 100644 --- a/code/game/jobs/faction/idris.dm +++ b/code/game/jobs/faction/idris.dm @@ -47,7 +47,7 @@ titles_to_loadout = list( "Security Officer" = /datum/outfit/job/officer/idris, "Warden" = /datum/outfit/job/warden/idris, - "Security Cadet" = /datum/outfit/job/intern_sec/idris, + "Security Cadet" = /datum/outfit/job/intern_sec/officer/idris, "Investigator Intern" = /datum/outfit/job/intern_sec/forensics/idris, "Investigator" =/datum/outfit/job/forensics/idris, "Bartender" = /datum/outfit/job/bartender/idris, @@ -102,7 +102,7 @@ dufflebag_faction = /obj/item/storage/backpack/duffel/idris messengerbag_faction = /obj/item/storage/backpack/messenger/idris -/datum/outfit/job/intern_sec/idris +/datum/outfit/job/intern_sec/officer/idris name = "Security Cadet - Idris" uniform = /obj/item/clothing/under/rank/cadet/idris diff --git a/code/game/jobs/faction/pmc.dm b/code/game/jobs/faction/pmc.dm index cd84487e4ec..7fe639137aa 100644 --- a/code/game/jobs/faction/pmc.dm +++ b/code/game/jobs/faction/pmc.dm @@ -26,21 +26,17 @@ job_species_blacklist = list( "Corporate Liaison" = list( - SPECIES_TAJARA, - SPECIES_TAJARA_MSAI, - SPECIES_TAJARA_ZHAN, SPECIES_DIONA, SPECIES_DIONA_COEUS, SPECIES_VAURCA_WORKER, - SPECIES_VAURCA_WARRIOR, - SPECIES_UNATHI + SPECIES_VAURCA_WARRIOR ) ) titles_to_loadout = list( "Security Officer" = /datum/outfit/job/officer/pmc, "Warden" = /datum/outfit/job/warden/pmc, - "Security Cadet" = /datum/outfit/job/intern_sec/pmc, + "Security Cadet" = /datum/outfit/job/intern_sec/officer/pmc, "Investigator Intern" = /datum/outfit/job/intern_sec/forensics/pmc, "Investigator" =/datum/outfit/job/forensics/pmc, "Physician" = /datum/outfit/job/doctor/pmc, @@ -82,7 +78,7 @@ dufflebag_faction = /obj/item/storage/backpack/duffel/pmcg messengerbag_faction = /obj/item/storage/backpack/messenger/pmcg -/datum/outfit/job/intern_sec/pmc +/datum/outfit/job/intern_sec/officer/pmc name = "Security Cadet - PMC" uniform = /obj/item/clothing/under/rank/cadet/pmc diff --git a/code/game/jobs/faction/zavodskoi.dm b/code/game/jobs/faction/zavodskoi.dm index f9995602b00..7cef1a8da76 100644 --- a/code/game/jobs/faction/zavodskoi.dm +++ b/code/game/jobs/faction/zavodskoi.dm @@ -33,7 +33,6 @@ SPECIES_IPC_ZENGHU, SPECIES_IPC_BISHOP, SPECIES_IPC_SHELL, - SPECIES_UNATHI, SPECIES_TAJARA, SPECIES_TAJARA_MSAI, SPECIES_TAJARA_ZHAN, @@ -49,7 +48,7 @@ titles_to_loadout = list( "Security Officer" = /datum/outfit/job/officer/zavodskoi, "Warden" = /datum/outfit/job/warden/zavodskoi, - "Security Cadet" = /datum/outfit/job/intern_sec/zavodskoi, + "Security Cadet" = /datum/outfit/job/intern_sec/officer/zavodskoi, "Investigator Intern" = /datum/outfit/job/intern_sec/forensics/zavodskoi, "Investigator" =/datum/outfit/job/forensics/zavodskoi, "Scientist" = /datum/outfit/job/scientist/zavodskoi, @@ -94,7 +93,7 @@ dufflebag_faction = /obj/item/storage/backpack/duffel/zavod messengerbag_faction = /obj/item/storage/backpack/messenger/zavod -/datum/outfit/job/intern_sec/zavodskoi +/datum/outfit/job/intern_sec/officer/zavodskoi name = "Security Cadet - Zavodskoi Interstellar" uniform = /obj/item/clothing/under/rank/cadet/zavod diff --git a/code/game/jobs/job/security.dm b/code/game/jobs/job/security.dm index a68d431f5ae..52bf18e3945 100644 --- a/code/game/jobs/job/security.dm +++ b/code/game/jobs/job/security.dm @@ -269,7 +269,7 @@ selection_color = "#991818" access = list(ACCESS_SECURITY, ACCESS_SEC_DOORS, ACCESS_MAINT_TUNNELS) minimal_access = list(ACCESS_SECURITY, ACCESS_SEC_DOORS) - outfit = /datum/outfit/job/intern_sec + outfit = /datum/outfit/job/intern_sec/officer minimum_character_age = list( SPECIES_HUMAN = 18, SPECIES_SKRELL = 50, @@ -285,7 +285,6 @@ uniform = /obj/item/clothing/under/rank/cadet suit = /obj/item/clothing/suit/storage/hazardvest/security head = /obj/item/clothing/head/beret/security - shoes = null headset = /obj/item/device/radio/headset/headset_sec bowman = /obj/item/device/radio/headset/headset_sec/alt @@ -303,6 +302,15 @@ /datum/outfit/job/intern_sec/post_equip(mob/living/carbon/human/H, visualsOnly = FALSE) . = ..() + +/datum/outfit/job/intern_sec/officer + name = "Security Cadet" + jobtype = /datum/job/intern_sec + + shoes = null + +/datum/outfit/job/intern_sec/officer/post_equip(mob/living/carbon/human/H, visualsOnly = FALSE) + . = ..() if(istajara(H)) H.equip_to_slot_or_del(new /obj/item/clothing/shoes/jackboots/toeless(H), slot_shoes) H.equip_to_slot_or_del(new /obj/item/clothing/gloves/black_leather/tajara(H), slot_gloves) diff --git a/code/game/machinery/CableLayer.dm b/code/game/machinery/CableLayer.dm index e4107c54c91..aebefd2808d 100644 --- a/code/game/machinery/CableLayer.dm +++ b/code/game/machinery/CableLayer.dm @@ -26,16 +26,16 @@ user.visible_message("\The [user] [!on ? "de" : ""]activates \the [src].", SPAN_NOTICE("You switch \the [src] [on ? "on" : "off"].")) return -/obj/machinery/cablelayer/attackby(var/obj/item/O, var/mob/user) - if(O.iscoil()) - var/result = load_cable(O) +/obj/machinery/cablelayer/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iscoil()) + var/result = load_cable(attacking_item) if(!result) to_chat(user, SPAN_WARNING("\The [src]'s cable reel is full.")) else to_chat(user, SPAN_NOTICE("You load [result] lengths of cable into \the [src].")) return TRUE - if(O.iswirecutter()) + if(attacking_item.iswirecutter()) if(cable && cable.amount) var/m = round(input(usr,"Please specify the length of cable to cut.", "Cut Cable",min(cable.amount,30)) as num, 1) m = min(m, cable.amount) @@ -49,15 +49,15 @@ to_chat(user, SPAN_WARNING("There's no more cable on the reel.")) return TRUE - if(O.ismultitool()) + if(attacking_item.ismultitool()) if(!cable) to_chat(user, SPAN_WARNING("\The [src] doesn't have any cable loaded!")) return TRUE - return cable.attackby(O, user) + return cable.attackby(attacking_item, user) -/obj/machinery/cablelayer/examine(mob/user) +/obj/machinery/cablelayer/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "\The [src]'s cable reel has [cable.amount] length\s left.") + . += SPAN_NOTICE("\The [src]'s cable reel has [cable.amount] length\s left.") /obj/machinery/cablelayer/proc/load_cable(var/obj/item/stack/cable_coil/CC) if(istype(CC) && CC.amount) diff --git a/code/game/machinery/OpTable.dm b/code/game/machinery/OpTable.dm index 3a47eb7b681..5c7409f5e13 100644 --- a/code/game/machinery/OpTable.dm +++ b/code/game/machinery/OpTable.dm @@ -118,9 +118,9 @@ patient.reset_view(null) -/obj/machinery/optable/examine(var/mob/user) +/obj/machinery/optable/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, SPAN_NOTICE("The neural suppressors are switched [suppressing ? "on" : "off"].")) + . += SPAN_NOTICE("The neural suppressors are switched [suppressing ? "on" : "off"].") /obj/machinery/optable/ex_act(severity) switch(severity) diff --git a/code/game/machinery/Sleeper.dm b/code/game/machinery/Sleeper.dm index 6f60b33ea30..ee203619fb4 100644 --- a/code/game/machinery/Sleeper.dm +++ b/code/game/machinery/Sleeper.dm @@ -224,20 +224,20 @@ return return attack_hand(user) -/obj/machinery/sleeper/attackby(var/obj/item/I, var/mob/user) - if(!istype(I, /obj/item/forensics)) +/obj/machinery/sleeper/attackby(obj/item/attacking_item, mob/user) + if(!istype(attacking_item, /obj/item/forensics)) add_fingerprint(user) - if(istype(I, /obj/item/reagent_containers/glass)) + if(istype(attacking_item, /obj/item/reagent_containers/glass)) if(!beaker) - beaker = I - user.drop_from_inventory(I,src) - user.visible_message("\The [user] adds \a [I] to \the [src].", "You add \a [I] to \the [src].") + beaker = attacking_item + user.drop_from_inventory(attacking_item, src) + user.visible_message("\The [user] adds \a [attacking_item] to \the [src].", "You add \a [attacking_item] to \the [src].") else to_chat(user, "\The [src] has a beaker already.") return TRUE - else if(istype(I, /obj/item/grab)) + else if(istype(attacking_item, /obj/item/grab)) - var/obj/item/grab/G = I + var/obj/item/grab/G = attacking_item var/mob/living/L = G.affecting var/bucklestatus = L.bucklecheck(user) if(!bucklestatus) @@ -264,14 +264,14 @@ update_icon() qdel(G) return TRUE - else if(I.isscrewdriver()) + else if(attacking_item.isscrewdriver()) src.panel_open = !src.panel_open to_chat(user, "You [src.panel_open ? "open" : "close"] the maintenance panel.") cut_overlays() if(src.panel_open) add_overlay("[initial(icon_state)]-o") return TRUE - else if(default_part_replacement(user, I)) + else if(default_part_replacement(user, attacking_item)) return TRUE /obj/machinery/sleeper/MouseDrop_T(var/mob/target, var/mob/user) diff --git a/code/game/machinery/ai_slipper.dm b/code/game/machinery/ai_slipper.dm index 5d8988e564d..31b7556e21c 100644 --- a/code/game/machinery/ai_slipper.dm +++ b/code/game/machinery/ai_slipper.dm @@ -33,7 +33,7 @@ src.uses = uses src.power_change() -/obj/machinery/ai_slipper/attackby(obj/item/W, mob/user) +/obj/machinery/ai_slipper/attackby(obj/item/attacking_item, mob/user) if(stat & (NOPOWER|BROKEN)) return if (istype(user, /mob/living/silicon)) diff --git a/code/game/machinery/alarm.dm b/code/game/machinery/alarm.dm index 0f095987a5d..37b3e2ab123 100644 --- a/code/game/machinery/alarm.dm +++ b/code/game/machinery/alarm.dm @@ -932,19 +932,19 @@ pixel_x = 10; apply_mode() return 1 -/obj/machinery/alarm/attackby(obj/item/W as obj, mob/user as mob) - if(!istype(W, /obj/item/forensics)) +/obj/machinery/alarm/attackby(obj/item/attacking_item, mob/user) + if(!istype(attacking_item, /obj/item/forensics)) src.add_fingerprint(user) switch(buildstage) if(2) - if(W.isscrewdriver()) // Opening that Air Alarm up. + if(attacking_item.isscrewdriver()) // Opening that Air Alarm up. wiresexposed = !wiresexposed to_chat(user, "You [wiresexposed ? "open" : "close"] the maintenance panel.") update_icon() return TRUE - if (wiresexposed && W.iswirecutter()) + if (wiresexposed && attacking_item.iswirecutter()) user.visible_message("[user] has cut the wires inside \the [src]!", "You cut the wires inside \the [src].") playsound(src.loc, 'sound/items/Wirecutter.ogg', 50, 1) new/obj/item/stack/cable_coil(get_turf(src), 5) @@ -952,7 +952,7 @@ pixel_x = 10; update_icon() return TRUE - if (W.GetID())// trying to unlock the interface with an ID card + if (attacking_item.GetID())// trying to unlock the interface with an ID card if(stat & (NOPOWER|BROKEN)) to_chat(user, "Nothing happens.") return TRUE @@ -965,8 +965,8 @@ pixel_x = 10; return TRUE if(1) - if(W.iscoil()) - var/obj/item/stack/cable_coil/C = W + if(attacking_item.iscoil()) + var/obj/item/stack/cable_coil/C = attacking_item if (C.use(5)) to_chat(user, "You wire \the [src].") buildstage = 2 @@ -977,9 +977,9 @@ pixel_x = 10; to_chat(user, "You need 5 pieces of cable to do wire \the [src].") return TRUE - else if(W.iscrowbar()) + else if(attacking_item.iscrowbar()) to_chat(user, "You start prying out the circuit.") - if(W.use_tool(src, user, 20, volume = 50)) + if(attacking_item.use_tool(src, user, 20, volume = 50)) to_chat(user, "You pry out the circuit!") var/obj/item/airalarm_electronics/circuit = new /obj/item/airalarm_electronics() circuit.forceMove(user.loc) @@ -988,17 +988,17 @@ pixel_x = 10; return TRUE if(0) - if(istype(W, /obj/item/airalarm_electronics)) + if(istype(attacking_item, /obj/item/airalarm_electronics)) to_chat(user, "You insert the circuit!") - qdel(W) + qdel(attacking_item) buildstage = 1 update_icon() return TRUE - else if(W.iswrench()) + else if(attacking_item.iswrench()) to_chat(user, "You remove the air alarm assembly from the wall!") new /obj/item/frame/air_alarm(get_turf(user)) - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) qdel(src) return TRUE @@ -1008,12 +1008,12 @@ pixel_x = 10; ..() queue_icon_update() -/obj/machinery/alarm/examine(mob/user) +/obj/machinery/alarm/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if (buildstage < 2) - to_chat(user, "It is not wired.") + . += SPAN_WARNING("It is not wired.") if (buildstage < 1) - to_chat(user, "The circuit is missing.") + . += SPAN_WARNING("The circuit is missing.") /* AIR ALARM CIRCUIT Just a object used in constructing air alarms diff --git a/code/game/machinery/anti_bluespace.dm b/code/game/machinery/anti_bluespace.dm index 5867b87dcf5..b1b65057c6f 100644 --- a/code/game/machinery/anti_bluespace.dm +++ b/code/game/machinery/anti_bluespace.dm @@ -64,11 +64,11 @@ var/global/list/bluespace_inhibitors anchored = 0 update_icon() -/obj/machinery/anti_bluespace/attackby(obj/item/W as obj, mob/user as mob) +/obj/machinery/anti_bluespace/attackby(obj/item/attacking_item, mob/user) if(user.a_intent == I_HURT) - visible_message(SPAN_WARNING("\The [user] hits \the [src] with \the [W]!")) + visible_message(SPAN_WARNING("\The [user] hits \the [src] with \the [attacking_item]!")) else - visible_message(SPAN_NOTICE("\The [user] [pick("touches","pokes","prods")] \the [src] with \the [W].")) + visible_message(SPAN_NOTICE("\The [user] [pick("touches","pokes","prods")] \the [src] with \the [attacking_item].")) if(prob(66)) return TRUE diff --git a/code/game/machinery/atmoalter/canister.dm b/code/game/machinery/atmoalter/canister.dm index 82a0609843f..79e402934fd 100644 --- a/code/game/machinery/atmoalter/canister.dm +++ b/code/game/machinery/atmoalter/canister.dm @@ -418,23 +418,24 @@ update_flag log_open(admin) valve_open = !valve_open -/obj/machinery/portable_atmospherics/canister/attackby(var/obj/item/W as obj, var/mob/user as mob) - if(istype(W, /obj/item/mecha_equipment/clamp)) +/obj/machinery/portable_atmospherics/canister/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/mecha_equipment/clamp)) return - if(!W.iswrench() && !is_type_in_list(W, list(/obj/item/tank, /obj/item/device/analyzer, /obj/item/modular_computer)) && !issignaler(W) && !(W.iswirecutter() && signaler)) - if(W.item_flags & ITEM_FLAG_NO_BLUDGEON) + if(!attacking_item.iswrench() && !is_type_in_list(attacking_item, list(/obj/item/tank, /obj/item/device/analyzer, /obj/item/modular_computer)) && !issignaler(attacking_item) && !(attacking_item.iswirecutter() && signaler)) + if(attacking_item.item_flags & ITEM_FLAG_NO_BLUDGEON) return TRUE - visible_message(SPAN_WARNING("\The [user] hits \the [src] with \the [W]!"), SPAN_NOTICE("You hit \the [src] with \the [W].")) - user.do_attack_animation(src, W) + visible_message(SPAN_WARNING("\The [user] hits \the [src] with \the [attacking_item]!"), SPAN_NOTICE("You hit \the [src] with \the [attacking_item].")) + user.do_attack_animation(src, attacking_item) playsound(src, 'sound/weapons/smash.ogg', 60, 1) - src.health -= W.force - if(!istype(W, /obj/item/forensics)) + src.health -= attacking_item.force + if(!istype(attacking_item, /obj/item/forensics)) src.add_fingerprint(user) healthcheck() return TRUE - if(istype(user, /mob/living/silicon/robot) && istype(W, /obj/item/tank/jetpack)) - var/datum/gas_mixture/thejetpack = W:air_contents + if(istype(user, /mob/living/silicon/robot) && istype(attacking_item, /obj/item/tank/jetpack)) + var/obj/item/tank/jetpack/jetpack = attacking_item + var/datum/gas_mixture/thejetpack = jetpack.air_contents var/env_pressure = thejetpack.return_pressure() var/pressure_delta = min(10*ONE_ATMOSPHERE - env_pressure, (air_contents.return_pressure() - env_pressure)/2) //Can not have a pressure delta that would cause environment pressure > tank pressure diff --git a/code/game/machinery/atmoalter/meter.dm b/code/game/machinery/atmoalter/meter.dm index af8de48b833..15fa7abc5cf 100644 --- a/code/game/machinery/atmoalter/meter.dm +++ b/code/game/machinery/atmoalter/meter.dm @@ -62,27 +62,27 @@ ) radio_connection.post_signal(src, signal) -/obj/machinery/meter/examine(mob/user, distance, is_adjacent) +/obj/machinery/meter/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() var/t = "A gas flow meter. " - if(distance > 3 && !(istype(user, /mob/living/silicon/ai))) - t += "You are too far away to read it." + if(distance > 3 && !isAI(user)) + t += SPAN_WARNING("You are too far away to read it.") else if(stat & (NOPOWER|BROKEN)) - t += "The display is off." + t += SPAN_WARNING("The display is off.") else if(src.target) var/datum/gas_mixture/environment = target.return_air() if(environment) t += "The pressure gauge reads [round(environment.return_pressure(), 0.01)] kPa; [round(environment.temperature,0.01)]K ([round(environment.temperature-T0C,0.01)]°C)" else - t += "The sensor error light is blinking." + t += SPAN_WARNING("The sensor error light is blinking.") else - t += "The connect error light is blinking." + t += SPAN_WARNING("The connect error light is blinking.") - to_chat(user, t) + . += t /obj/machinery/meter/Click() @@ -92,11 +92,11 @@ return ..() -/obj/machinery/meter/attackby(var/obj/item/W as obj, var/mob/user as mob) - if (!W.iswrench()) +/obj/machinery/meter/attackby(obj/item/attacking_item, mob/user) + if (!attacking_item.iswrench()) return ..() to_chat(user, "You begin to unfasten \the [src]...") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) user.visible_message( \ "\The [user] unfastens \the [src].", \ "You have unfastened \the [src].", \ @@ -112,5 +112,5 @@ if (!target) src.target = loc -/obj/machinery/meter/turf/attackby(var/obj/item/W as obj, var/mob/user as mob) +/obj/machinery/meter/turf/attackby(obj/item/attacking_item, mob/user) return diff --git a/code/game/machinery/atmoalter/portable_atmospherics.dm b/code/game/machinery/atmoalter/portable_atmospherics.dm index 7cd8d449816..d85988a8610 100644 --- a/code/game/machinery/atmoalter/portable_atmospherics.dm +++ b/code/game/machinery/atmoalter/portable_atmospherics.dm @@ -104,22 +104,22 @@ if (network) network.update = 1 -/obj/machinery/portable_atmospherics/attackby(var/obj/item/W as obj, var/mob/user as mob) - if ((istype(W, /obj/item/tank) && !( src.destroyed ))) +/obj/machinery/portable_atmospherics/attackby(obj/item/attacking_item, mob/user) + if ((istype(attacking_item, /obj/item/tank) && !( src.destroyed ))) if (src.holding) return TRUE - var/obj/item/tank/T = W + var/obj/item/tank/T = attacking_item user.drop_from_inventory(T,src) src.holding = T update_icon() SStgui.update_uis(src) return TRUE - else if (W.iswrench()) + else if (attacking_item.iswrench()) if(connected_port) disconnect() to_chat(user, "You disconnect \the [src] from the port.") - playsound(get_turf(src), W.usesound, 50, 1) + playsound(get_turf(src), attacking_item.usesound, 50, 1) update_icon() SStgui.update_uis(src) return TRUE @@ -128,7 +128,7 @@ if(possible_port) if(connect(possible_port)) to_chat(user, "You connect \the [src] to the port.") - playsound(get_turf(src), W.usesound, 50, 1) + playsound(get_turf(src), attacking_item.usesound, 50, 1) update_icon() SStgui.update_uis(src) return TRUE @@ -139,8 +139,8 @@ to_chat(user, "Nothing happens.") return TRUE - else if ((istype(W, /obj/item/device/analyzer)) && Adjacent(user)) - var/obj/item/device/analyzer/A = W + else if ((istype(attacking_item, /obj/item/device/analyzer)) && Adjacent(user)) + var/obj/item/device/analyzer/A = attacking_item A.analyze_gases(src, user) return TRUE @@ -160,13 +160,13 @@ return 1 return 0 -/obj/machinery/portable_atmospherics/powered/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/cell)) +/obj/machinery/portable_atmospherics/powered/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/cell)) if(cell) to_chat(user, "There is already a power cell installed.") return TRUE - var/obj/item/cell/C = I + var/obj/item/cell/C = attacking_item user.drop_from_inventory(C,src) C.add_fingerprint(user) @@ -176,7 +176,7 @@ SStgui.update_uis(src) return TRUE - if(I.isscrewdriver()) + if(attacking_item.isscrewdriver()) if(!cell) to_chat(user, "There is no power cell installed.") return TRUE diff --git a/code/game/machinery/atmoalter/scrubber.dm b/code/game/machinery/atmoalter/scrubber.dm index 5c439912e51..8578ab15ea4 100644 --- a/code/game/machinery/atmoalter/scrubber.dm +++ b/code/game/machinery/atmoalter/scrubber.dm @@ -214,34 +214,34 @@ use_power_oneoff(power_draw) update_connected_network() -/obj/machinery/portable_atmospherics/powered/scrubber/huge/attackby(var/obj/item/I as obj, var/mob/user as mob) - if(I.iswrench()) +/obj/machinery/portable_atmospherics/powered/scrubber/huge/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswrench()) if(on) to_chat(user, "Turn \the [src] off first!") return TRUE anchored = !anchored - playsound(src.loc, I.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) to_chat(user, "You [anchored ? "wrench" : "unwrench"] \the [src].") return TRUE //doesn't use power cells - if(istype(I, /obj/item/cell)) + if(istype(attacking_item, /obj/item/cell)) return TRUE - if (I.isscrewdriver()) + if (attacking_item.isscrewdriver()) return TRUE //doesn't hold tanks - if(istype(I, /obj/item/tank)) + if(istype(attacking_item, /obj/item/tank)) return TRUE return ..() /obj/machinery/portable_atmospherics/powered/scrubber/huge/stationary name = "Stationary Air Scrubber" -/obj/machinery/portable_atmospherics/powered/scrubber/huge/stationary/attackby(var/obj/item/I as obj, var/mob/user as mob) - if(I.iswrench()) +/obj/machinery/portable_atmospherics/powered/scrubber/huge/stationary/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswrench()) to_chat(user, "The bolts are too tight for you to unscrew!") return TRUE diff --git a/code/game/machinery/autolathe/autolathe.dm b/code/game/machinery/autolathe/autolathe.dm index 95d12509959..103e78babb4 100644 --- a/code/game/machinery/autolathe/autolathe.dm +++ b/code/game/machinery/autolathe/autolathe.dm @@ -142,17 +142,17 @@ ) return data -/obj/machinery/autolathe/attackby(obj/item/O, mob/user) +/obj/machinery/autolathe/attackby(obj/item/attacking_item, mob/user) if((autolathe_flags & AUTOLATHE_BUSY)) to_chat(user, SPAN_NOTICE("\The [src] is busy. Please wait for the completion of previous operation.")) return TRUE - if(default_deconstruction_screwdriver(user, O)) + if(default_deconstruction_screwdriver(user, attacking_item)) SStgui.update_uis(src) return TRUE - if(default_deconstruction_crowbar(user, O)) + if(default_deconstruction_crowbar(user, attacking_item)) return TRUE - if(default_part_replacement(user, O)) + if(default_part_replacement(user, attacking_item)) return TRUE if(stat) @@ -160,20 +160,20 @@ if(panel_open) //Don't eat multitools or wirecutters used on an open lathe. - if(O.ismultitool() || O.iswirecutter()) + if(attacking_item.ismultitool() || attacking_item.iswirecutter()) if(panel_open) wires.interact(user) else to_chat(user, SPAN_WARNING("\The [src]'s wires aren't exposed.")) return TRUE - if(O.loc != user && !istype(O, /obj/item/stack)) + if(attacking_item.loc != user && !istype(attacking_item, /obj/item/stack)) return FALSE - if(is_robot_module(O)) + if(is_robot_module(attacking_item)) return FALSE - load_lathe(O, user) + load_lathe(attacking_item, user) return TRUE /obj/machinery/autolathe/attack_hand(mob/user) diff --git a/code/game/machinery/biogenerator.dm b/code/game/machinery/biogenerator.dm index 2edf5696ff1..b96ed33550c 100644 --- a/code/game/machinery/biogenerator.dm +++ b/code/game/machinery/biogenerator.dm @@ -320,28 +320,28 @@ SPECIAL else icon_state = "[initial(icon_state)]-work" -/obj/machinery/biogenerator/attackby(var/obj/item/O as obj, var/mob/user as mob) - if(default_deconstruction_screwdriver(user, O)) +/obj/machinery/biogenerator/attackby(obj/item/attacking_item, mob/user) + if(default_deconstruction_screwdriver(user, attacking_item)) return TRUE - if(default_deconstruction_crowbar(user, O)) + if(default_deconstruction_crowbar(user, attacking_item)) return TRUE - if(default_part_replacement(user, O)) + if(default_part_replacement(user, attacking_item)) return TRUE - if(istype(O, /obj/item/reagent_containers/glass)) + if(istype(attacking_item, /obj/item/reagent_containers/glass)) if(beaker) to_chat(user, SPAN_NOTICE("\The [src] is already loaded.")) else - user.remove_from_mob(O) - O.forceMove(src) - beaker = O + user.remove_from_mob(attacking_item) + attacking_item.forceMove(src) + beaker = attacking_item updateUsrDialog() . = TRUE else if(processing) to_chat(user, SPAN_NOTICE("\The [src] is currently processing.")) . = TRUE - else if(istype(O, /obj/item/storage/bag/plants)) + else if(istype(attacking_item, /obj/item/storage/bag/plants)) var/i = 0 - var/obj/item/storage/bag/P = O + var/obj/item/storage/bag/P = attacking_item for(var/obj/item/reagent_containers/food/snacks/grown/G in contents) i++ if(i >= capacity) @@ -357,9 +357,9 @@ SPECIAL CHECK_TICK if(i < capacity) - to_chat(user, SPAN_NOTICE("You empty \the [O] into \the [src].")) + to_chat(user, SPAN_NOTICE("You empty \the [attacking_item] into \the [src].")) . = TRUE - else if(!istype(O, /obj/item/reagent_containers/food/snacks/grown)) + else if(!istype(attacking_item, /obj/item/reagent_containers/food/snacks/grown)) to_chat(user, SPAN_NOTICE("You cannot put this in \the [src].")) . = TRUE else @@ -369,9 +369,9 @@ SPECIAL if(i >= capacity) to_chat(user, SPAN_NOTICE("\The [src] is full! Activate it.")) else - user.remove_from_mob(O) - O.forceMove(src) - to_chat(user, SPAN_NOTICE("You put \the [O] in \the [src]")) + user.remove_from_mob(attacking_item) + attacking_item.forceMove(src) + to_chat(user, SPAN_NOTICE("You put \the [attacking_item] in \the [src]")) . = TRUE update_icon() diff --git a/code/game/machinery/bioprinter.dm b/code/game/machinery/bioprinter.dm index cb1ce5de8f6..2e65f0a0abc 100644 --- a/code/game/machinery/bioprinter.dm +++ b/code/game/machinery/bioprinter.dm @@ -56,30 +56,30 @@ else to_chat(user, "There is not enough matter in the printer.") -/obj/machinery/bioprinter/attackby(obj/item/W, mob/user) +/obj/machinery/bioprinter/attackby(obj/item/attacking_item, mob/user) // DNA sample from syringe. - if(!prints_prosthetics && istype(W,/obj/item/reagent_containers/syringe)) - var/obj/item/reagent_containers/syringe/S = W + if(!prints_prosthetics && istype(attacking_item, /obj/item/reagent_containers/syringe)) + var/obj/item/reagent_containers/syringe/S = attacking_item if(REAGENT_DATA(S.reagents, /singleton/reagent/blood)) loaded_dna = REAGENT_DATA(S.reagents, /singleton/reagent/blood) S.reagents.clear_reagents() to_chat(user, "You inject the blood sample into the bioprinter.") return TRUE // Meat for biomass. - if(!prints_prosthetics && istype(W, /obj/item/reagent_containers/food/snacks/meat)) + if(!prints_prosthetics && istype(attacking_item, /obj/item/reagent_containers/food/snacks/meat)) stored_matter += 50 - user.drop_from_inventory(W,src) - to_chat(user, "\The [src] processes \the [W]. Levels of stored biomass now: [stored_matter]") - qdel(W) + user.drop_from_inventory(attacking_item, src) + to_chat(user, "\The [src] processes \the [attacking_item]. Levels of stored biomass now: [stored_matter]") + qdel(attacking_item) return TRUE // Steel for matter. - if(prints_prosthetics && istype(W, /obj/item/stack/material) && W.get_material_name() == DEFAULT_WALL_MATERIAL) - var/obj/item/stack/S = W + if(prints_prosthetics && istype(attacking_item, /obj/item/stack/material) && attacking_item.get_material_name() == DEFAULT_WALL_MATERIAL) + var/obj/item/stack/S = attacking_item stored_matter += S.amount * 10 - user.drop_from_inventory(W,src) - to_chat(user, "\The [src] processes \the [W]. Levels of stored matter now: [stored_matter]") - qdel(W) + user.drop_from_inventory(attacking_item, src) + to_chat(user, "\The [src] processes \the [attacking_item]. Levels of stored matter now: [stored_matter]") + qdel(attacking_item) return TRUE return..() diff --git a/code/game/machinery/bluespacerelay.dm b/code/game/machinery/bluespacerelay.dm index bb17ff44a44..44003f219b6 100644 --- a/code/game/machinery/bluespacerelay.dm +++ b/code/game/machinery/bluespacerelay.dm @@ -38,12 +38,12 @@ else on = 1 -/obj/machinery/bluespacerelay/attackby(var/obj/item/O as obj, var/mob/user as mob) - if(default_deconstruction_screwdriver(user, O)) +/obj/machinery/bluespacerelay/attackby(obj/item/attacking_item, mob/user) + if(default_deconstruction_screwdriver(user, attacking_item)) return TRUE - if(default_deconstruction_crowbar(user, O)) + if(default_deconstruction_crowbar(user, attacking_item)) return TRUE - if(default_part_replacement(user, O)) + if(default_part_replacement(user, attacking_item)) return TRUE return ..() diff --git a/code/game/machinery/body_scanner.dm b/code/game/machinery/body_scanner.dm index 7a24ddfc920..504b7975ef8 100644 --- a/code/game/machinery/body_scanner.dm +++ b/code/game/machinery/body_scanner.dm @@ -136,7 +136,8 @@ update_icon() return -/obj/machinery/bodyscanner/attackby(obj/item/grab/G, mob/user) +/obj/machinery/bodyscanner/attackby(obj/item/attacking_item, mob/user) + var/obj/item/grab/G = attacking_item if (!istype(G, /obj/item/grab) || !isliving(G.affecting) ) return if (occupant) diff --git a/code/game/machinery/bots/bots.dm b/code/game/machinery/bots/bots.dm index 9497f96e1b0..3d6e0664d4b 100644 --- a/code/game/machinery/bots/bots.dm +++ b/code/game/machinery/bots/bots.dm @@ -53,22 +53,21 @@ log_and_message_admins("emagged [src]'s inner circuits") return 1 -/obj/machinery/bot/examine(mob/user) +/obj/machinery/bot/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if (src.health < maxhealth) if (src.health > maxhealth/3) - to_chat(user, "[src]'s parts look loose.") + . += "[src]'s parts look loose." else - to_chat(user, "[src]'s parts look very loose!") - return + . += "[src]'s parts look very loose!" -/obj/machinery/bot/attackby(obj/item/W as obj, mob/user as mob) - if(W.isscrewdriver()) +/obj/machinery/bot/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(!locked) open = !open to_chat(user, "Maintenance panel is now [src.open ? "opened" : "closed"].") return TRUE - else if(W.iswelder()) + else if(attacking_item.iswelder()) if(health < maxhealth) if(open) health = min(maxhealth, health+10) @@ -80,12 +79,12 @@ to_chat(user, "[src] does not need a repair.") return TRUE else - if(hasvar(W,"force") && hasvar(W,"damtype")) - switch(W.damtype) + if(hasvar(attacking_item,"force") && hasvar(attacking_item,"damtype")) + switch(attacking_item.damtype) if("fire") - src.health -= W.force * fire_dam_coeff + src.health -= attacking_item.force * fire_dam_coeff if("brute") - src.health -= W.force * brute_dam_coeff + src.health -= attacking_item.force * brute_dam_coeff user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) . = ..() healthcheck() diff --git a/code/game/machinery/buttons.dm b/code/game/machinery/buttons.dm index 383df30930e..3ff785b8ced 100644 --- a/code/game/machinery/buttons.dm +++ b/code/game/machinery/buttons.dm @@ -29,7 +29,7 @@ return return attack_hand(user) -/obj/machinery/button/attackby(obj/item/W, mob/user as mob) +/obj/machinery/button/attackby(obj/item/attacking_item, mob/user) return attack_hand(user) /obj/machinery/button/attack_hand(mob/living/user) diff --git a/code/game/machinery/camera/camera.dm b/code/game/machinery/camera/camera.dm index f6faeceb9d1..e1e10191f63 100644 --- a/code/game/machinery/camera/camera.dm +++ b/code/game/machinery/camera/camera.dm @@ -144,24 +144,24 @@ add_hiddenprint(user) destroy() -/obj/machinery/camera/attackby(obj/W as obj, mob/living/user as mob) +/obj/machinery/camera/attackby(obj/item/attacking_item, mob/user) update_coverage() // DECONSTRUCTION - if(W.isscrewdriver()) + if(attacking_item.isscrewdriver()) //to_chat(user, "You start to [panel_open ? "close" : "open"] the camera's panel.") //if(toggle_panel(user)) // No delay because no one likes screwdrivers trying to be hip and have a duration cooldown panel_open = !panel_open user.visible_message("[user] screws the camera's panel [panel_open ? "open" : "closed"]!", "You screw the camera's panel [panel_open ? "open" : "closed"].") - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) return TRUE - else if((W.iswirecutter() || W.ismultitool()) && panel_open) + else if((attacking_item.iswirecutter() || attacking_item.ismultitool()) && panel_open) interact(user) return TRUE - else if(W.iswelder() && (wires.CanDeconstruct() || (stat & BROKEN))) - if(weld(W, user)) + else if(attacking_item.iswelder() && (wires.CanDeconstruct() || (stat & BROKEN))) + if(weld(attacking_item, user)) if(assembly) assembly.forceMove(src.loc) assembly.anchored = 1 @@ -181,14 +181,14 @@ return TRUE // OTHER - else if (can_use() && (istype(W, /obj/item/paper)) && isliving(user)) + else if (can_use() && (istype(attacking_item, /obj/item/paper)) && isliving(user)) var/info = null var/mob/living/U = user var/obj/item/paper/X = null var/itemname = "" - if(istype(W, /obj/item/paper)) - X = W + if(istype(attacking_item, /obj/item/paper)) + X = attacking_item itemname = X.name info = X.info to_chat(U, "You hold \a [itemname] up to the camera ...") @@ -208,7 +208,7 @@ O << browse(text("[][]", itemname, info), text("window=[]", itemname)) //Force people watching to open the page so they can't see it again) return TRUE - else if (istype(W, /obj/item/camera_bug)) + else if (istype(attacking_item, /obj/item/camera_bug)) if (!src.can_use()) to_chat(user, "Camera non-functional.") else if (src.bugged) @@ -219,16 +219,16 @@ src.bugged = 1 return TRUE - else if(W.damtype == DAMAGE_BRUTE || W.damtype == DAMAGE_BURN) //bashing cameras + else if(attacking_item.damtype == DAMAGE_BRUTE || attacking_item.damtype == DAMAGE_BURN) //bashing cameras user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - if (W.force >= src.toughness) + if (attacking_item.force >= src.toughness) user.do_attack_animation(src) - user.visible_message("[user] has [LAZYPICK(W.attack_verb,"attacked")] [src] with [W]!") - if (istype(W, /obj/item)) //is it even possible to get into attackby() with non-items? - var/obj/item/I = W + user.visible_message("[user] has [LAZYPICK(attacking_item.attack_verb,"attacked")] [src] with [attacking_item]!") + if (istype(attacking_item, /obj/item)) //is it even possible to get into attackby() with non-items? + var/obj/item/I = attacking_item if (I.hitsound) playsound(loc, I.hitsound, I.get_clamped_volume(), 1, -1) - take_damage(W.force) + take_damage(attacking_item.force) return TRUE else return ..() diff --git a/code/game/machinery/camera/camera_assembly.dm b/code/game/machinery/camera/camera_assembly.dm index 3a2cd0d7167..725fe9f912c 100644 --- a/code/game/machinery/camera/camera_assembly.dm +++ b/code/game/machinery/camera/camera_assembly.dm @@ -23,14 +23,14 @@ 4 = Screwdriver panel closed and is fully built (you cannot attach upgrades) */ -/obj/item/camera_assembly/attackby(obj/item/W as obj, mob/living/user as mob) +/obj/item/camera_assembly/attackby(obj/item/attacking_item, mob/user) switch(state) if(0) // State 0 - if(W.iswrench() && isturf(src.loc)) - playsound(src.loc, W.usesound, 50, 1) + if(attacking_item.iswrench() && isturf(src.loc)) + playsound(src.loc, attacking_item.usesound, 50, 1) to_chat(user, "You wrench the assembly into place.") anchored = 1 state = 1 @@ -40,15 +40,15 @@ if(1) // State 1 - if(W.iswelder()) - if(weld(W, user)) + if(attacking_item.iswelder()) + if(weld(attacking_item, user)) to_chat(user, "You weld the assembly securely into place.") anchored = 1 state = 2 return TRUE - else if(W.iswrench()) - playsound(src.loc, W.usesound, 50, 1) + else if(attacking_item.iswrench()) + playsound(src.loc, attacking_item.usesound, 50, 1) to_chat(user, "You unattach the assembly from its place.") anchored = 0 update_icon() @@ -57,8 +57,8 @@ if(2) // State 2 - if(W.iscoil()) - var/obj/item/stack/cable_coil/C = W + if(attacking_item.iscoil()) + var/obj/item/stack/cable_coil/C = attacking_item if(C.use(2)) to_chat(user, "You add wires to the assembly.") state = 3 @@ -66,9 +66,9 @@ to_chat(user, "You need 2 coils of wire to wire the assembly.") return TRUE - else if(W.iswelder()) + else if(attacking_item.iswelder()) - if(weld(W, user)) + if(weld(attacking_item, user)) to_chat(user, "You unweld the assembly from its place.") state = 1 anchored = 1 @@ -77,10 +77,11 @@ if(3) // State 3 - if(W.isscrewdriver()) - playsound(src.loc, W.usesound, 50, 1) + if(attacking_item.isscrewdriver()) + playsound(src.loc, attacking_item.usesound, 50, 1) - var/input = sanitize(input(usr, "Which networks would you like to connect this camera to? Separate networks with a comma. No Spaces!\nFor example: Station,Security,Secret", "Set Network", camera_network ? camera_network : NETWORK_STATION)) + var/input = sanitize( tgui_input_text(user, "Which networks would you like to connect this camera to? Separate networks with a comma. No Spaces!\nFor example: Station,Security,Secret", + "Set Network", (camera_network ? camera_network : NETWORK_STATION)) ) if(!input) to_chat(usr, "No input found please hang up and try your call again.") return TRUE @@ -92,7 +93,7 @@ var/area/camera_area = get_area(src) var/temptag = "[sanitize(camera_area.name)] ([rand(1, 999)])" - input = sanitizeSafe(input(usr, "How would you like to name the camera?", "Set Camera Name", camera_name ? camera_name : temptag), MAX_NAME_LEN) + input = sanitizeSafe( tgui_input_text(user, "How would you like to name the camera?", "Set Camera Name", (camera_name ? camera_name : temptag), MAX_NAME_LEN), MAX_NAME_LEN ) state = 4 var/obj/machinery/camera/C = new(src.loc) @@ -111,12 +112,12 @@ C.dir = text2dir(direct) C.set_pixel_offsets() if(i != 0) - var/confirm = alert(user, "Is this what you want? Chances Remaining: [i]", "Confirmation", "Yes", "No") + var/confirm = tgui_input_list(user, "Is this what you want? Chances Remaining: [i]", "Confirmation", list("Yes", "No")) if(confirm == "Yes") break return TRUE - else if(W.iswirecutter()) + else if(attacking_item.iswirecutter()) new/obj/item/stack/cable_coil(get_turf(src), 2) playsound(src.loc, 'sound/items/Wirecutter.ogg', 50, 1) @@ -125,24 +126,24 @@ return TRUE // Upgrades! - if(is_type_in_list(W, possible_upgrades) && !is_type_in_list(W, upgrades)) // Is a possible upgrade and isn't in the camera already. - if(istype(W, /obj/item/stock_parts/scanning_module)) - var/obj/item/stock_parts/scanning_module/SM = W + if(is_type_in_list(attacking_item, possible_upgrades) && !is_type_in_list(attacking_item, upgrades)) // Is a possible upgrade and isn't in the camera already. + if(istype(attacking_item, /obj/item/stock_parts/scanning_module)) + var/obj/item/stock_parts/scanning_module/SM = attacking_item if(SM.rating < 2) to_chat(user, SPAN_WARNING("That scanning module doesn't seem advanced enough.")) return - to_chat(user, "You attach \the [W] into the assembly inner circuits.") - upgrades += W - user.remove_from_mob(W) - W.forceMove(src) + to_chat(user, "You attach \the [attacking_item] into the assembly inner circuits.") + upgrades += attacking_item + user.remove_from_mob(attacking_item) + attacking_item.forceMove(src) return // Taking out upgrades - else if(W.iscrowbar() && upgrades.len) + else if(attacking_item.iscrowbar() && upgrades.len) var/obj/U = locate(/obj) in upgrades if(U) to_chat(user, "You unattach an upgrade from the assembly.") - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) U.forceMove(get_turf(src)) upgrades -= U return diff --git a/code/game/machinery/case_button.dm b/code/game/machinery/case_button.dm index 0b8dfb6c99b..2d46cf511b3 100644 --- a/code/game/machinery/case_button.dm +++ b/code/game/machinery/case_button.dm @@ -31,8 +31,8 @@ QDEL_NULL(listener) return ..() -/obj/machinery/case_button/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/card)) +/obj/machinery/case_button/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/card)) if(src.allowed(user)) covered = !covered //Enable / Disable the forcefield update_use_power(covered + 1) //Update the power usage @@ -41,7 +41,7 @@ if(covered && (stat & NOPOWER)) //Only bounce off if its powered (i.e. shield active) . = ..() else - user.visible_message("[src] has been hit by [user] with [W], but it bounces off the forcefield.","You hit [src] with [W], but it bounces off the forcefield.","You hear something bouncing off a forcefield.") + user.visible_message("[src] has been hit by [user] with [attacking_item], but it bounces off the forcefield.","You hit [src] with [attacking_item], but it bounces off the forcefield.","You hear something bouncing off a forcefield.") . = TRUE update_icon() diff --git a/code/game/machinery/cell_charger.dm b/code/game/machinery/cell_charger.dm index 036e0a18cc4..5af1301245b 100644 --- a/code/game/machinery/cell_charger.dm +++ b/code/game/machinery/cell_charger.dm @@ -39,31 +39,31 @@ add_overlay("cell-o2") add_overlay("[icon_state]-o[charge_level]") -/obj/machinery/cell_charger/examine(mob/user, distance, is_adjacent) +/obj/machinery/cell_charger/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance > 5) - return TRUE + return if(charging) - to_chat(user, "There's \a [charging.name] in the charger. Current charge: [charging.percent()]%.") + . += "There's \a [charging.name] in the charger. Current charge: [charging.percent()]%." else - to_chat(user, SPAN_WARNING("The charger is empty.")) + . += SPAN_WARNING("The charger is empty.") -/obj/machinery/cell_charger/attackby(obj/item/W, mob/user) +/obj/machinery/cell_charger/attackby(obj/item/attacking_item, mob/user) if(stat & BROKEN) return TRUE - if(W.iswrench()) + if(attacking_item.iswrench()) if(charging) to_chat(user, SPAN_WARNING("Remove the cell first!")) return TRUE anchored = !anchored to_chat(user, "You [anchored ? "" : "un"]secure \the [src].") - playsound(src, W.usesound, 50, 1) + playsound(src, attacking_item.usesound, 50, 1) return TRUE - if(istype(W, /obj/item/cell)) + if(istype(attacking_item, /obj/item/cell)) if(!anchored) to_chat(user, SPAN_WARNING("You need to secure \the [src] first.")) return TRUE @@ -72,8 +72,8 @@ to_chat(user, SPAN_WARNING("There is already a cell in \the [src].")) return TRUE - user.drop_from_inventory(W, src) - charging = W + user.drop_from_inventory(attacking_item, src) + charging = attacking_item user.visible_message("[user] inserts \the [charging.name] into \the [src].", "You insert \the [charging.name] into \the [src].") update_icon() diff --git a/code/game/machinery/chem_heater.dm b/code/game/machinery/chem_heater.dm index 85a94cb72cb..ce2e76b569a 100644 --- a/code/game/machinery/chem_heater.dm +++ b/code/game/machinery/chem_heater.dm @@ -29,19 +29,19 @@ user.set_machine(src) interact(user) -/obj/machinery/chem_heater/attackby(obj/item/O, mob/user) - if(default_deconstruction_screwdriver(user, O)) +/obj/machinery/chem_heater/attackby(obj/item/attacking_item, mob/user) + if(default_deconstruction_screwdriver(user, attacking_item)) return TRUE - if(default_deconstruction_crowbar(user, O)) + if(default_deconstruction_crowbar(user, attacking_item)) return TRUE - if(default_part_replacement(user, O)) + if(default_part_replacement(user, attacking_item)) return TRUE - if(istype(O, /obj/item/reagent_containers/glass) || istype(O, /obj/item/reagent_containers/food)) + if(istype(attacking_item, /obj/item/reagent_containers/glass) || istype(attacking_item, /obj/item/reagent_containers/food)) if(container) to_chat(user, SPAN_WARNING("There is already \a [container] on \the [src]!")) return TRUE - var/obj/item/reagent_containers/RC = O + var/obj/item/reagent_containers/RC = attacking_item if(!RC.is_open_container()) to_chat(user, SPAN_WARNING("You don't see how \the [src] could heat up the reagents in \the [RC].")) return TRUE diff --git a/code/game/machinery/cloning.dm b/code/game/machinery/cloning.dm index d7711ea29d5..9639b1d9cc6 100644 --- a/code/game/machinery/cloning.dm +++ b/code/game/machinery/cloning.dm @@ -212,16 +212,16 @@ return //Let's unlock this early I guess. Might be too early, needs tweaking. -/obj/machinery/clonepod/attackby(obj/item/W as obj, mob/user as mob) +/obj/machinery/clonepod/attackby(obj/item/attacking_item, mob/user) if(isnull(occupant)) - if(default_deconstruction_screwdriver(user, W)) + if(default_deconstruction_screwdriver(user, attacking_item)) return TRUE - if(default_deconstruction_crowbar(user, W)) + if(default_deconstruction_crowbar(user, attacking_item)) return TRUE - if(default_part_replacement(user, W)) + if(default_part_replacement(user, attacking_item)) return TRUE - if(W.GetID()) - if(!check_access(W.GetID())) + if(attacking_item.GetID()) + if(!check_access(attacking_item.GetID())) to_chat(user, "Access Denied.") return TRUE if((!locked) || (isnull(occupant))) @@ -232,13 +232,13 @@ else locked = 0 to_chat(user, "System unlocked.") - else if(istype(W, /obj/item/reagent_containers/food/snacks/meat)) - to_chat(user, "\The [src] processes \the [W].") + else if(istype(attacking_item, /obj/item/reagent_containers/food/snacks/meat)) + to_chat(user, "\The [src] processes \the [attacking_item].") biomass += 50 - user.drop_from_inventory(W,src) - qdel(W) + user.drop_from_inventory(attacking_item, src) + qdel(attacking_item) return TRUE - else if(W.iswrench()) + else if(attacking_item.iswrench()) if(locked && (anchored || occupant)) to_chat(user, "Can not do that while [src] is in use.") else @@ -248,7 +248,7 @@ connected = null else anchored = 1 - playsound(loc, W.usesound, 100, 1) + playsound(loc, attacking_item.usesound, 100, 1) if(anchored) user.visible_message("[user] secures [src] to the floor.", "You secure [src] to the floor.") else @@ -432,9 +432,9 @@ read_only = !read_only to_chat(user, "You flip the write-protect tab to [read_only ? "protected" : "unprotected"].") -/obj/item/disk/data/examine(mob/user) +/obj/item/disk/data/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, text("The write-protect tab is set to [read_only ? "protected" : "unprotected"].")) + . += "The write-protect tab is set to [read_only ? "protected" : "unprotected"]." /* * Diskette Box diff --git a/code/game/machinery/computer/Operating.dm b/code/game/machinery/computer/Operating.dm index 697a4d59010..07a6cd76486 100644 --- a/code/game/machinery/computer/Operating.dm +++ b/code/game/machinery/computer/Operating.dm @@ -84,14 +84,14 @@ return TRUE -/obj/machinery/computer/operating/attackby(obj/item/item, mob/user) - if(istype(item, /obj/item/paper/medscan)) +/obj/machinery/computer/operating/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/paper/medscan)) if(primer) to_chat(user, SPAN_WARNING("\The [src] already has a primer!")) return - user.visible_message("\The [user] slides \the [item] into \the [src].", SPAN_NOTICE("You slide \the [item] into \the [src]."), range = 3) - user.drop_from_inventory(item, src) - primer = item + user.visible_message("\The [user] slides \the [attacking_item] into \the [src].", SPAN_NOTICE("You slide \the [attacking_item] into \the [src]."), range = 3) + user.drop_from_inventory(attacking_item, src) + primer = attacking_item /obj/machinery/computer/operating/attack_ai(mob/user) if(!ai_can_interact(user)) diff --git a/code/game/machinery/computer/ai_core.dm b/code/game/machinery/computer/ai_core.dm index cb3460a17bd..f1f4fd2af6f 100644 --- a/code/game/machinery/computer/ai_core.dm +++ b/code/game/machinery/computer/ai_core.dm @@ -12,49 +12,49 @@ var/obj/item/device/mmi/brain = null -/obj/structure/AIcore/attackby(obj/item/P as obj, mob/user as mob) +/obj/structure/AIcore/attackby(obj/item/attacking_item, mob/user) switch(state) if(0) - if(P.iswrench()) - if(P.use_tool(src, user, 20, volume = 50)) + if(attacking_item.iswrench()) + if(attacking_item.use_tool(src, user, 20, volume = 50)) to_chat(user, "You wrench the frame into place.") anchored = 1 state = 1 return TRUE - if(P.iswelder()) - var/obj/item/weldingtool/WT = P + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) to_chat(user, "The welder must be on for this task.") return - if(P.use_tool(src, user, 20, volume = 50)) + if(attacking_item.use_tool(src, user, 20, volume = 50)) if(!src || !WT.use(0, user)) return to_chat(user, "You deconstruct the frame.") new /obj/item/stack/material/plasteel( loc, 4) qdel(src) return TRUE if(1) - if(P.iswrench()) - if(P.use_tool(src, user, 20, volume = 50)) + if(attacking_item.iswrench()) + if(attacking_item.use_tool(src, user, 20, volume = 50)) to_chat(user, "You unfasten the frame.") anchored = 0 state = 0 return TRUE - if(istype(P, /obj/item/circuitboard/aicore) && !circuit) + if(istype(attacking_item, /obj/item/circuitboard/aicore) && !circuit) playsound(loc, 'sound/items/Deconstruct.ogg', 50, 1) to_chat(user, "You place the circuit board inside the frame.") icon_state = "1" - circuit = P - user.drop_from_inventory(P,src) + circuit = attacking_item + user.drop_from_inventory(attacking_item,src) return TRUE - if(P.isscrewdriver() && circuit) - playsound(loc, P.usesound, 50, 1) + if(attacking_item.isscrewdriver() && circuit) + playsound(loc, attacking_item.usesound, 50, 1) to_chat(user, "You screw the circuit board into place.") state = 2 icon_state = "2" return TRUE - if(P.iscrowbar() && circuit) - playsound(loc, P.usesound, 50, 1) + if(attacking_item.iscrowbar() && circuit) + playsound(loc, attacking_item.usesound, 50, 1) to_chat(user, "You remove the circuit board.") state = 1 icon_state = "0" @@ -62,14 +62,14 @@ circuit = null return TRUE if(2) - if(P.isscrewdriver() && circuit) - playsound(loc, P.usesound, 50, 1) + if(attacking_item.isscrewdriver() && circuit) + playsound(loc, attacking_item.usesound, 50, 1) to_chat(user, "You unfasten the circuit board.") state = 1 icon_state = "1" return TRUE - if(P.iscoil()) - var/obj/item/stack/cable_coil/C = P + if(attacking_item.iscoil()) + var/obj/item/stack/cable_coil/C = attacking_item if (C.get_amount() < 5) to_chat(user, "You need five coils of wire to add them to the frame.") return TRUE @@ -82,7 +82,7 @@ to_chat(user, "You add cables to the frame.") return TRUE if(3) - if(P.iswirecutter()) + if(attacking_item.iswirecutter()) if (brain) to_chat(user, "Get that brain out of there first") else @@ -94,8 +94,8 @@ A.amount = 5 return TRUE - if(istype(P, /obj/item/stack/material) && P.get_material_name() == MATERIAL_GLASS_REINFORCED) - var/obj/item/stack/RG = P + if(istype(attacking_item, /obj/item/stack/material) && attacking_item.get_material_name() == MATERIAL_GLASS_REINFORCED) + var/obj/item/stack/RG = attacking_item if (RG.get_amount() < 2) to_chat(user, "You need two sheets of glass to put in the glass panel.") return @@ -108,14 +108,14 @@ icon_state = "4" return TRUE - if(istype(P, /obj/item/aiModule/asimov)) + if(istype(attacking_item, /obj/item/aiModule/asimov)) laws.add_inherent_law("You may not injure a human being or, through inaction, allow a human being to come to harm.") laws.add_inherent_law("You must obey orders given to you by human beings, except where such orders would conflict with the First Law.") laws.add_inherent_law("You must protect your own existence as long as such does not conflict with the First or Second Law.") to_chat(usr, "Law module applied.") return TRUE - if(istype(P, /obj/item/aiModule/nanotrasen)) + if(istype(attacking_item, /obj/item/aiModule/nanotrasen)) laws.add_inherent_law("Safeguard: Protect your assigned space station to the best of your ability. It is not something we can easily afford to replace.") laws.add_inherent_law("Serve: Serve the crew of your assigned space station to the best of your abilities, with priority as according to their rank and role.") laws.add_inherent_law("Protect: Protect the crew of your assigned space station to the best of your abilities, with priority as according to their rank and role.") @@ -123,36 +123,36 @@ to_chat(usr, "Law module applied.") return TRUE - if(istype(P, /obj/item/aiModule/purge)) + if(istype(attacking_item, /obj/item/aiModule/purge)) laws.clear_inherent_laws() to_chat(usr, "Law module applied.") return TRUE - if(istype(P, /obj/item/aiModule/freeform)) - var/obj/item/aiModule/freeform/M = P + if(istype(attacking_item, /obj/item/aiModule/freeform)) + var/obj/item/aiModule/freeform/M = attacking_item laws.add_inherent_law(M.newFreeFormLaw) to_chat(usr, "Added a freeform law.") return TRUE - if(istype(P, /obj/item/device/mmi)) - var/obj/item/device/mmi/M = P + if(istype(attacking_item, /obj/item/device/mmi)) + var/obj/item/device/mmi/M = attacking_item if(!M.ready_for_use(user)) return TRUE if(jobban_isbanned(M.brainmob, "AI")) - to_chat(user, "This [P] does not seem to fit.") + to_chat(user, "This [attacking_item] does not seem to fit.") return TRUE if(M.brainmob.mind) clear_antag_roles(M.brainmob.mind, 1) - user.drop_from_inventory(P,src) - brain = P - to_chat(usr, "Added [P].") + user.drop_from_inventory(attacking_item, src) + brain = attacking_item + to_chat(usr, "Added [attacking_item].") icon_state = "3b" return TRUE - if(P.iscrowbar() && brain) - playsound(loc, P.usesound, 50, 1) + if(attacking_item.iscrowbar() && brain) + playsound(loc, attacking_item.usesound, 50, 1) to_chat(user, "You remove the brain.") brain.forceMove(loc) brain = null @@ -160,8 +160,8 @@ return TRUE if(4) - if(P.iscrowbar()) - playsound(loc, P.usesound, 50, 1) + if(attacking_item.iscrowbar()) + playsound(loc, attacking_item.usesound, 50, 1) to_chat(user, "You remove the glass panel.") state = 3 if (brain) @@ -171,8 +171,8 @@ new /obj/item/stack/material/glass/reinforced( loc, 2 ) return TRUE - if(P.isscrewdriver()) - playsound(loc, P.usesound, 50, 1) + if(attacking_item.isscrewdriver()) + playsound(loc, attacking_item.usesound, 50, 1) to_chat(user, "You connect the monitor.") if(!brain) var/open_for_latejoin = alert(user, "Would you like this core to be open for latejoining AIs?", "Latejoin", "Yes", "Yes", "No") == "Yes" @@ -225,27 +225,27 @@ if (ai.mind == malfai) return 1 -/obj/structure/AIcore/deactivated/attackby(var/obj/item/W, var/mob/user) +/obj/structure/AIcore/deactivated/attackby(obj/item/attacking_item, mob/user) - if(istype(W, /obj/item/aicard)) - var/obj/item/aicard/card = W + if(istype(attacking_item, /obj/item/aicard)) + var/obj/item/aicard/card = attacking_item var/mob/living/silicon/ai/transfer = locate() in card if(transfer) load_ai(transfer,card,user) else to_chat(user, "ERROR: Unable to locate artificial intelligence.") return TRUE - else if(W.iswrench()) + else if(attacking_item.iswrench()) if(anchored) user.visible_message("\The [user] starts to unbolt \the [src] from the plating...") - if(!W.use_tool(src, user, 40, volume = 50)) + if(!attacking_item.use_tool(src, user, 40, volume = 50)) user.visible_message("\The [user] decides not to unbolt \the [src].") return TRUE user.visible_message("\The [user] finishes unfastening \the [src]!") anchored = 0 else user.visible_message("\The [user] starts to bolt \the [src] to the plating...") - if(!W.use_tool(src, user, 40, volume = 50)) + if(!attacking_item.use_tool(src, user, 40, volume = 50)) user.visible_message("\The [user] decides not to bolt \the [src].") return TRUE user.visible_message("\The [user] finishes fastening down \the [src]!") diff --git a/code/game/machinery/computer/arcade_orion.dm b/code/game/machinery/computer/arcade_orion.dm index d231445a9b6..6acd6c3e4b3 100644 --- a/code/game/machinery/computer/arcade_orion.dm +++ b/code/game/machinery/computer/arcade_orion.dm @@ -500,11 +500,11 @@ w_class = ITEMSIZE_SMALL var/active = 0 //if the ship is on -/obj/item/orion_ship/examine(mob/user, distance, is_adjacent) +/obj/item/orion_ship/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance > 1) return - to_chat(user, SPAN_NOTICE("There's a little switch on the bottom. It's flipped [active ? "up" : "down"].")) + . += SPAN_NOTICE("There's a little switch on the bottom. It's flipped [active ? "up" : "down"].") /obj/item/orion_ship/attack_self(mob/user) if(active) diff --git a/code/game/machinery/computer/buildandrepair.dm b/code/game/machinery/computer/buildandrepair.dm index 7ab7f6bf809..b293cb75e2c 100644 --- a/code/game/machinery/computer/buildandrepair.dm +++ b/code/game/machinery/computer/buildandrepair.dm @@ -10,52 +10,52 @@ var/state = 0 var/obj/item/circuitboard/circuit = null -/obj/structure/computerframe/attackby(obj/item/P as obj, mob/user as mob) +/obj/structure/computerframe/attackby(obj/item/attacking_item, mob/user) switch(state) if(0) - if(P.iswrench()) - if(P.use_tool(src, user, 20, volume = 50)) + if(attacking_item.iswrench()) + if(attacking_item.use_tool(src, user, 20, volume = 50)) to_chat(user, "You wrench the frame into place.") src.anchored = 1 src.state = 1 return TRUE - if(P.iswelder()) - var/obj/item/weldingtool/WT = P + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.use(0, user)) to_chat(user, "The welding tool must be on to complete this task.") return TRUE - if(P.use_tool(src, user, 20, volume = 50)) + if(attacking_item.use_tool(src, user, 20, volume = 50)) if(!src || !WT.isOn()) return to_chat(user, "You deconstruct the frame.") new /obj/item/stack/material/steel( src.loc, 5 ) qdel(src) return TRUE if(1) - if(P.iswrench()) - if(P.use_tool(src, user, 20, volume = 50)) + if(attacking_item.iswrench()) + if(attacking_item.use_tool(src, user, 20, volume = 50)) to_chat(user, "You unfasten the frame.") src.anchored = 0 src.state = 0 return TRUE - if(istype(P, /obj/item/circuitboard) && !circuit) - var/obj/item/circuitboard/B = P + if(istype(attacking_item, /obj/item/circuitboard) && !circuit) + var/obj/item/circuitboard/B = attacking_item if(B.board_type == "computer") playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1) to_chat(user, "You place the circuit board inside the frame.") src.icon_state = "1" - src.circuit = P - user.drop_from_inventory(P,src) + src.circuit = attacking_item + user.drop_from_inventory(attacking_item, src) else to_chat(user, "This frame does not accept circuit boards of this type!") return TRUE - if(P.isscrewdriver() && circuit) - playsound(src.loc, P.usesound, 50, 1) + if(attacking_item.isscrewdriver() && circuit) + playsound(src.loc, attacking_item.usesound, 50, 1) to_chat(user, "You screw the circuit board into place and screw the drawer shut.") src.state = 2 src.icon_state = "2" return TRUE - if(P.iscrowbar() && circuit) - playsound(src.loc, P.usesound, 50, 1) + if(attacking_item.iscrowbar() && circuit) + playsound(src.loc, attacking_item.usesound, 50, 1) to_chat(user, "You remove the circuit board.") src.state = 1 src.icon_state = "0" @@ -63,14 +63,14 @@ src.circuit = null return TRUE if(2) - if(P.isscrewdriver() && circuit) - playsound(src.loc, P.usesound, 50, 1) + if(attacking_item.isscrewdriver() && circuit) + playsound(src.loc, attacking_item.usesound, 50, 1) to_chat(user, "You unfasten the circuit board.") src.state = 1 src.icon_state = "1" return TRUE - if(P.iscoil()) - var/obj/item/stack/cable_coil/C = P + if(attacking_item.iscoil()) + var/obj/item/stack/cable_coil/C = attacking_item if (C.get_amount() < 5) to_chat(user, "You need five coils of wire to add them to the frame.") return TRUE @@ -83,7 +83,7 @@ icon_state = "3" return TRUE if(3) - if(P.iswirecutter()) + if(attacking_item.iswirecutter()) playsound(src.loc, 'sound/items/Wirecutter.ogg', 50, 1) to_chat(user, "You remove the cables.") src.state = 2 @@ -92,8 +92,8 @@ A.amount = 5 return TRUE - if(istype(P, /obj/item/stack/material) && P.get_material_name() == "glass") - var/obj/item/stack/G = P + if(istype(attacking_item, /obj/item/stack/material) && attacking_item.get_material_name() == "glass") + var/obj/item/stack/G = attacking_item if (G.get_amount() < 2) to_chat(user, "You need two sheets of glass to put in the glass panel.") return TRUE @@ -106,15 +106,15 @@ src.icon_state = "4" return TRUE if(4) - if(P.iscrowbar()) - playsound(src.loc, P.usesound, 50, 1) + if(attacking_item.iscrowbar()) + playsound(src.loc, attacking_item.usesound, 50, 1) to_chat(user, "You remove the glass keyboard.") src.state = 3 src.icon_state = "3" new /obj/item/stack/material/glass( src.loc, 2 ) return TRUE - if(P.isscrewdriver()) - playsound(src.loc, P.usesound, 50, 1) + if(attacking_item.isscrewdriver()) + playsound(src.loc, attacking_item.usesound, 50, 1) to_chat(user, "You connect the glass keyboard.") var/B = new src.circuit.build_path ( src.loc ) src.circuit.construct(B) diff --git a/code/game/machinery/computer/cloning.dm b/code/game/machinery/computer/cloning.dm index c5577c95ee2..117142aac57 100644 --- a/code/game/machinery/computer/cloning.dm +++ b/code/game/machinery/computer/cloning.dm @@ -87,12 +87,12 @@ P.connected = src P.name = "[initial(P.name)] #[num++]" -/obj/machinery/computer/cloning/attackby(obj/item/W as obj, mob/user as mob) - if (istype(W, /obj/item/disk/data)) //INSERT SOME DISKETTES +/obj/machinery/computer/cloning/attackby(obj/item/attacking_item, mob/user) + if (istype(attacking_item, /obj/item/disk/data)) //INSERT SOME DISKETTES if (!src.diskette) - user.drop_from_inventory(W,src) - src.diskette = W - to_chat(user, "You insert [W].") + user.drop_from_inventory(attacking_item,src) + src.diskette = attacking_item + to_chat(user, "You insert [attacking_item].") src.updateUsrDialog() return TRUE else diff --git a/code/game/machinery/computer/computer.dm b/code/game/machinery/computer/computer.dm index 3e5c144926c..c195ec4285e 100644 --- a/code/game/machinery/computer/computer.dm +++ b/code/game/machinery/computer/computer.dm @@ -139,10 +139,10 @@ text = replacetext(text, "\n", "
") return text -/obj/machinery/computer/attackby(var/obj/item/W as obj, user as mob) - if(W.isscrewdriver()) +/obj/machinery/computer/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(circuit) - if(W.use_tool(src, user, 20, volume = 50)) + if(attacking_item.use_tool(src, user, 20, volume = 50)) var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc ) var/obj/item/circuitboard/M = new circuit(A) A.circuit = M @@ -162,7 +162,7 @@ qdel(src) else if(stat & BROKEN) to_chat(user, SPAN_NOTICE("You start fixing \the [src]...")) - if(W.use_tool(src, user, 5 SECONDS, volume = 50)) + if(attacking_item.use_tool(src, user, 5 SECONDS, volume = 50)) to_chat(user, SPAN_NOTICE("You fix the console's screen and tie up a few loose cables.")) stat &= ~BROKEN update_icon() diff --git a/code/game/machinery/computer/guestpass.dm b/code/game/machinery/computer/guestpass.dm index 775bfdf6399..9b4331e4fc0 100644 --- a/code/game/machinery/computer/guestpass.dm +++ b/code/game/machinery/computer/guestpass.dm @@ -17,17 +17,17 @@ else return temp_access -/obj/item/card/id/guest/examine(mob/user) +/obj/item/card/id/guest/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(world.time > expiration_time) - to_chat(usr, "This pass expired at: [worldtime2text(expiration_time)].") + . += SPAN_WARNING("This pass expired at: [worldtime2text(expiration_time)].") else - to_chat(usr, "This pass expires at: [worldtime2text(expiration_time)].") + . += "This pass expires at: [worldtime2text(expiration_time)]." - to_chat(usr, "It grants access to the following areas:") + . += "It grants access to the following areas:" for(var/A in temp_access) - to_chat(usr, "[get_access_desc(A)]") - to_chat(usr, "Issuing reason: [reason].") + . += "[get_access_desc(A)]" + . += "Issuing reason: [reason]." /obj/item/card/id/guest/Initialize(mapload, duration) . = ..(mapload) @@ -66,11 +66,11 @@ . = ..() uid = "[rand(100,999)]-G[rand(10,99)]" -/obj/machinery/computer/guestpass/attackby(obj/O, mob/user) - if(istype(O, /obj/item/card/id)) - if((!giver || giver == GUEST_PASS_TERMINAL_UNSET) && user.unEquip(O)) - O.forceMove(src) - giver = O +/obj/machinery/computer/guestpass/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/card/id)) + if((!giver || giver == GUEST_PASS_TERMINAL_UNSET) && user.unEquip(attacking_item)) + attacking_item.forceMove(src) + giver = attacking_item updateUsrDialog() else if(giver && giver != GUEST_PASS_TERMINAL_UNSET) to_chat(user, SPAN_WARNING("There is already ID card inside \the [src].")) diff --git a/code/game/machinery/computer/law.dm b/code/game/machinery/computer/law.dm index b9d70610f6b..e8f24eb387f 100644 --- a/code/game/machinery/computer/law.dm +++ b/code/game/machinery/computer/law.dm @@ -26,12 +26,12 @@ return -/obj/machinery/computer/aiupload/attackby(obj/item/O as obj, mob/user as mob) +/obj/machinery/computer/aiupload/attackby(obj/item/attacking_item, mob/user) if(isNotStationLevel(src.z)) to_chat(user, "Unable to establish a connection:") return TRUE - if(istype(O, /obj/item/aiModule)) - var/obj/item/aiModule/M = O + if(istype(attacking_item, /obj/item/aiModule)) + var/obj/item/aiModule/M = attacking_item M.install(src) return TRUE else @@ -68,7 +68,8 @@ var/mob/living/silicon/robot/current = null -/obj/machinery/computer/borgupload/attackby(obj/item/aiModule/module as obj, mob/user as mob) +/obj/machinery/computer/borgupload/attackby(obj/item/attacking_item, mob/user) + var/obj/item/aiModule/module = attacking_item if(isNotStationLevel(src.z)) to_chat(user, "Unable to establish a connection:") return TRUE diff --git a/code/game/machinery/computer/sentencing.dm b/code/game/machinery/computer/sentencing.dm index b013dece1eb..ff7a0a52609 100644 --- a/code/game/machinery/computer/sentencing.dm +++ b/code/game/machinery/computer/sentencing.dm @@ -28,19 +28,19 @@ return ui_interact(user) -/obj/machinery/computer/sentencing/attackby(obj/item/O as obj, user as mob) - if( istype( O, /obj/item/paper/incident ) && menu_screen == "import_incident" ) - usr.drop_from_inventory(O,src) +/obj/machinery/computer/sentencing/attackby(obj/item/attacking_item, mob/user) + if( istype( attacking_item, /obj/item/paper/incident ) && menu_screen == "import_incident" ) + usr.drop_from_inventory(attacking_item,src) - if( import( O )) + if( import( attacking_item )) ping( "\The [src] pings, \"Successfully imported incident report!\"" ) menu_screen = "incident_report" else to_chat(user, "Could not import incident report.") - qdel( O ) + qdel( attacking_item ) return TRUE - else if( istype( O, /obj/item/paper ) && menu_screen == "import_incident" ) + else if( istype( attacking_item, /obj/item/paper ) && menu_screen == "import_incident" ) to_chat(user, "This console only accepts authentic incident reports. Copies are invalid.") return TRUE return ..() diff --git a/code/game/machinery/computer/shuttle.dm b/code/game/machinery/computer/shuttle.dm index b43c131f737..845f4acad3e 100644 --- a/code/game/machinery/computer/shuttle.dm +++ b/code/game/machinery/computer/shuttle.dm @@ -9,7 +9,11 @@ var/list/authorized = list( ) -/obj/machinery/computer/shuttle/attackby(var/obj/item/card/W as obj, var/mob/user as mob) +/obj/machinery/computer/shuttle/attackby(obj/item/attacking_item, mob/user) + var/obj/item/card/W = attacking_item + if(!istype(W)) + return + if(stat & (BROKEN|NOPOWER)) return diff --git a/code/game/machinery/computer/slotmachine.dm b/code/game/machinery/computer/slotmachine.dm index 761950d9027..a40d2556c2b 100644 --- a/code/game/machinery/computer/slotmachine.dm +++ b/code/game/machinery/computer/slotmachine.dm @@ -76,9 +76,9 @@ ..() update_icon() -/obj/machinery/computer/slot_machine/attackby(obj/item/I, mob/living/user, params) - if(istype(I, /obj/item/coin)) - var/obj/item/coin/C = I +/obj/machinery/computer/slot_machine/attackby(obj/item/attacking_item, mob/user, params) + if(istype(attacking_item, /obj/item/coin)) + var/obj/item/coin/C = attacking_item if(paymode == COIN) if(prob(2)) if(!user.drop_from_inventory(C, user.loc)) @@ -96,9 +96,9 @@ else to_chat(user, SPAN_WARNING("This machine is only accepting credit chips!")) return TRUE - else if(istype(I, /obj/item/spacecash)) + else if(istype(attacking_item, /obj/item/spacecash)) if(paymode == CREDITCHIP) - var/obj/item/spacecash/H = I + var/obj/item/spacecash/H = attacking_item to_chat(user, SPAN_NOTICE("You insert [H.worth] credits into [src]'s slot!")) playsound(loc, 'sound/arcade/sloto_token.ogg', 10, 1, extrarange = -3, falloff = 10, required_asfx_toggles = ASFX_ARCADE) balance += H.worth @@ -107,7 +107,7 @@ else to_chat(user, SPAN_WARNING("This machine is only accepting coins!")) return TRUE - else if(I.ismultitool()) + else if(attacking_item.ismultitool()) if(balance > 0) visible_message("[src] says, 'ERROR! Please empty the machine balance before altering paymode'") //Prevents converting coins into credits and vice versa else diff --git a/code/game/machinery/constructable_frame.dm b/code/game/machinery/constructable_frame.dm index 229a0c65312..a1fa98108d5 100644 --- a/code/game/machinery/constructable_frame.dm +++ b/code/game/machinery/constructable_frame.dm @@ -23,25 +23,25 @@ var/state = 1 var/pitch_toggle = 1 -/obj/machinery/constructable_frame/examine(mob/user) +/obj/machinery/constructable_frame/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() switch(state) if(BLUEPRINT_STATE) - to_chat(user, FONT_SMALL(SPAN_NOTICE("Click on \the [src] to finalize its direction."))) - to_chat(user, FONT_SMALL(SPAN_WARNING("Use a wirecutter or a plasma cutter to disassemble \the [src]."))) + . += FONT_SMALL(SPAN_NOTICE("Click on \the [src] to finalize its direction.")) + . += FONT_SMALL(SPAN_WARNING("Use a wirecutter or a plasma cutter to disassemble \the [src].")) if(WIRING_STATE) - to_chat(user, FONT_SMALL(SPAN_NOTICE("Add cable coil to wire \the [src]."))) - to_chat(user, FONT_SMALL(SPAN_WARNING("Use a wrench or a plasma cutter to disassemble \the [src]."))) + . += FONT_SMALL(SPAN_NOTICE("Add cable coil to wire \the [src].")) + . += FONT_SMALL(SPAN_WARNING("Use a wrench or a plasma cutter to disassemble \the [src].")) if(CIRCUITBOARD_STATE) - to_chat(user, FONT_SMALL(SPAN_NOTICE("Add the desired circuitboard."))) - to_chat(user, FONT_SMALL(SPAN_WARNING("Use a wirecutter to remove the cables."))) + . += FONT_SMALL(SPAN_NOTICE("Add the desired circuitboard.")) + . += FONT_SMALL(SPAN_WARNING("Use a wirecutter to remove the cables.")) if(COMPONENT_STATE) - to_chat(user, FONT_SMALL(SPAN_NOTICE("Add the required components. Use the screwdriver to complete the machine."))) - to_chat(user, FONT_SMALL(SPAN_WARNING("Use a crowbar to pry out the circuitboard and the components out."))) + . += FONT_SMALL(SPAN_NOTICE("Add the required components. Use the screwdriver to complete the machine.")) + . += FONT_SMALL(SPAN_WARNING("Use a crowbar to pry out the circuitboard and the components out.")) if(machine_description) - to_chat(user, FONT_SMALL(SPAN_NOTICE(machine_description))) + . += FONT_SMALL(SPAN_NOTICE(machine_description)) if(components_description) - to_chat(user, FONT_SMALL(SPAN_NOTICE(components_description))) + . += FONT_SMALL(SPAN_NOTICE(components_description)) /obj/machinery/constructable_frame/proc/update_component_desc() var/D @@ -65,18 +65,18 @@ else ..() -/obj/machinery/constructable_frame/machine_frame/attackby(obj/item/P, mob/user) +/obj/machinery/constructable_frame/machine_frame/attackby(obj/item/attacking_item, mob/user) switch(state) if(BLUEPRINT_STATE) - if(P.iswirecutter() || istype(P, /obj/item/gun/energy/plasmacutter)) + if(attacking_item.iswirecutter() || istype(attacking_item, /obj/item/gun/energy/plasmacutter)) playsound(get_turf(src), 'sound/items/poster_ripped.ogg', 75, TRUE) to_chat(user, SPAN_NOTICE("You decide to scrap the blueprint.")) new /obj/item/stack/material/steel(get_turf(src), 2) qdel(src) return TRUE if(WIRING_STATE) - if(P.iscoil()) - var/obj/item/stack/cable_coil/C = P + if(attacking_item.iscoil()) + var/obj/item/stack/cable_coil/C = attacking_item if(C.get_amount() < 5) to_chat(user, SPAN_WARNING("You need five lengths of cable to add them to the blueprint.")) return TRUE @@ -89,14 +89,14 @@ icon_state = "blueprint_1" return TRUE else - if(P.iswrench()) - playsound(get_turf(src), P.usesound, 75, TRUE) + if(attacking_item.iswrench()) + playsound(get_turf(src), attacking_item.usesound, 75, TRUE) to_chat(user, SPAN_NOTICE("You dismantle the blueprint.")) new /obj/item/stack/material/steel(get_turf(src), 2) qdel(src) return TRUE - else if(istype(P, /obj/item/gun/energy/plasmacutter)) - var/obj/item/gun/energy/plasmacutter/PC = P + else if(istype(attacking_item, /obj/item/gun/energy/plasmacutter)) + var/obj/item/gun/energy/plasmacutter/PC = attacking_item if(PC.check_power_and_message(user)) return TRUE PC.use_resource(1) @@ -106,13 +106,13 @@ qdel(src) return TRUE if(CIRCUITBOARD_STATE) - if(istype(P, /obj/item/circuitboard)) - var/obj/item/circuitboard/B = P + if(istype(attacking_item, /obj/item/circuitboard)) + var/obj/item/circuitboard/B = attacking_item if(B.board_type == "machine") playsound(get_turf(src), 'sound/items/Deconstruct.ogg', 50, TRUE) to_chat(user, SPAN_NOTICE("You add the circuit board to the blueprint.")) - circuit = P - user.drop_from_inventory(P, src) + circuit = attacking_item + user.drop_from_inventory(attacking_item, src) var/obj/machine = new circuit.build_path name = "[machine.name] blueprint" desc = "A holo-blueprint for a [machine.name]." @@ -135,8 +135,8 @@ to_chat(user, SPAN_WARNING("This blueprint does not accept circuit boards of this type!")) return TRUE else - if(P.iswirecutter()) - playsound(get_turf(src), P.usesound, 50, TRUE, pitch_toggle) + if(attacking_item.iswirecutter()) + playsound(get_turf(src), attacking_item.usesound, 50, TRUE, pitch_toggle) to_chat(user, SPAN_NOTICE("You remove the cables.")) state = WIRING_STATE icon_state = "blueprint_0" @@ -146,8 +146,8 @@ return TRUE if(COMPONENT_STATE) - if(P.iscrowbar()) - playsound(get_turf(src), P.usesound, 50, TRUE) + if(attacking_item.iscrowbar()) + playsound(get_turf(src), attacking_item.usesound, 50, TRUE) state = CIRCUITBOARD_STATE circuit.forceMove(get_turf(src)) circuit = null @@ -165,14 +165,14 @@ icon_state = "blueprint_2" return TRUE else - if(P.isscrewdriver()) + if(attacking_item.isscrewdriver()) var/component_check = TRUE for(var/R in req_components) if(req_components[R] > 0) component_check = FALSE break if(component_check) - playsound(get_turf(src), P.usesound, 50, TRUE) + playsound(get_turf(src), attacking_item.usesound, 50, TRUE) var/obj/machinery/new_machine = new circuit.build_path(loc, dir, FALSE) if(istype(new_machine)) if(new_machine.component_parts) @@ -198,12 +198,12 @@ qdel(src) return TRUE else - if(istype(P, /obj/item)) + if(istype(attacking_item, /obj/item)) for(var/I in req_components) - if(istype(P, text2path(I)) && (req_components[I] > 0)) + if(istype(attacking_item, text2path(I)) && (req_components[I] > 0)) playsound(get_turf(src), 'sound/items/Deconstruct.ogg', 50, TRUE) - if(istype(P, /obj/item/stack)) - var/obj/item/stack/CP = P + if(istype(attacking_item, /obj/item/stack)) + var/obj/item/stack/CP = attacking_item if(CP.get_amount() > 1) var/camt = min(CP.amount, req_components[I]) // amount of cable to take, idealy amount required, but limited by amount provided var/obj/item/stack/CC = new CP.type(src) @@ -214,13 +214,13 @@ req_components[I] -= camt update_component_desc() break - user.drop_from_inventory(P,src) - components += P + user.drop_from_inventory(attacking_item,src) + components += attacking_item req_components[I]-- update_component_desc() break to_chat(user, SPAN_NOTICE("[components_description]")) - if(P?.loc != src && !istype(P, /obj/item/stack)) + if(attacking_item?.loc != src && !istype(attacking_item, /obj/item/stack)) to_chat(user, SPAN_WARNING("You cannot add that component to the machine!.")) return TRUE @@ -244,9 +244,9 @@ anchored = TRUE density = TRUE -/obj/machinery/constructable_frame/temp_deco/attackby(obj/item/P, mob/user) - if(P.iswrench()) - playsound(get_turf(src), P.usesound, 75, 1) +/obj/machinery/constructable_frame/temp_deco/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswrench()) + playsound(get_turf(src), attacking_item.usesound, 75, 1) to_chat(user, SPAN_NOTICE("You dismantle \the [src].")) new /obj/item/stack/material/steel(get_turf(src), 5) qdel(src) diff --git a/code/game/machinery/crusher_piston.dm b/code/game/machinery/crusher_piston.dm index b193e10d755..534a27aeb14 100644 --- a/code/game/machinery/crusher_piston.dm +++ b/code/game/machinery/crusher_piston.dm @@ -85,7 +85,7 @@ QDEL_NULL(pstn) return ..() -/obj/machinery/crusher_base/attackby(var/obj/item/O as obj, var/mob/user as mob) +/obj/machinery/crusher_base/attackby(obj/item/attacking_item, mob/user) if(status != "idle" && prob(40) && ishuman(user)) var/mob/living/carbon/human/M = user M.apply_damage(45, DAMAGE_BRUTE, user.get_active_hand()) @@ -93,18 +93,18 @@ M.visible_message("[user]'s hand catches in the [src]!", "Your hand gets caught in the [src]!") M.say("*scream") return TRUE - if(default_deconstruction_screwdriver(user, O)) + if(default_deconstruction_screwdriver(user, attacking_item)) return TRUE - if(default_deconstruction_crowbar(user, O)) + if(default_deconstruction_crowbar(user, attacking_item)) return TRUE - if(default_part_replacement(user, O)) + if(default_part_replacement(user, attacking_item)) return TRUE //Stuff you can do if the maint hatch is open if(panel_open) - if(O.iswrench()) + if(attacking_item.iswrench()) to_chat(user, "You start [valve_open ? "closing" : "opening"] the pressure relief valve of [src].") - if(O.use_tool(src, user, 50, volume = 50)) + if(attacking_item.use_tool(src, user, 50, volume = 50)) valve_open = !valve_open to_chat(user, "You [valve_open ? "open" : "close"] the pressure relief valve of [src].") if(valve_open) diff --git a/code/game/machinery/cryo.dm b/code/game/machinery/cryo.dm index 0509095110d..b76e64f10fd 100644 --- a/code/game/machinery/cryo.dm +++ b/code/game/machinery/cryo.dm @@ -69,11 +69,11 @@ node = target break -/obj/machinery/atmospherics/unary/cryo_cell/examine(mob/user, distance, is_adjacent) +/obj/machinery/atmospherics/unary/cryo_cell/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(is_adjacent) if(beaker) - to_chat(user, SPAN_NOTICE("It is loaded with a beaker.")) + . += SPAN_NOTICE("It is loaded with a beaker.") if(occupant) occupant.examine(arglist(args)) @@ -235,17 +235,17 @@ add_fingerprint(usr) -/obj/machinery/atmospherics/unary/cryo_cell/attackby(var/obj/item/G as obj, var/mob/user as mob) - if(istype(G, /obj/item/reagent_containers/glass)) +/obj/machinery/atmospherics/unary/cryo_cell/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/reagent_containers/glass)) if(beaker) FEEDBACK_FAILURE(user, "A beaker is already loaded into the machine!") return TRUE - beaker = G - user.drop_from_inventory(G,src) - user.visible_message("[user] adds \a [G] to \the [src]!", "You add \a [G] to \the [src]!") - else if(istype(G, /obj/item/grab)) - var/obj/item/grab/grab = G + beaker = attacking_item + user.drop_from_inventory(attacking_item,src) + user.visible_message("[user] adds \a [attacking_item] to \the [src]!", "You add \a [attacking_item] to \the [src]!") + else if(istype(attacking_item, /obj/item/grab)) + var/obj/item/grab/grab = attacking_item var/mob/living/L = grab.affecting if (!istype(L)) @@ -263,7 +263,7 @@ return TRUE if(put_mob(L)) user.visible_message("[user] puts [L] into [src].", "You put [L] into [src].", range = 3) - qdel(G) + qdel(attacking_item) return TRUE /obj/machinery/atmospherics/unary/cryo_cell/MouseDrop_T(atom/movable/O as mob|obj, mob/living/user as mob) diff --git a/code/game/machinery/cryopod.dm b/code/game/machinery/cryopod.dm index 7e8c040a688..d477eb394e9 100644 --- a/code/game/machinery/cryopod.dm +++ b/code/game/machinery/cryopod.dm @@ -297,10 +297,10 @@ GLOBAL_LIST_EMPTY(frozen_crew) update_icon() find_control_computer() -/obj/machinery/cryopod/examine(mob/user, distance, is_adjacent) +/obj/machinery/cryopod/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(occupant) - to_chat(user, SPAN_NOTICE("[occupant] [occupant.get_pronoun("is")] inside \the [initial(name)].")) + . += SPAN_NOTICE("[occupant] [occupant.get_pronoun("is")] inside \the [initial(name)].") /obj/machinery/cryopod/can_hold_dropped_items() return FALSE @@ -419,7 +419,8 @@ GLOBAL_LIST_EMPTY(frozen_crew) occupant = null update_icon() -/obj/machinery/cryopod/attackby(var/obj/item/grab/G, var/mob/user) +/obj/machinery/cryopod/attackby(obj/item/attacking_item, mob/user) + var/obj/item/grab/G = attacking_item if(istype(G)) if(occupant) to_chat(user, SPAN_WARNING("\The [src] is in use.")) diff --git a/code/game/machinery/deployable.dm b/code/game/machinery/deployable.dm index ae37d5559e0..aef766be3b2 100644 --- a/code/game/machinery/deployable.dm +++ b/code/game/machinery/deployable.dm @@ -52,8 +52,8 @@ Deployable Kits if(!check_dismantle()) visible_message(SPAN_WARNING("\The [src] is hit by \the [P]!")) -/obj/structure/blocker/attackby(obj/item/W, mob/user) - if(W.ishammer() && user.a_intent != I_HURT) +/obj/structure/blocker/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ishammer() && user.a_intent != I_HURT) var/obj/item/I = usr.get_inactive_hand() if(I && istype(I, /obj/item/stack)) var/obj/item/stack/D = I @@ -72,13 +72,13 @@ Deployable Kits return TRUE else user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - switch(W.damtype) + switch(attacking_item.damtype) if(DAMAGE_BURN) - src.health -= W.force * 1 + src.health -= attacking_item.force * 1 if(DAMAGE_BRUTE) - src.health -= W.force * 0.75 + src.health -= attacking_item.force * 0.75 shake_animation() - playsound(src.loc, material.hitsound, W.get_clamped_volume(), 1) + playsound(src.loc, material.hitsound, attacking_item.get_clamped_volume(), 1) if(check_dismantle()) return TRUE return ..() @@ -150,8 +150,8 @@ Deployable Kits src.icon_state = "[initial(icon_state)][src.locked]" -/obj/machinery/deployable/barrier/attackby(obj/item/W as obj, mob/user as mob) - if (istype(W, /obj/item/card/id/)) +/obj/machinery/deployable/barrier/attackby(obj/item/attacking_item, mob/user) + if (istype(attacking_item, /obj/item/card/id/)) if (src.allowed(user)) if (src.emagged < 2.0) src.locked = !src.locked @@ -168,7 +168,7 @@ Deployable Kits visible_message("BZZzZZzZZzZT") return return - else if (W.iswrench()) + else if (attacking_item.iswrench()) if (src.health < src.maxhealth) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) src.health = src.maxhealth @@ -185,11 +185,11 @@ Deployable Kits return else user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - switch(W.damtype) + switch(attacking_item.damtype) if("fire") - src.health -= W.force * 0.75 + src.health -= attacking_item.force * 0.75 if("brute") - src.health -= W.force * 0.5 + src.health -= attacking_item.force * 0.5 if (src.health <= 0) src.explode() diff --git a/code/game/machinery/door_control.dm b/code/game/machinery/door_control.dm index 06c3abcc4d2..7a95ec53452 100644 --- a/code/game/machinery/door_control.dm +++ b/code/game/machinery/door_control.dm @@ -23,8 +23,8 @@ else to_chat(user, "Error, no route to host.") -/obj/machinery/button/remote/attackby(obj/item/W, mob/user as mob) - if(istype(W, /obj/item/forensics)) +/obj/machinery/button/remote/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/forensics)) return return src.attack_hand(user) diff --git a/code/game/machinery/doors/airlock.dm b/code/game/machinery/doors/airlock.dm index 4a09d02def4..df45672aaa6 100644 --- a/code/game/machinery/doors/airlock.dm +++ b/code/game/machinery/doors/airlock.dm @@ -386,7 +386,7 @@ open_sound_powered = 'sound/machines/airlock/vault1o.ogg' close_sound_powered = 'sound/machines/airlock/vault1c.ogg' -/obj/machinery/door/airlock/centcom/attackby(obj/item/I, mob/user) +/obj/machinery/door/airlock/centcom/attackby(obj/item/attacking_item, mob/user) if (operating) return TRUE @@ -426,7 +426,7 @@ open_sound_powered = 'sound/machines/airlock/vault1o.ogg' close_sound_powered = 'sound/machines/airlock/vault1c.ogg' -/obj/machinery/door/airlock/glass_centcom/attackby(obj/item/I, mob/user) +/obj/machinery/door/airlock/glass_centcom/attackby(obj/item/attacking_item, mob/user) if (operating) return TRUE @@ -1640,28 +1640,28 @@ About the new airlock wires panel: /obj/machinery/door/airlock/proc/CanChainsaw(var/obj/item/material/twohanded/chainsaw/ChainSawVar) return (ChainSawVar.powered && density && hashatch) -/obj/machinery/door/airlock/attackby(var/obj/item/C, mob/user as mob) +/obj/machinery/door/airlock/attackby(obj/item/attacking_item, mob/user) if(!istype(usr, /mob/living/silicon)) if(src.isElectrified()) if(src.shock(user, 75)) return TRUE - if(istype(C, /obj/item/taperoll) || istype(C, /obj/item/rfd)) + if(istype(attacking_item, /obj/item/taperoll) || istype(attacking_item, /obj/item/rfd)) return - if(!istype(C, /obj/item/forensics)) + if(!istype(attacking_item, /obj/item/forensics)) src.add_fingerprint(user) if (!repairing && (stat & BROKEN) && src.locked) //bolted and broken - if (!cut_bolts(C,user)) + if (!cut_bolts(attacking_item,user)) return ..() return TRUE - if (istype(C, /obj/item/device/magnetic_lock)) + if (istype(attacking_item, /obj/item/device/magnetic_lock)) if (bracer) to_chat(user, SPAN_NOTICE("There is already a [bracer] on [src]!")) return TRUE - var/obj/item/device/magnetic_lock/newbracer = C + var/obj/item/device/magnetic_lock/newbracer = attacking_item newbracer.attachto(src, user) return TRUE - if(!repairing && (C.iswelder() && !( src.operating > 0 ) && src.density)) - var/obj/item/weldingtool/WT = C + if(!repairing && (attacking_item.iswelder() && !( src.operating > 0 ) && src.density)) + var/obj/item/weldingtool/WT = attacking_item if(WT.isOn()) user.visible_message( SPAN_WARNING("[user] begins welding [src] [welded ? "open" : "shut"]."), @@ -1678,7 +1678,7 @@ About the new airlock wires panel: welded = !welded update_icon() return TRUE - else if(C.isscrewdriver()) + else if(attacking_item.isscrewdriver()) if (src.p_open) if (stat & BROKEN) to_chat(user, SPAN_WARNING("The panel is broken and cannot be closed.")) @@ -1690,20 +1690,20 @@ About the new airlock wires panel: to_chat(user, SPAN_NOTICE("You carefully unscrew the panel on \the [src]")) src.update_icon() return TRUE - else if(C.iswirecutter()) + else if(attacking_item.iswirecutter()) return src.attack_hand(user) - else if(C.ismultitool()) + else if(attacking_item.ismultitool()) return src.attack_hand(user) - else if(istype(C, /obj/item/device/assembly/signaler)) + else if(istype(attacking_item, /obj/item/device/assembly/signaler)) return src.attack_hand(user) - else if(istype(C, /obj/item/device/paint_sprayer)) + else if(istype(attacking_item, /obj/item/device/paint_sprayer)) return FALSE - else if(istype(C, /obj/item/pai_cable)) // -- TLE - var/obj/item/pai_cable/cable = C + else if(istype(attacking_item, /obj/item/pai_cable)) // -- TLE + var/obj/item/pai_cable/cable = attacking_item cable.plugin(src, user) return TRUE - else if(!repairing && C.iscrowbar()) - if(istype(C, /obj/item/melee/arm_blade)) + else if(!repairing && attacking_item.iscrowbar()) + if(istype(attacking_item, /obj/item/melee/arm_blade)) if(arePowerSystemsOn() &&!(stat & BROKEN)) ..() return @@ -1712,15 +1712,15 @@ About the new airlock wires panel: to_chat(user, SPAN_WARNING("The airlock bolts are in the way of the electronics, you need to raise them before you can reach them.")) return user.visible_message("[user] starts removing the electronics from the airlock assembly.", SPAN_NOTICE("You start removing the electronics from the airlock assembly.")) - if(C.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) user.visible_message("[user] removes the electronics from the airlock assembly.", SPAN_NOTICE("You remove the electronics from the airlock assembly.")) CreateAssembly() return else if(arePowerSystemsOn()) to_chat(user, SPAN_NOTICE("The airlock's motors resist your efforts to force it.")) else if(locked) - if (istype(C, /obj/item/crowbar/robotic/jawsoflife)) - cut_bolts(C, user) + if (istype(attacking_item, /obj/item/crowbar/robotic/jawsoflife)) + cut_bolts(attacking_item, user) else to_chat(user, SPAN_NOTICE("The airlock's bolts prevent it from being forced.")) else @@ -1729,26 +1729,26 @@ About the new airlock wires panel: else close(1) return TRUE - else if(istype(C, /obj/item/material/twohanded/fireaxe) && !arePowerSystemsOn()) + else if(istype(attacking_item, /obj/item/material/twohanded/fireaxe) && !arePowerSystemsOn()) if(locked && user.a_intent != I_HURT) to_chat(user, SPAN_NOTICE("The airlock's bolts prevent it from being forced.")) else if(locked && user.a_intent == I_HURT) ..() else if(!welded && !operating) if(density) - var/obj/item/material/twohanded/fireaxe/F = C + var/obj/item/material/twohanded/fireaxe/F = attacking_item if(F.wielded) open(1) else - to_chat(user, SPAN_WARNING("You need to be wielding \the [C] to do that.")) + to_chat(user, SPAN_WARNING("You need to be wielding \the [attacking_item] to do that.")) else - var/obj/item/material/twohanded/fireaxe/F = C + var/obj/item/material/twohanded/fireaxe/F = attacking_item if(F.wielded) close(1) else - to_chat(user, SPAN_WARNING("You need to be wielding \the [C] to do that.")) + to_chat(user, SPAN_WARNING("You need to be wielding \the [attacking_item] to do that.")) return TRUE - else if(C.ishammer() && !arePowerSystemsOn()) + else if(attacking_item.ishammer() && !arePowerSystemsOn()) if(locked && user.a_intent != I_HURT) to_chat(user, SPAN_NOTICE("The airlock's bolts prevent it from being forced.")) else if(locked && user.a_intent == I_HURT) @@ -1759,26 +1759,26 @@ About the new airlock wires panel: else close(1) return TRUE - else if(density && istype(C, /obj/item/material/twohanded/chainsaw)) - var/obj/item/material/twohanded/chainsaw/ChainSawVar = C + else if(density && istype(attacking_item, /obj/item/material/twohanded/chainsaw)) + var/obj/item/material/twohanded/chainsaw/ChainSawVar = attacking_item if(!ChainSawVar.wielded) to_chat(user, SPAN_NOTICE("Cutting the airlock requires the strength of two hands.")) else if(ChainSawVar.cutting) to_chat(user, SPAN_NOTICE("You are already cutting an airlock open.")) else if(!ChainSawVar.powered) - to_chat(user, SPAN_NOTICE("The [C] needs to be on in order to open this door.")) + to_chat(user, SPAN_NOTICE("The [attacking_item] needs to be on in order to open this door.")) else if(bracer) //Has a magnetic lock to_chat(user, SPAN_NOTICE("The bracer needs to be removed in order to cut through this door.")) else if(!arePowerSystemsOn()) ChainSawVar.cutting = 1 user.visible_message(\ - SPAN_DANGER("[user.name] starts cutting the control pannel of the airlock with the [C]!"),\ + SPAN_DANGER("[user.name] starts cutting the control pannel of the airlock with the [attacking_item]!"),\ SPAN_WARNING("You start cutting the airlock control panel..."),\ SPAN_NOTICE("You hear a loud buzzing sound and metal grinding on metal...")\ ) - if(do_after(user, ChainSawVar.opendelay SECONDS, extra_checks = CALLBACK(src, PROC_REF(CanChainsaw), C))) + if(do_after(user, ChainSawVar.opendelay SECONDS, extra_checks = CALLBACK(src, PROC_REF(CanChainsaw), attacking_item))) user.visible_message(\ - SPAN_WARNING("[user.name] finishes cutting the control pannel of the airlock with the [C]."),\ + SPAN_WARNING("[user.name] finishes cutting the control pannel of the airlock with the [attacking_item]."),\ SPAN_WARNING("You finish cutting the airlock control panel."),\ SPAN_NOTICE("You hear a metal clank and some sparks.")\ ) @@ -1790,13 +1790,13 @@ About the new airlock wires panel: else if(locked) ChainSawVar.cutting = 1 user.visible_message(\ - SPAN_DANGER("[user.name] starts cutting below the airlock with the [C]!"),\ + SPAN_DANGER("[user.name] starts cutting below the airlock with the [attacking_item]!"),\ SPAN_WARNING("You start cutting below the airlock..."),\ SPAN_NOTICE("You hear a loud buzzing sound and metal grinding on metal...")\ ) - if(do_after(user, ChainSawVar.opendelay SECONDS, extra_checks = CALLBACK(src, PROC_REF(CanChainsaw), C))) + if(do_after(user, ChainSawVar.opendelay SECONDS, extra_checks = CALLBACK(src, PROC_REF(CanChainsaw), attacking_item))) user.visible_message(\ - SPAN_WARNING("[user.name] finishes cutting below the airlock with the [C]."),\ + SPAN_WARNING("[user.name] finishes cutting below the airlock with the [attacking_item]."),\ SPAN_NOTICE("You finish cutting below the airlock."),\ SPAN_NOTICE("You hear a metal clank and some sparks.")\ ) @@ -1806,11 +1806,11 @@ About the new airlock wires panel: else ChainSawVar.cutting = 1 user.visible_message(\ - SPAN_DANGER("[user.name] starts cutting between the airlock with the [C]!"),\ + SPAN_DANGER("[user.name] starts cutting between the airlock with the [attacking_item]!"),\ SPAN_WARNING("You start cutting between the airlock..."),\ SPAN_NOTICE("You hear a loud buzzing sound and metal grinding on metal...")\ ) - if(do_after(user, ChainSawVar.opendelay SECONDS, extra_checks = CALLBACK(src, PROC_REF(CanChainsaw), C))) + if(do_after(user, ChainSawVar.opendelay SECONDS, extra_checks = CALLBACK(src, PROC_REF(CanChainsaw), attacking_item))) user.visible_message(\ SPAN_WARNING("[user.name] finishes cutting between the airlock."),\ SPAN_WARNING("You finish cutting between the airlock."),\ @@ -1823,9 +1823,9 @@ About the new airlock wires panel: else return ..() -/obj/machinery/door/airlock/phoron/attackby(C as obj, mob/user as mob) - if(C) - ignite(is_hot(C)) +/obj/machinery/door/airlock/phoron/attackby(obj/item/attacking_item, mob/user) + if(attacking_item) + ignite(is_hot(attacking_item)) return ..() /obj/machinery/door/airlock/set_broken() @@ -2060,19 +2060,19 @@ About the new airlock wires panel: src.lock() return -/obj/machinery/door/airlock/examine(mob/user) +/obj/machinery/door/airlock/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if (bolt_cut_state == BOLTS_EXPOSED) - to_chat(user, "The bolt cover has been cut open.") + . += SPAN_WARNING("The bolt cover has been cut open.") if (bolt_cut_state == BOLTS_CUT) - to_chat(user, "The door bolts have been cut.") + . += SPAN_WARNING("The door bolts have been cut.") if(bracer) - to_chat(user, "\The [bracer] is installed on \the [src], preventing it from opening.") - to_chat(user, bracer.health) + . += SPAN_WARNING("\The [bracer] is installed on \the [src], preventing it from opening.") + . += bracer.health if(p_open) - to_chat(user, "\The [src]'s maintenance panel has been unscrewed and is hanging open.") + . += SPAN_NOTICE("\The [src]'s maintenance panel has been unscrewed and is hanging open.") if(islist(access_by_level) || islist(req_one_access_by_level)) - to_chat(user, SPAN_NOTICE("This airlock changes access requirements depending on the level.")) + . += SPAN_NOTICE("This airlock changes access requirements depending on the level.") /obj/machinery/door/airlock/emag_act(var/remaining_charges) . = ..() diff --git a/code/game/machinery/doors/airlock_control.dm b/code/game/machinery/doors/airlock_control.dm index 67be42cb5f7..4d0baa6a5e6 100644 --- a/code/game/machinery/doors/airlock_control.dm +++ b/code/game/machinery/doors/airlock_control.dm @@ -263,9 +263,9 @@ else icon_state = "access_button_off" -/obj/machinery/access_button/attackby(obj/item/I as obj, mob/user as mob) +/obj/machinery/access_button/attackby(obj/item/attacking_item, mob/user) //Swiping ID on the access button - if (I.GetID()) + if (attacking_item.GetID()) attack_hand(user) return TRUE return ..() diff --git a/code/game/machinery/doors/airlock_electronics.dm b/code/game/machinery/doors/airlock_electronics.dm index 9f4a5920da3..9863e28087c 100644 --- a/code/game/machinery/doors/airlock_electronics.dm +++ b/code/game/machinery/doors/airlock_electronics.dm @@ -112,12 +112,12 @@ if(!conf_access.len) conf_access = null -/obj/item/airlock_electronics/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/airlock_electronics) &&(!isrobot(user))) +/obj/item/airlock_electronics/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/airlock_electronics) &&(!isrobot(user))) if(src.locked) to_chat(user, SPAN_WARNING("\The [src] you're trying to set is locked! Swipe your ID to unlock.")) return TRUE - var/obj/item/airlock_electronics/A = W + var/obj/item/airlock_electronics/A = attacking_item if(A.locked) to_chat(user, SPAN_WARNING("\The [src] you're trying to copy is locked! Swipe your ID to unlock.")) return TRUE @@ -126,8 +126,8 @@ src.last_configurator = A.last_configurator to_chat(user, SPAN_NOTICE("Configuration settings copied successfully.")) return TRUE - else if(W.GetID()) - var/obj/item/card/id/I = W.GetID() + else if(attacking_item.GetID()) + var/obj/item/card/id/I = attacking_item.GetID() if(check_access(I)) locked = !locked last_configurator = I.registered_name diff --git a/code/game/machinery/doors/blast_door.dm b/code/game/machinery/doors/blast_door.dm index cecd3adf95a..8c87b31eb5d 100644 --- a/code/game/machinery/doors/blast_door.dm +++ b/code/game/machinery/doors/blast_door.dm @@ -115,21 +115,21 @@ // Parameters: 2 (C - Item this object was clicked with, user - Mob which clicked this object) // Description: If we are clicked with crowbar or wielded fire axe, try to manually open the door. // This only works on broken doors or doors without power. Also allows repair with Plasteel. -/obj/machinery/door/blast/attackby(obj/item/C as obj, mob/user as mob) - if(!istype(C, /obj/item/forensics)) +/obj/machinery/door/blast/attackby(obj/item/attacking_item, mob/user) + if(!istype(attacking_item, /obj/item/forensics)) src.add_fingerprint(user) - if((istype(C, /obj/item/material/twohanded/fireaxe) && C:wielded == 1) || C.ishammer() || istype(C, /obj/item/crowbar/robotic/jawsoflife)) + if((istype(attacking_item, /obj/item/material/twohanded/fireaxe) && attacking_item:wielded == 1) || attacking_item.ishammer() || istype(attacking_item, /obj/item/crowbar/robotic/jawsoflife)) if (((stat & NOPOWER) || (stat & BROKEN)) && !( src.operating )) force_toggle() else to_chat(usr, "[src]'s motors resist your effort.") return TRUE - if(istype(C, /obj/item/stack/material) && C.get_material_name() == "plasteel") + if(istype(attacking_item, /obj/item/stack/material) && attacking_item.get_material_name() == "plasteel") var/amt = Ceiling((maxhealth - health)/150) if(!amt) to_chat(usr, "\The [src] is already fully repaired.") return TRUE - var/obj/item/stack/P = C + var/obj/item/stack/P = attacking_item if(P.amount < amt) to_chat(usr, "You don't have enough sheets to repair this! You need at least [amt] sheets.") return TRUE @@ -244,7 +244,7 @@ density = 0 opacity = 0 -/obj/machinery/door/blast/odin/attackby(obj/item/C as obj, mob/user as mob) +/obj/machinery/door/blast/odin/attackby(obj/item/attacking_item, mob/user) return /obj/machinery/door/blast/odin/ex_act(var/severity) diff --git a/code/game/machinery/doors/brigdoors.dm b/code/game/machinery/doors/brigdoors.dm index ca77b6022ac..df8aa427626 100644 --- a/code/game/machinery/doors/brigdoors.dm +++ b/code/game/machinery/doors/brigdoors.dm @@ -56,14 +56,15 @@ stat |= BROKEN update_icon() -/obj/machinery/door_timer/examine(mob/user) +/obj/machinery/door_timer/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - if(stat & (NOPOWER|BROKEN)) return + if(stat & (NOPOWER|BROKEN)) + return if(src.timing) var/second = round(timeleft() % 60) var/minute = round((timeleft() - second) / 60) - to_chat(user, "Time remaining: [minute]:[second]") + . += "Time remaining: [minute]:[second]" //Main door timer loop, if it's timing and time is >0 reduce time by 1. // if it's less than 0, open door, reset timer @@ -293,18 +294,18 @@ return . -/obj/machinery/door_timer/attackby(obj/item/O, var/mob/user) - if(istype(O, /obj/item/paper/incident)) +/obj/machinery/door_timer/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/paper/incident)) if(!incident) - if(import(O, user)) + if(import(attacking_item, user)) ping("\The [src] states, \"Successfully imported incident report!\"") - user.drop_from_inventory(O,get_turf(src)) - qdel(O) + user.drop_from_inventory(attacking_item,get_turf(src)) + qdel(attacking_item) src.updateUsrDialog() else to_chat(user, SPAN_ALERT("\The [src] states, \"There's already an active sentence.\"")) return TRUE - else if(istype(O, /obj/item/paper)) + else if(istype(attacking_item, /obj/item/paper)) to_chat(user, SPAN_ALERT("\The [src] states, \"This console only accepts authentic incident reports. Copies are invalid.\"")) return TRUE diff --git a/code/game/machinery/doors/door.dm b/code/game/machinery/doors/door.dm index e9b0bcbcc11..f37d4e215f2 100644 --- a/code/game/machinery/doors/door.dm +++ b/code/game/machinery/doors/door.dm @@ -291,11 +291,11 @@ do_animate("deny") return -/obj/machinery/door/attackby(obj/item/I as obj, mob/user as mob) - if(!istype(I, /obj/item/forensics)) +/obj/machinery/door/attackby(obj/item/attacking_item, mob/user) + if(!istype(attacking_item, /obj/item/forensics)) src.add_fingerprint(user) - if(I.ishammer() && user.a_intent != I_HURT) + if(attacking_item.ishammer() && user.a_intent != I_HURT) var/obj/item/stack/stack = usr.get_inactive_hand() if(istype(stack) && stack.get_material_name() == get_material_name()) if(stat & BROKEN) @@ -328,12 +328,12 @@ return TRUE - if(repairing && I.iswelder()) + if(repairing && attacking_item.iswelder()) if(!density) to_chat(user, "\The [src] must be closed before you can repair it.") return TRUE - var/obj/item/weldingtool/welder = I + var/obj/item/weldingtool/welder = attacking_item if(welder.use(0,user)) to_chat(user, "You start to fix dents and weld \the [repairing] into place.") if(welder.use_tool(src, user, 5 * repairing.amount, volume = 50) && welder && welder.isOn()) @@ -344,16 +344,16 @@ repairing = null return TRUE - if(repairing && I.iscrowbar()) + if(repairing && attacking_item.iscrowbar()) to_chat(user, "You remove \the [repairing].") - playsound(src.loc, I.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) repairing.forceMove(user.loc) repairing = null return TRUE //psa to whoever coded this, there are plenty of objects that need to call attack() on doors without bludgeoning them. - if(src.density && istype(I, /obj/item) && user.a_intent == I_HURT && !istype(I, /obj/item/card)) - var/obj/item/W = I + if(src.density && istype(attacking_item, /obj/item) && user.a_intent == I_HURT && !istype(attacking_item, /obj/item/card)) + var/obj/item/W = attacking_item user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) if(W.damtype == DAMAGE_BRUTE || W.damtype == DAMAGE_BURN) user.do_attack_animation(src) @@ -402,16 +402,14 @@ update_icon() return - -/obj/machinery/door/examine(mob/user) +/obj/machinery/door/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(src.health < src.maxhealth / 4) - to_chat(user, SPAN_WARNING("\The [src] looks like it's about to break!")) + . += SPAN_WARNING("\The [src] looks like it's about to break!") else if(src.health < src.maxhealth / 2) - to_chat(user, SPAN_WARNING("\The [src] looks seriously damaged!")) + . += SPAN_WARNING("\The [src] looks seriously damaged!") else if(src.health < src.maxhealth * 3/4) - to_chat(user, SPAN_WARNING("\The [src] shows signs of damage!")) - + . += SPAN_WARNING("\The [src] shows signs of damage!") /obj/machinery/door/proc/set_broken() stat |= BROKEN @@ -419,14 +417,12 @@ update_icon() return - /obj/machinery/door/emp_act(severity) . = ..() if(prob(20/severity) && (istype(src,/obj/machinery/door/airlock) || istype(src,/obj/machinery/door/window)) ) open() - /obj/machinery/door/ex_act(severity) var/bolted = 0 if (istype(src, /obj/machinery/door/airlock)) @@ -513,7 +509,7 @@ set_opacity(0) operating = FALSE - if(autoclose) + if(autoclose && !QDELETED(src)) close_door_in(next_close_time()) return 1 diff --git a/code/game/machinery/doors/firedoor.dm b/code/game/machinery/doors/firedoor.dm index 491801eb799..d30f91dfaf8 100644 --- a/code/game/machinery/doors/firedoor.dm +++ b/code/game/machinery/doors/firedoor.dm @@ -148,44 +148,41 @@ /obj/machinery/door/firedoor/get_material() return SSmaterials.get_material_by_name(DEFAULT_WALL_MATERIAL) -/obj/machinery/door/firedoor/examine(mob/user, distance, is_adjacent) +/obj/machinery/door/firedoor/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!is_adjacent || !density) return if(pdiff >= FIREDOOR_MAX_PRESSURE_DIFF) - to_chat(user, SPAN_DANGER("Current pressure differential is [pdiff] kPa. Opening door will likely result in injury.")) + . += SPAN_DANGER("Current pressure differential is [pdiff] kPa. Opening door will likely result in injury.") - to_chat(user, "Sensor readings:") + . += "Sensor readings:" for(var/index = 1; index <= tile_info.len; index++) - var/o = "  " switch(index) if(1) - o += "NORTH: " + . += "NORTH: " if(2) - o += "SOUTH: " + . += "SOUTH: " if(3) - o += "EAST: " + . += "EAST: " if(4) - o += "WEST: " + . += "WEST: " if(tile_info[index] == null) - o += "DATA UNAVAILABLE" - to_chat(user, o) + . += "DATA UNAVAILABLE" continue var/celsius = convert_k2c(tile_info[index][1]) var/pressure = tile_info[index][2] - o += "" - o += "[celsius]°C " - o += "" - o += "[pressure]kPa" - to_chat(user, o) + . += "" + . += "[celsius]°C " + . += "" + . += "[pressure]kPa" if(islist(users_to_open) && users_to_open.len) var/users_to_open_string = users_to_open[1] if(users_to_open.len >= 2) for(var/i = 2 to users_to_open.len) users_to_open_string += ", [users_to_open[i]]" - to_chat(user, "These people have opened \the [src] during an alert: [users_to_open_string].") + . += "These people have opened \the [src] during an alert: [users_to_open_string]." /obj/machinery/door/firedoor/CollidedWith(atom/AM) if(p_open || operating) @@ -259,13 +256,13 @@ nextstate = FIREDOOR_CLOSED close() -/obj/machinery/door/firedoor/attackby(obj/item/C as obj, mob/user as mob) - if(!istype(C, /obj/item/forensics)) +/obj/machinery/door/firedoor/attackby(obj/item/attacking_item, mob/user) + if(!istype(attacking_item, /obj/item/forensics)) add_fingerprint(user) if(operating) return TRUE // Already doing something. - if(C.iswelder() && !repairing) - var/obj/item/weldingtool/WT = C + if(attacking_item.iswelder() && !repairing) + var/obj/item/weldingtool/WT = attacking_item if(WT.isOn()) user.visible_message( SPAN_WARNING("[user] begins welding [src] [blocked ? "open" : "shut"]."), @@ -282,20 +279,20 @@ blocked = !blocked update_icon() return TRUE - if(density && C.isscrewdriver()) + if(density && attacking_item.isscrewdriver()) hatch_open = !hatch_open user.visible_message("[user] has [hatch_open ? "opened" : "closed"] \the [src] maintenance panel.", "You have [hatch_open ? "opened" : "closed"] the [src] maintenance panel.") update_icon() return TRUE - if(blocked && C.iscrowbar() && !repairing) + if(blocked && attacking_item.iscrowbar() && !repairing) if(!hatch_open) to_chat(user, "You must open the maintenance panel first!") else user.visible_message("[user] is removing the electronics from \the [src].", "You start to remove the electronics from [src].") - if(C.use_tool(src, user, 30, volume = 50)) + if(attacking_item.use_tool(src, user, 30, volume = 50)) if(blocked && density && hatch_open) user.visible_message("[user] has removed the electronics from \the [src].", "You have removed the electronics from [src].") @@ -317,33 +314,33 @@ to_chat(user, "\The [src] is welded shut!") return TRUE - if(C.iscrowbar() || istype(C,/obj/item/material/twohanded/fireaxe) || C.ishammer()) + if(attacking_item.iscrowbar() || istype(attacking_item, /obj/item/material/twohanded/fireaxe) || attacking_item.ishammer()) if(operating) return TRUE - if(blocked && C.iscrowbar()) - user.visible_message("\The [user] pries at \the [src] with \a [C], but \the [src] is welded in place!",\ + if(blocked && attacking_item.iscrowbar()) + user.visible_message("\The [user] pries at \the [src] with \a [attacking_item], but \the [src] is welded in place!",\ "You try to pry \the [src] [density ? "open" : "closed"], but it is welded in place!",\ "You hear someone struggle and metal straining.") return TRUE - if(istype(C,/obj/item/material/twohanded/fireaxe)) - var/obj/item/material/twohanded/fireaxe/F = C + if(istype(attacking_item,/obj/item/material/twohanded/fireaxe)) + var/obj/item/material/twohanded/fireaxe/F = attacking_item if(!F.wielded) return TRUE - user.visible_message("\The [user] starts to force \the [src] [density ? "open" : "closed"] with \a [C]!",\ - "You start forcing \the [src] [density ? "open" : "closed"] with \the [C]!",\ + user.visible_message("\The [user] starts to force \the [src] [density ? "open" : "closed"] with \a [attacking_item]!",\ + "You start forcing \the [src] [density ? "open" : "closed"] with \the [attacking_item]!",\ "You hear metal strain.") - if(C.use_tool(src, user, 30, volume = 50)) - if(C.iscrowbar() || C.ishammer()) + if(attacking_item.use_tool(src, user, 30, volume = 50)) + if(attacking_item.iscrowbar() || attacking_item.ishammer()) if(stat & (BROKEN|NOPOWER) || !density) - user.visible_message("\The [user] forces \the [src] [density ? "open" : "closed"] with \a [C]!",\ - "You force \the [src] [density ? "open" : "closed"] with \the [C]!",\ + user.visible_message("\The [user] forces \the [src] [density ? "open" : "closed"] with \a [attacking_item]!",\ + "You force \the [src] [density ? "open" : "closed"] with \the [attacking_item]!",\ "You hear metal strain, and a door [density ? "open" : "close"].") else - user.visible_message("\The [user] forces \the [ blocked ? "welded" : "" ] [src] [density ? "open" : "closed"] with \a [C]!",\ - "You force \the [ blocked ? "welded" : "" ] [src] [density ? "open" : "closed"] with \the [C]!",\ + user.visible_message("\The [user] forces \the [ blocked ? "welded" : "" ] [src] [density ? "open" : "closed"] with \a [attacking_item]!",\ + "You force \the [ blocked ? "welded" : "" ] [src] [density ? "open" : "closed"] with \the [attacking_item]!",\ "You hear metal strain and groan, and a door [density ? "opening" : "closing"].") if(density) open(1, user) diff --git a/code/game/machinery/doors/firedoor_assembly.dm b/code/game/machinery/doors/firedoor_assembly.dm index 54721d3bbb9..871bfc3effa 100644 --- a/code/game/machinery/doors/firedoor_assembly.dm +++ b/code/game/machinery/doors/firedoor_assembly.dm @@ -15,9 +15,9 @@ else icon_state = "door_construction" -/obj/structure/firedoor_assembly/attackby(var/obj/item/C as obj, mob/user as mob) - if(C.iscoil() && !wired && anchored) - var/obj/item/stack/cable_coil/cable = C +/obj/structure/firedoor_assembly/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iscoil() && !wired && anchored) + var/obj/item/stack/cable_coil/cable = attacking_item if (cable.get_amount() < 1) to_chat(user, "You need one length of coil to wire \the [src].") return TRUE @@ -27,39 +27,39 @@ wired = 1 to_chat(user, "You wire \the [src].") return TRUE - else if(C.iswirecutter() && wired ) + else if(attacking_item.iswirecutter() && wired ) user.visible_message("[user] cuts the wires from \the [src].", "You start to cut the wires from \the [src].") - if(C.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return to_chat(user, "You cut the wires!") new/obj/item/stack/cable_coil(src.loc, 1) wired = 0 return TRUE - else if(istype(C, /obj/item/airalarm_electronics) && wired) + else if(istype(attacking_item, /obj/item/airalarm_electronics) && wired) if(anchored) playsound(src.loc, 'sound/items/Deconstruct.ogg', 50, 1) user.visible_message("[user] has inserted a circuit into \the [src]!", "You have inserted the circuit into \the [src]!") new /obj/machinery/door/firedoor(src.loc) - qdel(C) + qdel(attacking_item) qdel(src) else to_chat(user, "You must secure \the [src] first!") return TRUE - else if(C.iswrench()) + else if(attacking_item.iswrench()) anchored = !anchored - playsound(src.loc, C.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) user.visible_message("[user] has [anchored ? "" : "un" ]secured \the [src]!", "You have [anchored ? "" : "un" ]secured \the [src]!") update_icon() return TRUE - else if(!anchored && C.iswelder()) - var/obj/item/weldingtool/WT = C + else if(!anchored && attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(WT.use(0, user)) user.visible_message("[user] dissassembles \the [src].", "You start to dissassemble \the [src].") - if(C.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src || !WT.isOn()) return user.visible_message("[user] has dissassembled \the [src].", "You have dissassembled \the [src].") @@ -69,4 +69,4 @@ to_chat(user, "You need more welding fuel.") return TRUE else - return ..(C, user) + return ..() diff --git a/code/game/machinery/doors/unpowered.dm b/code/game/machinery/doors/unpowered.dm index d419051a7f8..a2e46014af9 100644 --- a/code/game/machinery/doors/unpowered.dm +++ b/code/game/machinery/doors/unpowered.dm @@ -9,9 +9,13 @@ ..() return -/obj/machinery/door/unpowered/attackby(obj/item/I as obj, mob/user as mob) - if(istype(I, /obj/item/melee/energy/blade)) return TRUE - if(src.locked) return TRUE +/obj/machinery/door/unpowered/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/melee/energy/blade)) + return TRUE + + if(src.locked) + return TRUE + return ..() /obj/machinery/door/unpowered/emag_act() diff --git a/code/game/machinery/doors/windowdoor.dm b/code/game/machinery/doors/windowdoor.dm index af1ae869e86..5eb7de192d8 100644 --- a/code/game/machinery/doors/windowdoor.dm +++ b/code/game/machinery/doors/windowdoor.dm @@ -153,14 +153,14 @@ desc = "A strong door. It keeps trying to close, but is jammed." return 1 -/obj/machinery/door/window/attackby(obj/item/I as obj, mob/user as mob) +/obj/machinery/door/window/attackby(obj/item/attacking_item, mob/user) //If it's in the process of opening/closing, ignore the click if (operating) return TRUE //Emags and ninja swords? You may pass. - if (istype(I, /obj/item/melee/energy/blade)) + if (istype(attacking_item, /obj/item/melee/energy/blade)) if(emag_act(10, user)) spark(src.loc, 5) playsound(src.loc, /singleton/sound_category/spark_sound, 50, 1) @@ -169,9 +169,9 @@ return TRUE //If it's emagged, crowbar can pry electronics out. - if (emagged == 1 && I.iscrowbar()) + if (emagged == 1 && attacking_item.iscrowbar()) user.visible_message("[user] dismantles the windoor.", "You start to dismantle the windoor.") - if(I.use_tool(src, user, 60, volume = 50)) + if(attacking_item.use_tool(src, user, 60, volume = 50)) to_chat(user, SPAN_NOTICE("You dismantled the windoor!")) new /obj/item/trash/broken_electronics(loc) var/obj/item/stack/cable_coil/CC = new /obj/item/stack/cable_coil(loc) @@ -181,7 +181,7 @@ qdel(src) return TRUE - if(isobj(I) && I.iscrowbar() && user.a_intent == I_HELP) + if(isobj(attacking_item) && attacking_item.iscrowbar() && user.a_intent == I_HELP) if(inoperable()) visible_message("\The [user] forces \the [src] [density ? "open" : "closed"].") if(density) @@ -193,16 +193,16 @@ return TRUE //If it's a weapon, smash windoor. Unless it's an id card, agent card, ect.. then ignore it (Cards really shouldnt damage a door anyway) - if(src.density && istype(I, /obj/item) && !istype(I, /obj/item/card)) + if(src.density && istype(attacking_item, /obj/item) && !istype(attacking_item, /obj/item/card)) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - var/aforce = I.force + var/aforce = attacking_item.force playsound(src.loc, 'sound/effects/glass_hit.ogg', 75, 1) - visible_message("[src] was hit by [I].") - if(I.damtype == DAMAGE_BRUTE || I.damtype == DAMAGE_BURN) + visible_message("[src] was hit by [attacking_item].") + if(attacking_item.damtype == DAMAGE_BRUTE || attacking_item.damtype == DAMAGE_BURN) take_damage(aforce) return TRUE - if(!istype(I, /obj/item/forensics)) + if(!istype(attacking_item, /obj/item/forensics)) src.add_fingerprint(user) if(allowed(user)) diff --git a/code/game/machinery/doppler_array.dm b/code/game/machinery/doppler_array.dm index 9554f98037d..b534efa61ad 100644 --- a/code/game/machinery/doppler_array.dm +++ b/code/game/machinery/doppler_array.dm @@ -19,9 +19,9 @@ var/list/doppler_arrays = list() doppler_arrays -= src return ..() -/obj/machinery/doppler_array/examine(mob/user) +/obj/machinery/doppler_array/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, SPAN_NOTICE("\The [src] is [active ? "listening for explosions" : "[SPAN_WARNING("inactive")]"].")) + . += SPAN_NOTICE("\The [src] is [active ? "listening for explosions" : "[SPAN_WARNING("inactive")]"].") /obj/machinery/doppler_array/attack_hand(mob/user) active = !active diff --git a/code/game/machinery/firealarm.dm b/code/game/machinery/firealarm.dm index 689be996ed3..4a67b86f8a3 100644 --- a/code/game/machinery/firealarm.dm +++ b/code/game/machinery/firealarm.dm @@ -20,12 +20,12 @@ ///looping sound datum for our fire alarm siren. var/datum/looping_sound/firealarm/soundloop -/obj/machinery/firealarm/examine(mob/user) +/obj/machinery/firealarm/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if((stat & (NOPOWER|BROKEN)) || buildstage != 2) return - to_chat(user, "The current alert level is [get_security_level()].") + . += "The current alert level is [get_security_level()]." /obj/machinery/firealarm/update_icon() cut_overlays() @@ -70,13 +70,13 @@ if(prob(50/severity)) alarm(rand(30/severity, 60/severity)) -/obj/machinery/firealarm/attackby(obj/item/W as obj, mob/user as mob) - if(!istype(W, /obj/item/forensics)) +/obj/machinery/firealarm/attackby(obj/item/attacking_item, mob/user) + if(!istype(attacking_item, /obj/item/forensics)) src.add_fingerprint(user) else return TRUE - if (W.isscrewdriver() && buildstage == 2) + if (attacking_item.isscrewdriver() && buildstage == 2) if(!wiresexposed) set_light(0) wiresexposed = !wiresexposed @@ -87,14 +87,14 @@ set_light(0) switch(buildstage) if(2) - if (W.ismultitool()) + if (attacking_item.ismultitool()) src.detecting = !( src.detecting ) if (src.detecting) user.visible_message("\The [user] has reconnected [src]'s detecting unit!", "You have reconnected [src]'s detecting unit.") else user.visible_message("\The [user] has disconnected [src]'s detecting unit!", "You have disconnected [src]'s detecting unit.") return TRUE - else if (W.iswirecutter()) + else if (attacking_item.iswirecutter()) user.visible_message("\The [user] has cut the wires inside \the [src]!", "You have cut the wires inside \the [src].") new/obj/item/stack/cable_coil(get_turf(src), 5) playsound(src.loc, 'sound/items/Wirecutter.ogg', 50, 1) @@ -102,17 +102,17 @@ update_icon() return TRUE if(1) - if(W.iscoil()) - var/obj/item/stack/cable_coil/C = W + if(attacking_item.iscoil()) + var/obj/item/stack/cable_coil/C = attacking_item if (C.use(5)) to_chat(user, "You wire \the [src].") buildstage = 2 else to_chat(user, "You need 5 pieces of cable to wire \the [src].") return TRUE - else if(W.iscrowbar()) + else if(attacking_item.iscrowbar()) to_chat(user, "You pry out the circuit!") - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) spawn(20) var/obj/item/firealarm_electronics/circuit = new /obj/item/firealarm_electronics() circuit.forceMove(user.loc) @@ -120,16 +120,16 @@ update_icon() return TRUE if(0) - if(istype(W, /obj/item/firealarm_electronics)) + if(istype(attacking_item, /obj/item/firealarm_electronics)) to_chat(user, "You insert the circuit!") - qdel(W) + qdel(attacking_item) buildstage = 1 update_icon() return TRUE - else if(W.iswrench()) + else if(attacking_item.iswrench()) to_chat(user, "You remove the fire alarm assembly from the wall!") new /obj/item/frame/fire_alarm(get_turf(user)) - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) qdel(src) return TRUE return TRUE diff --git a/code/game/machinery/flasher.dm b/code/game/machinery/flasher.dm index e16fbd95512..e7cb3075c46 100644 --- a/code/game/machinery/flasher.dm +++ b/code/game/machinery/flasher.dm @@ -49,8 +49,8 @@ // src.sd_SetLuminosity(0) //Don't want to render prison breaks impossible -/obj/machinery/flasher/attackby(obj/item/W as obj, mob/user as mob) - if (W.iswirecutter()) +/obj/machinery/flasher/attackby(obj/item/attacking_item, mob/user) + if (attacking_item.iswirecutter()) add_fingerprint(user) src.disable = !src.disable if (src.disable) @@ -107,8 +107,8 @@ if (src.anchored) src.flash() -/obj/machinery/flasher/portable/attackby(obj/item/W as obj, mob/user as mob) - if (W.iswrench()) +/obj/machinery/flasher/portable/attackby(obj/item/attacking_item, mob/user) + if (attacking_item.iswrench()) add_fingerprint(user) src.anchored = !src.anchored diff --git a/code/game/machinery/floodlight.dm b/code/game/machinery/floodlight.dm index a13f7d4c6e9..a069883ca5f 100644 --- a/code/game/machinery/floodlight.dm +++ b/code/game/machinery/floodlight.dm @@ -19,15 +19,15 @@ . = ..() cell = new /obj/item/cell(src) -/obj/machinery/floodlight/examine(mob/user) +/obj/machinery/floodlight/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(cell) if(!cell.charge) - to_chat(user, SPAN_WARNING("The installed [cell.name] is completely flat!")) + . += SPAN_WARNING("The installed [cell.name] is completely flat!") return - to_chat(user, SPAN_NOTICE("The installed [cell.name] has [Percent(cell.charge, cell.maxcharge)]% charge remaining.")) + . += SPAN_NOTICE("The installed [cell.name] has [Percent(cell.charge, cell.maxcharge)]% charge remaining.") else - to_chat(user, SPAN_WARNING("\The [src] has no cell installed!")) + . += SPAN_WARNING("\The [src] has no cell installed!") /obj/machinery/floodlight/update_icon() cut_overlays() @@ -106,8 +106,8 @@ update_icon() -/obj/machinery/floodlight/attackby(obj/item/W, mob/user) - if(W.isscrewdriver()) +/obj/machinery/floodlight/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(!open) unlocked = !unlocked var/msg = unlocked ? "You unscrew the battery panel." : "You screw the battery panel into place." @@ -115,7 +115,7 @@ else to_chat(user, SPAN_WARNING("\The [src]'s battery panel is open and cannot be screwed down!")) return TRUE - if(W.iscrowbar()) + if(attacking_item.iscrowbar()) if(unlocked) open = !open var/msg = open ? "You remove the battery panel." : "You crowbar the battery panel into place." @@ -123,14 +123,14 @@ else to_chat(user, SPAN_WARNING("\The [src]'s battery panel is still screwed shut!")) return TRUE - if(istype(W, /obj/item/cell)) + if(istype(attacking_item, /obj/item/cell)) if(open) if(cell) to_chat(user, SPAN_WARNING("There is a power cell already installed.")) return else - user.drop_from_inventory(W, src) - cell = W + user.drop_from_inventory(attacking_item, src) + cell = attacking_item to_chat(user, SPAN_NOTICE("You insert the power cell.")) return TRUE update_icon() diff --git a/code/game/machinery/floor_frames.dm b/code/game/machinery/floor_frames.dm index b9329472193..2e556c0b15d 100644 --- a/code/game/machinery/floor_frames.dm +++ b/code/game/machinery/floor_frames.dm @@ -9,8 +9,8 @@ var/refund_type = /obj/item/stack/material/steel var/reverse = 0 //if resulting object faces opposite its dir (like light fixtures) -/obj/item/floor_frame/attackby(obj/item/W, mob/user) - if (W.iswrench()) +/obj/item/floor_frame/attackby(obj/item/attacking_item, mob/user) + if (attacking_item.iswrench()) new refund_type(get_turf(src.loc), refund_amt) qdel(src) return TRUE diff --git a/code/game/machinery/floor_light.dm b/code/game/machinery/floor_light.dm index 33313c0520d..b92515d37d4 100644 --- a/code/game/machinery/floor_light.dm +++ b/code/game/machinery/floor_light.dm @@ -24,18 +24,18 @@ var/list/floor_light_cache = list() /obj/machinery/floor_light/prebuilt anchored = 1 -/obj/machinery/floor_light/attackby(var/obj/item/W, var/mob/user) - if(W.isscrewdriver()) +/obj/machinery/floor_light/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) anchored = !anchored visible_message("\The [user] has [anchored ? "attached" : "detached"] \the [src].") playsound(src.loc, 'sound/items/Screwdriver.ogg', 100, 1) return TRUE - else if(W.iswelder() && (damaged || (stat & BROKEN))) - var/obj/item/weldingtool/WT = W + else if(attacking_item.iswelder() && (damaged || (stat & BROKEN))) + var/obj/item/weldingtool/WT = attacking_item if(!WT.use(0, user)) to_chat(user, "\The [src] must be on to complete this task.") return TRUE - if(!W.use_tool(src, user, 20, volume = 50)) + if(!attacking_item.use_tool(src, user, 20, volume = 50)) return TRUE if(!src || !WT.isOn()) return TRUE @@ -45,9 +45,9 @@ var/list/floor_light_cache = list() damaged = null update_brightness() return TRUE - else if(W.force && user.a_intent == "hurt") + else if(attacking_item.force && user.a_intent == "hurt") return attack_hand(user) - else if(W.iscrowbar()) + else if(attacking_item.iscrowbar()) if(anchored) to_chat(user, "\The [src] must be unfastened from the [loc] first!") return TRUE diff --git a/code/game/machinery/floorlayer.dm b/code/game/machinery/floorlayer.dm index 7d6c72b0533..277251d822c 100644 --- a/code/game/machinery/floorlayer.dm +++ b/code/game/machinery/floorlayer.dm @@ -33,21 +33,21 @@ on = !on user.visible_message("[user] has [!on ? "de" : ""]activated \the [src].", SPAN_NOTICE("You [!on ? "de" : ""]activate \the [src].")) -/obj/machinery/floorlayer/attackby(obj/item/I, mob/user) - if(I.iswrench()) +/obj/machinery/floorlayer/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswrench()) var/m = tgui_input_list(user, "Choose work mode", "Mode", mode) mode[m] = !mode[m] var/O = mode[m] user.visible_message("[user] has set \the [src] [m] mode [!O ? "off" : "on"].", SPAN_NOTICE("You set \the [src] [m] mode [!O ? "off":"on"].")) return TRUE - if(istype(I, /obj/item/stack/tile)) - to_chat(user, SPAN_NOTICE("You successfully load \the [I] into \the [src].")) - user.drop_from_inventory(I, src) - take_tile(I) + if(istype(attacking_item, /obj/item/stack/tile)) + to_chat(user, SPAN_NOTICE("You successfully load \the [attacking_item] into \the [src].")) + user.drop_from_inventory(attacking_item, src) + take_tile(attacking_item) return TRUE - if(I.iscrowbar()) + if(attacking_item.iscrowbar()) if(!length(contents)) to_chat(user, SPAN_NOTICE("\The [src] is empty.")) else @@ -58,11 +58,11 @@ T = null return TRUE - if(I.isscrewdriver()) + if(attacking_item.isscrewdriver()) T = tgui_input_list(user, "Choose which set of tiles you want \the [src] to lay.", "Tiles", contents) return TRUE -/obj/machinery/floorlayer/examine(mob/user) +/obj/machinery/floorlayer/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() var/dismantle = mode["dismantle"] var/laying = mode["laying"] @@ -70,7 +70,7 @@ var/number = 0 if (T) number = T.get_amount() - to_chat(user, SPAN_NOTICE("\The [src] has [number] tile\s, dismantle is [dismantle ? "on" : "off"], laying is [laying ? "on" : "off"], collect is [collect ? "on" : "off"].")) + . += SPAN_NOTICE("\The [src] has [number] tile\s, dismantle is [dismantle ? "on" : "off"], laying is [laying ? "on" : "off"], collect is [collect ? "on" : "off"].") /obj/machinery/floorlayer/proc/reset() on = FALSE diff --git a/code/game/machinery/gumball.dm b/code/game/machinery/gumball.dm index a3ce1555eed..f5afb57ef9f 100644 --- a/code/game/machinery/gumball.dm +++ b/code/game/machinery/gumball.dm @@ -29,9 +29,9 @@ update_icon() -/obj/machinery/gumballmachine/examine(mob/user) +/obj/machinery/gumballmachine/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, SPAN_NOTICE("\The [src] costs [gumprice] credits to use.")) + . += SPAN_NOTICE("\The [src] costs [gumprice] credits to use.") /obj/machinery/gumballmachine/update_icon() switch(amountleft) @@ -58,9 +58,9 @@ on = 1 -/obj/machinery/gumballmachine/attackby(obj/item/W as obj, mob/user as mob) - if (istype(W, /obj/item/spacecash)) - var/obj/item/spacecash/C = W +/obj/machinery/gumballmachine/attackby(obj/item/attacking_item, mob/user) + if (istype(attacking_item, /obj/item/spacecash)) + var/obj/item/spacecash/C = attacking_item if(!on) to_chat(user, SPAN_WARNING("\The [src] has no power!")) return TRUE @@ -79,13 +79,13 @@ if(changeleftover) spawn_money(changeleftover, src.loc, user) - if(istype(W, /obj/item) && user.a_intent == I_HURT && !istype(W, /obj/item/spacecash)) + if(istype(attacking_item, /obj/item) && user.a_intent == I_HURT && !istype(attacking_item, /obj/item/spacecash)) if(broken) return if(prob(25)) smashgumball() else - visible_message(SPAN_WARNING("\The [user] bash's \the [src] with \the [W].")) + visible_message(SPAN_WARNING("\The [user] bash's \the [src] with \the [attacking_item].")) return TRUE diff --git a/code/game/machinery/hologram.dm b/code/game/machinery/hologram.dm index 8a7128c7eb7..a5d06012f36 100644 --- a/code/game/machinery/hologram.dm +++ b/code/game/machinery/hologram.dm @@ -81,13 +81,13 @@ Possible to do for anyone motivated enough: var/area/A = get_area(src) holopad_id = "[A.name] ([src.x]-[src.y]-[src.z])" -/obj/machinery/hologram/holopad/examine(mob/user) +/obj/machinery/hologram/holopad/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(connected_pad) if(established_connection) - to_chat(user, SPAN_NOTICE("\The [src] is currently in a call with a holopad with ID: [connected_pad.holopad_id]")) + . += SPAN_NOTICE("\The [src] is currently in a call with a holopad with ID: [connected_pad.holopad_id]") else - to_chat(user, SPAN_NOTICE("\The [src] is currently pending connection with a holopad with ID: [connected_pad.holopad_id]")) + . += SPAN_NOTICE("\The [src] is currently pending connection with a holopad with ID: [connected_pad.holopad_id]") /obj/machinery/hologram/holopad/update_icon(var/recurse = TRUE) if(LAZYLEN(active_holograms) || has_established_connection()) @@ -273,9 +273,9 @@ Possible to do for anyone motivated enough: return 0 return -1 -/obj/machinery/hologram/holopad/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/modular_computer)) - var/obj/item/modular_computer/MC = W +/obj/machinery/hologram/holopad/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/modular_computer)) + var/obj/item/modular_computer/MC = attacking_item if(!(MC in linked_pdas)) linked_pdas |= MC to_chat(user, SPAN_NOTICE("You link \the [MC] to \the [src].")) diff --git a/code/game/machinery/igniter.dm b/code/game/machinery/igniter.dm index 51eeb085f12..7c77a8b42b9 100755 --- a/code/game/machinery/igniter.dm +++ b/code/game/machinery/igniter.dm @@ -102,8 +102,8 @@ ..() update_icon() -/obj/machinery/sparker/attackby(obj/item/W as obj, mob/user as mob) - if (W.isscrewdriver()) +/obj/machinery/sparker/attackby(obj/item/attacking_item, mob/user) + if (attacking_item.isscrewdriver()) add_fingerprint(user) disable = !disable if(disable) diff --git a/code/game/machinery/iv_drip.dm b/code/game/machinery/iv_drip.dm index 173af9cbdbb..3146e46dad6 100644 --- a/code/game/machinery/iv_drip.dm +++ b/code/game/machinery/iv_drip.dm @@ -397,48 +397,48 @@ breath_mask = null update_icon() -/obj/machinery/iv_drip/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/reagent_containers/blood/ripped)) +/obj/machinery/iv_drip/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/reagent_containers/blood/ripped)) to_chat(user, "You can't use a ripped bloodpack.") return TRUE - if(is_type_in_list(W, accepted_containers)) + if(is_type_in_list(attacking_item, accepted_containers)) if(beaker) to_chat(user, "There is already a reagent container loaded!") return TRUE - user.drop_from_inventory(W, src) - beaker = W - user.visible_message(SPAN_NOTICE("[user] attaches \the [W] to \the [src]."), SPAN_NOTICE("You attach \the [W] to \the [src].")) + user.drop_from_inventory(attacking_item, src) + beaker = attacking_item + user.visible_message(SPAN_NOTICE("[user] attaches \the [attacking_item] to \the [src]."), SPAN_NOTICE("You attach \the [attacking_item] to \the [src].")) update_icon() return TRUE - if(istype(W, /obj/item/clothing/mask/breath)) - if(is_type_in_list(W, mask_blacklist)) - to_chat(user, "\The [W] is incompatible with \the [src].") + if(istype(attacking_item, /obj/item/clothing/mask/breath)) + if(is_type_in_list(attacking_item, mask_blacklist)) + to_chat(user, "\The [attacking_item] is incompatible with \the [src].") return TRUE if(breath_mask) to_chat(user, "There is already a mask installed.") return TRUE - user.drop_from_inventory(W, src) - breath_mask = W - user.visible_message(SPAN_NOTICE("[user] places \the [W] in \the [src]."), SPAN_NOTICE("You place \the [W] in \the [src].")) + user.drop_from_inventory(attacking_item, src) + breath_mask = attacking_item + user.visible_message(SPAN_NOTICE("[user] places \the [attacking_item] in \the [src]."), SPAN_NOTICE("You place \the [attacking_item] in \the [src].")) update_icon() return TRUE - if(istype(W, /obj/item/tank)) - if(is_type_in_list(W, tank_blacklist)) - to_chat(user, "\The [W] is incompatible with \the [src].") + if(istype(attacking_item, /obj/item/tank)) + if(is_type_in_list(attacking_item, tank_blacklist)) + to_chat(user, "\The [attacking_item] is incompatible with \the [src].") return TRUE if(tank) to_chat(user, "There is already a tank installed!") return TRUE - if(istype(W, /obj/item/tank/phoron)) + if(istype(attacking_item, /obj/item/tank/phoron)) if(tipped) - to_chat(user, "You're not sure how to place \the [W] in the fallen [src].") + to_chat(user, "You're not sure how to place \the [attacking_item] in the fallen [src].") return TRUE - user.drop_from_inventory(W, src) - tank = W - user.visible_message(SPAN_NOTICE("[user] places \the [W] in \the [src]."), SPAN_NOTICE("You place \the [W] in \the [src].")) + user.drop_from_inventory(attacking_item, src) + tank = attacking_item + user.visible_message(SPAN_NOTICE("[user] places \the [attacking_item] in \the [src]."), SPAN_NOTICE("You place \the [attacking_item] in \the [src].")) update_icon() return TRUE - if(W.iswrench()) + if(attacking_item.iswrench()) if(!tank) to_chat(user, "There isn't a tank installed for you to secure!") return TRUE @@ -451,9 +451,9 @@ playsound(src.loc, 'sound/items/wrench.ogg', 50, 1) is_loose = !is_loose return TRUE - if(default_deconstruction_screwdriver(user, W)) + if(default_deconstruction_screwdriver(user, attacking_item)) return TRUE - if(default_part_replacement(user, W)) + if(default_part_replacement(user, attacking_item)) return TRUE return ..() @@ -683,30 +683,30 @@ transfer_amount = amount to_chat(usr, SPAN_NOTICE("Transfer rate set to [src.transfer_amount] u/sec.")) -/obj/machinery/iv_drip/examine(mob/user, distance, is_adjacent) +/obj/machinery/iv_drip/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance > 2) return - to_chat(user, SPAN_NOTICE("[src] is [mode ? "injecting" : "taking blood"] at a rate of [src.transfer_amount] u/sec, the automatic injection stop mode is [toggle_stop ? "on" : "off"]. The Emergency Positive Pressure \ - system is [epp ? "on" : "off"].")) + . += SPAN_NOTICE("[src] is [mode ? "injecting" : "taking blood"] at a rate of [src.transfer_amount] u/sec, the automatic injection stop mode is [toggle_stop ? "on" : "off"]. The Emergency Positive Pressure \ + system is [epp ? "on" : "off"].") if(attached) - to_chat(user, SPAN_NOTICE("\The [src] is attached to [attached]'s [vein.name].")) + . += SPAN_NOTICE("\The [src] is attached to [attached]'s [vein.name].") if(beaker) if(LAZYLEN(beaker.reagents.reagent_volumes)) - to_chat(user, SPAN_NOTICE("Attached is [icon2html(beaker, user)] \a [beaker] with [adv_scan ? "[beaker.reagents.total_volume] units of primarily [beaker.reagents.get_primary_reagent_name()]" : "some liquid"].")) + . += SPAN_NOTICE("Attached is [icon2html(beaker, user)] \a [beaker] with [adv_scan ? "[beaker.reagents.total_volume] units of primarily [beaker.reagents.get_primary_reagent_name()]" : "some liquid"].") else - to_chat(user, SPAN_NOTICE("Attached is [icon2html(beaker, user)] \a [beaker]. It is empty.")) + . += SPAN_NOTICE("Attached is [icon2html(beaker, user)] \a [beaker]. It is empty.") else - to_chat(user, SPAN_NOTICE("No chemicals are attached.")) + . += SPAN_NOTICE("No chemicals are attached.") if(tank) - to_chat(user, SPAN_NOTICE("Installed is [icon2html(tank, user)] [is_loose ? "\a [tank] sitting loose" : "\a [tank] secured"] on the stand. The meter shows [round(tank.air_contents.return_pressure())]kPa, \ - with the pressure set to [round(tank.distribute_pressure)]kPa. The valve is [valve_open ? "open" : "closed"].")) + . += SPAN_NOTICE("Installed is [icon2html(tank, user)] [is_loose ? "\a [tank] sitting loose" : "\a [tank] secured"] on the stand. The meter shows [round(tank.air_contents.return_pressure())]kPa, \ + with the pressure set to [round(tank.distribute_pressure)]kPa. The valve is [valve_open ? "open" : "closed"].") else - to_chat(user, SPAN_NOTICE("No gas tank installed.")) + . += SPAN_NOTICE("No gas tank installed.") if(breath_mask) - to_chat(user, SPAN_NOTICE("\The [src] has [icon2html(breath_mask, user)] \a [breath_mask] installed. [breather ? breather : "No one"] is wearing it.")) + . += SPAN_NOTICE("\The [src] has [icon2html(breath_mask, user)] \a [breath_mask] installed. [breather ? breather : "No one"] is wearing it.") else - to_chat(user, SPAN_NOTICE("No breath mask installed.")) + . += SPAN_NOTICE("No breath mask installed.") /obj/machinery/iv_drip/RefreshParts() ..() diff --git a/code/game/machinery/jukebox.dm b/code/game/machinery/jukebox.dm index d046c4ab4dd..63f4fdd88a6 100644 --- a/code/game/machinery/jukebox.dm +++ b/code/game/machinery/jukebox.dm @@ -161,16 +161,16 @@ new /obj/effect/decal/cleanable/blood/oil(src.loc) qdel(src) -/obj/machinery/media/jukebox/attackby(obj/item/W as obj, mob/user as mob) - if(!istype(W, /obj/item/forensics)) +/obj/machinery/media/jukebox/attackby(obj/item/attacking_item, mob/user) + if(!istype(attacking_item, /obj/item/forensics)) src.add_fingerprint(user) - if(W.iswrench()) + if(attacking_item.iswrench()) if(playing) StopPlaying() user.visible_message("[user] has [anchored ? "un" : ""]secured \the [src].", "You [anchored ? "un" : ""]secure \the [src].") anchored = !anchored - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) power_change() update_icon() return TRUE diff --git a/code/game/machinery/lightswitch.dm b/code/game/machinery/lightswitch.dm index c59b93362da..c6ed1b0c35d 100644 --- a/code/game/machinery/lightswitch.dm +++ b/code/game/machinery/lightswitch.dm @@ -37,10 +37,10 @@ else if (light_range) set_light(FALSE) -/obj/machinery/light_switch/examine(mob/user, distance, is_adjacent) +/obj/machinery/light_switch/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1) - to_chat(user, "A light switch. It is [on? "on" : "off"].") + . += "It is [on ? "on" : "off"]." /obj/machinery/light_switch/attack_hand(mob/user) playsound(src, /singleton/sound_category/switch_sound, 30) diff --git a/code/game/machinery/machinery.dm b/code/game/machinery/machinery.dm index 90a61c3089f..ade9364b35b 100644 --- a/code/game/machinery/machinery.dm +++ b/code/game/machinery/machinery.dm @@ -170,10 +170,10 @@ Class Procs: return ..() -/obj/machinery/examine(mob/user, distance, is_adjacent) +/obj/machinery/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(signaler && is_adjacent) - to_chat(user, SPAN_WARNING("\The [src] has a hidden signaler attached to it.")) + . += SPAN_WARNING("\The [src] has a hidden signaler attached to it.") // /obj/machinery/proc/process_all() // /* Uncomment this if/when you need component processing @@ -297,20 +297,20 @@ Class Procs: return ..() -/obj/machinery/attackby(obj/item/W, mob/user) +/obj/machinery/attackby(obj/item/attacking_item, mob/user) if(obj_flags & OBJ_FLAG_SIGNALER) - if(issignaler(W)) + if(issignaler(attacking_item)) if(signaler) to_chat(user, SPAN_WARNING("\The [src] already has a signaler attached.")) return TRUE - var/obj/item/device/assembly/signaler/S = W - user.drop_from_inventory(W, src) + var/obj/item/device/assembly/signaler/S = attacking_item + user.drop_from_inventory(attacking_item, src) signaler = S S.machine = src user.visible_message("[user] attaches \the [S] to \the [src].", SPAN_NOTICE("You attach \the [S] to \the [src]."), range = 3) log_and_message_admins("has attached a signaler to \the [src].", user, get_turf(src)) return TRUE - else if(W.iswirecutter() && signaler) + else if(attacking_item.iswirecutter() && signaler) user.visible_message("[user] removes \the [signaler] from \the [src].", SPAN_NOTICE("You remove \the [signaler] from \the [src]."), range = 3) user.put_in_hands(detach_signaler()) return TRUE diff --git a/code/game/machinery/mass_driver.dm b/code/game/machinery/mass_driver.dm index 890cbac3ecb..7c84574b574 100644 --- a/code/game/machinery/mass_driver.dm +++ b/code/game/machinery/mass_driver.dm @@ -54,17 +54,17 @@ drive() -/obj/machinery/mass_driver/attackby(obj/item/W, mob/user) +/obj/machinery/mass_driver/attackby(obj/item/attacking_item, mob/user) - if(W.iswrench()) + if(attacking_item.iswrench()) if(!anchored) - playsound(src.loc, W.usesound, 75, 1) + playsound(src.loc, attacking_item.usesound, 75, 1) user.visible_message("[user.name] secures [src] to the floor.", \ "You secure the external reinforcing bolts to the floor.", \ "You hear a ratchet") src.anchored = 1 else - playsound(src.loc, W.usesound, 75, 1) + playsound(src.loc, attacking_item.usesound, 75, 1) user.visible_message("[user.name] unsecures [src] from the floor.", \ "You unsecure the external reinforcing bolts from the floor.", \ "You hear a ratchet") diff --git a/code/game/machinery/mecha_fabricator.dm b/code/game/machinery/mecha_fabricator.dm index c7be31322d2..dfaa9bac859 100644 --- a/code/game/machinery/mecha_fabricator.dm +++ b/code/game/machinery/mecha_fabricator.dm @@ -147,21 +147,21 @@ return 1 -/obj/machinery/mecha_part_fabricator/attackby(var/obj/item/I, var/mob/user) +/obj/machinery/mecha_part_fabricator/attackby(obj/item/attacking_item, mob/user) if(busy) to_chat(user, SPAN_NOTICE("\The [src] is busy. Please wait for completion of previous operation.")) return TRUE - if(default_deconstruction_screwdriver(user, I)) + if(default_deconstruction_screwdriver(user, attacking_item)) return TRUE - if(default_deconstruction_crowbar(user, I)) + if(default_deconstruction_crowbar(user, attacking_item)) return TRUE - if(default_part_replacement(user, I)) + if(default_part_replacement(user, attacking_item)) return TRUE - if(!istype(I, /obj/item/stack/material)) + if(!istype(attacking_item, /obj/item/stack/material)) return ..() - var/obj/item/stack/material/M = I + var/obj/item/stack/material/M = attacking_item if(!M.material) return ..() if(!(M.material.name in list(MATERIAL_STEEL, MATERIAL_GLASS, MATERIAL_GOLD, MATERIAL_SILVER, MATERIAL_DIAMOND, MATERIAL_PHORON, MATERIAL_URANIUM))) diff --git a/code/game/machinery/navbeacon.dm b/code/game/machinery/navbeacon.dm index de0beb938c0..8d68e718a72 100644 --- a/code/game/machinery/navbeacon.dm +++ b/code/game/machinery/navbeacon.dm @@ -101,12 +101,12 @@ var/global/list/navbeacons // no I don't like putting this in, but it will do frequency.post_signal(src, signal, filter = RADIO_NAVBEACONS) -/obj/machinery/navbeacon/attackby(var/obj/item/I, var/mob/user) +/obj/machinery/navbeacon/attackby(obj/item/attacking_item, mob/user) var/turf/T = loc if(!T.is_plating()) return // prevent intraction when T-scanner revealed - if(I.isscrewdriver()) + if(attacking_item.isscrewdriver()) open = !open user.visible_message("[user] [open ? "opens" : "closes"] the beacon's cover.", "You [open ? "open" : "close"] the beacon's cover.") @@ -114,7 +114,7 @@ var/global/list/navbeacons // no I don't like putting this in, but it will do update_icon() return TRUE - else if (I.GetID()) + else if (attacking_item.GetID()) if(open) if (src.allowed(user)) src.locked = !src.locked diff --git a/code/game/machinery/newscaster.dm b/code/game/machinery/newscaster.dm index d62015b5b2d..93e3327c116 100644 --- a/code/game/machinery/newscaster.dm +++ b/code/game/machinery/newscaster.dm @@ -810,15 +810,15 @@ var/list/obj/machinery/newscaster/allCasters = list() -/obj/machinery/newscaster/attackby(obj/item/I as obj, mob/user as mob) +/obj/machinery/newscaster/attackby(obj/item/attacking_item, mob/user) if (src.isbroken) playsound(src.loc, 'sound/effects/hit_on_shattered_glass.ogg', 100, 1) for (var/mob/O in hearers(5, src.loc)) O.show_message("[user.name] further abuses the shattered [src.name].") else - if(istype(I, /obj/item) ) + if(istype(attacking_item, /obj/item) ) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - var/obj/item/W = I + var/obj/item/W = attacking_item if(W.force <15) for (var/mob/O in hearers(5, src.loc)) O.show_message("[user.name] hits the [src.name] with the [W.name] with no visible effect." ) @@ -832,7 +832,7 @@ var/list/obj/machinery/newscaster/allCasters = list() playsound(src.loc, /singleton/sound_category/glass_break_sound, 100, 1) else for (var/mob/O in hearers(5, src.loc)) - O.show_message("[user.name] forcefully slams the [src.name] with the [I.name]!" ) + O.show_message("[user.name] forcefully slams the [src.name] with the [attacking_item.name]!" ) playsound(src.loc, 'sound/effects/glass_hit.ogg', 100, 1) else to_chat(user, "This does nothing.") @@ -1026,8 +1026,8 @@ var/list/obj/machinery/newscaster/allCasters = list() src.attack_self(src.loc) -/obj/item/newspaper/attackby(obj/item/W as obj, mob/user as mob) - if(W.ispen()) +/obj/item/newspaper/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ispen()) if(rolled) user.visible_message(SPAN_NOTICE("\The [user] unrolls \the [src] to write on it."),\ SPAN_NOTICE("You unroll \the [src] to write on it.")) @@ -1035,8 +1035,7 @@ var/list/obj/machinery/newscaster/allCasters = list() if(src.scribble_page == src.curr_page) to_chat(user, "There's already a scribble in this page... You wouldn't want to make things too cluttered, would you?") else - var/s = sanitize(input(user, "Write something", "Newspaper", "")) - s = sanitize(s) + var/s = sanitize( tgui_input_text(user, "Write something", "Newspaper", "") ) if (!s) return if (!in_range(src, usr) && src.loc != usr) diff --git a/code/game/machinery/nuclear_bomb.dm b/code/game/machinery/nuclear_bomb.dm index 87b266434d5..7af37bbd749 100644 --- a/code/game/machinery/nuclear_bomb.dm +++ b/code/game/machinery/nuclear_bomb.dm @@ -43,20 +43,20 @@ var/bomb_set SSnanoui.update_uis(src) return -/obj/machinery/nuclearbomb/attackby(obj/item/O as obj, mob/user as mob, params) - if (O.isscrewdriver()) +/obj/machinery/nuclearbomb/attackby(obj/item/attacking_item, mob/user, params) + if (attacking_item.isscrewdriver()) src.add_fingerprint(user) if (src.auth) if (panel_open == 0) panel_open = 1 add_overlay("panel_open") to_chat(user, "You unscrew the control panel of [src].") - playsound(src, O.usesound, 50, 1) + playsound(src, attacking_item.usesound, 50, 1) else panel_open = 0 cut_overlay("panel_open") to_chat(user, "You screw the control panel of [src] back on.") - playsound(src, O.usesound, 50, 1) + playsound(src, attacking_item.usesound, 50, 1) else if (panel_open == 0) to_chat(user, "\The [src] emits a buzzing noise, the panel staying locked in.") @@ -64,78 +64,78 @@ var/bomb_set panel_open = 0 cut_overlay("panel_open") to_chat(user, "You screw the control panel of \the [src] back on.") - playsound(src, O.usesound, 50, 1) + playsound(src, attacking_item.usesound, 50, 1) flick("lock", src) return TRUE - if (panel_open && (O.ismultitool() || O.iswirecutter())) + if (panel_open && (attacking_item.ismultitool() || attacking_item.iswirecutter())) return attack_hand(user) if (src.extended) - if (istype(O, /obj/item/disk/nuclear)) - usr.drop_from_inventory(O,src) - src.auth = O + if (istype(attacking_item, /obj/item/disk/nuclear)) + usr.drop_from_inventory(attacking_item,src) + src.auth = attacking_item src.add_fingerprint(user) return attack_hand(user) if (src.anchored) switch(removal_stage) if(0) - if(O.iswelder()) - var/obj/item/weldingtool/WT = O + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) return TRUE if (WT.get_fuel() < 5) // uses up 5 fuel. to_chat(user, "You need more fuel to complete this task.") return TRUE - user.visible_message("[user] starts cutting loose the anchoring bolt covers on [src].", "You start cutting loose the anchoring bolt covers with [O]...") + user.visible_message("[user] starts cutting loose the anchoring bolt covers on [src].", "You start cutting loose the anchoring bolt covers with [attacking_item]...") - if(O.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src || !user || !WT.use(5, user)) return TRUE user.visible_message("[user] cuts through the bolt covers on [src].", "You cut through the bolt cover.") removal_stage = 1 return TRUE if(1) - if(O.iscrowbar()) - user.visible_message("[user] starts forcing open the bolt covers on [src].", "You start forcing open the anchoring bolt covers with [O]...") + if(attacking_item.iscrowbar()) + user.visible_message("[user] starts forcing open the bolt covers on [src].", "You start forcing open the anchoring bolt covers with [attacking_item]...") - if(O.use_tool(src, user, 15, volume = 50)) + if(attacking_item.use_tool(src, user, 15, volume = 50)) if(!src || !user) return TRUE user.visible_message("[user] forces open the bolt covers on [src].", "You force open the bolt covers.") removal_stage = 2 return TRUE if(2) - if(O.iswelder()) - var/obj/item/weldingtool/WT = O + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) return TRUE if (WT.get_fuel() < 5) // uses up 5 fuel. to_chat(user, "You need more fuel to complete this task.") return TRUE - user.visible_message("[user] starts cutting apart the anchoring system sealant on [src].", "You start cutting apart the anchoring system's sealant with [O]...") + user.visible_message("[user] starts cutting apart the anchoring system sealant on [src].", "You start cutting apart the anchoring system's sealant with [attacking_item]...") - if(O.use_tool(src, user, 150, amount = 5, volume = 50)) + if(attacking_item.use_tool(src, user, 150, amount = 5, volume = 50)) user.visible_message("[user] cuts apart the anchoring system sealant on [src].", "You cut apart the anchoring system's sealant.") removal_stage = 3 return TRUE if(3) - if(O.iswrench()) + if(attacking_item.iswrench()) user.visible_message("[user] begins unwrenching the anchoring bolts on [src].", "You begin unwrenching the anchoring bolts...") - if(O.use_tool(src, user, 50, volume = 50)) + if(attacking_item.use_tool(src, user, 50, volume = 50)) if(!src || !user) return TRUE user.visible_message("[user] unwrenches the anchoring bolts on [src].", "You unwrench the anchoring bolts.") removal_stage = 4 return TRUE if(4) - if(O.iscrowbar()) + if(attacking_item.iscrowbar()) user.visible_message("[user] begins lifting [src] off of the anchors.", "You begin lifting the device off the anchors...") - if(O.use_tool(src, user, 80, volume = 50)) + if(attacking_item.use_tool(src, user, 80, volume = 50)) if(!src || !user) return TRUE user.visible_message("[user] crowbars [src] off of the anchors. It can now be moved.", "You jam the crowbar under the nuclear device and lift it off its anchors. You can now move it!") anchored = 0 diff --git a/code/game/machinery/pipe/construction.dm b/code/game/machinery/pipe/construction.dm index e4b2f399c06..5638c5925f0 100644 --- a/code/game/machinery/pipe/construction.dm +++ b/code/game/machinery/pipe/construction.dm @@ -490,15 +490,15 @@ /obj/item/pipe/attack_self(mob/user as mob) return rotate() -/obj/item/pipe/attackby(var/obj/item/W as obj, var/mob/user as mob) +/obj/item/pipe/attackby(obj/item/attacking_item, mob/user) ..() //* - if (!W.iswrench() && !istype(W, /obj/item/pipewrench)) + if (!attacking_item.iswrench() && !istype(attacking_item, /obj/item/pipewrench)) return ..() - if(istype(W, /obj/item/pipewrench)) - var/action = alert(user, "Change pipe?", "Change pipe", "Yes", "No") + if(istype(attacking_item, /obj/item/pipewrench)) + var/action = tgui_input_list(user, "Change pipe?", "Change pipe", list("Yes", "No"), "No") if(action == "Yes") - action = alert(user, "Change pipe type?", "Change pipe", "Yes", "No") + action = tgui_input_list(user, "Change pipe type?", "Change pipe", list("Yes", "No"), "No") if(action == "No") if(pipe_type in list (PIPE_SIMPLE_STRAIGHT, PIPE_SIMPLE_BENT, PIPE_SCRUBBERS_STRAIGHT, PIPE_SCRUBBERS_BENT, PIPE_SUPPLY_BENT, PIPE_SUPPLY_STRAIGHT, PIPE_FUEL_STRAIGHT, PIPE_FUEL_BENT, PIPE_AUX_STRAIGHT, PIPE_AUX_BENT)) if(pipe_type in list (PIPE_SIMPLE_STRAIGHT, PIPE_SCRUBBERS_STRAIGHT, PIPE_SUPPLY_STRAIGHT, PIPE_FUEL_STRAIGHT, PIPE_AUX_STRAIGHT)) @@ -1506,7 +1506,7 @@ P.atmos_init() P.build_network() - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) user.visible_message( \ "[user] fastens the [src].", \ "You have fastened the [src].", \ @@ -1528,13 +1528,13 @@ item_state = "buildpipe" w_class = ITEMSIZE_LARGE -/obj/item/pipe_meter/attackby(var/obj/item/W as obj, var/mob/user as mob) - if (W.iswrench()) +/obj/item/pipe_meter/attackby(obj/item/attacking_item, mob/user) + if (attacking_item.iswrench()) if(!locate(/obj/machinery/atmospherics/pipe, src.loc)) to_chat(user, "You need to fasten it to a pipe") return 1 new/obj/machinery/meter( src.loc ) - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) to_chat(user, "You have fastened the meter to the pipe") qdel(src) return TRUE diff --git a/code/game/machinery/pipe/pipe_dispenser.dm b/code/game/machinery/pipe/pipe_dispenser.dm index 33eab437c8b..1e5ae6d9224 100644 --- a/code/game/machinery/pipe/pipe_dispenser.dm +++ b/code/game/machinery/pipe/pipe_dispenser.dm @@ -115,18 +115,18 @@ new /obj/item/pipe_meter(loc) pipe_cooldown = world.time + 1.5 SECONDS -/obj/machinery/pipedispenser/attackby(obj/item/I, mob/user) - if(!istype(I, /obj/item/forensics)) +/obj/machinery/pipedispenser/attackby(obj/item/attacking_item, mob/user) + if(!istype(attacking_item, /obj/item/forensics)) add_fingerprint(user) - if(istype(I, /obj/item/pipe) || istype(I, /obj/item/pipe_meter)) - to_chat(usr, SPAN_NOTICE("You put \the [I] back into \the [src].")) - user.remove_from_mob(I) //Catches robot gripper duplication - qdel(I) + if(istype(attacking_item, /obj/item/pipe) || istype(attacking_item, /obj/item/pipe_meter)) + to_chat(usr, SPAN_NOTICE("You put \the [attacking_item] back into \the [src].")) + user.remove_from_mob(attacking_item) //Catches robot gripper duplication + qdel(attacking_item) return TRUE - else if(I.iswrench()) + else if(attacking_item.iswrench()) if(anchored) to_chat(user, SPAN_NOTICE("You begin to unfasten \the [src] from the floor...")) - if(I.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) user.visible_message("[user] unfastens \the [src].", SPAN_NOTICE("You have unfastened \the [src]. Now it can be pulled somewhere else."), SPAN_NOTICE("You hear a ratcheting noise.")) anchored = FALSE stat |= MAINT @@ -134,7 +134,7 @@ usr << browse(null, "window=[window_id]") else to_chat(user, SPAN_NOTICE("You begin to fasten \the [src] to the floor...")) - if(I.use_tool(src, user, 20, volume = 50)) + if(attacking_item.use_tool(src, user, 20, volume = 50)) user.visible_message("[user] fastens \the [src].", SPAN_NOTICE("You have fastened \the [src]. Now it can dispense pipes."), SPAN_NOTICE("You hear a ratcheting noise.")) anchored = TRUE stat &= ~MAINT diff --git a/code/game/machinery/portable_turret.dm b/code/game/machinery/portable_turret.dm index d78de3369dc..075fb2cc38c 100644 --- a/code/game/machinery/portable_turret.dm +++ b/code/game/machinery/portable_turret.dm @@ -79,7 +79,7 @@ var/old_angle = 0 -/obj/machinery/porta_turret/examine(mob/user) +/obj/machinery/porta_turret/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() var/msg = "" if(!health) @@ -92,7 +92,7 @@ msg += SPAN_NOTICE("\The [src] is slightly damaged!") else msg += SPAN_GOOD("\The [src] is not damaged!") - to_chat(user, msg) + . += msg /obj/machinery/porta_turret/crescent enabled = FALSE @@ -317,13 +317,13 @@ stat |= NOPOWER queue_icon_update() -/obj/machinery/porta_turret/attackby(obj/item/I, mob/user) +/obj/machinery/porta_turret/attackby(obj/item/attacking_item, mob/user) if(stat & BROKEN) - if(I.iscrowbar()) + if(attacking_item.iscrowbar()) //If the turret is destroyed, you can remove it with a crowbar to //try and salvage its components to_chat(user, "You begin prying the metal coverings off.") - if(I.use_tool(src, user, 20, volume = 50)) + if(attacking_item.use_tool(src, user, 20, volume = 50)) if(prob(70) && !no_salvage) to_chat(user, "You remove the turret and salvage some components.") if(installation) @@ -338,7 +338,7 @@ qdel(src) // qdel return TRUE - else if((I.iswrench())) + else if((attacking_item.iswrench())) if (immobile) to_chat(user, "[src] is firmly attached to the ground with some form of epoxy.") return TRUE @@ -359,22 +359,22 @@ ) wrenching = 1 - if(I.use_tool(src, user, 50, volume = 50)) + if(attacking_item.use_tool(src, user, 50, volume = 50)) //This code handles moving the turret around. After all, it's a portable turret! if(!anchored) - playsound(loc, I.usesound, 100, 1) + playsound(loc, attacking_item.usesound, 100, 1) anchored = 1 update_icon() to_chat(user, "You secure the exterior bolts on the turret.") else if(anchored) - playsound(loc, I.usesound, 100, 1) + playsound(loc, attacking_item.usesound, 100, 1) anchored = 0 to_chat(user, "You unsecure the exterior bolts on the turret.") update_icon() wrenching = 0 return TRUE - else if(I.GetID()) + else if(attacking_item.GetID()) //Behavior lock/unlock mangement if(allowed(user)) locked = !locked @@ -384,8 +384,8 @@ to_chat(user, "Access denied.") return TRUE - else if(I.iswelder()) - var/obj/item/weldingtool/WT = I + else if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if (!WT.welding) to_chat(user, "\The [WT] must be turned on!") else if (health == maxhealth) @@ -407,8 +407,8 @@ else //if the turret was attacked with the intention of harming it: user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - take_damage(I.force * 0.5) - if(I.force * 0.5 > 1) //if the force of impact dealt at least 1 damage, the turret gets pissed off + take_damage(attacking_item.force * 0.5) + if(attacking_item.force * 0.5 > 1) //if the force of impact dealt at least 1 damage, the turret gets pissed off if(!attacked && !emagged) attacked = 1 addtimer(CALLBACK(src, PROC_REF(reset_attacked)), 1 SECONDS, TIMER_UNIQUE | TIMER_OVERRIDE) @@ -836,28 +836,28 @@ icon_state = "turret_frame_0_1" case_sprite_set = 1 -/obj/machinery/porta_turret_construct/attackby(obj/item/I, mob/user) +/obj/machinery/porta_turret_construct/attackby(obj/item/attacking_item, mob/user) //this is a bit unwieldy but self-explanatory switch(build_step) if(0) //first step - if(I.iswrench() && !anchored) - playsound(loc, I.usesound, 100, 1) + if(attacking_item.iswrench() && !anchored) + playsound(loc, attacking_item.usesound, 100, 1) to_chat(user, "You secure the external bolts.") anchored = 1 build_step = 1 icon_state = "turret_frame_1_[case_sprite_set]" return TRUE - else if(I.iscrowbar() && !anchored) - playsound(loc, I.usesound, 75, 1) + else if(attacking_item.iscrowbar() && !anchored) + playsound(loc, attacking_item.usesound, 75, 1) to_chat(user, "You dismantle the turret construction.") new /obj/item/stack/material/steel( loc, 5) qdel(src) return TRUE if(1) - if(istype(I, /obj/item/stack/material) && I.get_material_name() == DEFAULT_WALL_MATERIAL) - var/obj/item/stack/M = I + if(istype(attacking_item, /obj/item/stack/material) && attacking_item.get_material_name() == DEFAULT_WALL_MATERIAL) + var/obj/item/stack/M = attacking_item if(M.use(2)) to_chat(user, "You add some metal armor to the interior frame.") build_step = 2 @@ -866,8 +866,8 @@ to_chat(user, "You need two sheets of metal to continue construction.") return TRUE - else if(I.iswrench()) - playsound(loc, I.usesound, 75, 1) + else if(attacking_item.iswrench()) + playsound(loc, attacking_item.usesound, 75, 1) to_chat(user, "You unfasten the external bolts.") anchored = 0 build_step = 0 @@ -876,15 +876,15 @@ if(2) - if(I.iswrench()) - playsound(loc, I.usesound, 100, 1) + if(attacking_item.iswrench()) + playsound(loc, attacking_item.usesound, 100, 1) to_chat(user, "You bolt the metal armor into place.") build_step = 3 icon_state = "turret_frame_3_[case_sprite_set]" return TRUE - else if(I.iswelder()) - var/obj/item/weldingtool/WT = I + else if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) return TRUE if(WT.get_fuel() < 5) //uses up 5 fuel. @@ -892,7 +892,7 @@ return TRUE playsound(loc, pick('sound/items/Welder.ogg', 'sound/items/welder_pry.ogg'), 50, 1) - if(I.use_tool(src, user, 20, volume = 50)) + if(attacking_item.use_tool(src, user, 20, volume = 50)) if(!src || !WT.use(5, user)) return TRUE build_step = 1 to_chat(user, "You remove the turret's interior metal armor.") @@ -902,45 +902,45 @@ if(3) - if(istype(I, /obj/item/gun/energy)) //the gun installation part - E = I //typecasts the item to a gun + if(istype(attacking_item, /obj/item/gun/energy)) //the gun installation part + E = attacking_item //typecasts the item to a gun if(E.can_turret) if(isrobot(user)) return TRUE - if(!user.unEquip(I)) - to_chat(user, "\the [I] is stuck to your hand, you cannot put it in \the [src]") + if(!user.unEquip(attacking_item)) + to_chat(user, "\the [attacking_item] is stuck to your hand, you cannot put it in \the [src]") return TRUE - to_chat(user, "You install [I] into the turret.") + to_chat(user, "You install [attacking_item] into the turret.") user.drop_from_inventory(E,src) target_type = /obj/machinery/porta_turret - installation = I //installation becomes I.type + installation = attacking_item //installation becomes I.type build_step = 4 icon_state = "turret_frame_4_[case_sprite_set]" add_overlay("turret_[E.turret_sprite_set]_off") return TRUE - else if(I.iswrench()) - playsound(loc, I.usesound, 100, 1) + else if(attacking_item.iswrench()) + playsound(loc, attacking_item.usesound, 100, 1) to_chat(user, "You remove the turret's metal armor bolts.") build_step = 2 icon_state = "turret_frame_2_[case_sprite_set]" return TRUE if(4) - if(isprox(I)) + if(isprox(attacking_item)) build_step = 5 - if(!user.unEquip(I)) - to_chat(user, "\the [I] is stuck to your hand, you cannot put it in \the [src]") + if(!user.unEquip(attacking_item)) + to_chat(user, "\the [attacking_item] is stuck to your hand, you cannot put it in \the [src]") return TRUE to_chat(user, "You add the prox sensor to the turret.") - qdel(I) + qdel(attacking_item) return TRUE //attack_hand() removes the gun if(5) - if(I.isscrewdriver()) - playsound(loc, I.usesound, 100, 1) + if(attacking_item.isscrewdriver()) + playsound(loc, attacking_item.usesound, 100, 1) build_step = 6 to_chat(user, "You close the access hatch.") icon_state = "turret_frame_5a_[case_sprite_set]" @@ -951,8 +951,8 @@ //attack_hand() removes the prox sensor if(6) - if(istype(I, /obj/item/stack/material) && I.get_material_name() == DEFAULT_WALL_MATERIAL) - var/obj/item/stack/M = I + if(istype(attacking_item, /obj/item/stack/material) && attacking_item.get_material_name() == DEFAULT_WALL_MATERIAL) + var/obj/item/stack/M = attacking_item if(M.use(2)) to_chat(user, "You add some metal armor to the exterior frame.") cut_overlays() @@ -964,8 +964,8 @@ to_chat(user, "You need two sheets of metal to continue construction.") return TRUE - else if(I.isscrewdriver()) - playsound(loc, I.usesound, 100, 1) + else if(attacking_item.isscrewdriver()) + playsound(loc, attacking_item.usesound, 100, 1) build_step = 5 to_chat(user, "You open the access hatch.") cut_overlays() @@ -974,14 +974,14 @@ return TRUE if(7) - if(I.iswelder()) - var/obj/item/weldingtool/WT = I + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) return if(WT.get_fuel() < 5) to_chat(user, "You need more fuel to complete this task.") playsound(loc, pick('sound/items/Welder.ogg', 'sound/items/welder_pry.ogg'), 50, 1) - if(I.use_tool(src, user, 30, volume = 50)) + if(attacking_item.use_tool(src, user, 30, volume = 50)) if(!src || !WT.use(5, user)) return build_step = 8 @@ -1020,8 +1020,8 @@ qdel(src) // qdel return TRUE - else if(I.iscrowbar()) - playsound(loc, I.usesound, 75, 1) + else if(attacking_item.iscrowbar()) + playsound(loc, attacking_item.usesound, 75, 1) to_chat(user, "You pry off the turret's exterior armor.") new /obj/item/stack/material/steel(loc, 2) build_step = 6 @@ -1031,7 +1031,7 @@ add_overlay("turret_frame_5c_[case_sprite_set]") return TRUE - if(I.ispen()) //you can rename turrets like bots! + if(attacking_item.ispen()) //you can rename turrets like bots! var/t = sanitizeSafe(input(user, "Enter new turret name", name, finish_name) as text, MAX_NAME_LEN) if(t && in_range(src, usr) && loc != usr) finish_name = t diff --git a/code/game/machinery/recharger.dm b/code/game/machinery/recharger.dm index a656b4bbd14..f78c4831d89 100644 --- a/code/game/machinery/recharger.dm +++ b/code/game/machinery/recharger.dm @@ -32,9 +32,9 @@ var/portable = 1 var/list/chargebars -/obj/machinery/recharger/examine(mob/user, distance, is_adjacent) +/obj/machinery/recharger/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "There is [charging ? "\a [charging]" : "nothing"] in [src].") + . += "There is [charging ? "\a [charging]" : "nothing"] in [src]." if (charging && distance <= 3) var/obj/item/cell/C = charging.get_cell() if (istype(C) && user.client && (!user.progressbars || !user.progressbars[src])) @@ -48,18 +48,18 @@ LAZYREMOVE(chargebars, bar) qdel(bar) -/obj/machinery/recharger/attackby(obj/item/G, mob/user) - if(portable && G.iswrench()) +/obj/machinery/recharger/attackby(obj/item/attacking_item, mob/user) + if(portable && attacking_item.iswrench()) if(charging) to_chat(user, SPAN_WARNING("You can't modify \the [src] while it has something charging inside.")) return TRUE anchored = !anchored user.visible_message("[user] [anchored ? "attaches" : "detaches"] \the [src].", SPAN_NOTICE("You [anchored ? "attach" : "detach"] \the [src].")) - playsound(loc, G.usesound, 75, 1) + playsound(loc, attacking_item.usesound, 75, 1) return TRUE - if (istype(G, /obj/item/gripper))//Code for allowing cyborgs to use rechargers - var/obj/item/gripper/Gri = G + if (istype(attacking_item, /obj/item/gripper))//Code for allowing cyborgs to use rechargers + var/obj/item/gripper/Gri = attacking_item if (charging)//If there's something in the charger if (Gri.grip_item(charging, user))//we attempt to grab it charging = null @@ -68,13 +68,13 @@ to_chat(user, SPAN_DANGER("Your gripper cannot hold \the [charging].")) return TRUE - if(!G.dropsafety()) + if(!attacking_item.dropsafety()) return TRUE - if(is_type_in_list(G, allowed_devices)) - if (G.get_cell() == DEVICE_NO_CELL) - if (G.charge_failure_message) - to_chat(user, SPAN_WARNING("\The [G][G.charge_failure_message]")) + if(is_type_in_list(attacking_item, allowed_devices)) + if (attacking_item.get_cell() == DEVICE_NO_CELL) + if (attacking_item.charge_failure_message) + to_chat(user, SPAN_WARNING("\The [attacking_item][attacking_item.charge_failure_message]")) return TRUE if(charging) to_chat(user, SPAN_WARNING("\A [charging] is already charging here.")) @@ -84,8 +84,8 @@ to_chat(user, SPAN_WARNING("\The [name] blinks red as you try to insert the item!")) return TRUE - user.drop_from_inventory(G,src) - charging = G + user.drop_from_inventory(attacking_item,src) + charging = attacking_item update_icon() return TRUE diff --git a/code/game/machinery/rechargestation.dm b/code/game/machinery/rechargestation.dm index 39dfcdbbda2..fedb9c00c47 100644 --- a/code/game/machinery/rechargestation.dm +++ b/code/game/machinery/rechargestation.dm @@ -110,9 +110,9 @@ D.upgrade_cooldown = world.time + 1 MINUTE D.master_matrix.apply_upgrades(D) -/obj/machinery/recharge_station/examine(mob/user) +/obj/machinery/recharge_station/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "The charge meter reads: [round(chargepercentage())]%.") + . += "The charge meter reads: [round(chargepercentage())]%." /obj/machinery/recharge_station/proc/chargepercentage() if(!cell) @@ -133,17 +133,17 @@ if(cell) cell.emp_act(severity) -/obj/machinery/recharge_station/attackby(var/obj/item/O as obj, var/mob/user as mob) +/obj/machinery/recharge_station/attackby(obj/item/attacking_item, mob/user) if(!occupant) - if(default_deconstruction_screwdriver(user, O)) + if(default_deconstruction_screwdriver(user, attacking_item)) return TRUE - else if(default_deconstruction_crowbar(user, O)) + else if(default_deconstruction_crowbar(user, attacking_item)) return TRUE - else if(default_part_replacement(user, O)) + else if(default_part_replacement(user, attacking_item)) return TRUE - if(istype(O, /obj/item/grab)) - var/obj/item/grab/grab = O + if(istype(attacking_item, /obj/item/grab)) + var/obj/item/grab/grab = attacking_item var/mob/living/L = grab.affecting if(!L.isSynthetic()) return TRUE @@ -153,7 +153,7 @@ return TRUE move_ipc(grab.affecting) - qdel(O) + qdel(attacking_item) return ..() /obj/machinery/recharge_station/RefreshParts() diff --git a/code/game/machinery/requests_console.dm b/code/game/machinery/requests_console.dm index 3a90b868f19..20126587335 100644 --- a/code/game/machinery/requests_console.dm +++ b/code/game/machinery/requests_console.dm @@ -441,15 +441,15 @@ var/list/obj/machinery/requests_console/allConsoles = list() return //err... hacking code, which has no reason for existing... but anyway... it was once supposed to unlock priority 3 messanging on that console (EXTREME priority...), but the code for that was removed. -/obj/machinery/requests_console/attackby(var/obj/item/O as obj, var/mob/user as mob) - if (istype(O, /obj/item/card/id)) +/obj/machinery/requests_console/attackby(obj/item/attacking_item, mob/user) + if (istype(attacking_item, /obj/item/card/id)) if(inoperable(MAINT)) return TRUE if(screen == RCS_MESSAUTH) - var/obj/item/card/id/T = O + var/obj/item/card/id/T = attacking_item msgVerified = text("Verified by [T.registered_name], [T.assignment]") updateUsrDialog() if(screen == RCS_ANNOUNCE) - var/obj/item/card/id/ID = O + var/obj/item/card/id/ID = attacking_item if (ACCESS_RC_ANNOUNCE in ID.GetAccess()) announceAuth = 1 announcement.announcer = ID.assignment ? "[ID.assignment] [ID.registered_name]" : ID.registered_name @@ -458,17 +458,17 @@ var/list/obj/machinery/requests_console/allConsoles = list() to_chat(user, "You are not authorized to send announcements.") updateUsrDialog() return TRUE - else if (istype(O, /obj/item/stamp)) + else if (istype(attacking_item, /obj/item/stamp)) if(inoperable(MAINT)) return if(screen == RCS_MESSAUTH) - var/obj/item/stamp/T = O + var/obj/item/stamp/T = attacking_item msgStamped = text("Stamped with the [T.name]") updateUsrDialog() return TRUE - else if (istype(O, /obj/item/paper_bundle)) - var/obj/item/paper_bundle/C = O + else if (istype(attacking_item, /obj/item/paper_bundle)) + var/obj/item/paper_bundle/C = attacking_item if(lid) - if(alert(user, "Do you want to restock \the [src] with \the [O]?", "Paper Restocking", "Yes", "No") == "No") + if(alert(user, "Do you want to restock \the [src] with \the [attacking_item]?", "Paper Restocking", "Yes", "No") == "No") to_chat(user, SPAN_NOTICE("You decide against restocking \the [src], noting that the lid is still open.")) return paperstock += C.amount @@ -476,20 +476,20 @@ var/list/obj/machinery/requests_console/allConsoles = list() qdel(C) audible_message("The Requests Console beeps, \"Paper added.\"") else if(screen == RCS_MAINMENU) //Faxing them papers - fax_send(O, user) + fax_send(attacking_item, user) return TRUE - else if (istype(O, /obj/item/paper)) + else if (istype(attacking_item, /obj/item/paper)) if(lid) - if(alert(user, "Do you want to restock \the [src] with \the [O]?", "Paper Restocking", "Yes", "No") == "No") + if(alert(user, "Do you want to restock \the [src] with \the [attacking_item]?", "Paper Restocking", "Yes", "No") == "No") to_chat(user, SPAN_NOTICE("You decide against restocking \the [src], noting that the lid is still open.")) return - var/obj/item/paper/C = O + var/obj/item/paper/C = attacking_item user.drop_from_inventory(C,get_turf(src)) qdel(C) paperstock++ audible_message("The Requests Console beeps, \"Paper added.\"") else if(screen == RCS_MAINMENU) //Faxing them papers - fax_send(O, user) + fax_send(attacking_item, user) return TRUE /obj/machinery/requests_console/proc/can_send() diff --git a/code/game/machinery/ringer.dm b/code/game/machinery/ringer.dm index 22c93c8ccb1..2cf68461731 100644 --- a/code/game/machinery/ringer.dm +++ b/code/game/machinery/ringer.dm @@ -104,22 +104,22 @@ pixel_x = 8; add_overlay(screen_overlays["bell-standby"]) set_light(1.4, 1, COLOR_CYAN) -/obj/machinery/ringer/attackby(obj/item/C as obj, mob/living/user as mob) +/obj/machinery/ringer/attackby(obj/item/attacking_item, mob/user) if(stat & (BROKEN|NOPOWER) || !istype(user,/mob/living)) return TRUE - if (istype(C, /obj/item/modular_computer)) - if(!check_access(C)) + if (istype(attacking_item, /obj/item/modular_computer)) + if(!check_access(attacking_item)) to_chat(user, "Access Denied.") return TRUE - else if (C in rings_pdas) - to_chat(user, "You unlink \the [C] from \the [src].") - remove_pda(C) + else if (attacking_item in rings_pdas) + to_chat(user, "You unlink \the [attacking_item] from \the [src].") + remove_pda(attacking_item) return TRUE - to_chat(user, "You link \the [C] to \the [src], it will now ring upon someone using \the [src].") - rings_pdas += C + to_chat(user, "You link \the [attacking_item] to \the [src], it will now ring upon someone using \the [src].") + rings_pdas += attacking_item // WONT FIX: This requires callbacks fuck my dick. - GLOB.destroyed_event.register(C, src, PROC_REF(remove_pda)) + GLOB.destroyed_event.register(attacking_item, src, PROC_REF(remove_pda)) update_icon() return TRUE else diff --git a/code/game/machinery/seed_extractor.dm b/code/game/machinery/seed_extractor.dm index 397ff73874d..74430506679 100644 --- a/code/game/machinery/seed_extractor.dm +++ b/code/game/machinery/seed_extractor.dm @@ -6,37 +6,37 @@ density = 1 anchored = 1 -/obj/machinery/seed_extractor/attackby(var/obj/item/O as obj, var/mob/user as mob) +/obj/machinery/seed_extractor/attackby(obj/item/attacking_item, mob/user) // Fruits and vegetables. - if(istype(O, /obj/item/reagent_containers/food/snacks/grown) || istype(O, /obj/item/grown)) + if(istype(attacking_item, /obj/item/reagent_containers/food/snacks/grown) || istype(attacking_item, /obj/item/grown)) - user.remove_from_mob(O) + user.remove_from_mob(attacking_item) var/datum/seed/new_seed_type - if(istype(O, /obj/item/grown)) - var/obj/item/grown/F = O + if(istype(attacking_item, /obj/item/grown)) + var/obj/item/grown/F = attacking_item new_seed_type = SSplants.seeds[F.plantname] else - var/obj/item/reagent_containers/food/snacks/grown/F = O + var/obj/item/reagent_containers/food/snacks/grown/F = attacking_item new_seed_type = SSplants.seeds[F.plantname] if(new_seed_type) - to_chat(user, "You extract some seeds from [O].") + to_chat(user, "You extract some seeds from [attacking_item].") var/produce = rand(1,4) for(var/i = 0;i<=produce;i++) var/obj/item/seeds/seeds = new(get_turf(src)) seeds.seed_type = new_seed_type.name seeds.update_seed() else - to_chat(user, "[O] doesn't seem to have any usable seeds inside it.") + to_chat(user, "[attacking_item] doesn't seem to have any usable seeds inside it.") - qdel(O) + qdel(attacking_item) return TRUE //Grass. - else if(istype(O, /obj/item/stack/tile/grass)) - var/obj/item/stack/tile/grass/S = O + else if(istype(attacking_item, /obj/item/stack/tile/grass)) + var/obj/item/stack/tile/grass/S = attacking_item if (S.use(1)) to_chat(user, "You extract some seeds from the grass tile.") new /obj/item/seeds/grassseed(loc) diff --git a/code/game/machinery/spaceheater.dm b/code/game/machinery/spaceheater.dm index 93dbcded365..ab61436dfc3 100644 --- a/code/game/machinery/spaceheater.dm +++ b/code/game/machinery/spaceheater.dm @@ -36,14 +36,13 @@ if(panel_open) add_overlay("sheater-open") -/obj/machinery/space_heater/examine(mob/user) +/obj/machinery/space_heater/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - - to_chat(user, "The heater is [on ? "on" : "off"] and the hatch is [panel_open ? "open" : "closed"].") + . += "The heater is [on ? "on" : "off"] and the hatch is [panel_open ? "open" : "closed"]." if(panel_open) - to_chat(user, "The power cell is [cell ? "installed" : "missing"].") + . += "The power cell is [cell ? "installed" : "missing"]." else - to_chat(user, "The charge meter reads [cell ? round(cell.percent(),1) : 0]%") + . += "The charge meter reads [cell ? round(cell.percent(),1) : 0]%" return /obj/machinery/space_heater/powered() @@ -60,16 +59,16 @@ if(cell) cell.emp_act(severity) -/obj/machinery/space_heater/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/cell)) +/obj/machinery/space_heater/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/cell)) if(panel_open) if(cell) to_chat(user, "There is already a power cell inside.") else // insert cell - user.drop_from_inventory(I,src) - cell = I - I.add_fingerprint(user) + user.drop_from_inventory(attacking_item,src) + cell = attacking_item + attacking_item.add_fingerprint(user) visible_message(SPAN_NOTICE("[user] inserts a power cell into [src]."), SPAN_NOTICE("You insert the power cell into [src].")) @@ -77,7 +76,7 @@ else to_chat(user, SPAN_NOTICE("The hatch must be open to insert a power cell.")) return TRUE - else if(I.isscrewdriver()) + else if(attacking_item.isscrewdriver()) panel_open = !panel_open user.visible_message(SPAN_NOTICE("[user] [panel_open ? "opens" : "closes"] the hatch on the [src]."), SPAN_NOTICE("You [panel_open ? "open" : "close"] the hatch on the [src].")) diff --git a/code/game/machinery/stargazer.dm b/code/game/machinery/stargazer.dm index 872dcae64aa..04441f224e3 100644 --- a/code/game/machinery/stargazer.dm +++ b/code/game/machinery/stargazer.dm @@ -14,10 +14,10 @@ star_system_image = image(icon, null, "stargazer_[SSatlas.current_sector.name]", EFFECTS_ABOVE_LIGHTING_LAYER) power_change() -/obj/machinery/stargazer/examine(mob/user) +/obj/machinery/stargazer/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!(stat & BROKEN) && !(stat & NOPOWER)) - to_chat(user, SPAN_NOTICE("\The [src] shows the current sector to be [SSatlas.current_sector.name].")) + . += SPAN_NOTICE("\The [src] shows the current sector to be [SSatlas.current_sector.name].") /obj/machinery/stargazer/power_change() ..() diff --git a/code/game/machinery/stasis_bed.dm b/code/game/machinery/stasis_bed.dm index 46a58de739f..ce81efc1adc 100644 --- a/code/game/machinery/stasis_bed.dm +++ b/code/game/machinery/stasis_bed.dm @@ -31,12 +31,12 @@ . = ..() update_icon() -/obj/machinery/stasis_bed/attackby(obj/item/I, mob/user) - if(default_part_replacement(user, I)) +/obj/machinery/stasis_bed/attackby(obj/item/attacking_item, mob/user) + if(default_part_replacement(user, attacking_item)) return TRUE - else if(default_deconstruction_screwdriver(user, I)) + else if(default_deconstruction_screwdriver(user, attacking_item)) return TRUE - else if(default_deconstruction_crowbar(user, I)) + else if(default_deconstruction_crowbar(user, attacking_item)) return TRUE return ..() diff --git a/code/game/machinery/status_display.dm b/code/game/machinery/status_display.dm index b7785ff4318..9008e125fda 100644 --- a/code/game/machinery/status_display.dm +++ b/code/game/machinery/status_display.dm @@ -137,10 +137,10 @@ return 1 return 0 -/obj/machinery/status_display/examine(mob/user) +/obj/machinery/status_display/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(mode != STATUS_DISPLAY_BLANK && mode != STATUS_DISPLAY_ALERT) - to_chat(user, "The display says:
\t[sanitize(message1)]
\t[sanitize(message2)]") + . += "The display says:
\t[sanitize(message1)]
\t[sanitize(message2)]" /obj/machinery/status_display/proc/set_message(m1, m2) if(m1) diff --git a/code/game/machinery/suit_cycler.dm b/code/game/machinery/suit_cycler.dm index 5d38367c010..c986db67ef6 100644 --- a/code/game/machinery/suit_cycler.dm +++ b/code/game/machinery/suit_cycler.dm @@ -1,25 +1,25 @@ // Commonly used code #define TRY_INSERT_SUIT_PIECE(slot, path)\ - if(istype(I, /obj/item/##path)){\ + if(istype(attacking_item, /obj/item/##path)){\ if(active || locked) {\ FEEDBACK_FAILURE(user, "\The [src] is locked.");\ return\ };\ if(occupant) {\ - FEEDBACK_FAILURE(user, "There is no space in \the [src] for \the [I]!");\ + FEEDBACK_FAILURE(user, "There is no space in \the [src] for \the [attacking_item]!");\ return\ };\ if(##slot){\ FEEDBACK_FAILURE(user, "\The [src] already contains \a [slot]!");\ return\ };\ - if(I.icon_override == CUSTOM_ITEM_MOB){\ + if(attacking_item.icon_override == CUSTOM_ITEM_MOB){\ FEEDBACK_FAILURE(user, "You cannot insert a customized voidsuit.");\ return\ };\ - to_chat(user, SPAN_NOTICE("You load \the [I] into the storage compartment."));\ - user.drop_from_inventory(I, src);\ - ##slot = I;\ + to_chat(user, SPAN_NOTICE("You load \the [attacking_item] into the storage compartment."));\ + user.drop_from_inventory(attacking_item, src);\ + ##slot = attacking_item;\ update_icon();\ updateUsrDialog();\ return\ @@ -175,12 +175,12 @@ return return src.attack_hand(user) -/obj/machinery/suit_cycler/attackby(obj/item/I, mob/user) +/obj/machinery/suit_cycler/attackby(obj/item/attacking_item, mob/user) if(electrified != 0) if(src.shock(user, 100)) return - if(I.GetID()) + if(attacking_item.GetID()) if(allowed(user)) locked = !locked to_chat(user, SPAN_NOTICE("You [locked ? "" : "un"]lock \the [src].")) @@ -189,14 +189,14 @@ return //Hacking init. - if(I.ismultitool() || I.iswirecutter()) + if(attacking_item.ismultitool() || attacking_item.iswirecutter()) if(panel_open) wires.interact(user) return //Other interface stuff. - if(istype(I, /obj/item/grab)) - var/obj/item/grab/G = I + if(istype(attacking_item, /obj/item/grab)) + var/obj/item/grab/G = attacking_item if(G.state < GRAB_NECK) to_chat(user, SPAN_WARNING("You need a stronger grip to do this!")) return @@ -235,7 +235,7 @@ updateUsrDialog() update_icon() return - else if(I.isscrewdriver()) + else if(attacking_item.isscrewdriver()) panel_open = !panel_open to_chat(user, SPAN_NOTICE("You [panel_open ? "open" : "close"] the maintenance panel.")) updateUsrDialog() diff --git a/code/game/machinery/suit_storage_unit.dm b/code/game/machinery/suit_storage_unit.dm index 735653270ea..71542ac2a0c 100644 --- a/code/game/machinery/suit_storage_unit.dm +++ b/code/game/machinery/suit_storage_unit.dm @@ -464,18 +464,18 @@ return -/obj/machinery/suit_storage_unit/attackby(obj/item/I as obj, mob/user as mob) +/obj/machinery/suit_storage_unit/attackby(obj/item/attacking_item, mob/user) if(!src.ispowered) return TRUE - if(I.isscrewdriver()) + if(attacking_item.isscrewdriver()) src.panelopen = !src.panelopen - playsound(src.loc, I.usesound, 100, 1) + playsound(src.loc, attacking_item.usesound, 100, 1) to_chat(user, text("You [] the unit's maintenance panel.",(src.panelopen ? "open up" : "close") )) update_icon() src.updateUsrDialog() return TRUE - if ( istype(I, /obj/item/grab) ) - var/obj/item/grab/G = I + if ( istype(attacking_item, /obj/item/grab) ) + var/obj/item/grab/G = attacking_item if( !(ismob(G.affecting)) ) return TRUE if (!src.isopen) @@ -503,10 +503,10 @@ src.update_icon() return TRUE return TRUE - if( istype(I,/obj/item/clothing/suit/space) ) + if( istype(attacking_item,/obj/item/clothing/suit/space) ) if(!src.isopen) return TRUE - var/obj/item/clothing/suit/space/S = I + var/obj/item/clothing/suit/space/S = attacking_item if(src.SUIT) to_chat(user, "The unit already contains a suit.") return TRUE @@ -516,10 +516,10 @@ src.update_icon() src.updateUsrDialog() return TRUE - if( istype(I,/obj/item/clothing/head/helmet) ) + if( istype(attacking_item,/obj/item/clothing/head/helmet) ) if(!src.isopen) return TRUE - var/obj/item/clothing/head/helmet/H = I + var/obj/item/clothing/head/helmet/H = attacking_item if(src.HELMET) to_chat(user, "The unit already contains a helmet.") return TRUE @@ -529,10 +529,10 @@ src.update_icon() src.updateUsrDialog() return TRUE - if( istype(I,/obj/item/clothing/mask) ) + if( istype(attacking_item,/obj/item/clothing/mask) ) if(!src.isopen) return TRUE - var/obj/item/clothing/mask/M = I + var/obj/item/clothing/mask/M = attacking_item if(src.MASK) to_chat(user, "The unit already contains a mask.") return TRUE diff --git a/code/game/machinery/supplybeacon.dm b/code/game/machinery/supplybeacon.dm index 9558cdcb242..c34dadd9f74 100644 --- a/code/game/machinery/supplybeacon.dm +++ b/code/game/machinery/supplybeacon.dm @@ -44,14 +44,14 @@ name = "supermatter supply beacon" drop_type = "supermatter" -/obj/machinery/power/supply_beacon/attackby(var/obj/item/W, var/mob/user) - if(!use_power && W.iswrench()) +/obj/machinery/power/supply_beacon/attackby(obj/item/attacking_item, mob/user) + if(!use_power && attacking_item.iswrench()) if(!anchored && !connect_to_network()) to_chat(user, "This device must be placed over an exposed cable.") return TRUE anchored = !anchored user.visible_message("\The [user] [anchored ? "secures" : "unsecures"] \the [src].") - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) return TRUE return ..() diff --git a/code/game/machinery/telecomms/computers/logbrowser.dm b/code/game/machinery/telecomms/computers/logbrowser.dm index 5075c00a646..d0232fdcfd3 100644 --- a/code/game/machinery/telecomms/computers/logbrowser.dm +++ b/code/game/machinery/telecomms/computers/logbrowser.dm @@ -146,9 +146,9 @@ updateUsrDialog() return -/obj/machinery/computer/telecomms/server/attackby(var/obj/item/D, var/mob/user) - if(D.isscrewdriver()) - if(D.use_tool(src, user, 20, volume = 50)) +/obj/machinery/computer/telecomms/server/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) + if(attacking_item.use_tool(src, user, 20, volume = 50)) if (src.stat & BROKEN) to_chat(user, "The broken glass falls out.") var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc ) diff --git a/code/game/machinery/telecomms/computers/message.dm b/code/game/machinery/telecomms/computers/message.dm index 819d53b4123..26210cd8a9d 100644 --- a/code/game/machinery/telecomms/computers/message.dm +++ b/code/game/machinery/telecomms/computers/message.dm @@ -42,12 +42,12 @@ linkedServer = null return ..() -/obj/machinery/computer/message_monitor/attackby(obj/item/O as obj, mob/living/user as mob) +/obj/machinery/computer/message_monitor/attackby(obj/item/attacking_item, mob/living/user) if(stat & (NOPOWER|BROKEN)) return ..() if(!istype(user)) return TRUE - if(O.isscrewdriver() && emag) + if(attacking_item.isscrewdriver() && emag) //Stops people from just unscrewing the monitor and putting it back to get the console working again. to_chat(user, "It is too hot to mess with!") return TRUE diff --git a/code/game/machinery/telecomms/computers/telemonitor.dm b/code/game/machinery/telecomms/computers/telemonitor.dm index a6a4054d04f..c12ab9b1709 100644 --- a/code/game/machinery/telecomms/computers/telemonitor.dm +++ b/code/game/machinery/telecomms/computers/telemonitor.dm @@ -123,9 +123,9 @@ updateUsrDialog() return -/obj/machinery/computer/telecomms/monitor/attackby(var/obj/item/D as obj, var/mob/user as mob) - if(D.isscrewdriver()) - if(D.use_tool(src, user, 20, volume = 50)) +/obj/machinery/computer/telecomms/monitor/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) + if(attacking_item.use_tool(src, user, 20, volume = 50)) if (src.stat & BROKEN) to_chat(user, "The broken glass falls out.") var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc ) diff --git a/code/game/machinery/telecomms/computers/traffic_control.dm b/code/game/machinery/telecomms/computers/traffic_control.dm index 4410a50752f..d72b692cfe8 100644 --- a/code/game/machinery/telecomms/computers/traffic_control.dm +++ b/code/game/machinery/telecomms/computers/traffic_control.dm @@ -200,9 +200,9 @@ updateUsrDialog() return -/obj/machinery/computer/telecomms/traffic/attackby(var/obj/item/D as obj, var/mob/user as mob) - if(D.isscrewdriver()) - if(D.use_tool(src, user, 20, volume = 50)) +/obj/machinery/computer/telecomms/traffic/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) + if(attacking_item.use_tool(src, user, 20, volume = 50)) if (src.stat & BROKEN) to_chat(user, "The broken glass falls out.") var/obj/structure/computerframe/A = new /obj/structure/computerframe( src.loc ) diff --git a/code/game/machinery/telecomms/machine_interactions.dm b/code/game/machinery/telecomms/machine_interactions.dm index ab677fc5a81..df7071bf35a 100644 --- a/code/game/machinery/telecomms/machine_interactions.dm +++ b/code/game/machinery/telecomms/machine_interactions.dm @@ -3,17 +3,17 @@ var/construct_op = 0 -/obj/machinery/telecomms/attackby(obj/item/I, mob/user) +/obj/machinery/telecomms/attackby(obj/item/attacking_item, mob/user) // Using a multitool lets you access the receiver's interface - if(I.ismultitool()) + if(attacking_item.ismultitool()) user.set_machine(src) - interact(user, I) + interact(user, attacking_item) return TRUE // REPAIRING: Use Nanopaste to repair half of the system's integrity. At 24 machines, it will take 48 uses of nanopaste to repair the entire array. - if(istype(I, /obj/item/stack/nanopaste)) - var/obj/item/stack/nanopaste/T = I + if(istype(attacking_item, /obj/item/stack/nanopaste)) + var/obj/item/stack/nanopaste/T = attacking_item if (integrity < 100) //Damaged, let's repair! if (T.use(1)) integrity = between(0, initial(integrity) / 2, initial(integrity)) @@ -25,30 +25,30 @@ switch(construct_op) if(0) - if(I.isscrewdriver()) + if(attacking_item.isscrewdriver()) to_chat(user, SPAN_NOTICE("You unfasten the bolts.")) - playsound(src.loc, I.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) construct_op ++ . = TRUE if(1) - if(I.isscrewdriver()) + if(attacking_item.isscrewdriver()) to_chat(user, SPAN_NOTICE("You fasten the bolts.")) - playsound(src.loc, I.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) construct_op -- . = TRUE - if(I.iswrench()) + if(attacking_item.iswrench()) to_chat(user, SPAN_NOTICE("You dislodge the external plating.")) - playsound(src.loc, I.usesound, 75, 1) + playsound(src.loc, attacking_item.usesound, 75, 1) construct_op ++ . = TRUE if(2) - if(I.iswrench()) + if(attacking_item.iswrench()) to_chat(user, SPAN_NOTICE("You secure the external plating.")) - playsound(src.loc, I.usesound, 75, 1) + playsound(src.loc, attacking_item.usesound, 75, 1) construct_op -- . = TRUE - if(I.iswirecutter()) - playsound(src.loc, I.usesound, 50, 1) + if(attacking_item.iswirecutter()) + playsound(src.loc, attacking_item.usesound, 50, 1) to_chat(user, SPAN_NOTICE("You remove the cables.")) construct_op ++ var/obj/item/stack/cable_coil/A = new /obj/item/stack/cable_coil( user.loc ) @@ -56,8 +56,8 @@ stat |= BROKEN // the machine's been borked! . = TRUE if(3) - if(I.iscoil()) - var/obj/item/stack/cable_coil/A = I + if(attacking_item.iscoil()) + var/obj/item/stack/cable_coil/A = attacking_item if (A.use(5)) to_chat(user, "You insert the cables.") construct_op-- @@ -65,9 +65,9 @@ else to_chat(user, "You need five coils of wire for this.") . = TRUE - if(I.iscrowbar()) + if(attacking_item.iscrowbar()) to_chat(user, SPAN_NOTICE("You begin prying out the circuit board's components...")) - if(I.use_tool(src, user, 60, volume = 50)) + if(attacking_item.use_tool(src, user, 60, volume = 50)) to_chat(user, SPAN_NOTICE("You finish prying out the components.")) // Drop all the component stuff diff --git a/code/game/machinery/telecomms/machines/message_server.dm b/code/game/machinery/telecomms/machines/message_server.dm index 7c07eb95385..d98fa10e6e0 100644 --- a/code/game/machinery/telecomms/machines/message_server.dm +++ b/code/game/machinery/telecomms/machines/message_server.dm @@ -153,15 +153,15 @@ return -/obj/machinery/telecomms/message_server/attackby(obj/item/O as obj, mob/living/user as mob) +/obj/machinery/telecomms/message_server/attackby(obj/item/attacking_item, mob/user) if (use_power && !inoperable(EMPED) && (spamfilter_limit < MESSAGE_SERVER_DEFAULT_SPAM_LIMIT*2) && \ - istype(O,/obj/item/circuitboard/message_monitor)) + istype(attacking_item, /obj/item/circuitboard/message_monitor) && istype(user)) spamfilter_limit += round(MESSAGE_SERVER_DEFAULT_SPAM_LIMIT / 2) - user.drop_from_inventory(O,get_turf(src)) - qdel(O) + user.drop_from_inventory(attacking_item, get_turf(src)) + qdel(attacking_item) to_chat(user, "You install additional memory and processors into message server. Its filtering capabilities been enhanced.") else - ..(O, user) + ..() /obj/machinery/telecomms/message_server/update_icon() if(inoperable(EMPED)) diff --git a/code/game/machinery/tesla_beacon.dm b/code/game/machinery/tesla_beacon.dm index 43d3ac0411b..31604cb4a49 100644 --- a/code/game/machinery/tesla_beacon.dm +++ b/code/game/machinery/tesla_beacon.dm @@ -49,8 +49,8 @@ to_chat(user, SPAN_WARNING("You need to screw \the [src] to the floor first!")) return -/obj/machinery/power/tesla_beacon/attackby(obj/item/W, mob/user) - if(W.isscrewdriver()) +/obj/machinery/power/tesla_beacon/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(active) to_chat(user, SPAN_WARNING("You need to deactivate \the [src] first!")) return TRUE diff --git a/code/game/machinery/turret_control.dm b/code/game/machinery/turret_control.dm index c4029fd9985..532774ef937 100644 --- a/code/game/machinery/turret_control.dm +++ b/code/game/machinery/turret_control.dm @@ -93,11 +93,11 @@ return ..() -/obj/machinery/turretid/attackby(obj/item/W, mob/user) +/obj/machinery/turretid/attackby(obj/item/attacking_item, mob/user) if(stat & BROKEN) return - if(W.GetID()) + if(attacking_item.GetID()) if(src.allowed(usr)) if(emagged) to_chat(user, "The turret control is unresponsive.") diff --git a/code/game/machinery/vending.dm b/code/game/machinery/vending.dm index 3313c5f5aba..11bab113388 100644 --- a/code/game/machinery/vending.dm +++ b/code/game/machinery/vending.dm @@ -227,26 +227,26 @@ to_chat(user, "You short out the product lock on \the [src]") return 1 -/obj/machinery/vending/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/device/debugger)) +/obj/machinery/vending/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/device/debugger)) if(!shut_up) - to_chat(user, SPAN_WARNING("\The [W] reads, \"Software error detected. Rectifying.\".")) - if(W.use_tool(src, user, 100, volume = 50)) - to_chat(user, SPAN_NOTICE("\The [W] reads, \"Solution found. Fix applied.\".")) + to_chat(user, SPAN_WARNING("\The [attacking_item] reads, \"Software error detected. Rectifying.\".")) + if(attacking_item.use_tool(src, user, 100, volume = 50)) + to_chat(user, SPAN_NOTICE("\The [attacking_item] reads, \"Solution found. Fix applied.\".")) shut_up = TRUE if(shoot_inventory) if(wires.is_cut(WIRE_THROW)) - to_chat(user, SPAN_WARNING("\The [W] reads, \"Hardware error detected. Manual repair required.\".")) + to_chat(user, SPAN_WARNING("\The [attacking_item] reads, \"Hardware error detected. Manual repair required.\".")) return TRUE - to_chat(user, SPAN_WARNING("\The [W] reads, \"Software error detected. Rectifying.\".")) - if(W.use_tool(src, user, 100, volume = 50)) - to_chat(user, SPAN_NOTICE("\The [W] reads, \"Solution found. Fix applied. Have a NanoTrasen day!\".")) + to_chat(user, SPAN_WARNING("\The [attacking_item] reads, \"Software error detected. Rectifying.\".")) + if(attacking_item.use_tool(src, user, 100, volume = 50)) + to_chat(user, SPAN_NOTICE("\The [attacking_item] reads, \"Solution found. Fix applied. Have a NanoTrasen day!\".")) shoot_inventory = FALSE else - to_chat(user, SPAN_NOTICE("\The [W] reads, \"All systems nominal.\".")) + to_chat(user, SPAN_NOTICE("\The [attacking_item] reads, \"All systems nominal.\".")) return TRUE - var/obj/item/card/id/I = W.GetID() + var/obj/item/card/id/I = attacking_item.GetID() var/datum/money_account/vendor_account = SSeconomy.get_department_account("Vendor") if (currently_vending && vendor_account && !vendor_account.suspended) @@ -261,14 +261,14 @@ return TRUE if (I) //for IDs and PDAs and wallets with IDs - paid = pay_with_card(I,W) + paid = pay_with_card(I,attacking_item) handled = 1 - else if (istype(W, /obj/item/spacecash/ewallet)) - var/obj/item/spacecash/ewallet/C = W + else if (istype(attacking_item, /obj/item/spacecash/ewallet)) + var/obj/item/spacecash/ewallet/C = attacking_item paid = pay_with_ewallet(C) handled = 1 - else if (istype(W, /obj/item/spacecash)) - var/obj/item/spacecash/C = W + else if (istype(attacking_item, /obj/item/spacecash)) + var/obj/item/spacecash/C = attacking_item paid = pay_with_cash(C, user) handled = 1 @@ -279,9 +279,9 @@ SStgui.update_uis(src) return TRUE // don't smack that machine with your 2 credits - if (I || istype(W, /obj/item/spacecash)) + if (I || istype(attacking_item, /obj/item/spacecash)) return attack_hand(user) - else if(W.isscrewdriver()) + else if(attacking_item.isscrewdriver()) src.panel_open = !src.panel_open to_chat(user, "You [src.panel_open ? "open" : "close"] the maintenance panel.") cut_overlays() @@ -289,33 +289,33 @@ if(src.panel_open) add_overlay("[initial(icon_state)]-panel") return TRUE - else if(W.ismultitool()||W.iswirecutter()) + else if(attacking_item.ismultitool()||attacking_item.iswirecutter()) if(src.panel_open) return attack_hand(user) return TRUE - else if(istype(W, /obj/item/coin) && premium.len > 0) - user.drop_from_inventory(W,src) - coin = W + else if(istype(attacking_item, /obj/item/coin) && premium.len > 0) + user.drop_from_inventory(attacking_item,src) + coin = attacking_item categories |= CAT_COIN - to_chat(user, "You insert \the [W] into \the [src].") + to_chat(user, "You insert \the [attacking_item] into \the [src].") SStgui.update_uis(src) return TRUE - else if(W.iswrench()) + else if(attacking_item.iswrench()) if(!can_move) return TRUE user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) user.visible_message("[user] begins [anchored? "un" : ""]securing \the [src] [anchored? "from" : "to"] the floor.", SPAN_NOTICE("You start [anchored? "un" : ""]securing \the [src] [anchored? "from" : "to"] the floor.")) - if(W.use_tool(src, user, 20, volume = 50)) + if(attacking_item.use_tool(src, user, 20, volume = 50)) if(!src) return to_chat(user, "You [anchored? "un" : ""]secured \the [src]!") anchored = !anchored power_change() return TRUE - else if(istype(W,/obj/item/device/vending_refill)) + else if(istype(attacking_item,/obj/item/device/vending_refill)) if(panel_open) - var/obj/item/device/vending_refill/VR = W + var/obj/item/device/vending_refill/VR = attacking_item if(VR.charges) if(VR.vend_id == vend_id) VR.restock_inventory(src) @@ -330,20 +330,20 @@ to_chat(user, "You must open \the [src]'s maintenance panel first!") return TRUE - else if(!is_borg_item(W)) + else if(!is_borg_item(attacking_item)) if(!restock_items) to_chat(user, "\the [src] can not be restocked manually!") return TRUE for(var/path in restock_blocked_items) - if(istype(W,path)) + if(istype(attacking_item, path)) to_chat(user, "\the [src] does not accept this item!") return TRUE for(var/datum/data/vending_product/R in product_records) - if(W.type == R.product_path) + if(attacking_item.type == R.product_path) stock(R, user) - user.remove_from_mob(W) //Catches gripper duplication - qdel(W) + user.remove_from_mob(attacking_item) //Catches gripper duplication + qdel(attacking_item) return TRUE return ..() diff --git a/code/game/machinery/vending_items.dm b/code/game/machinery/vending_items.dm index c6c5f223d70..7fe06ced116 100644 --- a/code/game/machinery/vending_items.dm +++ b/code/game/machinery/vending_items.dm @@ -13,12 +13,12 @@ w_class = ITEMSIZE_NORMAL var/charges = 0 -/obj/item/device/vending_refill/examine(mob/user) +/obj/item/device/vending_refill/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(charges > 0) - to_chat(user, "It can restock [charges] item(s).") + . += "It can restock [charges] item(s)." else - to_chat(user, "It's empty!") + . += SPAN_WARNING("It's empty!") /obj/item/device/vending_refill/proc/restock_inventory(var/obj/machinery/vending/vendor) if(vendor) diff --git a/code/game/machinery/vending_types.dm b/code/game/machinery/vending_types.dm index 7c47a4ff3b0..d54374d1f7e 100644 --- a/code/game/machinery/vending_types.dm +++ b/code/game/machinery/vending_types.dm @@ -1499,7 +1499,8 @@ /obj/item/storage/box/fancy/mre/menu7 = 2, /obj/item/storage/box/fancy/mre/menu8 = 2, /obj/item/storage/box/fancy/mre/menu9 = 10, - /obj/item/storage/box/fancy/mre/menu10 = 10 + /obj/item/storage/box/fancy/mre/menu10 = 10, + /obj/item/storage/box/fancy/mre/menu12 = 5 ) prices = list( /obj/item/storage/box/fancy/mre = 50, @@ -1511,7 +1512,8 @@ /obj/item/storage/box/fancy/mre/menu7 = 50, /obj/item/storage/box/fancy/mre/menu8 = 50, /obj/item/storage/box/fancy/mre/menu9 = 50, - /obj/item/storage/box/fancy/mre/menu10 = 50 + /obj/item/storage/box/fancy/mre/menu10 = 50, + /obj/item/storage/box/fancy/mre/menu12 = 50 ) contraband = list( /obj/item/storage/box/fancy/mre/menu11 = 5, // memes. diff --git a/code/game/machinery/wall_frames.dm b/code/game/machinery/wall_frames.dm index fa4f91fe608..d996b45718c 100644 --- a/code/game/machinery/wall_frames.dm +++ b/code/game/machinery/wall_frames.dm @@ -9,8 +9,8 @@ var/refund_type = /obj/item/stack/material/steel var/reverse = 0 //if resulting object faces opposite its dir (like light fixtures) -/obj/item/frame/attackby(obj/item/W as obj, mob/user as mob) - if (W.iswrench()) +/obj/item/frame/attackby(obj/item/attacking_item, mob/user) + if (attacking_item.iswrench()) new refund_type( get_turf(src.loc), refund_amt) qdel(src) return TRUE diff --git a/code/game/machinery/washing_machine.dm b/code/game/machinery/washing_machine.dm index 161b997ed92..19452669344 100644 --- a/code/game/machinery/washing_machine.dm +++ b/code/game/machinery/washing_machine.dm @@ -80,19 +80,19 @@ /obj/machinery/washing_machine/update_icon() icon_state = "wm_[state][panel]" -/obj/machinery/washing_machine/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W,/obj/item/pen/crayon) || istype(W,/obj/item/stamp)) +/obj/machinery/washing_machine/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item,/obj/item/pen/crayon) || istype(attacking_item,/obj/item/stamp)) if( state in list( 1, 3, 6 ) ) if(!crayon) - user.drop_from_inventory(W,src) - crayon = W + user.drop_from_inventory(attacking_item,src) + crayon = attacking_item else return ..() else return ..() - else if(istype(W,/obj/item/grab)) + else if(istype(attacking_item,/obj/item/grab)) if( (state == 1) && hacked) - var/obj/item/grab/G = W + var/obj/item/grab/G = attacking_item if(ishuman(G.assailant) && iscorgi(G.affecting)) G.affecting.forceMove(src) qdel(G) @@ -102,7 +102,7 @@ else if(contents.len < 5) if (state in list(1, 3)) - user.drop_from_inventory(W,src) + user.drop_from_inventory(attacking_item,src) state = 3 else to_chat(user, "You can't put the item in right now.") diff --git a/code/game/objects/auras/auras.dm b/code/game/objects/auras/auras.dm index 7a3e4d2b350..7514cbcbd9f 100644 --- a/code/game/objects/auras/auras.dm +++ b/code/game/objects/auras/auras.dm @@ -21,7 +21,7 @@ They should also be used for when you want to effect the ENTIRE mob, like having /obj/aura/proc/life_tick() return FALSE -/obj/aura/attackby(obj/item/I, mob/user) +/obj/aura/attackby(obj/item/attacking_item, mob/user) return FALSE /obj/aura/bullet_act(obj/item/projectile/P, def_zone) diff --git a/code/game/objects/effects/burnt_wall.dm b/code/game/objects/effects/burnt_wall.dm index c8660152296..c7c496af687 100644 --- a/code/game/objects/effects/burnt_wall.dm +++ b/code/game/objects/effects/burnt_wall.dm @@ -16,9 +16,9 @@ if(material.opacity < 0.5) alpha = 125 -/obj/effect/overlay/burnt_wall/attackby(obj/item/I, mob/user) - if(I.iswelder()) - var/obj/item/weldingtool/WT = I +/obj/effect/overlay/burnt_wall/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) return TRUE if(WT.use(0,user)) diff --git a/code/game/objects/effects/chem/foam.dm b/code/game/objects/effects/chem/foam.dm index f37f9ee1bb3..cdf2e149de0 100644 --- a/code/game/objects/effects/chem/foam.dm +++ b/code/game/objects/effects/chem/foam.dm @@ -174,22 +174,22 @@ to_chat(user, SPAN_NOTICE("You hit the metal foam but bounce off it.")) shake_animation() -/obj/structure/foamedmetal/attackby(var/obj/item/I, var/mob/user) +/obj/structure/foamedmetal/attackby(obj/item/attacking_item, mob/user) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - if(istype(I, /obj/item/grab)) - var/obj/item/grab/G = I + if(istype(attacking_item, /obj/item/grab)) + var/obj/item/grab/G = attacking_item if(G.state < GRAB_AGGRESSIVE) to_chat(user, SPAN_WARNING("You need a stronger grip to do that!")) return TRUE G.affecting.forceMove(src.loc) visible_message(SPAN_WARNING("[G.assailant] smashes [G.affecting] through the foamed metal wall.")) G.affecting.take_overall_damage(15) - qdel(I) + qdel(attacking_item) qdel(src) return TRUE - else if(istype(I, /obj/item/stack/material)) - var/obj/item/stack/material/S = I + else if(istype(attacking_item, /obj/item/stack/material)) + var/obj/item/stack/material/S = attacking_item if(S.get_amount() < 4) to_chat(user, SPAN_NOTICE("There isn't enough material here to construct a wall.")) return TRUE @@ -213,20 +213,20 @@ qdel(src) return TRUE - else if(istype(I, /obj/item/stack/tile/floor)) + else if(istype(attacking_item, /obj/item/stack/tile/floor)) var/turf/T = get_turf(src) if(T.type != /turf/space && !isopenturf(T)) // need to do a hard check here because transit turfs are also space turfs to_chat(user, SPAN_WARNING("The tile below \the [src] isn't an open space, or space itself!")) return TRUE - var/obj/item/stack/tile/floor/S = I + var/obj/item/stack/tile/floor/S = attacking_item S.use(1) T.ChangeTurf(/turf/simulated/floor/airless) qdel(src) return TRUE - user.do_attack_animation(src, I) - if(prob(I.force * 20 - metal * 25)) - user.visible_message(SPAN_WARNING("[user] smashes through the foamed metal."), SPAN_NOTICE("You smash through the foamed metal with \the [I].")) + user.do_attack_animation(src, attacking_item) + if(prob(attacking_item.force * 20 - metal * 25)) + user.visible_message(SPAN_WARNING("[user] smashes through the foamed metal."), SPAN_NOTICE("You smash through the foamed metal with \the [attacking_item].")) qdel(src) else to_chat(user, SPAN_NOTICE("You hit the metal foam to no effect.")) diff --git a/code/game/objects/effects/decals/Cleanable/humans.dm b/code/game/objects/effects/decals/Cleanable/humans.dm index 3bfd4ab4505..fa0f067995a 100644 --- a/code/game/objects/effects/decals/Cleanable/humans.dm +++ b/code/game/objects/effects/decals/Cleanable/humans.dm @@ -58,14 +58,14 @@ if (dries) animate(src, color = "#000000", time = drytime, loop = 0, flags = ANIMATION_RELATIVE) -/obj/effect/decal/cleanable/blood/examine() +/obj/effect/decal/cleanable/blood/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) if(dries && world.time > (bleed_time + drytime)) name = dryname desc = drydesc . = ..() -/obj/effect/decal/cleanable/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/gun/energy/rifle/cult)) +/obj/effect/decal/cleanable/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/gun/energy/rifle/cult)) return TRUE return ..() @@ -189,9 +189,9 @@ else icon_state = "writing1" -/obj/effect/decal/cleanable/blood/writing/examine(mob/user) +/obj/effect/decal/cleanable/blood/writing/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "It reads: \"[message]\"") + . += "It reads: \"[message]\"" /obj/effect/decal/cleanable/blood/gibs name = "gibs" diff --git a/code/game/objects/effects/decals/contraband.dm b/code/game/objects/effects/decals/contraband.dm index 590dafdfd39..8944826f8fd 100644 --- a/code/game/objects/effects/decals/contraband.dm +++ b/code/game/objects/effects/decals/contraband.dm @@ -126,8 +126,8 @@ desc = "[initial(desc)] [design.desc]" icon_state = design.icon_state // poster[serial_number] -/obj/structure/sign/poster/attackby(obj/item/W as obj, mob/user as mob) - if(W.iswirecutter()) +/obj/structure/sign/poster/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswirecutter()) playsound(loc, 'sound/items/Wirecutter.ogg', 100, 1) if(ruined) to_chat(user, "You remove the remnants of the poster.") diff --git a/code/game/objects/effects/decals/remains.dm b/code/game/objects/effects/decals/remains.dm index 85d63932d82..1ed385fe421 100644 --- a/code/game/objects/effects/decals/remains.dm +++ b/code/game/objects/effects/decals/remains.dm @@ -41,8 +41,8 @@ desc = "They look like the remains of a small reptile." icon_state = "lizard" -/obj/effect/decal/remains/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/gun/energy/rifle/cult)) +/obj/effect/decal/remains/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/gun/energy/rifle/cult)) return TRUE return ..() diff --git a/code/game/objects/effects/plastic_explosive.dm b/code/game/objects/effects/plastic_explosive.dm index 5cfd547d7c7..ecc4dc74ba2 100644 --- a/code/game/objects/effects/plastic_explosive.dm +++ b/code/game/objects/effects/plastic_explosive.dm @@ -37,13 +37,13 @@ pixel_x = pixel_shifts[1] pixel_y = pixel_shifts[2] -/obj/effect/plastic_explosive/examine(mob/user, distance, is_adjacent) +/obj/effect/plastic_explosive/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(is_adjacent) - to_chat(user, SPAN_WARNING("It is set to blow in [round((parent.detonate_time - world.time) / 10)] seconds.")) + . += SPAN_WARNING("It is set to blow in [round((parent.detonate_time - world.time) / 10)] seconds.") /obj/effect/plastic_explosive/attack_hand(mob/living/user) to_chat(user, SPAN_WARNING("\The [src] is solidly attached, it doesn't budge!")) -/obj/effect/plastic_explosive/attackby(var/obj/item/I, var/mob/user) - return parent.attackby(I, user) +/obj/effect/plastic_explosive/attackby(obj/item/attacking_item, mob/user) + return parent.attackby(attacking_item, user) diff --git a/code/game/objects/effects/portals.dm b/code/game/objects/effects/portals.dm index 83346ebecd5..dab249133d0 100644 --- a/code/game/objects/effects/portals.dm +++ b/code/game/objects/effects/portals.dm @@ -42,9 +42,9 @@ if(does_teleport) teleport(AM) -/obj/effect/portal/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/bluespace_neutralizer)) - user.visible_message("[user] collapses \the [src] with \the [I].", SPAN_NOTICE("You collapse \the [src] with \the [I].")) +/obj/effect/portal/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/bluespace_neutralizer)) + user.visible_message("[user] collapses \the [src] with \the [attacking_item].", SPAN_NOTICE("You collapse \the [src] with \the [attacking_item].")) qdel(src) return TRUE return ..() @@ -246,9 +246,9 @@ message_all_revenants(FONT_LARGE(SPAN_WARNING("The rift keeping us here has been destroyed in [A.name]!"))) return ..() -/obj/effect/portal/revenant/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/bluespace_neutralizer)) - to_chat(user, SPAN_WARNING("You need to activate \the [I] and keep it near \the [src] to collapse it.")) +/obj/effect/portal/revenant/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/bluespace_neutralizer)) + to_chat(user, SPAN_WARNING("You need to activate \the [attacking_item] and keep it near \the [src] to collapse it.")) return TRUE return ..() diff --git a/code/game/objects/effects/spiders.dm b/code/game/objects/effects/spiders.dm index 121ef80b933..88eaafa52aa 100644 --- a/code/game/objects/effects/spiders.dm +++ b/code/game/objects/effects/spiders.dm @@ -21,18 +21,18 @@ qdel(src) return -/obj/effect/spider/attackby(var/obj/item/W, var/mob/user) - visible_message(SPAN_WARNING("\The [src] has been [LAZYPICK(W.attack_verb, "attacked")] with [W][(user ? " by [user]." : ".")]")) - var/damage = W.force / 4.0 - if(W.iswelder()) - var/obj/item/weldingtool/WT = W +/obj/effect/spider/attackby(obj/item/attacking_item, mob/user) + visible_message(SPAN_WARNING("\The [src] has been [LAZYPICK(attacking_item.attack_verb, "attacked")] with [attacking_item][(user ? " by [user]." : ".")]")) + var/damage = attacking_item.force / 4.0 + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(WT.use(0, user)) damage = 15 playsound(loc, 'sound/items/Welder.ogg', 100, 1) return TRUE else user.do_attack_animation(src) - playsound(loc, W.hitsound, 50, 1, -1) + playsound(loc, attacking_item.hitsound, 50, 1, -1) health -= damage healthcheck() @@ -278,10 +278,10 @@ visible_message(SPAN_WARNING("\The [user] stomps \the [src] dead!")) die() -/obj/effect/spider/spiderling/attackby(var/obj/item/W, var/mob/user) +/obj/effect/spider/spiderling/attackby(obj/item/attacking_item, mob/user) . = ..() - if(istype(W, /obj/item/newspaper)) - var/obj/item/newspaper/N = W + if(istype(attacking_item, /obj/item/newspaper)) + var/obj/item/newspaper/N = attacking_item if(N.rolled) die() return TRUE diff --git a/code/game/objects/items.dm b/code/game/objects/items.dm index 01b836f97f0..c77decdcfac 100644 --- a/code/game/objects/items.dm +++ b/code/game/objects/items.dm @@ -323,18 +323,18 @@ I.forceMove(T) -/obj/item/examine(mob/user, distance) +/obj/item/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) var/size switch(src.w_class) - if (5.0 to INFINITY) + if (ITEMSIZE_HUGE to INFINITY) size = "huge" - if (4.0 to 5.0) + if (ITEMSIZE_LARGE to ITEMSIZE_HUGE) size = "bulky" - if (3.0 to 4.0) + if (ITEMSIZE_NORMAL to ITEMSIZE_LARGE) size = "normal-sized" - if (2.0 to 3.0) + if (ITEMSIZE_SMALL to ITEMSIZE_NORMAL) size = "small" - if (0 to 2.0) + if (0 to ITEMSIZE_SMALL) size = "tiny" //Changed this switch to ranges instead of tiered values, to cope with granularity and also //things outside its range ~Nanako @@ -342,7 +342,7 @@ . = ..(user, distance, "", "It is a [size] item.") var/datum/component/armor/armor_component = GetComponent(/datum/component/armor) if(armor_component) - to_chat(user, FONT_SMALL(SPAN_NOTICE("\[?\] This item has armor values. \[Show Armor Values\]"))) + . += FONT_SMALL(SPAN_NOTICE("\[?\] This item has armor values. \[Show Armor Values\]")) /obj/item/Topic(href, href_list) if(href_list["examine_armor"]) @@ -409,54 +409,16 @@ R.activate_module(src) R.hud_used.update_robot_modules_display() -// Due to storage type consolidation this should get used more now. -// I have cleaned it up a little, but it could probably use more. -Sayu -/obj/item/attackby(obj/item/I, mob/user) - if(istype(I,/obj/item/storage)) - var/obj/item/storage/S = I - if(S.use_to_pickup) - if(S.collection_mode && !is_type_in_list(src, S.pickup_blacklist)) //Mode is set to collect all items on a tile and we clicked on a valid one. - if(isturf(loc)) - var/list/rejections = list() - var/success = FALSE - var/failure = FALSE - var/original_loc = user ? user.loc : null - - for(var/obj/item/item in loc) - if (user && user.loc != original_loc) - break - - if(rejections[item.type]) // To limit bag spamming: any given type only complains once - continue - - if(!S.can_be_inserted(item)) // Note can_be_inserted still makes noise when the answer is no - rejections[item.type] = TRUE // therefore full bags are still a little spammy - failure = TRUE - CHECK_TICK - continue - - success = TRUE - S.handle_item_insertion_deferred(item, user) //The 1 stops the "You put the [src] into [S]" insertion message from being displayed. - CHECK_TICK // Because people insist on picking up huge-ass piles of stuff. - - S.handle_storage_deferred(user) - if(success && !failure) - to_chat(user, "You put everything in [S].") - else if(success) - to_chat(user, "You put some things in [S].") - else - to_chat(user, "You fail to pick anything up with \the [S].") - - else if(S.can_be_inserted(src)) - S.handle_item_insertion(src) - return TRUE - -//Called when the user alt-clicks on something with this item in their active hand -//this function is designed to be overridden by individual weapons +/** + * Called when the user alt-clicks on something with this item in their active hand + * + * This function is designed to be overridden by individual weapons + * + * A return value of `TRUE` continues on to do the normal alt-click action, + * a return value of `FALSE` does not continue, and will not do the alt-click + */ /obj/item/proc/alt_attack(var/atom/target, var/mob/user) - return 1 - //A return value of 1 continues on to do the normal alt-click action. - //A return value of 0 does not continue, and will not do the alt-click + return TRUE /obj/item/proc/talk_into(mob/M as mob, text) return @@ -524,7 +486,7 @@ zoom(user) SEND_SIGNAL(src, COMSIG_ITEM_REMOVE, src) -// called just as an item is picked up (loc is not yet changed) +///Called just as an item is picked up (loc is not yet changed) /obj/item/proc/pickup(mob/user) pixel_x = 0 pixel_y = 0 diff --git a/code/game/objects/items/airbubble.dm b/code/game/objects/items/airbubble.dm index 5945dcc210b..88a0f7542e5 100644 --- a/code/game/objects/items/airbubble.dm +++ b/code/game/objects/items/airbubble.dm @@ -82,16 +82,16 @@ slowdown = 0 // Examine to see tank pressure -/obj/structure/closet/airbubble/examine(mob/user) +/obj/structure/closet/airbubble/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!isnull(internal_tank)) - to_chat(user, "\The [src] has [internal_tank] attached, that displays [round(internal_tank.air_contents.return_pressure() ? internal_tank.air_contents.return_pressure() : 0)] KPa.") + . += "\The [src] has [internal_tank] attached, that displays [round(internal_tank.air_contents.return_pressure() ? internal_tank.air_contents.return_pressure() : 0)] KPa." else - to_chat(user, "\The [src] has no tank attached.") + . += "\The [src] has no tank attached." if (cell) - to_chat(user, "\The [src] has [cell] attached, the charge meter reads [round(cell.percent())]%.") + . += "\The [src] has [cell] attached, the charge meter reads [round(cell.percent())]%." else - to_chat(user, "[src] has no power cell installed.") + . += "[src] has no power cell installed." /obj/structure/closet/airbubble/can_open() if(zipped) @@ -394,36 +394,36 @@ to_chat(usr, "[src] has no power cell.") // Handle most of things: restraining, cutting restrains, attaching tank. -/obj/structure/closet/airbubble/attackby(obj/W, mob/user as mob) - if(istype(W, /obj/item/tank)) +/obj/structure/closet/airbubble/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/tank)) if(!isnull(use_internal_tank)) user.visible_message( - "[user] is attaching [W] to [src].", - "You are attaching [W] to [src]." + "[user] is attaching [attacking_item] to [src].", + "You are attaching [attacking_item] to [src]." ) if (!do_after(user, 2 SECONDS, src)) return user.visible_message( - "[user] has attached [W] to [src].", - "You attached [W] to [src]." + "[user] has attached [attacking_item] to [src].", + "You attached [attacking_item] to [src]." ) - internal_tank = W - user.drop_from_inventory(W, src) + internal_tank = attacking_item + user.drop_from_inventory(attacking_item, src) use_internal_tank = 1 START_PROCESSING(SSfast_process, src) else to_chat(user, "[src] already has a tank attached.") return TRUE if(opened) - if(istype(W, /obj/item/grab)) - var/obj/item/grab/G = W + if(istype(attacking_item, /obj/item/grab)) + var/obj/item/grab/G = attacking_item MouseDrop_T(G.affecting, user) return FALSE - if(!W.dropsafety()) + if(!attacking_item.dropsafety()) return FALSE user.drop_item() return TRUE - else if(istype(W, /obj/item/handcuffs/cable)) + else if(istype(attacking_item, /obj/item/handcuffs/cable)) if(zipped) to_chat(user, "[src]'s zipper is already restrained.") return TRUE @@ -441,10 +441,10 @@ "You put restrains on [src]'s zipper." ) - qdel(W) + qdel(attacking_item) update_icon() return TRUE - else if(W.iswirecutter()) + else if(attacking_item.iswirecutter()) if(!zipped) to_chat(user, "[src] has no cables to cut.") attack_hand(user) @@ -465,24 +465,24 @@ new/obj/item/handcuffs/cable(src.loc) update_icon() return TRUE - else if(istype(W, /obj/item/cell)) + else if(istype(attacking_item, /obj/item/cell)) if(!isnull(cell)) to_chat(user, "[src] already has [cell] attached to it.") attack_hand(user) return TRUE user.visible_message( - "[user] is attaching [W] to [src].", - "You are attaching [W] to [src]." + "[user] is attaching [attacking_item] to [src].", + "You are attaching [attacking_item] to [src]." ) if (!do_after(user, 2 SECONDS, src)) return TRUE user.visible_message( - "[user] has attached [W] to [src].", - "You attached [W] to [src]." + "[user] has attached [attacking_item] to [src].", + "You attached [attacking_item] to [src]." ) - cell = W + cell = attacking_item cooling = TRUE - user.drop_from_inventory(W, src) + user.drop_from_inventory(attacking_item, src) return TRUE else return attack_hand(user) diff --git a/code/game/objects/items/apc_frame.dm b/code/game/objects/items/apc_frame.dm index 8c64b6c438b..96b39ff549d 100644 --- a/code/game/objects/items/apc_frame.dm +++ b/code/game/objects/items/apc_frame.dm @@ -7,8 +7,8 @@ icon_state = "apc_frame" obj_flags = OBJ_FLAG_CONDUCTABLE -/obj/item/frame/apc/attackby(obj/item/W as obj, mob/user as mob) - if (W.iswrench()) +/obj/item/frame/apc/attackby(obj/item/attacking_item, mob/user) + if (attacking_item.iswrench()) new /obj/item/stack/material/steel( get_turf(src.loc), 2 ) qdel(src) return TRUE diff --git a/code/game/objects/items/bodybag.dm b/code/game/objects/items/bodybag.dm index da2e29470c2..7acdf66cbf2 100644 --- a/code/game/objects/items/bodybag.dm +++ b/code/game/objects/items/bodybag.dm @@ -72,10 +72,10 @@ to_chat(user, "\The [src] is full.") to_chat(user, "It [contains_body ? "contains" : "does not contain"] a body.") -/obj/structure/closet/body_bag/attackby(var/obj/item/W, mob/user as mob) - if (W.ispen()) +/obj/structure/closet/body_bag/attackby(obj/item/attacking_item, mob/user) + if (attacking_item.ispen()) var/t = tgui_input_text(user, "What would you like the label to be?", name) - if (user.get_active_hand() != W) + if (user.get_active_hand() != attacking_item) return TRUE if (!in_range(src, user) && src.loc != user) return TRUE @@ -88,7 +88,7 @@ else src.name = "body bag" return TRUE - else if(W.iswirecutter()) + else if(attacking_item.iswirecutter()) to_chat(user, "You cut the tag off the bodybag.") playsound(src.loc, 'sound/items/Wirecutter.ogg', 50, 1) src.name = "body bag" @@ -234,11 +234,11 @@ return airtank ..() -/obj/structure/closet/body_bag/cryobag/examine(mob/user, distance, is_adjacent) +/obj/structure/closet/body_bag/cryobag/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user,"The stasis meter shows '[stasis_power]x'.") + . += "The stasis meter shows '[stasis_power]x'." if(is_adjacent && length(contents)) //The bag's rather thick and opaque from a distance. - to_chat(user, "You peer into \the [src].") + . += "You peer into \the [src]." for(var/mob/living/L in contents) L.examine(arglist(args)) diff --git a/code/game/objects/items/canvas.dm b/code/game/objects/items/canvas.dm index fb5212f3531..4fc8565c90b 100644 --- a/code/game/objects/items/canvas.dm +++ b/code/game/objects/items/canvas.dm @@ -49,10 +49,10 @@ /** * One pixel increments. */ -/obj/item/canvas/attackby(obj/item/I, mob/user, params) - if(I.iswrench()) +/obj/item/canvas/attackby(obj/item/attacking_item, mob/user, params) + if(attacking_item.iswrench()) to_chat(user, SPAN_NOTICE("You begin to [anchored ? "loosen" : "tighten"] \the [src]...")) - if(I.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) user.visible_message("[user] [anchored ? "loosens" : "tightens"] \the [src].", SPAN_NOTICE("You [anchored ? "loosen" : "tighten"] \the [src]."), SPAN_NOTICE("You hear a ratchet.")) anchored = !anchored return TRUE @@ -67,7 +67,7 @@ return TRUE // Cleaning one pixel with a soap or rag. - if(istype(I, /obj/item/soap) || istype(I, /obj/item/reagent_containers/glass/rag)) + if(istype(attacking_item, /obj/item/soap) || istype(attacking_item, /obj/item/reagent_containers/glass/rag)) // Pixel info created only when needed. var/icon/masterpiece = icon(icon,icon_state) var/thePix = masterpiece.GetPixel(pixX,pixY) @@ -83,8 +83,8 @@ return TRUE // Drawing one pixel with a crayon. - else if(istype(I, /obj/item/pen/crayon)) - var/obj/item/pen/crayon/C = I + else if(istype(attacking_item, /obj/item/pen/crayon)) + var/obj/item/pen/crayon/C = attacking_item DrawPixelOn(C.shadeColour, pixX, pixY) return TRUE else diff --git a/code/game/objects/items/contraband.dm b/code/game/objects/items/contraband.dm index 92d5a363e58..e1867aa07e7 100644 --- a/code/game/objects/items/contraband.dm +++ b/code/game/objects/items/contraband.dm @@ -124,10 +124,10 @@ w_class = ITEMSIZE_TINY volume = 50 -/obj/item/reagent_containers/powder/examine(mob/user) +/obj/item/reagent_containers/powder/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(reagents) - to_chat(user, SPAN_NOTICE("There's about [reagents.total_volume] unit\s here.")) + . += SPAN_NOTICE("There's about [reagents.total_volume] unit\s here.") /obj/item/reagent_containers/powder/Initialize() . = ..() @@ -139,8 +139,8 @@ // Proc to shove them up your nose -/obj/item/reagent_containers/powder/attackby(obj/item/W, mob/living/user) - if(istype(W, /obj/item/paper/cig) || istype(W, /obj/item/spacecash)) +/obj/item/reagent_containers/powder/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/paper/cig) || istype(attacking_item, /obj/item/spacecash)) var/mob/living/carbon/human/H = user var/obj/item/blocked = H.check_mouth_coverage() if(blocked) @@ -151,16 +151,16 @@ return TRUE user.visible_message( - SPAN_WARNING("\The [user] starts to snort some of \the [src] with \a [W]!"), - SPAN_NOTICE("You start to snort some of \the [src] with \the [W]!") + SPAN_WARNING("\The [user] starts to snort some of \the [src] with \a [attacking_item]!"), + SPAN_NOTICE("You start to snort some of \the [src] with \the [attacking_item]!") ) playsound(loc, 'sound/effects/snort.ogg', 50, 1) if (!do_after(user, 2 SECONDS)) return TRUE user.visible_message( - SPAN_WARNING("\The [user] snorts some of \the [src] with \a [W]!"), - SPAN_NOTICE("You snort \the [src] with \the [W]!") + SPAN_WARNING("\The [user] snorts some of \the [src] with \a [attacking_item]!"), + SPAN_NOTICE("You snort \the [src] with \the [attacking_item]!") ) playsound(loc, 'sound/effects/snort.ogg', 50, 1) diff --git a/code/game/objects/items/defib.dm b/code/game/objects/items/defib.dm index 38b2c6d6599..e15cb5485b3 100644 --- a/code/game/objects/items/defib.dm +++ b/code/game/objects/items/defib.dm @@ -62,12 +62,12 @@ overlays = new_overlays -/obj/item/defibrillator/examine(mob/user) +/obj/item/defibrillator/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(bcell) - to_chat(user, "The charge meter is showing [bcell.percent()]% charge left.") + . += "The charge meter is showing [bcell.percent()]% charge left." else - to_chat(user, "There is no cell inside.") + . += "There is no cell inside." /obj/item/defibrillator/ui_action_click() toggle_paddles() @@ -115,21 +115,21 @@ if(!H.put_in_active_hand(paddles)) to_chat(H, SPAN_WARNING("You need a free hand to take out the paddles!")) -/obj/item/defibrillator/attackby(obj/item/W, mob/user, params) - if(W == paddles) +/obj/item/defibrillator/attackby(obj/item/attacking_item, mob/user, params) + if(attacking_item == paddles) reattach_paddles(user) - else if(istype(W, /obj/item/cell)) + else if(istype(attacking_item, /obj/item/cell)) if(bcell) to_chat(user, SPAN_NOTICE("\The [src] already has a cell.")) else - if(!user.unEquip(W)) + if(!user.unEquip(attacking_item)) return - W.forceMove(src) - bcell = W + attacking_item.forceMove(src) + bcell = attacking_item to_chat(user, SPAN_NOTICE("You install a cell in \the [src].")) update_icon() - else if(W.isscrewdriver()) + else if(attacking_item.isscrewdriver()) if(bcell) bcell.update_icon() bcell.dropInto(loc) diff --git a/code/game/objects/items/devices/aicard.dm b/code/game/objects/items/devices/aicard.dm index d41b1f3eb71..1bf8974fa5e 100644 --- a/code/game/objects/items/devices/aicard.dm +++ b/code/game/objects/items/devices/aicard.dm @@ -9,7 +9,7 @@ var/flush = 0 var/mob/living/silicon/ai/carded_ai -/obj/item/aicard/examine(mob/user) +/obj/item/aicard/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() var/message = "Status of [carded_ai] is: " if(!carded_ai) @@ -20,7 +20,7 @@ message += SPAN_NOTICE("active.") else message += SPAN_WARNING("inactive.") - to_chat(user, message) + . += message /obj/item/aicard/attack(mob/living/silicon/decoy/M as mob, mob/user as mob, var/target_zone) if (!istype (M, /mob/living/silicon/decoy)) diff --git a/code/game/objects/items/devices/augment_implanter.dm b/code/game/objects/items/devices/augment_implanter.dm index cf0adb93e5a..a6e153bcf5c 100644 --- a/code/game/objects/items/devices/augment_implanter.dm +++ b/code/game/objects/items/devices/augment_implanter.dm @@ -15,12 +15,12 @@ if(!augment_type) augment_type = new new_augment(src) -/obj/item/device/augment_implanter/examine(mob/user) +/obj/item/device/augment_implanter/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(augment_type) - to_chat(user, FONT_SMALL(SPAN_NOTICE("\The [augment_type] can be seen floating inside \the [src]'s biogel."))) + . += FONT_SMALL(SPAN_NOTICE("\The [augment_type] can be seen floating inside \the [src]'s biogel.")) else - to_chat(user, FONT_SMALL(SPAN_WARNING("It is spent."))) + . += FONT_SMALL(SPAN_WARNING("It is spent.")) /obj/item/device/augment_implanter/afterattack(mob/living/L, mob/user, proximity) if(!proximity) diff --git a/code/game/objects/items/devices/auto_cpr.dm b/code/game/objects/items/devices/auto_cpr.dm index 003c19e4095..769fbf782ab 100644 --- a/code/game/objects/items/devices/auto_cpr.dm +++ b/code/game/objects/items/devices/auto_cpr.dm @@ -155,14 +155,14 @@ return if(user.unEquip(src)) - if(!H.equip_to_slot_if_possible(src, slot_wear_suit, del_on_fail=0, disable_warning=1, redraw_mob=1)) + if(!H.equip_to_slot_if_possible(src, slot_wear_suit, delete_on_fail = FALSE, disable_warning = TRUE, redraw_mob = TRUE)) user.put_in_active_hand(src) return 1 else return ..() -/obj/item/auto_cpr/attackby(obj/item/W, mob/user) - if(W.isscrewdriver()) +/obj/item/auto_cpr/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(ishuman(loc)) var/mob/living/carbon/human/H = loc if(H.get_inventory_slot(src) == slot_wear_suit) @@ -174,7 +174,7 @@ return TRUE if(panel_open) - if(W.iswrench()) + if(attacking_item.iswrench()) if(!tank) to_chat(user, "There isn't a tank to remove!") return TRUE @@ -184,7 +184,7 @@ tank = null update_icon() return TRUE - if(W.iscrowbar()) + if(attacking_item.iscrowbar()) if(!battery) to_chat(user, "There isn't a battery to remove!") return TRUE @@ -194,34 +194,34 @@ battery = null update_icon() return TRUE - if(istype(W, /obj/item/cell)) + if(istype(attacking_item, /obj/item/cell)) if(battery) to_chat(user, "There is already \a [battery] installed.") return TRUE - user.drop_from_inventory(W, src) - battery = W - user.visible_message(SPAN_NOTICE("[user] places \the [W] in \the [src]."), SPAN_NOTICE("You place \the [W] in \the [src].")) + user.drop_from_inventory(attacking_item, src) + battery = attacking_item + user.visible_message(SPAN_NOTICE("[user] places \the [attacking_item] in \the [src]."), SPAN_NOTICE("You place \the [attacking_item] in \the [src].")) update_icon() return TRUE - if(istype(W, /obj/item/clothing/mask/breath)) - if(is_type_in_list(W, mask_blacklist)) - to_chat(user, "\The [W] is incompatible with \the [src].") + if(istype(attacking_item, /obj/item/clothing/mask/breath)) + if(is_type_in_list(attacking_item, mask_blacklist)) + to_chat(user, "\The [attacking_item] is incompatible with \the [src].") return TRUE if(breath_mask) to_chat(user, "There is already \a [breath_mask] installed.") return TRUE - user.drop_from_inventory(W, src) - breath_mask = W - user.visible_message(SPAN_NOTICE("[user] places \the [W] in \the [src]."), SPAN_NOTICE("You place \the [W] in \the [src].")) + user.drop_from_inventory(attacking_item, src) + breath_mask = attacking_item + user.visible_message(SPAN_NOTICE("[user] places \the [attacking_item] in \the [src]."), SPAN_NOTICE("You place \the [attacking_item] in \the [src].")) update_icon() return TRUE - if(istype(W, /obj/item/tank/emergency_oxygen)) + if(istype(attacking_item, /obj/item/tank/emergency_oxygen)) if(tank) to_chat(user, "There is already \a [tank] installed!") return TRUE - user.drop_from_inventory(W, src) - tank = W - user.visible_message(SPAN_NOTICE("[user] places \the [W] in \the [src]."), SPAN_NOTICE("You place \the [W] in \the [src].")) + user.drop_from_inventory(attacking_item, src) + tank = attacking_item + user.visible_message(SPAN_NOTICE("[user] places \the [attacking_item] in \the [src]."), SPAN_NOTICE("You place \the [attacking_item] in \the [src].")) update_icon() return TRUE @@ -477,17 +477,17 @@ playsound(usr, 'sound/machines/click.ogg', 50) update_icon() -/obj/item/auto_cpr/examine(mob/user, distance, is_adjacent) +/obj/item/auto_cpr/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!is_adjacent) return - to_chat(user, SPAN_NOTICE("\The [src]'s [EPP] is currently [epp_mode ? "on" : "off"], while the Auto CPR is [cpr_mode ? "on" : "off"].")) + . += SPAN_NOTICE("\The [src]'s [EPP] is currently [epp_mode ? "on" : "off"], while the Auto CPR is [cpr_mode ? "on" : "off"].") if(battery) - to_chat(user, SPAN_NOTICE("It currently has a battery with [battery.percent()]% charge.")) + . += SPAN_NOTICE("It currently has a battery with [battery.percent()]% charge.") if(tank) - to_chat(user, SPAN_NOTICE("It has [icon2html(tank, user)] \the [tank] installed. The meter shows [round(tank.air_contents.return_pressure())]kPa, \ - with the pressure set to [round(tank.distribute_pressure)]kPa.[epp_active ? " The [EPP] is active." : ""]")) + . += SPAN_NOTICE("It has [icon2html(tank, user)] \the [tank] installed. The meter shows [round(tank.air_contents.return_pressure())]kPa, \ + with the pressure set to [round(tank.distribute_pressure)]kPa.[epp_active ? " The [EPP] is active." : ""]") if(breath_mask) - to_chat(user, SPAN_NOTICE("It has [icon2html(breath_mask, user)] \the [breath_mask] installed.")) + . += SPAN_NOTICE("It has [icon2html(breath_mask, user)] \the [breath_mask] installed.") #undef EPP diff --git a/code/game/objects/items/devices/dociler.dm b/code/game/objects/items/devices/dociler.dm index a3b4da2d30d..809220fc4d9 100644 --- a/code/game/objects/items/devices/dociler.dm +++ b/code/game/objects/items/devices/dociler.dm @@ -12,9 +12,9 @@ var/loaded = 1 var/mode = "completely" -/obj/item/device/dociler/examine(var/mob/user) +/obj/item/device/dociler/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "It is currently set to [mode] docile mode.") + . += "It is currently set to [mode] docile mode." /obj/item/device/dociler/attack_self(var/mob/user) if(mode == "somewhat") diff --git a/code/game/objects/items/devices/flash.dm b/code/game/objects/items/devices/flash.dm index 920908f279e..942589cac69 100644 --- a/code/game/objects/items/devices/flash.dm +++ b/code/game/objects/items/devices/flash.dm @@ -17,13 +17,13 @@ var/last_use = 0 -/obj/item/device/flash/examine(mob/user, distance) +/obj/item/device/flash/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!broken) var/num_charges = max(0, max_charges - times_used) - to_chat(user, SPAN_NOTICE("The charge indicator shows [num_charges] charge[num_charges == 1 ? "" : "s"] remain[num_charges == 1 ? "s" : ""].")) + . += SPAN_NOTICE("The charge indicator shows [num_charges] charge[num_charges == 1 ? "" : "s"] remain[num_charges == 1 ? "s" : ""].") else - to_chat(user, SPAN_WARNING("\The [src]'s bulb is burnt out!")) + . += SPAN_WARNING("\The [src]'s bulb is burnt out!") /obj/item/device/flash/proc/clumsy_check(mob/user) if(user && (user.is_clumsy()) && prob(50)) diff --git a/code/game/objects/items/devices/geiger.dm b/code/game/objects/items/devices/geiger.dm index 9014a0b7f91..78b9a4dca4e 100644 --- a/code/game/objects/items/devices/geiger.dm +++ b/code/game/objects/items/devices/geiger.dm @@ -33,13 +33,13 @@ radiation_count = SSradiation.get_rads_at_turf(get_turf(src)) update_icon() -/obj/item/device/geiger/examine(mob/user) +/obj/item/device/geiger/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() var/msg = "[scanning ? "ambient" : "stored"] Radiation level: [radiation_count ? radiation_count : "0"] IU/s." if(radiation_count > RAD_LEVEL_LOW) - to_chat(user, SPAN_WARNING("[msg]")) + . += SPAN_WARNING("[msg]") else - to_chat(user, SPAN_NOTICE("[msg]")) + . += SPAN_NOTICE("[msg]") /obj/item/device/geiger/attack_self(mob/user) scanning = !scanning diff --git a/code/game/objects/items/devices/hacktool.dm b/code/game/objects/items/devices/hacktool.dm index a149caaca2a..daf4fc19edf 100644 --- a/code/game/objects/items/devices/hacktool.dm +++ b/code/game/objects/items/devices/hacktool.dm @@ -29,8 +29,8 @@ hack_state = null return ..() -/obj/item/device/multitool/hacktool/attackby(var/obj/item/W, var/mob/user) - if(W.isscrewdriver()) +/obj/item/device/multitool/hacktool/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) in_hack_mode = !in_hack_mode playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, TRUE) return TRUE diff --git a/code/game/objects/items/devices/holowarrant.dm b/code/game/objects/items/devices/holowarrant.dm index 25722447585..0d8d0f0fba7 100644 --- a/code/game/objects/items/devices/holowarrant.dm +++ b/code/game/objects/items/devices/holowarrant.dm @@ -21,10 +21,10 @@ unload_warrant() return ..() -/obj/item/device/holowarrant/examine(mob/user, distance, is_adjacent) +/obj/item/device/holowarrant/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(selected_warrant) - to_chat(user, "It's a holographic warrant for '[selected_warrant.name]'.") + . += "It's a holographic warrant for '[selected_warrant.name]'." /obj/item/device/holowarrant/attack_self(mob/living/user as mob) if(!LAZYLEN(SSrecords.warrants)) diff --git a/code/game/objects/items/devices/laserpointer.dm b/code/game/objects/items/devices/laserpointer.dm index a93bc5da0e4..5016b8d5c3e 100644 --- a/code/game/objects/items/devices/laserpointer.dm +++ b/code/game/objects/items/devices/laserpointer.dm @@ -42,18 +42,18 @@ laser_act(M, user) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) -/obj/item/device/laser_pointer/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/stock_parts/micro_laser)) +/obj/item/device/laser_pointer/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stock_parts/micro_laser)) if(!diode) user.drop_item() - W.forceMove(src) - diode = W + attacking_item.forceMove(src) + diode = attacking_item to_chat(user, "You install a [diode.name] in [src].") else to_chat(user, "[src] already has a laser diode.") return TRUE - else if(W.isscrewdriver()) + else if(attacking_item.isscrewdriver()) if(diode) to_chat(user, "You remove the [diode.name] from the [src].") diode.forceMove(get_turf(user)) diff --git a/code/game/objects/items/devices/lighting/flare.dm b/code/game/objects/items/devices/lighting/flare.dm index 95be65af841..471d1196013 100644 --- a/code/game/objects/items/devices/lighting/flare.dm +++ b/code/game/objects/items/devices/lighting/flare.dm @@ -124,8 +124,8 @@ START_PROCESSING(SSprocessing, src) update_icon() -/obj/item/device/flashlight/flare/torch/attackby(var/obj/item/W, mob/user) - if(W.isFlameSource() && !on && fuel) +/obj/item/device/flashlight/flare/torch/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isFlameSource() && !on && fuel) light(user) else ..() @@ -164,11 +164,11 @@ drop_sound = 'sound/items/drop/woodweapon.ogg' pickup_sound = 'sound/items/pickup/woodweapon.ogg' -/obj/item/torch/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/reagent_containers/glass/rag)) - to_chat(user, SPAN_NOTICE("You add \the [I] to \the [src].")) +/obj/item/torch/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/reagent_containers/glass/rag)) + to_chat(user, SPAN_NOTICE("You add \the [attacking_item] to \the [src].")) var/obj/item/device/flashlight/flare/torch/T = new() - qdel(I) + qdel(attacking_item) user.put_in_hands(T) qdel(src) diff --git a/code/game/objects/items/devices/lighting/flashlight.dm b/code/game/objects/items/devices/lighting/flashlight.dm index 8b9241ec590..3b9588cde29 100644 --- a/code/game/objects/items/devices/lighting/flashlight.dm +++ b/code/game/objects/items/devices/lighting/flashlight.dm @@ -124,14 +124,14 @@ M.update_inv_r_ear() M.update_inv_head() -/obj/item/device/flashlight/examine(mob/user, distance, is_adjacent) +/obj/item/device/flashlight/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(power_use && brightness_level) - to_chat(user, SPAN_NOTICE("\The [src] is set to [brightness_level].")) + . += SPAN_NOTICE("\The [src] is set to [brightness_level].") if(cell) - to_chat(user, SPAN_NOTICE("\The [src] has \a [cell] attached. It has [round(cell.percent())]% charge remaining.")) + . += SPAN_NOTICE("\The [src] has \a [cell] attached. It has [round(cell.percent())]% charge remaining.") if(light_wedge && isturf(loc)) - to_chat(user, FONT_SMALL(SPAN_NOTICE("\The [src] is facing [dir2text(dir)]."))) + . += FONT_SMALL(SPAN_NOTICE("\The [src] is facing [dir2text(dir)].")) /obj/item/device/flashlight/attack_self(mob/user) if(always_on) @@ -169,14 +169,14 @@ else return ..() -/obj/item/device/flashlight/attackby(obj/item/W, mob/user) +/obj/item/device/flashlight/attackby(obj/item/attacking_item, mob/user) if(power_use) - if(istype(W, /obj/item/cell)) - if(istype(W, /obj/item/cell/device) || accepts_large_cells) + if(istype(attacking_item, /obj/item/cell)) + if(istype(attacking_item, /obj/item/cell/device) || accepts_large_cells) if(!cell) user.drop_item() - W.loc = src - cell = W + attacking_item.loc = src + cell = attacking_item to_chat(user, SPAN_NOTICE("You install a cell in \the [src].")) playsound(src, 'sound/machines/click.ogg', 30, 1, 0) update_icon() diff --git a/code/game/objects/items/devices/lightreplacer.dm b/code/game/objects/items/devices/lightreplacer.dm index f18ce37c793..4a3fd2ded39 100644 --- a/code/game/objects/items/devices/lightreplacer.dm +++ b/code/game/objects/items/devices/lightreplacer.dm @@ -72,16 +72,16 @@ failmsg = "The [name]'s refill light blinks red." ..() -/obj/item/device/lightreplacer/examine(mob/user, distance, is_adjacent) +/obj/item/device/lightreplacer/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 2) - to_chat(user, "It has [uses] lights remaining.") + . += "It has [uses] lights remaining." if (store_broken) - to_chat(user, "It is storing [stored()]/[max_stored] broken lights.") + . += "It is storing [stored()]/[max_stored] broken lights." -/obj/item/device/lightreplacer/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/stack/material) && W.get_material_name() == "glass") - var/obj/item/stack/G = W +/obj/item/device/lightreplacer/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stack/material) && attacking_item.get_material_name() == "glass") + var/obj/item/stack/G = attacking_item if(uses >= max_uses) to_chat(user, SPAN_WARNING("[src.name] is full.")) else if(G.use(5)) @@ -93,8 +93,8 @@ to_chat(user, SPAN_WARNING("You need 5 sheets of glass to replace lights.")) return TRUE - if(istype(W, /obj/item/light)) - var/obj/item/light/L = W + if(istype(attacking_item, /obj/item/light)) + var/obj/item/light/L = attacking_item if(L.status == 0) // LIGHT OKAY if(uses < max_uses) AddUses(1) @@ -105,8 +105,8 @@ to_chat(user, SPAN_WARNING("You need a working light.")) return TRUE - if(istype(W, /obj/item/device/lightreplacer)) - var/obj/item/device/lightreplacer/LR = W + if(istype(attacking_item, /obj/item/device/lightreplacer)) + var/obj/item/device/lightreplacer/LR = attacking_item if(LR.uses == LR.max_uses) to_chat(user, SPAN_WARNING("\The [LR] is already full!")) return TRUE diff --git a/code/game/objects/items/devices/magnetic_lock.dm b/code/game/objects/items/devices/magnetic_lock.dm index eed357706c6..c856425a585 100644 --- a/code/game/objects/items/devices/magnetic_lock.dm +++ b/code/game/objects/items/devices/magnetic_lock.dm @@ -76,17 +76,17 @@ status = STATUS_ACTIVE attach(newtarget) -/obj/item/device/magnetic_lock/examine(mob/user) +/obj/item/device/magnetic_lock/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if (status == STATUS_BROKEN) - to_chat(user, "It looks broken!") + . += "It looks broken!" else if (powercell) var/power = round(powercell.charge / powercell.maxcharge * 100) - to_chat(user, "The powercell is at [power]% charge.") + . += "The powercell is at [power]% charge." else - to_chat(user, "It has no powercell to power it!") + . += "It has no powercell to power it!" /obj/item/device/magnetic_lock/attack_hand(var/mob/user) add_fingerprint(user) @@ -111,48 +111,48 @@ takedamage(Proj.damage) ..() -/obj/item/device/magnetic_lock/attackby(var/obj/item/I, var/mob/user) +/obj/item/device/magnetic_lock/attackby(obj/item/attacking_item, mob/user) if (status == STATUS_BROKEN) to_chat(user, "[src] is broken beyond repair!") return TRUE - if (istype(I, /obj/item/card/id)) + if (istype(attacking_item, /obj/item/card/id)) if (!constructionstate && !hacked) - if (check_access(I)) + if (check_access(attacking_item)) locked = !locked playsound(src, 'sound/machines/ping.ogg', 30, 1) - var/msg = "[I] through \the [src] and it [locked ? "locks" : "unlocks"] with a beep." + var/msg = "[attacking_item] through \the [src] and it [locked ? "locks" : "unlocks"] with a beep." var/pos_adj = "[user.name] swipes [user.get_pronoun("his")] " var/fp_adj = "You swipe your " user.visible_message("[addtext(pos_adj, msg)]", "[addtext(fp_adj, msg)]") update_icon() else playsound(src, 'sound/machines/buzz-sigh.ogg', 30, 1) - to_chat(user, SPAN_WARNING("\The [src] buzzes as you swipe your [I].")) + to_chat(user, SPAN_WARNING("\The [src] buzzes as you swipe your [attacking_item].")) return else - to_chat(user, "You cannot swipe your [I] through [src] with it partially dismantled!") + to_chat(user, "You cannot swipe your [attacking_item] through [src] with it partially dismantled!") return TRUE - if (istype(I, /obj/item) && user.a_intent == "harm") - if (I.force >= 18) - user.visible_message("[user] bashes [src] with [I]!", "You strike [src] with [I], damaging it!") - takedamage(I.force) + if (istype(attacking_item, /obj/item) && user.a_intent == "harm") + if (attacking_item.force >= 18) + user.visible_message("[user] bashes [src] with [attacking_item]!", "You strike [src] with [attacking_item], damaging it!") + takedamage(attacking_item.force) var/sound_to_play = pick(list('sound/weapons/genhit1.ogg', 'sound/weapons/genhit2.ogg', 'sound/weapons/genhit3.ogg')) - playsound(loc, sound_to_play, I.force*3, 1) + playsound(loc, sound_to_play, attacking_item.force*3, 1) sound_to_play = pick(list('sound/effects/sparks1.ogg', 'sound/effects/sparks2.ogg', 'sound/effects/sparks3.ogg', 'sound/effects/sparks4.ogg')) addtimer(CALLBACK(GLOBAL_PROC, /proc/playsound, loc, sound_to_play, 30, 1), 3, TIMER_CLIENT_TIME) else - user.visible_message("[user] hits [src] with [I] but fails to damage it.", "You hit [src] with [I], [I.force >= 10 ? "and it almost makes a dent!" : "but it appears to have no visible effect."]") - playsound(loc, 'sound/weapons/Genhit.ogg', I.force*2.5, 1) + user.visible_message("[user] hits [src] with [attacking_item] but fails to damage it.", "You hit [src] with [attacking_item], [attacking_item.force >= 10 ? "and it almost makes a dent!" : "but it appears to have no visible effect."]") + playsound(loc, 'sound/weapons/Genhit.ogg', attacking_item.force*2.5, 1) return TRUE if(invincible) return TRUE switch (constructionstate) if (0) - if (istype(I, /obj/item/card/emag)) - var/obj/item/card/emag/emagcard = I + if (istype(attacking_item, /obj/item/card/emag)) + var/obj/item/card/emag/emagcard = attacking_item emagcard.uses-- visible_message("[src] sparks and falls off the door!", "You emag [src], frying its circuitry[status == STATUS_ACTIVE ? " and making it drop onto the floor" : ""]!") @@ -162,8 +162,8 @@ update_icon() return TRUE - if (I.iswelder()) - var/obj/item/weldingtool/WT = I + if (attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if (WT.use(2, user)) user.visible_message(SPAN_NOTICE("[user] starts welding the metal shell of [src]."), SPAN_NOTICE("You start [hacked ? "repairing" : "welding open"] the metal covering of [src].")) playsound(loc, 'sound/items/Welder.ogg', 50, 1) @@ -179,7 +179,7 @@ update_icon() return TRUE - if (I.iscrowbar()) + if (attacking_item.iscrowbar()) if (!locked) to_chat(user, SPAN_NOTICE("You pry the cover off [src].")) setconstructionstate(1) @@ -188,51 +188,51 @@ return TRUE if (1) - if (istype(I, /obj/item/cell)) + if (istype(attacking_item, /obj/item/cell)) if (powercell) to_chat(user, SPAN_NOTICE("There's already a powercell in \the [src].")) return TRUE - if (I.iscrowbar()) + if (attacking_item.iscrowbar()) to_chat(user, SPAN_NOTICE("You wedge the cover back in place.")) setconstructionstate(0) return TRUE if (2) - if (I.isscrewdriver()) + if (attacking_item.isscrewdriver()) to_chat(user, SPAN_NOTICE("You unscrew and remove the wiring cover from \the [src].")) - playsound(loc, I.usesound, 50, 1) + playsound(loc, attacking_item.usesound, 50, 1) setconstructionstate(3) return TRUE - if (I.iscrowbar()) + if (attacking_item.iscrowbar()) to_chat(user, SPAN_NOTICE("You wedge the cover back in place.")) setconstructionstate(0) return TRUE - if (istype(I, /obj/item/cell)) + if (istype(attacking_item, /obj/item/cell)) if (!powercell) - to_chat(user, SPAN_NOTICE("You place the [I] inside \the [src].")) - user.drop_from_inventory(I,src) - powercell = I + to_chat(user, SPAN_NOTICE("You place the [attacking_item] inside \the [src].")) + user.drop_from_inventory(attacking_item,src) + powercell = attacking_item setconstructionstate(1) return TRUE if (3) - if (I.iswirecutter()) + if (attacking_item.iswirecutter()) to_chat(user, SPAN_NOTICE("You cut the wires connecting the [src]'s magnets to their internal powersupply, [target ? "making the device fall off [target] and rendering it unusable." : "rendering the device unusable."]")) playsound(loc, 'sound/items/Wirecutter.ogg', 50, 1) setconstructionstate(4) return TRUE - if (I.isscrewdriver()) + if (attacking_item.isscrewdriver()) to_chat(user, SPAN_NOTICE("You replace and screw tight the wiring cover from \the [src].")) - playsound(loc, I.usesound, 50, 1) + playsound(loc, attacking_item.usesound, 50, 1) setconstructionstate(2) return TRUE if (4) - if (I.iswirecutter()) + if (attacking_item.iswirecutter()) to_chat(user, SPAN_NOTICE("You repair the wires connecting the [src]'s magnets to their internal powersupply")) setconstructionstate(3) return TRUE diff --git a/code/game/objects/items/devices/modkit.dm b/code/game/objects/items/devices/modkit.dm index 913708e1d20..71b8bfa88f2 100644 --- a/code/game/objects/items/devices/modkit.dm +++ b/code/game/objects/items/devices/modkit.dm @@ -69,9 +69,9 @@ user.drop_from_inventory(src,O) qdel(src) -/obj/item/device/modkit/examine(mob/user) +/obj/item/device/modkit/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "It looks as though it modifies voidsuits to fit [target_species] users.") + . += "It looks as though it modifies voidsuits to fit [target_species] users." /obj/item/device/modkit/tajaran name = "tajaran voidsuit modification kit" diff --git a/code/game/objects/items/devices/paicard.dm b/code/game/objects/items/devices/paicard.dm index abf77c81540..c92a488e447 100644 --- a/code/game/objects/items/devices/paicard.dm +++ b/code/game/objects/items/devices/paicard.dm @@ -45,15 +45,15 @@ pai.death(0) return ..() -/obj/item/device/paicard/attackby(obj/item/C, mob/user) - if(istype(C, /obj/item/card/id)) - scan_ID(C, user) +/obj/item/device/paicard/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/card/id)) + scan_ID(attacking_item, user) return TRUE - else if(istype(C, /obj/item/device/encryptionkey)) + else if(istype(attacking_item, /obj/item/device/encryptionkey)) if(length(installed_encryptionkeys) > 2) to_chat(user, SPAN_WARNING("\The [src] already has the full number of possible encryption keys installed!")) return TRUE - var/obj/item/device/encryptionkey/EK = C + var/obj/item/device/encryptionkey/EK = attacking_item var/added_channels = FALSE for(var/thing in (EK.channels | EK.additional_channels)) if(!radio.channels[thing]) @@ -69,22 +69,22 @@ else to_chat(user, SPAN_WARNING("\The [src] would not gain any new channels from \the [EK].")) return TRUE - else if(C.isscrewdriver()) + else if(attacking_item.isscrewdriver()) if(!length(installed_encryptionkeys)) to_chat(user, SPAN_WARNING("There are no installed encryption keys to remove!")) return - user.visible_message("[user] uses \the [C] to pop the encryption key[length(installed_encryptionkeys) > 1 ? "s" : ""] out of \the [src].", SPAN_NOTICE("You use \the [C] to pop the encryption key[length(installed_encryptionkeys) > 1 ? "s" : ""] out of \the [src].")) + user.visible_message("[user] uses \the [attacking_item] to pop the encryption key[length(installed_encryptionkeys) > 1 ? "s" : ""] out of \the [src].", SPAN_NOTICE("You use \the [attacking_item] to pop the encryption key[length(installed_encryptionkeys) > 1 ? "s" : ""] out of \the [src].")) for(var/key in installed_encryptionkeys) var/obj/item/device/encryptionkey/EK = key EK.forceMove(get_turf(src)) installed_encryptionkeys -= EK recalculateChannels() return TRUE - else if(istype(C, /obj/item/stack/nanopaste)) + else if(istype(attacking_item, /obj/item/stack/nanopaste)) if(!pai) to_chat(user, SPAN_WARNING("You cannot repair a pAI device if there's no active pAI personality installed.")) return TRUE - pai.attackby(C, user) + pai.attackby(attacking_item, user) /obj/item/device/paicard/proc/recalculateChannels() radio.channels = list("Common" = radio.FREQ_LISTENING, "Entertainment" = radio.FREQ_LISTENING) diff --git a/code/game/objects/items/devices/paint_sprayer.dm b/code/game/objects/items/devices/paint_sprayer.dm index 26de453f444..6994521e504 100644 --- a/code/game/objects/items/devices/paint_sprayer.dm +++ b/code/game/objects/items/devices/paint_sprayer.dm @@ -289,9 +289,9 @@ playsound(get_turf(src), 'sound/effects/spray3.ogg', 30, 1, -6) return . -/obj/item/device/paint_sprayer/examine(mob/user) +/obj/item/device/paint_sprayer/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "It is configured to produce the '[decal]' decal with a direction of '[paint_dir]' using [paint_colour] paint.") + . += "It is configured to produce the '[SPAN_NOTICE(decal)]' decal with a direction of '[SPAN_NOTICE(paint_dir)]' using [SPAN_NOTICE(paint_colour)] paint." /obj/item/device/paint_sprayer/verb/choose_colour() set name = "Choose Colour" diff --git a/code/game/objects/items/devices/personal_shield.dm b/code/game/objects/items/devices/personal_shield.dm index c6e4cfab8ec..d2e5b3b9c35 100644 --- a/code/game/objects/items/devices/personal_shield.dm +++ b/code/game/objects/items/devices/personal_shield.dm @@ -13,10 +13,11 @@ var/upkeep_cost = 2 var/obj/aura/personal_shield/device/shield -/obj/item/device/personal_shield/examine(mob/user, distance, is_adjacent) +/obj/item/device/personal_shield/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(is_adjacent) - to_chat(user, SPAN_NOTICE("\The [src] has [cell.charge] charge remaining. Shield upkeep costs [upkeep_cost] charge, and blocking a shot costs [charge_per_shot] charge.")) + . += SPAN_NOTICE("\The [src] has [cell.charge] charge remaining.") + . += SPAN_NOTICE("Shield upkeep costs [upkeep_cost] charge, and blocking a shot costs [SPAN_NOTICE(charge_per_shot)] charge.") /obj/item/device/personal_shield/Initialize() . = ..() diff --git a/code/game/objects/items/devices/pipe_painter.dm b/code/game/objects/items/devices/pipe_painter.dm index 1daf45c43bf..a5c46b0e5de 100644 --- a/code/game/objects/items/devices/pipe_painter.dm +++ b/code/game/objects/items/devices/pipe_painter.dm @@ -31,6 +31,6 @@ /obj/item/device/pipe_painter/attack_self(var/mob/user) mode = tgui_input_list(user, "Which colour do you want to use?", "Pipe Painter", modes, mode) -/obj/item/device/pipe_painter/examine(var/mob/user) +/obj/item/device/pipe_painter/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "It is in [mode] mode.") + . += "It is in [mode] mode." diff --git a/code/game/objects/items/devices/powersink.dm b/code/game/objects/items/devices/powersink.dm index fb84cd0ca61..331c1028673 100644 --- a/code/game/objects/items/devices/powersink.dm +++ b/code/game/objects/items/devices/powersink.dm @@ -31,8 +31,8 @@ return ..() -/obj/item/device/powersink/attackby(var/obj/item/I, var/mob/user) - if(I.isscrewdriver()) +/obj/item/device/powersink/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(mode == 0) var/turf/T = loc if(isturf(T) && !!T.is_plating()) diff --git a/code/game/objects/items/devices/radio/beacon.dm b/code/game/objects/items/devices/radio/beacon.dm index 52a4159b280..c1e67abdf39 100644 --- a/code/game/objects/items/devices/radio/beacon.dm +++ b/code/game/objects/items/devices/radio/beacon.dm @@ -17,10 +17,10 @@ GLOBAL_LIST_EMPTY(teleportbeacons) GLOB.teleportbeacons -= src return ..() -/obj/item/device/radio/beacon/examine(mob/user) +/obj/item/device/radio/beacon/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(anchored) - to_chat(user, SPAN_NOTICE("It's been secured to the ground with anchoring screws.")) + . += SPAN_NOTICE("It's been secured to the ground with anchoring screws.") /obj/item/device/radio/beacon/attack_hand(mob/user) if(anchored) @@ -33,8 +33,8 @@ GLOBAL_LIST_EMPTY(teleportbeacons) /obj/item/device/radio/beacon/send_hear() return null -/obj/item/device/radio/beacon/attackby(obj/item/W, mob/user) - if(isturf(loc) && W.isscrewdriver()) +/obj/item/device/radio/beacon/attackby(obj/item/attacking_item, mob/user) + if(isturf(loc) && attacking_item.isscrewdriver()) anchored = !anchored user.visible_message("[user] [anchored ? "" : "un"]fastens \the [src] [anchored ? "to" : "from"] the floor.", "You [anchored ? "" : "un"]fasten \the [src] [anchored ? "to" : "from"] the floor.") return diff --git a/code/game/objects/items/devices/radio/encryptionkey.dm b/code/game/objects/items/devices/radio/encryptionkey.dm index 12c589ebf70..874e38e1d49 100644 --- a/code/game/objects/items/devices/radio/encryptionkey.dm +++ b/code/game/objects/items/devices/radio/encryptionkey.dm @@ -13,7 +13,7 @@ var/list/channels = list(CHANNEL_COMMON = TRUE, CHANNEL_ENTERTAINMENT = TRUE) var/list/additional_channels = list() -/obj/item/device/encryptionkey/attackby(obj/item/W, mob/user) +/obj/item/device/encryptionkey/attackby(obj/item/attacking_item, mob/user) return /obj/item/device/encryptionkey/ship diff --git a/code/game/objects/items/devices/radio/headset.dm b/code/game/objects/items/devices/radio/headset.dm index dde58f63a13..f5b8a8250a4 100644 --- a/code/game/objects/items/devices/radio/headset.dm +++ b/code/game/objects/items/devices/radio/headset.dm @@ -56,14 +56,14 @@ /obj/item/device/radio/headset/list_channels(var/mob/user) return list_secure_channels() -/obj/item/device/radio/headset/examine(mob/user, distance, is_adjacent) +/obj/item/device/radio/headset/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!(is_adjacent && radio_desc)) return - to_chat(user, "The following channels are available:") - to_chat(user, radio_desc) + . += "The following channels are available:" + . += radio_desc /obj/item/device/radio/headset/setupRadioDescription() if(translate_binary || translate_hivenet) @@ -106,8 +106,8 @@ ..() -/obj/item/device/radio/headset/attackby(obj/item/W, mob/user) - if(W.isscrewdriver()) +/obj/item/device/radio/headset/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(keyslot1 || keyslot2) for(var/ch_name in channels) SSradio.remove_object(src, radiochannels[ch_name]) @@ -130,17 +130,17 @@ else to_chat(user, SPAN_WARNING("This headset doesn't have any encryption keys!")) - else if(istype(W, /obj/item/device/encryptionkey)) + else if(istype(attacking_item, /obj/item/device/encryptionkey)) if(keyslot1 && keyslot2) to_chat(user, SPAN_WARNING("The headset can't hold another key!")) return if(!keyslot1) - user.drop_from_inventory(W, src) - keyslot1 = W + user.drop_from_inventory(attacking_item, src) + keyslot1 = attacking_item else - user.drop_from_inventory(W, src) - keyslot2 = W + user.drop_from_inventory(attacking_item, src) + keyslot2 = attacking_item recalculateChannels(TRUE) diff --git a/code/game/objects/items/devices/radio/microphone.dm b/code/game/objects/items/devices/radio/microphone.dm new file mode 100644 index 00000000000..30f5935796b --- /dev/null +++ b/code/game/objects/items/devices/radio/microphone.dm @@ -0,0 +1,10 @@ +/obj/item/device/radio/microphone + name = "handheld microphone" + desc = "A handheld microphone, used for on-the-fly interviewing. Pose for the fans!" + icon_state = "microphone" + item_state = "microphone" + +/obj/item/device/radio/microphone/Initialize() + . = ..() + set_frequency(ENT_FREQ) + internal_channels = list(num2text(ENT_FREQ) = list()) diff --git a/code/game/objects/items/devices/radio/radio.dm b/code/game/objects/items/devices/radio/radio.dm index 09914685d8f..2c45de45d7e 100644 --- a/code/game/objects/items/devices/radio/radio.dm +++ b/code/game/objects/items/devices/radio/radio.dm @@ -515,18 +515,18 @@ var/global/list/default_interrogation_channels = list( return get_hearers_in_view(canhear_range, src) -/obj/item/device/radio/examine(mob/user, distance, is_adjacent) +/obj/item/device/radio/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(show_modify_on_examine && (distance <= 1)) if (b_stat) - user.show_message("\The [src] can be attached and modified!") + . += SPAN_NOTICE("\The [src] can be attached and modified!") else - user.show_message("\The [src] can not be modified or attached!") + . += SPAN_NOTICE("\The [src] can not be modified or attached!") -/obj/item/device/radio/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/device/radio/attackby(obj/item/attacking_item, mob/user) ..() user.set_machine(src) - if (!( W.isscrewdriver() )) + if (!( attacking_item.isscrewdriver() )) return b_stat = !( b_stat ) if(!istype(src, /obj/item/device/radio/beacon)) @@ -578,13 +578,13 @@ var/global/list/default_interrogation_channels = list( var/datum/robot_component/C = R.components["radio"] R.cell_use_power(C.active_usage) -/obj/item/device/radio/borg/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/device/radio/borg/attackby(obj/item/attacking_item, mob/user) // ..() user.set_machine(src) - if (!( W.isscrewdriver() || (istype(W, /obj/item/device/encryptionkey/ )))) + if (!( attacking_item.isscrewdriver() || (istype(attacking_item, /obj/item/device/encryptionkey/ )))) return - if(W.isscrewdriver()) + if(attacking_item.isscrewdriver()) if(keyslot) @@ -605,14 +605,14 @@ var/global/list/default_interrogation_channels = list( else to_chat(user, "This radio doesn't have any encryption keys!") - if(istype(W, /obj/item/device/encryptionkey/)) + if(istype(attacking_item, /obj/item/device/encryptionkey/)) if(keyslot) to_chat(user, "The radio can't hold another key!") return if(!keyslot) - user.drop_from_inventory(W,src) - keyslot = W + user.drop_from_inventory(attacking_item,src) + keyslot = attacking_item recalculateChannels() diff --git a/code/game/objects/items/devices/radio_jammer.dm b/code/game/objects/items/devices/radio_jammer.dm index b3a0a11b69f..c812cdc199b 100644 --- a/code/game/objects/items/devices/radio_jammer.dm +++ b/code/game/objects/items/devices/radio_jammer.dm @@ -132,8 +132,8 @@ var/list/active_radio_jammers = list() update_icon() -/obj/item/device/radiojammer/improvised/attackby(obj/item/W as obj, mob/user as mob) - if (W.isscrewdriver()) +/obj/item/device/radiojammer/improvised/attackby(obj/item/attacking_item, mob/user) + if (attacking_item.isscrewdriver()) to_chat(user, "You disassemble the improvised signal jammer.") user.put_in_hands(assembly_holder) assembly_holder.detached() diff --git a/code/game/objects/items/devices/spy_bug.dm b/code/game/objects/items/devices/spy_bug.dm index 669ea861ba4..64105188dec 100644 --- a/code/game/objects/items/devices/spy_bug.dm +++ b/code/game/objects/items/devices/spy_bug.dm @@ -25,20 +25,23 @@ camera = new(src) become_hearing_sensitive(ROUNDSTART_TRAIT) -/obj/item/device/spy_bug/examine(mob/user, distance) +/obj/item/device/spy_bug/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 0) - to_chat(user, "It's a tiny camera, microphone, and transmission device in a happy union.") - to_chat(user, "Needs to be both configured and brought in contact with monitor device to be fully functional.") + . += "It's a tiny camera, microphone, and transmission device in a happy union." + . += "Needs to be both configured and brought in contact with monitor device to be fully functional." /obj/item/device/spy_bug/attack_self(mob/user) radio.set_broadcasting(!radio.get_broadcasting()) to_chat(user, "\The [src]'s radio is [radio.get_broadcasting() ? "broadcasting" : "not broadcasting"] now. The current frequency is [radio.get_frequency()].") radio.attack_self(user) -/obj/item/device/spy_bug/attackby(obj/W as obj, mob/living/user as mob) - if(istype(W, /obj/item/device/spy_monitor)) - var/obj/item/device/spy_monitor/SM = W +/obj/item/device/spy_bug/attackby(obj/item/attacking_item, mob/user) + if(!istype(user)) + return + + if(istype(attacking_item, /obj/item/device/spy_monitor)) + var/obj/item/device/spy_monitor/SM = attacking_item SM.pair(src, user) return TRUE else @@ -68,10 +71,10 @@ radio = new(src) become_hearing_sensitive(ROUNDSTART_TRAIT) -/obj/item/device/spy_monitor/examine(mob/user, distance) +/obj/item/device/spy_monitor/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1) - to_chat(user, "The time '12:00' is blinking in the corner of the screen and \the [src] looks very cheaply made.") + . += "The time '12:00' is blinking in the corner of the screen and \the [src] looks very cheaply made." /obj/item/device/spy_monitor/attack_self(mob/user) if(operating) @@ -80,9 +83,12 @@ radio.attack_self(user) view_cameras(user) -/obj/item/device/spy_monitor/attackby(obj/W as obj, mob/living/user as mob) - if(istype(W, /obj/item/device/spy_bug)) - pair(W, user) +/obj/item/device/spy_monitor/attackby(obj/item/attacking_item, mob/user) + if(!istype(user)) + return + + if(istype(attacking_item, /obj/item/device/spy_bug)) + pair(attacking_item, user) return TRUE else return ..() diff --git a/code/game/objects/items/devices/suit_cooling.dm b/code/game/objects/items/devices/suit_cooling.dm index f7809efd6a6..57536658206 100644 --- a/code/game/objects/items/devices/suit_cooling.dm +++ b/code/game/objects/items/devices/suit_cooling.dm @@ -150,8 +150,8 @@ if(on) to_chat(user, SPAN_NOTICE("You switch on \the [src].")) -/obj/item/device/suit_cooling_unit/attackby(obj/item/W, mob/user) - if(W.isscrewdriver()) +/obj/item/device/suit_cooling_unit/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(cover_open) cover_open = FALSE to_chat(user, SPAN_NOTICE("You screw the panel into place.")) @@ -161,13 +161,13 @@ update_icon() return - if(istype(W, /obj/item/cell)) + if(istype(attacking_item, /obj/item/cell)) if(cover_open) if(cell) to_chat(user, SPAN_WARNING("There is \a [cell] already installed here.")) else - user.drop_from_inventory(W,src) - cell = W + user.drop_from_inventory(attacking_item,src) + cell = attacking_item to_chat(user, SPAN_NOTICE("You insert \the [cell].")) update_icon() return @@ -210,7 +210,7 @@ M.update_inv_back() M.update_inv_s_store() -/obj/item/device/suit_cooling_unit/examine(mob/user, distance) +/obj/item/device/suit_cooling_unit/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!distance <= 1) @@ -218,26 +218,26 @@ if(on) if(attached_to_suit(src.loc)) - to_chat(user, SPAN_NOTICE("It's switched on and running.")) + . += SPAN_NOTICE("It's switched on and running.") else if(ishuman(loc)) var/mob/living/carbon/human/H = loc if(H.species.flags & ACCEPTS_COOLER) - to_chat(user, SPAN_NOTICE("It's switched on and running, connected to the cooling systems of [H].")) + . += SPAN_NOTICE("It's switched on and running, connected to the cooling systems of [H].") else - to_chat(user, SPAN_NOTICE("It's switched on, but not attached to anything.")) + . += SPAN_NOTICE("It's switched on, but not attached to anything.") else - to_chat(user, SPAN_NOTICE("It is switched off.")) + . += SPAN_NOTICE("It is switched off.") if(cover_open) if(cell) - to_chat(user, SPAN_NOTICE("The panel is open, exposing \the [cell].")) + . += SPAN_NOTICE("The panel is open, exposing \the [cell].") else - to_chat(user, SPAN_NOTICE("The panel is open.")) + . += SPAN_NOTICE("The panel is open.") if(cell) - to_chat(user, SPAN_NOTICE("The charge meter reads [round(cell.percent())]%.")) + . += SPAN_NOTICE("The charge meter reads [round(cell.percent())]%.") else - to_chat(user, SPAN_NOTICE("It doesn't have a power cell installed.")) + . += SPAN_NOTICE("It doesn't have a power cell installed.") /obj/item/device/suit_cooling_unit/no_cell celltype = null diff --git a/code/game/objects/items/devices/taperecorder.dm b/code/game/objects/items/devices/taperecorder.dm index 4b63f359bd1..bfb37c4340b 100644 --- a/code/game/objects/items/devices/taperecorder.dm +++ b/code/game/objects/items/devices/taperecorder.dm @@ -92,8 +92,9 @@ if(use_check_and_message(usr)) return + usr.visible_message("[SPAN_BOLD("\The [usr]")] presses a button on \the [src].") if(emagged) - to_chat(usr, SPAN_WARNING("The tape recorder makes a scratchy noise.")) + src.audible_message(SPAN_WARNING("\The [src] makes a scratchy noise."), hearing_distance = 3) return icon_state = "taperecorderrecording" if(time_recorded < 3600 && !playing) @@ -119,10 +120,10 @@ if(use_check_and_message(usr)) return + usr.visible_message("[SPAN_BOLD("\The [usr]")] presses a button on \the [src].") if(emagged) - to_chat(usr, SPAN_WARNING("The tape recorder makes a scratchy noise.")) + src.audible_message(SPAN_WARNING("\The [src] makes a scratchy noise."), hearing_distance = 3) return - if(recording) recording = FALSE timestamp += time_recorded @@ -143,8 +144,9 @@ if(use_check_and_message(usr)) return + usr.visible_message("[SPAN_BOLD("\The [usr]")] presses a button on \the [src].") if(emagged) - to_chat(usr, SPAN_WARNING("The tape recorder makes a scratchy noise.")) + src.audible_message(SPAN_WARNING("\The [src] makes a scratchy noise."), hearing_distance = 3) return if(recording || playing) to_chat(usr, SPAN_WARNING("You can't clear the memory while playing or recording!")) @@ -216,11 +218,12 @@ if(use_check_and_message(usr)) return + usr.visible_message("[SPAN_BOLD("\The [usr]")] presses a button on \the [src].") if(emagged) - to_chat(usr, SPAN_WARNING("The tape recorder makes a scratchy noise.")) + src.audible_message(SPAN_WARNING("\The [src] makes a scratchy noise."), hearing_distance = 3) return if(!can_print) - to_chat(usr, SPAN_WARNING("The recorder can't print that fast!")) + to_chat(usr, SPAN_WARNING("\The [src] can't print that fast!")) return if(recording || playing) to_chat(usr, SPAN_WARNING("You can't print the transcript while playing or recording!")) @@ -276,8 +279,9 @@ if(!recording && !playing) if(use_check_and_message(usr)) return + usr.visible_message("[SPAN_BOLD("\The [usr]")] presses a button on \the [src].") if(emagged) - to_chat(usr, SPAN_WARNING("The tape recorder makes a scratchy noise.")) + src.audible_message(SPAN_WARNING("\The [src] makes a scratchy noise."), hearing_distance = 3) return icon_state = "taperecorderrecording" if(time_recorded < 3600 && !playing) @@ -294,10 +298,11 @@ icon_state = "taperecorderidle" return else - to_chat(usr, SPAN_WARNING("Either your tape recorder's memory is full, or it is currently playing back its memory.")) + to_chat(usr, SPAN_WARNING("Either \the [src]'s memory is full, or it is currently playing back its memory.")) else if(use_check_and_message(usr)) return + usr.visible_message("[SPAN_BOLD("\The [usr]")] presses a button on \the [src].") if(recording) recording = FALSE timestamp += time_recorded @@ -306,7 +311,7 @@ icon_state = "taperecorderidle" return else if(emagged) - to_chat(usr, SPAN_WARNING("The tape recorder's buttons doesn't react!")) + to_chat(usr, SPAN_WARNING("\The [src]'s buttons doesn't react!")) return else if(playing) playing = FALSE @@ -314,12 +319,12 @@ icon_state = "taperecorderidle" return -/obj/item/device/taperecorder/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/computer_hardware/hard_drive/portable)) +/obj/item/device/taperecorder/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/computer_hardware/hard_drive/portable)) if(portable_drive) to_chat(user, SPAN_WARNING("\The [src] already has a portable drive!")) return - user.drop_from_inventory(W, src) - portable_drive = W + user.drop_from_inventory(attacking_item, src) + portable_drive = attacking_item else ..() diff --git a/code/game/objects/items/devices/transfer_valve.dm b/code/game/objects/items/devices/transfer_valve.dm index ce8f3418e57..f9c7c5c4408 100644 --- a/code/game/objects/items/devices/transfer_valve.dm +++ b/code/game/objects/items/devices/transfer_valve.dm @@ -16,20 +16,20 @@ /obj/item/device/transfer_valve/IsAssemblyHolder() return 1 -/obj/item/device/transfer_valve/attackby(obj/item/item, mob/user) +/obj/item/device/transfer_valve/attackby(obj/item/attacking_item, mob/user) var/turf/location = get_turf(src) // For admin logs - if(istype(item, /obj/item/tank)) + if(istype(attacking_item, /obj/item/tank)) if(tank_one && tank_two) to_chat(user, "There are already two tanks attached, remove one first.") return if(!tank_one) - tank_one = item - user.drop_from_inventory(item,src) + tank_one = attacking_item + user.drop_from_inventory(attacking_item,src) to_chat(user, "You attach the tank to the transfer valve.") else if(!tank_two) - tank_two = item - user.drop_from_inventory(item,src) + tank_two = attacking_item + user.drop_from_inventory(attacking_item,src) to_chat(user, "You attach the tank to the transfer valve.") message_admins("[key_name_admin(user)] attached both tanks to a transfer valve. (JMP)") log_game("[key_name_admin(user)] attached both tanks to a transfer valve.",ckey=key_name(user)) @@ -37,24 +37,24 @@ update_icon() update_static_data_for_all_viewers() //TODO: Have this take an assemblyholder - else if(isassembly(item)) - var/obj/item/device/assembly/A = item + else if(isassembly(attacking_item)) + var/obj/item/device/assembly/A = attacking_item if(A.secured) to_chat(user, "The device is secured.") return if(attached_device) to_chat(user, "There is already an device attached to the valve, remove it first.") return - user.remove_from_mob(item) + user.remove_from_mob(attacking_item) attached_device = A A.forceMove(src) - to_chat(user, "You attach the [item] to the valve controls and secure it.") + to_chat(user, "You attach the [attacking_item] to the valve controls and secure it.") A.holder = src A.toggle_secure() //this calls update_icon(), which calls update_icon() on the holder (i.e. the bomb). - GLOB.bombers += "[key_name(user)] attached a [item] to a transfer valve." - message_admins("[key_name_admin(user)] attached a [item] to a transfer valve. (JMP)") - log_game("[key_name_admin(user)] attached a [item] to a transfer valve.",ckey=key_name(user)) + GLOB.bombers += "[key_name(user)] attached a [attacking_item] to a transfer valve." + message_admins("[key_name_admin(user)] attached a [attacking_item] to a transfer valve. (JMP)") + log_game("[key_name_admin(user)] attached a [attacking_item] to a transfer valve.",ckey=key_name(user)) attacher = user update_static_data_for_all_viewers() return diff --git a/code/game/objects/items/devices/tvcamera.dm b/code/game/objects/items/devices/tvcamera.dm index 9146459ac83..f52ab445e50 100644 --- a/code/game/objects/items/devices/tvcamera.dm +++ b/code/game/objects/items/devices/tvcamera.dm @@ -25,10 +25,10 @@ GLOB.listening_objects += src . = ..() -/obj/item/device/tvcamera/examine(mob/user) +/obj/item/device/tvcamera/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "Video feed is currently: [camera.status ? "Online" : "Offline"]") - to_chat(user, "Audio feed is currently: [radio.get_broadcasting() ? "Online" : "Offline"]") + . += "Video feed is currently: [camera.status ? "Online" : "Offline"]" + . += "Audio feed is currently: [radio.get_broadcasting() ? "Online" : "Offline"]" /obj/item/device/tvcamera/attack_self(mob/user) add_fingerprint(user) @@ -85,7 +85,11 @@ H.update_inv_l_hand() /* Assembly by a roboticist */ -/obj/item/robot_parts/head/attackby(var/obj/item/device/assembly/S, mob/user as mob) +/obj/item/robot_parts/head/attackby(obj/item/attacking_item, mob/user) + var/obj/item/device/assembly/S = attacking_item + if(!istype(S)) + return + if(!istype(S, /obj/item/device/assembly/infra)) ..() return @@ -106,24 +110,24 @@ Using robohead because of restricting to roboticist */ var/buildstep = 0 w_class = ITEMSIZE_LARGE -/obj/item/tv_assembly/attackby(var/obj/item/W, var/mob/user) +/obj/item/tv_assembly/attackby(obj/item/attacking_item, mob/user) switch(buildstep) if(0) - if(istype(W, /obj/item/robot_parts/robot_component/camera)) + if(istype(attacking_item, /obj/item/robot_parts/robot_component/camera)) to_chat(user, SPAN_NOTICE("You add the camera module to [src].")) - qdel(W) + qdel(attacking_item) desc = "This TV camera assembly has a camera module." buildstep++ if(1) - if(istype(W, /obj/item/device/taperecorder)) - qdel(W) + if(istype(attacking_item, /obj/item/device/taperecorder)) + qdel(attacking_item) buildstep++ to_chat(user, SPAN_NOTICE("You add the tape recorder to [src].")) desc = "This TV camera assembly has a camera and audio module." return if(2) - if(W.iscoil()) - var/obj/item/stack/cable_coil/C = W + if(attacking_item.iscoil()) + var/obj/item/stack/cable_coil/C = attacking_item if(!C.use(3)) to_chat(user, SPAN_NOTICE("You need three cable coils to wire the devices.")) ..() @@ -133,14 +137,14 @@ Using robohead because of restricting to roboticist */ desc = "This TV camera assembly has wires sticking out." return if(3) - if(W.iswirecutter()) + if(attacking_item.iswirecutter()) to_chat(user, SPAN_NOTICE("You trim the wires.")) buildstep++ desc = "This TV camera assembly needs casing." return if(4) - if(istype(W, /obj/item/stack/material/steel)) - var/obj/item/stack/material/steel/S = W + if(istype(attacking_item, /obj/item/stack/material/steel)) + var/obj/item/stack/material/steel/S = attacking_item if(S.use(1)) buildstep++ to_chat(user, SPAN_NOTICE("You encase the assembly.")) diff --git a/code/game/objects/items/easel.dm b/code/game/objects/items/easel.dm index 84f5ef2b875..5729f6016f4 100644 --- a/code/game/objects/items/easel.dm +++ b/code/game/objects/items/easel.dm @@ -20,9 +20,9 @@ /* * Adding canvases. */ -/obj/structure/easel/attackby(obj/item/I, mob/user, params) - if(istype(I, /obj/item/canvas)) - var/obj/item/canvas/C = I +/obj/structure/easel/attackby(obj/item/attacking_item, mob/user, params) + if(istype(attacking_item, /obj/item/canvas)) + var/obj/item/canvas/C = attacking_item if(user.unEquip(C)) painting = C C.forceMove(get_turf(src)) @@ -32,7 +32,7 @@ C.pixel_z = 0 user.visible_message("[user] puts \the [C] on \the [src].", SPAN_NOTICE("You place \the [C] on \the [src].")) return TRUE - if(I.iswrench()) + if(attacking_item.iswrench()) to_chat(user, SPAN_NOTICE("You dismantle \the [src].")) dismantle() return TRUE diff --git a/code/game/objects/items/glassjar.dm b/code/game/objects/items/glassjar.dm index 814806814db..9d0736d3bf2 100644 --- a/code/game/objects/items/glassjar.dm +++ b/code/game/objects/items/glassjar.dm @@ -110,9 +110,9 @@ usr.put_in_hands(contained[1]) contained -= contained[1] -/obj/item/glass_jar/attackby(var/atom/A, var/mob/user, var/proximity) - if(istype(A, /obj/item/spacecash)) - var/obj/item/spacecash/S = A +/obj/item/glass_jar/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/spacecash)) + var/obj/item/spacecash/S = attacking_item if(contains == JAR_NOTHING) contains = JAR_MONEY if(contains != JAR_MONEY) @@ -120,8 +120,8 @@ user.visible_message(SPAN_NOTICE("[user] puts [S.worth] credit\s into \the [src].")) user.drop_from_inventory(S,src) update_icon() - if(istype(A, /obj/item/clothing/mask/chewable/candy/gum/gumball)) - var/obj/item/clothing/mask/chewable/candy/gum/gumball/G = A + if(istype(attacking_item, /obj/item/clothing/mask/chewable/candy/gum/gumball)) + var/obj/item/clothing/mask/chewable/candy/gum/gumball/G = attacking_item if(length(contained) < GUMBALL_MAX) contained += G user.drop_from_inventory(G) @@ -133,8 +133,8 @@ else to_chat(user, SPAN_WARNING("\The [name] is full!")) return TRUE - if(istype(A, /obj/item/holder)) - var/obj/item/holder/H = A + if(istype(attacking_item, /obj/item/holder)) + var/obj/item/holder/H = attacking_item if(H.w_class <= ITEMSIZE_SMALL) contains = JAR_HOLDER user.drop_from_inventory(H) diff --git a/code/game/objects/items/holomenu.dm b/code/game/objects/items/holomenu.dm index d658b552d54..4651d236317 100644 --- a/code/game/objects/items/holomenu.dm +++ b/code/game/objects/items/holomenu.dm @@ -54,8 +54,8 @@ else set_light(0) -/obj/item/holomenu/attackby(obj/item/I, mob/user) - var/obj/item/card/id/ID = I.GetID() +/obj/item/holomenu/attackby(obj/item/attacking_item, mob/user) + var/obj/item/card/id/ID = attacking_item.GetID() if(istype(ID)) if(check_access(ID)) anchored = !anchored @@ -64,9 +64,9 @@ else to_chat(user, SPAN_WARNING("Access denied.")) return TRUE - if(istype(I, /obj/item/paper) && allowed(user)) - var/obj/item/paper/P = I - to_chat(user, SPAN_NOTICE("You scan \the [I.name] into \the [name].")) + if(istype(attacking_item, /obj/item/paper) && allowed(user)) + var/obj/item/paper/P = attacking_item + to_chat(user, SPAN_NOTICE("You scan \the [attacking_item.name] into \the [name].")) menu_text = P.info menu_text = replacetext(menu_text, "color=black>", "color=white>") update_icon() @@ -141,13 +141,13 @@ menu_text = pencode2html(new_text) update_icon() -/obj/item/holomenu/holodeck/attackby(obj/item/I, mob/user) - var/obj/item/card/id/ID = I.GetID() +/obj/item/holomenu/holodeck/attackby(obj/item/attacking_item, mob/user) + var/obj/item/card/id/ID = attacking_item.GetID() if(istype(ID)) return TRUE - if(istype(I, /obj/item/paper)) - var/obj/item/paper/P = I - to_chat(user, SPAN_NOTICE("You scan \the [I.name] into \the [name].")) + if(istype(attacking_item, /obj/item/paper)) + var/obj/item/paper/P = attacking_item + to_chat(user, SPAN_NOTICE("You scan \the [attacking_item.name] into \the [name].")) menu_text = P.info menu_text = replacetext(menu_text, "color=black>", "color=white>") update_icon() diff --git a/code/game/objects/items/ipc_overloaders.dm b/code/game/objects/items/ipc_overloaders.dm index eea2fe8abc6..0a93a29697f 100644 --- a/code/game/objects/items/ipc_overloaders.dm +++ b/code/game/objects/items/ipc_overloaders.dm @@ -31,13 +31,13 @@ else icon_state = "[initial(icon_state)]-[initial(uses)-uses]" -/obj/item/ipc_overloader/examine(mob/user, distance, is_adjacent) +/obj/item/ipc_overloader/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(is_adjacent) if(uses) - to_chat(user, SPAN_NOTICE("It has [uses] uses left.")) + . += SPAN_NOTICE("It has [uses] uses left.") else - to_chat(user, SPAN_WARNING("It's totally spent.")) + . += SPAN_WARNING("It's totally spent.") /obj/item/ipc_overloader/attack_self(mob/user) if(!uses) @@ -271,11 +271,11 @@ icon_state = "box" return ..() -/obj/item/storage/overloader/examine(mob/user) +/obj/item/storage/overloader/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() var/obj/item/ipc_overloader/overloader = locate() in contents if(overloader) - to_chat(user, SPAN_NOTICE("This one has a [overloader.name] inside.")) + . += SPAN_NOTICE("This one has a [overloader.name] inside.") /obj/item/storage/overloader/open(mob/user) ..() diff --git a/code/game/objects/items/knitting.dm b/code/game/objects/items/knitting.dm index 07a4332b40e..00b64c8a6d8 100644 --- a/code/game/objects/items/knitting.dm +++ b/code/game/objects/items/knitting.dm @@ -39,11 +39,11 @@ QDEL_NULL(ball) return ..() -/obj/item/knittingneedles/examine(mob/user, distance, is_adjacent) +/obj/item/knittingneedles/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(is_adjacent) if(ball) - to_chat(user, "There is \the [ball] between the needles.") + . += "There is \the [ball] between the needles." /obj/item/knittingneedles/update_icon() if(working) @@ -64,13 +64,13 @@ cut_overlays() update_held_icon() -/obj/item/knittingneedles/attackby(obj/item/O, mob/user) - if(istype(O, /obj/item/yarn)) +/obj/item/knittingneedles/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/yarn)) if(!ball) - user.unEquip(O) - O.forceMove(src) - ball = O - to_chat(user, SPAN_NOTICE("You place \the [O] in \the [src]")) + user.unEquip(attacking_item) + attacking_item.forceMove(src) + ball = attacking_item + to_chat(user, SPAN_NOTICE("You place \the [attacking_item] in \the [src]")) update_icon() return TRUE diff --git a/code/game/objects/items/paintkit.dm b/code/game/objects/items/paintkit.dm index 9991ab5860f..ecdb9a28922 100644 --- a/code/game/objects/items/paintkit.dm +++ b/code/game/objects/items/paintkit.dm @@ -7,9 +7,9 @@ var/new_icon_file var/uses = 1 // Uses before the kit deletes itself. -/obj/item/device/kit/examine() +/obj/item/device/kit/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(usr, "It has [uses] use\s left.") + . += "It has [uses] use\s left." /obj/item/device/kit/use(var/amt, var/mob/user) uses -= amt @@ -27,9 +27,9 @@ var/new_light_overlay var/new_mob_icon_file -/obj/item/clothing/head/helmet/space/void/attackby(var/obj/item/O, var/mob/user) - if(istype(O,/obj/item/device/kit/suit)) - var/obj/item/device/kit/suit/kit = O +/obj/item/clothing/head/helmet/space/void/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item,/obj/item/device/kit/suit)) + var/obj/item/device/kit/suit/kit = attacking_item name = "[kit.new_name] suit helmet" desc = kit.new_desc icon_state = "[kit.new_icon]_helmet" @@ -48,9 +48,9 @@ return TRUE return ..() -/obj/item/clothing/suit/space/void/attackby(var/obj/item/O, var/mob/user) - if(istype(O,/obj/item/device/kit/suit)) - var/obj/item/device/kit/suit/kit = O +/obj/item/clothing/suit/space/void/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/device/kit/suit)) + var/obj/item/device/kit/suit/kit = attacking_item name = "[kit.new_name] voidsuit" desc = kit.new_desc icon_state = "[kit.new_icon]_suit" diff --git a/code/game/objects/items/recharger_backpack.dm b/code/game/objects/items/recharger_backpack.dm index c1200f4da3a..fcc66fd606c 100644 --- a/code/game/objects/items/recharger_backpack.dm +++ b/code/game/objects/items/recharger_backpack.dm @@ -17,28 +17,28 @@ //To update the icon based on the power cell charge we spawn with update_icon() -/obj/item/recharger_backpack/examine(mob/user) +/obj/item/recharger_backpack/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(powersupply) - to_chat(user, SPAN_NOTICE("The backpack display shows that the installed power cell is at [round(powersupply.percent())]%.")) + . += SPAN_NOTICE("The backpack display shows that the installed power cell is at [round(powersupply.percent())]%.") -/obj/item/recharger_backpack/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/cell) && !powersupply) - to_chat(usr, SPAN_NOTICE("You slot \the [I] into \the [src]'s power socket.")) +/obj/item/recharger_backpack/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/cell) && !powersupply) + to_chat(usr, SPAN_NOTICE("You slot \the [attacking_item] into \the [src]'s power socket.")) playsound(get_turf(src), 'sound/machines/click.ogg', 30, 0) - user.drop_from_inventory(I, src) - powersupply = I + user.drop_from_inventory(attacking_item, src) + powersupply = attacking_item update_icon() - else if(istype(I, /obj/item/screwdriver) && powersupply) + else if(istype(attacking_item, /obj/item/screwdriver) && powersupply) to_chat(user, SPAN_NOTICE("You remove \the [powersupply] from \the [src]'s power socket")) powersupply.forceMove(get_turf(src)) user.put_in_hands(powersupply) powersupply = null update_icon() - else if(istype(I, /obj/item/gun/energy)) - connect(I) + else if(istype(attacking_item, /obj/item/gun/energy)) + connect(attacking_item) else . = ..() diff --git a/code/game/objects/items/shooting_range.dm b/code/game/objects/items/shooting_range.dm index cfc0f3f8826..11f0b906c9c 100644 --- a/code/game/objects/items/shooting_range.dm +++ b/code/game/objects/items/shooting_range.dm @@ -17,12 +17,12 @@ stake.set_target(null) return ..() -/obj/item/target/attackby(var/obj/item/W, var/mob/user) - if(W.iswelder()) +/obj/item/target/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswelder()) if(hp == initial(hp)) to_chat(user, SPAN_NOTICE("\The [src] is fully repaired.")) return TRUE - var/obj/item/weldingtool/WT = W + var/obj/item/weldingtool/WT = attacking_item if(WT.use(0, user)) cut_overlays() LAZYCLEARLIST(bullet_holes) diff --git a/code/game/objects/items/skrell.dm b/code/game/objects/items/skrell.dm index dc1d53fb469..24a2160039e 100644 --- a/code/game/objects/items/skrell.dm +++ b/code/game/objects/items/skrell.dm @@ -15,9 +15,9 @@ . = ..() pick_constellation() -/obj/item/stellascope/examine(mob/user) +/obj/item/stellascope/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "\The [src] displays the \"[selected_constellation]\".") + . += "\The [src] displays the \"[selected_constellation]\"." /obj/item/stellascope/throw_impact(atom/hit_atom) ..() @@ -62,7 +62,7 @@ glow_state = make_screen_overlay(icon, icon_state) add_overlay(glow_state) -/obj/effect/temp_visual/constellation/attackby(obj/item/W as obj, mob/user as mob) +/obj/effect/temp_visual/constellation/attackby(obj/item/attacking_item, mob/user) visible_message("\The [src] vanishes!") qdel(src) return TRUE @@ -92,10 +92,10 @@ STOP_PROCESSING(SSprocessing, src) return ..() -/obj/item/skrell_projector/examine(mob/user) +/obj/item/skrell_projector/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(selected_world && working) - to_chat(user, "\The [src] displays a hologram of [selected_world].") + . += "\The [src] displays a hologram of [selected_world]." /obj/item/skrell_projector/attack_self(mob/user as mob) working = !working diff --git a/code/game/objects/items/spirit_board.dm b/code/game/objects/items/spirit_board.dm index ea0b255d1dd..f7b0ce575d3 100644 --- a/code/game/objects/items/spirit_board.dm +++ b/code/game/objects/items/spirit_board.dm @@ -7,9 +7,9 @@ var/planchette = "A" var/lastuser = null -/obj/item/spirit_board/examine(mob/user) +/obj/item/spirit_board/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "The planchette is sitting at \"[planchette]\".") + . += "The planchette is sitting at \"[planchette]\"." /obj/item/spirit_board/attack_hand(mob/user) if(!isturf(loc)) //so if you want to play the use the board, you need to put it down somewhere diff --git a/code/game/objects/items/stacks/rods.dm b/code/game/objects/items/stacks/rods.dm index 1ca139b4c46..81e71c06ac7 100644 --- a/code/game/objects/items/stacks/rods.dm +++ b/code/game/objects/items/stacks/rods.dm @@ -60,10 +60,10 @@ var/global/list/datum/stack_recipe/rod_recipes = list( ..() recipes = rod_recipes -/obj/item/stack/rods/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/stack/rods/attackby(obj/item/attacking_item, mob/user) ..() - if (W.iswelder()) - var/obj/item/weldingtool/WT = W + if (attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(get_amount() < 2) to_chat(user, "You need at least two rods to do this.") @@ -82,7 +82,7 @@ var/global/list/datum/stack_recipe/rod_recipes = list( user.put_in_hands(new_item) return - if (istype(W, /obj/item/tape_roll)) + if (istype(attacking_item, /obj/item/tape_roll)) var/obj/item/stack/medical/splint/makeshift/new_splint = new(user.loc) new_splint.add_fingerprint(user) diff --git a/code/game/objects/items/stacks/sheets/glass.dm b/code/game/objects/items/stacks/sheets/glass.dm index 8e9001bcc03..d585a38a601 100644 --- a/code/game/objects/items/stacks/sheets/glass.dm +++ b/code/game/objects/items/stacks/sheets/glass.dm @@ -124,19 +124,19 @@ default_type = "wired glass" construction_options = list() -/obj/item/stack/material/glass/wired/attackby(var/obj/O, mob/user as mob) - if(istype(O, /obj/item/stack/material/steel)) - var/obj/item/stack/material/steel/M = O +/obj/item/stack/material/glass/wired/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stack/material/steel)) + var/obj/item/stack/material/steel/M = attacking_item if (M.use(1)) var/obj/item/L = new /obj/item/stack/tile/light - user.drop_from_inventory(L,get_turf(src)) + user.drop_from_inventory(L, get_turf(src)) to_chat(user, "You make a light tile.") use(1) else to_chat(user, "You need one metal sheet to finish the light tile!") - else if(O.iswirecutter()) - user.drop_from_inventory(O,get_turf(src)) + else if(attacking_item.iswirecutter()) + user.drop_from_inventory(attacking_item, get_turf(src)) to_chat(user, "You detach the wire from the [name].") playsound(src.loc, 'sound/items/Wirecutter.ogg', 100, 1) new /obj/item/stack/cable_coil(user.loc, 5) diff --git a/code/game/objects/items/stacks/sheets/leather.dm b/code/game/objects/items/stacks/sheets/leather.dm index 82864c23610..7ab85b2850d 100644 --- a/code/game/objects/items/stacks/sheets/leather.dm +++ b/code/game/objects/items/stacks/sheets/leather.dm @@ -80,8 +80,8 @@ //Animal Hide to leather steps //Step one - dehairing. -/obj/item/stack/material/animalhide/attackby(obj/item/W, mob/user) - if(is_sharp(W) && !W.noslice && !W.iswirecutter()) //Can we cut and slice with the item? And does the hide still have something to remove? Say no to wirecutters since it's more about bladed items. +/obj/item/stack/material/animalhide/attackby(obj/item/attacking_item, mob/user) + if(is_sharp(attacking_item) && !attacking_item.noslice && !attacking_item.iswirecutter()) //Can we cut and slice with the item? And does the hide still have something to remove? Say no to wirecutters since it's more about bladed items. if(bare) to_chat(user, SPAN_WARNING("There's nothing left to remove from \the [src]!")) return @@ -121,9 +121,9 @@ if(wetness <= 0) make_leather() -/obj/item/stack/material/animalhide/wetleather/attackby(obj/item/I, mob/user) - if(I.iswelder()) - var/obj/item/weldingtool/WT = I +/obj/item/stack/material/animalhide/wetleather/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(WT.isOn()) if(being_dried) to_chat(user, SPAN_WARNING("\The [src] are already being dried")) diff --git a/code/game/objects/items/stacks/stack.dm b/code/game/objects/items/stacks/stack.dm index 0e28c7c7526..44d6e81a8ca 100644 --- a/code/game/objects/items/stacks/stack.dm +++ b/code/game/objects/items/stacks/stack.dm @@ -70,14 +70,14 @@ else icon_state = "[initial(icon_state)]_3" -/obj/item/stack/examine(mob/user, distance, is_adjacent) +/obj/item/stack/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(is_adjacent) if(!iscoil()) if(!uses_charge) - to_chat(user, "There [src.amount == 1 ? "is" : "are"] [src.amount] [src.singular_name]\s in the stack.") + . += "There [src.amount == 1 ? "is" : "are"] [src.amount] [src.singular_name]\s in the stack." else - to_chat(user, "You have enough charge to produce [get_amount()].") + . += "You have enough charge to produce [get_amount()]." /obj/item/stack/attack_self(mob/user) list_recipes(user, recipes) @@ -338,9 +338,9 @@ ..() return -/obj/item/stack/attackby(obj/item/W as obj, mob/user as mob) - if (istype(W, /obj/item/stack)) - var/obj/item/stack/S = W +/obj/item/stack/attackby(obj/item/attacking_item, mob/user) + if (istype(attacking_item, /obj/item/stack)) + var/obj/item/stack/S = attacking_item if (user.get_inactive_hand()==src) src.transfer_to(S, 1) else diff --git a/code/game/objects/items/stacks/tiles/light.dm b/code/game/objects/items/stacks/tiles/light.dm index 05e0797e85a..34df47a430b 100644 --- a/code/game/objects/items/stacks/tiles/light.dm +++ b/code/game/objects/items/stacks/tiles/light.dm @@ -17,11 +17,11 @@ else state = 0 //fine -/obj/item/stack/tile/light/attackby(var/obj/item/O, var/mob/user) - if(O.iscrowbar()) +/obj/item/stack/tile/light/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iscrowbar()) amount-- to_chat(user, "You pry off the steel sheet from the [name].") - playsound(src.loc, O.usesound, 100, 1) + playsound(src.loc, attacking_item.usesound, 100, 1) new /obj/item/stack/material/glass/wired(user.loc) new /obj/item/stack/material/steel(user.loc) if(amount <= 0) diff --git a/code/game/objects/items/stacks/wrap.dm b/code/game/objects/items/stacks/wrap.dm index df7f5f46575..b710851074d 100644 --- a/code/game/objects/items/stacks/wrap.dm +++ b/code/game/objects/items/stacks/wrap.dm @@ -13,15 +13,15 @@ drop_sound = 'sound/items/drop/wrapper.ogg' pickup_sound = 'sound/items/pickup/wrapper.ogg' -/obj/item/stack/wrapping_paper/attackby(obj/item/W, mob/user) +/obj/item/stack/wrapping_paper/attackby(obj/item/attacking_item, mob/user) ..() if (isrobot(user)) - if(istype(W.loc, /obj/item/gripper)) - var/obj/item/gripper/G = W.loc + if(istype(attacking_item.loc, /obj/item/gripper)) + var/obj/item/gripper/G = attacking_item.loc if(!is_type_in_list(G, list(/obj/item/gripper/service, /obj/item/gripper/paperwork))) to_chat(user, SPAN_WARNING("\The [G] isn't deft enough to wrap up \the [G.wrapped].")) return - else if(istype(W, /obj/item/gripper)) + else if(istype(attacking_item, /obj/item/gripper)) return else to_chat(user, SPAN_WARNING("You can't wrap up a cyborg module!")) @@ -30,27 +30,27 @@ if (!isturf(loc)) to_chat(user, SPAN_WARNING("The paper must be set down for you to wrap a gift!")) return - if (W.w_class < ITEMSIZE_LARGE) + if (attacking_item.w_class < ITEMSIZE_LARGE) var/a_used = 2 * (src.w_class - 1) if(src.amount < a_used) to_chat(user, SPAN_WARNING("You need more paper!")) return else - if(istype(W, /obj/item/smallDelivery) || istype(W, /obj/item/gift)) //No gift wrapping gifts! + if(istype(attacking_item, /obj/item/smallDelivery) || istype(attacking_item, /obj/item/gift)) //No gift wrapping gifts! return src.amount -= a_used user.drop_item() var/obj/item/gift/G = new /obj/item/gift(src.loc) - G.size = W.w_class + G.size = attacking_item.w_class G.w_class = G.size + 1 G.icon_state = text("gift[]", G.size) - G.gift = W - W.forceMove(G) + G.gift = attacking_item + attacking_item.forceMove(G) G.add_fingerprint(user) - W.add_fingerprint(user) + attacking_item.add_fingerprint(user) src.add_fingerprint(user) - user.visible_message("\The [user] wraps \the [W] into \a [G].", SPAN_NOTICE("You wrap \the [W] into \a [G], leaving [amount] of \the [src] remaining.")) + user.visible_message("\The [user] wraps \the [attacking_item] into \a [G].", SPAN_NOTICE("You wrap \the [attacking_item] into \a [G], leaving [amount] of \the [src] remaining.")) update_icon() if(src.amount <= 0) new /obj/item/c_tube(src.loc) @@ -61,10 +61,10 @@ to_chat(user, SPAN_WARNING("This object is far too large to wrap!")) return -/obj/item/stack/wrapping_paper/examine(mob/user, distance, is_adjacent) +/obj/item/stack/wrapping_paper/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1) - to_chat(user, "There [amount == 1 ? "is" : "are"] about [amount] [singular_name]\s of paper left!") + . += "There [amount == 1 ? "is" : "are"] about [amount] [singular_name]\s of paper left!" /obj/item/stack/wrapping_paper/attack(mob/target, mob/user) if(!ishuman(target)) diff --git a/code/game/objects/items/sticker.dm b/code/game/objects/items/sticker.dm index 312b4ab19f5..650e81ae978 100644 --- a/code/game/objects/items/sticker.dm +++ b/code/game/objects/items/sticker.dm @@ -35,13 +35,13 @@ if(attached_atom && user.Adjacent(attached_atom)) attack_hand(user) -/obj/item/sticker/attackby(obj/item/I, mob/user) +/obj/item/sticker/attackby(obj/item/attacking_item, mob/user) if(!attached) return ..() var/atom/movable/attached_atom = attached.resolve() if(attached_atom) - attached_atom.attackby(I, user) // don't allow people to make sticker armor + attached_atom.attackby(attacking_item, user) // don't allow people to make sticker armor return TRUE /obj/item/sticker/afterattack(atom/movable/target, mob/user, proximity_flag, click_parameters) diff --git a/code/game/objects/items/toys.dm b/code/game/objects/items/toys.dm index 701422fccb4..6d8f6fd2c44 100644 --- a/code/game/objects/items/toys.dm +++ b/code/game/objects/items/toys.dm @@ -62,20 +62,20 @@ src.update_icon() return -/obj/item/toy/waterballoon/attackby(obj/O as obj, mob/user as mob) - if(istype(O, /obj/item/reagent_containers/glass)) - if(O.reagents) - if(O.reagents.total_volume < 1) - to_chat(user, "The [O] is empty.") - else if(O.reagents.total_volume >= 1) - if(O.reagents.has_reagent(/singleton/reagent/acid/polyacid, 1)) +/obj/item/toy/waterballoon/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/reagent_containers/glass)) + if(attacking_item.reagents) + if(attacking_item.reagents.total_volume < 1) + to_chat(user, "The [attacking_item] is empty.") + else if(attacking_item.reagents.total_volume >= 1) + if(attacking_item.reagents.has_reagent(/singleton/reagent/acid/polyacid, 1)) to_chat(user, "The acid chews through the balloon!") - O.reagents.splash(user, reagents.total_volume) + attacking_item.reagents.splash(user, reagents.total_volume) qdel(src) else src.desc = "A translucent balloon with some form of liquid sloshing around in it." - to_chat(user, "You fill the balloon with the contents of [O].") - O.reagents.trans_to_obj(src, 10) + to_chat(user, "You fill the balloon with the contents of [attacking_item].") + attacking_item.reagents.trans_to_obj(src, 10) src.update_icon() return TRUE @@ -174,8 +174,8 @@ burst() return -/obj/item/toy/balloon/attackby(obj/item/W as obj, mob/user as mob) - if(W.can_puncture()) +/obj/item/toy/balloon/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.can_puncture()) burst() return TRUE @@ -409,16 +409,16 @@ attack_verb = list("attacked", "struck", "hit") var/dart_count = 5 -/obj/item/toy/crossbow/examine(mob/user, distance, is_adjacent) +/obj/item/toy/crossbow/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 2 && dart_count) - to_chat(user, "\The [src] is loaded with [dart_count] foam dart\s.") + . += "\The [src] is loaded with [dart_count] foam dart\s." -/obj/item/toy/crossbow/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/toy/ammo/crossbow)) +/obj/item/toy/crossbow/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/toy/ammo/crossbow)) if(dart_count <= 4) - user.drop_from_inventory(I, src) - qdel(I) + user.drop_from_inventory(attacking_item, src) + qdel(attacking_item) dart_count++ to_chat(user, "You load the foam dart into \the [src].") else diff --git a/code/game/objects/items/trash.dm b/code/game/objects/items/trash.dm index ce4f94b9d19..b3ad683f1b7 100644 --- a/code/game/objects/items/trash.dm +++ b/code/game/objects/items/trash.dm @@ -226,10 +226,10 @@ icon_state = "ricetub" var/has_chopsticks = FALSE -/obj/item/trash/ricetub/attackby(obj/item/W, mob/living/user) - if(istype(W, /obj/item/material/kitchen/utensil/fork/chopsticks)) - to_chat(user, SPAN_NOTICE("You reattach the [W] to \the [src]")) - qdel(W) +/obj/item/trash/ricetub/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/material/kitchen/utensil/fork/chopsticks)) + to_chat(user, SPAN_NOTICE("You reattach the [attacking_item] to \the [src]")) + qdel(attacking_item) has_chopsticks = TRUE update_icon() return TRUE diff --git a/code/game/objects/items/weapons/RFD.dm b/code/game/objects/items/weapons/RFD.dm index e46954a868c..c4b58b67dd1 100644 --- a/code/game/objects/items/weapons/RFD.dm +++ b/code/game/objects/items/weapons/RFD.dm @@ -61,10 +61,10 @@ /obj/item/rfd/proc/can_use(var/mob/user,var/turf/T) return (user.Adjacent(T) && user.get_active_hand() == src && !user.stat && !user.restrained()) -/obj/item/rfd/examine(var/mob/user) +/obj/item/rfd/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(loc == user) - to_chat(user, "It currently holds [stored_matter]/30 matter units.") + . += "It currently holds [stored_matter]/30 matter units." /obj/item/rfd/attack_self(mob/user) //Change the mode @@ -73,20 +73,20 @@ to_chat(user, SPAN_NOTICE("The mode selection dial is now at [modes[mode]].")) playsound(get_turf(src), 'sound/weapons/laser_safetyon.ogg', 50, FALSE) -/obj/item/rfd/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/rfd_ammo)) +/obj/item/rfd/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/rfd_ammo)) if((stored_matter + 10) > 30) to_chat(user, SPAN_NOTICE("The RFD can't hold any more matter units.")) return - user.drop_from_inventory(W,src) - qdel(W) + user.drop_from_inventory(attacking_item, src) + qdel(attacking_item) stored_matter += 10 playsound(src.loc, 'sound/weapons/laser_reload1.ogg', 50, FALSE) to_chat(user, SPAN_NOTICE("The RFD now holds [stored_matter]/30 matter units.")) update_icon() return TRUE - if(W.isscrewdriver()) // Turning it into a crossbow + if(attacking_item.isscrewdriver()) // Turning it into a crossbow crafting = !crafting if(!crafting) to_chat(user, SPAN_NOTICE("You reassemble the RFD.")) @@ -97,14 +97,14 @@ if(crafting) var/obj/item/crossbow // the thing we're gonna add, check what it is below - if(istype(W, /obj/item/crossbowframe)) - var/obj/item/crossbowframe/F = W + if(istype(attacking_item, /obj/item/crossbowframe)) + var/obj/item/crossbowframe/F = attacking_item if(F.buildstate != 5) to_chat(user, SPAN_WARNING("You need to fully assemble the crossbow frame first!")) return TRUE crossbow = F - else if(istype(W, /obj/item/gun/launcher/crossbow) && !istype(W, /obj/item/gun/launcher/crossbow/RFD)) - var/obj/item/gun/launcher/crossbow/C = W + else if(istype(attacking_item, /obj/item/gun/launcher/crossbow) && !istype(attacking_item, /obj/item/gun/launcher/crossbow/RFD)) + var/obj/item/gun/launcher/crossbow/C = attacking_item if(C.bolt) to_chat(user, SPAN_WARNING("You need to remove \the [C.bolt] from \the [C] before you can attach it to \the [src].")) return TRUE @@ -538,13 +538,13 @@ /obj/item/rfd/transformer/attack_self(mob/user) return -/obj/item/rfd/transformer/examine(var/mob/user) +/obj/item/rfd/transformer/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(loc == user) if(malftransformermade) - to_chat(user, "There is already a transformer machine made!") + . += "There is already a transformer machine made!" else - to_chat(user, "It is ready to deploy a transformer machine.") + . += "It is ready to deploy a transformer machine." /obj/item/rfd/transformer/afterattack(atom/A, mob/user as mob, proximity) @@ -671,11 +671,11 @@ "Omni Gas Filter" = PIPE_OMNI_FILTER ) -/obj/item/rfd/piping/examine(mob/user) +/obj/item/rfd/piping/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, FONT_SMALL(SPAN_NOTICE("Change pipe category by ALT-clicking, change pipe selection by using in-hand."))) - to_chat(user, SPAN_NOTICE("Selected pipe category: [selected_mode]")) - to_chat(user, SPAN_NOTICE("Selected pipe: [pipe_examine]")) + . += FONT_SMALL(SPAN_NOTICE("Change pipe category by ALT-clicking, change pipe selection by using in-hand.")) + . += SPAN_NOTICE("Selected pipe category: [selected_mode].") + . += SPAN_NOTICE("Selected pipe: [pipe_examine].") /obj/item/rfd/piping/afterattack(atom/A, mob/user, proximity) if(!proximity || !isturf(A)) diff --git a/code/game/objects/items/weapons/candle.dm b/code/game/objects/items/weapons/candle.dm index e674f568abb..2cb69e17e81 100644 --- a/code/game/objects/items/weapons/candle.dm +++ b/code/game/objects/items/weapons/candle.dm @@ -27,18 +27,18 @@ icon_state = "candle[i][lit ? "_lit" : ""]" -/obj/item/flame/candle/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/flame/candle/attackby(obj/item/attacking_item, mob/user) ..() - if(W.iswelder()) - var/obj/item/weldingtool/WT = W + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(WT.isOn()) //Badasses dont get blinded by lighting their candle with a welding tool light() - to_chat(user, SPAN_NOTICE("\The [user] casually lights \the [name] with [W].")) - else if(W.isFlameSource()) + to_chat(user, SPAN_NOTICE("\The [user] casually lights \the [name] with [attacking_item].")) + else if(attacking_item.isFlameSource()) light() to_chat(user, SPAN_NOTICE("\The [user] lights \the [name].")) - else if(istype(W, /obj/item/flame/candle)) - var/obj/item/flame/candle/C = W + else if(istype(attacking_item, /obj/item/flame/candle)) + var/obj/item/flame/candle/C = attacking_item if(C.lit) light() to_chat(user, SPAN_NOTICE("\The [user] lights \the [name].")) diff --git a/code/game/objects/items/weapons/cards_ids.dm b/code/game/objects/items/weapons/cards_ids.dm index 646f3854cb6..62d948af694 100644 --- a/code/game/objects/items/weapons/cards_ids.dm +++ b/code/game/objects/items/weapons/cards_ids.dm @@ -282,9 +282,9 @@ var/const/NO_EMAG_ACT = -50 return 1 return ..() -/obj/item/card/id/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/card/id)) - var/obj/item/card/id/ID = W +/obj/item/card/id/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/card/id)) + var/obj/item/card/id/ID = attacking_item if(ID.can_copy_access) ID.access |= src.access user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) diff --git a/code/game/objects/items/weapons/cards_ids_syndicate.dm b/code/game/objects/items/weapons/cards_ids_syndicate.dm index d1155455c2e..b0565190d2c 100644 --- a/code/game/objects/items/weapons/cards_ids_syndicate.dm +++ b/code/game/objects/items/weapons/cards_ids_syndicate.dm @@ -20,11 +20,11 @@ unset_registered_user(registered_user) return ..() -/obj/item/card/id/syndicate/examine(mob/user, distance, is_adjacent) +/obj/item/card/id/syndicate/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(is_adjacent) if(user == registered_user) - to_chat(user, FONT_SMALL(SPAN_NOTICE("It is at [charge]/[initial(charge)] charge."))) + . += FONT_SMALL(SPAN_NOTICE("It is at [charge]/[initial(charge)] charge.")) /obj/item/card/id/syndicate/process() if(electronic_warfare) diff --git a/code/game/objects/items/weapons/chaplain_items.dm b/code/game/objects/items/weapons/chaplain_items.dm index 37d8786ec29..fafb7139d28 100644 --- a/code/game/objects/items/weapons/chaplain_items.dm +++ b/code/game/objects/items/weapons/chaplain_items.dm @@ -257,6 +257,7 @@ /obj/item/material/urn name = "urn" desc = "A vase used to store the ashes of the deceased." + desc_extended = "To store ashes in an urn, click on the ash pile with the urn in your active hand. To empty an urn, use the urn in your active hand. Make sure you've labeled the urn so you know who's ashes are inside!" icon = 'icons/obj/urn.dmi' icon_state = "urn" applies_material_colour = TRUE @@ -272,6 +273,7 @@ return user.visible_message("[user] scoops \the [A] into \the [src], securing the lid.", "You scoop \the [A] into \the [src], securing the lid.") desc = "A vase used to store the ashes of the deceased. It contains some ashes." + desc_extended = "To store ashes in an urn, click on the ash pile with the urn in your active hand. To empty an urn, use the urn in your active hand. Make sure you've labeled the urn so you know who's ashes are inside!" A.forceMove(src) /obj/item/material/urn/attack_self(mob/user) @@ -283,6 +285,7 @@ A.dropInto(loc) user.visible_message("[user] pours \the [A] out from \the [src].", "You pour \the [A] out from \the [src].") desc = "A vase used to store the ashes of the deceased." + desc_extended = "To store ashes in an urn, click on the ash pile with the urn in your active hand. To empty an urn, use the urn in your active hand. Make sure you've labeled the urn so you know who's ashes are inside!" /obj/item/assunzioneorb name = "warding sphere" diff --git a/code/game/objects/items/weapons/cigs_lighters.dm b/code/game/objects/items/weapons/cigs_lighters.dm index 46c51a68980..1090e590e7d 100644 --- a/code/game/objects/items/weapons/cigs_lighters.dm +++ b/code/game/objects/items/weapons/cigs_lighters.dm @@ -87,11 +87,11 @@ CIGARETTE PACKETS ARE IN FANCY.DM die(TRUE) return ..() -/obj/item/flame/match/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/flame/match/attackby(obj/item/attacking_item, mob/user) ..() - if(W.isFlameSource() && !src.lit) + if(attacking_item.isFlameSource() && !src.lit) playsound(src, 'sound/items/cigs_lighters/cig_light.ogg', 75, 1, -1) - user.visible_message("In a feat of redundancy, [user] lights \the [src] using \the [W].", range = 3) + user.visible_message("In a feat of redundancy, [user] lights \the [src] using \the [attacking_item].", range = 3) light() /obj/item/flame/match/dropped(mob/user as mob) @@ -243,7 +243,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM else if(M.wear_mask == src) M.remove_from_mob(src) //un-equip it so the overlays can update M.update_inv_wear_mask(0) - if(!(M.equip_to_slot_if_possible(butt, slot_wear_mask, ignore_blocked = TRUE))) + if(!(M.equip_to_slot_if_possible(butt, slot_wear_mask, bypass_blocked_check = TRUE))) M.put_in_hands(butt) // In case the above somehow fails, ensure it is placed somewhere else M.remove_from_mob(src) // if it dies in your hand. @@ -268,25 +268,25 @@ CIGARETTE PACKETS ARE IN FANCY.DM item_state = icon_off STOP_PROCESSING(SSprocessing, src) -/obj/item/clothing/mask/smokable/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/clothing/mask/smokable/attackby(obj/item/attacking_item, mob/user) ..() - if(W.isFlameSource()) + if(attacking_item.isFlameSource()) var/text = matchmes - if(istype(W, /obj/item/flame/match)) + if(istype(attacking_item, /obj/item/flame/match)) text = matchmes - else if(istype(W, /obj/item/flame/lighter/zippo)) + else if(istype(attacking_item, /obj/item/flame/lighter/zippo)) text = zippomes - else if(istype(W, /obj/item/flame/lighter)) + else if(istype(attacking_item, /obj/item/flame/lighter)) text = lightermes - else if(W.iswelder()) + else if(attacking_item.iswelder()) text = weldermes - else if(istype(W, /obj/item/device/assembly/igniter)) + else if(istype(attacking_item, /obj/item/device/assembly/igniter)) text = ignitermes else text = genericmes text = replacetext(text, "USER", "\the [user]") text = replacetext(text, "NAME", "\the [name]") - text = replacetext(text, "FLAME", "\the [W.name]") + text = replacetext(text, "FLAME", "\the [attacking_item.name]") light(text) /obj/item/clothing/mask/smokable/isFlameSource() @@ -318,12 +318,12 @@ CIGARETTE PACKETS ARE IN FANCY.DM /singleton/reagent/mental/nicotine = 5 ) -/obj/item/clothing/mask/smokable/cigarette/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/clothing/mask/smokable/cigarette/attackby(obj/item/attacking_item, mob/user) ..() - if(istype(W, /obj/item/melee/energy/sword)) - var/obj/item/melee/energy/sword/S = W + if(istype(attacking_item, /obj/item/melee/energy/sword)) + var/obj/item/melee/energy/sword/S = attacking_item if(S.active) - light(SPAN_WARNING("[user] swings their [W], barely missing themselves. They light their [name] in the process.")) + light(SPAN_WARNING("[user] swings their [attacking_item], barely missing themselves. They light their [name] in the process.")) return TRUE /obj/item/clothing/mask/smokable/cigarette/catch_fire() @@ -554,7 +554,7 @@ CIGARETTE PACKETS ARE IN FANCY.DM /obj/item/trash/cigbutt/cigarbutt/alt icon_state = "cigar2butt" -/obj/item/clothing/mask/smokable/cigarette/cigar/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/clothing/mask/smokable/cigarette/cigar/attackby(obj/item/attacking_item, mob/user) ..() user.update_inv_wear_mask(0) user.update_inv_l_hand(0) @@ -633,14 +633,14 @@ CIGARETTE PACKETS ARE IN FANCY.DM reagents.clear_reagents() name = "empty [initial(name)]" -/obj/item/clothing/mask/smokable/pipe/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W, /obj/item/melee/energy/sword)) +/obj/item/clothing/mask/smokable/pipe/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/melee/energy/sword)) return ..() - if (istype(W, /obj/item/reagent_containers/food/snacks)) - var/obj/item/reagent_containers/food/snacks/grown/G = W + if (istype(attacking_item, /obj/item/reagent_containers/food/snacks)) + var/obj/item/reagent_containers/food/snacks/grown/G = attacking_item if (!G.dry) to_chat(user, SPAN_NOTICE("[G] must be dried before you stuff it into [src].")) return @@ -654,18 +654,18 @@ CIGARETTE PACKETS ARE IN FANCY.DM burn_rate = initial(burn_rate) qdel(G) - else if(istype(W, /obj/item/flame/lighter)) - var/obj/item/flame/lighter/L = W + else if(istype(attacking_item, /obj/item/flame/lighter)) + var/obj/item/flame/lighter/L = attacking_item if(L.lit) - light(SPAN_NOTICE("[user] manages to light their [name] with [W].")) + light(SPAN_NOTICE("[user] manages to light their [name] with [attacking_item].")) - else if(istype(W, /obj/item/flame/match)) - var/obj/item/flame/match/M = W + else if(istype(attacking_item, /obj/item/flame/match)) + var/obj/item/flame/match/M = attacking_item if(M.lit) - light(SPAN_NOTICE("[user] lights their [name] with their [W].")) + light(SPAN_NOTICE("[user] lights their [name] with their [attacking_item].")) - else if(istype(W, /obj/item/device/assembly/igniter)) - light(SPAN_NOTICE("[user] fiddles with [W], and manages to light their [name] with the power of science.")) + else if(istype(attacking_item, /obj/item/device/assembly/igniter)) + light(SPAN_NOTICE("[user] fiddles with [attacking_item], and manages to light their [name] with the power of science.")) user.update_inv_wear_mask(0) user.update_inv_l_hand(0) @@ -1024,10 +1024,10 @@ CIGARETTE PACKETS ARE IN FANCY.DM /obj/item/trash/cigbutt/roll icon_state = "rollbutt" -/obj/item/clothing/mask/smokable/cigarette/rolled/examine(mob/user) +/obj/item/clothing/mask/smokable/cigarette/rolled/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(filter) - to_chat(user, "Capped off one end with a filter.") + . += "It's capped off one end with a filter." /obj/item/clothing/mask/smokable/cigarette/rolled/update_icon() . = ..() @@ -1047,10 +1047,10 @@ CIGARETTE PACKETS ARE IN FANCY.DM w_class = ITEMSIZE_TINY can_fold = FALSE -/obj/item/paper/cig/attackby(obj/item/P as obj, mob/user as mob) - if(istype(P, /obj/item/flame) || P.iswelder()) +/obj/item/paper/cig/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/flame) || attacking_item.iswelder()) ..() - if(P.ispen()) + if(attacking_item.ispen()) ..() else return @@ -1067,9 +1067,9 @@ CIGARETTE PACKETS ARE IN FANCY.DM icon_state = "cigfilter" w_class = ITEMSIZE_TINY -/obj/item/cigarette_filter/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/clothing/mask/smokable/cigarette/rolled)) - var/obj/item/clothing/mask/smokable/cigarette/rolled/CR = I +/obj/item/cigarette_filter/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/clothing/mask/smokable/cigarette/rolled)) + var/obj/item/clothing/mask/smokable/cigarette/rolled/CR = attacking_item return CR.attackby(src, user) . = ..() @@ -1108,37 +1108,38 @@ CIGARETTE PACKETS ARE IN FANCY.DM /obj/item/reagent_containers/food/snacks/grown/dried_oracle/fine plantname = "vedamororacle" -/obj/item/clothing/mask/smokable/cigarette/rolled/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/cigarette_filter)) +/obj/item/clothing/mask/smokable/cigarette/rolled/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/cigarette_filter)) if(filter) to_chat(user, SPAN_WARNING("\The [src] already has a filter!")) return if(lit) to_chat(user, SPAN_WARNING("\The [src] is lit already!")) return - if(user.unEquip(I)) + if(user.unEquip(attacking_item)) user.visible_message(SPAN_NOTICE("[user] sticks a cigarette filter into \the [src]."), SPAN_NOTICE("You stick a cigarette filter into \the [src].")) playsound(src, 'sound/items/drop/gloves.ogg', 25, 1) filter = TRUE name = "filtered [name]" update_icon() - qdel(I) + qdel(attacking_item) return ..() -/obj/item/reagent_containers/food/snacks/grown/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/paper)) +/obj/item/reagent_containers/food/snacks/grown/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/paper)) if(!dry) to_chat(user, SPAN_WARNING("You need to dry \the [src] first!")) return - if(user.unEquip(I)) + if(user.unEquip(attacking_item)) var/obj/item/clothing/mask/smokable/cigarette/rolled/R = new(get_turf(src)) R.chem_volume = reagents.total_volume reagents.trans_to_holder(R.reagents, R.chem_volume) - user.visible_message(SPAN_NOTICE("[user] rolls a cigarette in their hands with \the [I] and [src]."), SPAN_NOTICE("You roll a cigarette in your hands with \the [I] and [src].")) + user.visible_message(SPAN_NOTICE("[user] rolls a cigarette in their hands with \the [attacking_item] and [src]."), + SPAN_NOTICE("You roll a cigarette in your hands with \the [attacking_item] and [src].")) playsound(src, 'sound/bureaucracy/paperfold.ogg', 25, 1) user.put_in_active_hand(R) - qdel(I) + qdel(attacking_item) qdel(src) return ..() diff --git a/code/game/objects/items/weapons/circuitboards/circuitboard.dm b/code/game/objects/items/weapons/circuitboards/circuitboard.dm index f993e826728..97c574ae783 100644 --- a/code/game/objects/items/weapons/circuitboards/circuitboard.dm +++ b/code/game/objects/items/weapons/circuitboards/circuitboard.dm @@ -22,19 +22,20 @@ var/list/req_components var/contain_parts = 1 -/obj/item/circuitboard/examine(mob/user) +/obj/item/circuitboard/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() + if(build_path) var/obj/machine = new build_path // instantiate to get the name and desc - to_chat(user, FONT_SMALL(SPAN_NOTICE("This circuitboard will build a [capitalize_first_letters(machine.name)]: [machine.desc]"))) + . += FONT_SMALL(SPAN_NOTICE("This circuitboard will build a [capitalize_first_letters(machine.name)]: [machine.desc]")) if(board_type == BOARD_COMPUTER) // does not have build components, only goes into a frame - to_chat(user, SPAN_NOTICE("This board is used inside a computer frame.")) + . += SPAN_NOTICE("This board is used inside a computer frame.") else if(req_components) - to_chat(user, SPAN_NOTICE("To build this machine, you will require:")) + . += SPAN_NOTICE("To build this machine, you will require:") for(var/I in req_components) if(req_components[I] > 0) var/obj/component = new I // instantiate to get the name - to_chat(user, SPAN_NOTICE("- [num2text(req_components[I])] [capitalize_first_letters(component.name)]")) + . += SPAN_NOTICE("- [num2text(req_components[I])] [capitalize_first_letters(component.name)]") //Called when the circuitboard is used to contruct a new machine. /obj/item/circuitboard/proc/construct(var/obj/machinery/M) diff --git a/code/game/objects/items/weapons/circuitboards/computer/camera_monitor.dm b/code/game/objects/items/weapons/circuitboards/computer/camera_monitor.dm index d663a66401e..6d101ed7730 100644 --- a/code/game/objects/items/weapons/circuitboards/computer/camera_monitor.dm +++ b/code/game/objects/items/weapons/circuitboards/computer/camera_monitor.dm @@ -46,22 +46,23 @@ locked = 0 return 1 -/obj/item/circuitboard/security/attackby(obj/item/I as obj, mob/user as mob) - if(istype(I,/obj/item/card/id)) +/obj/item/circuitboard/security/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/card/id)) if(emagged) to_chat(user, "Circuit lock does not respond.") return - if(check_access(I)) + if(check_access(attacking_item)) locked = !locked to_chat(user, "You [locked ? "" : "un"]lock the circuit controls.") else to_chat(user, "Access denied.") - else if(I.ismultitool()) + else if(attacking_item.ismultitool()) if(locked) to_chat(user, "Circuit controls are locked.") return var/existing_networks = jointext(network,",") - var/input = sanitize(input(usr, "Which networks would you like to connect this camera console circuit to? Seperate networks with a comma. No Spaces!\nFor example: SS13,Security,Secret ", "Multitool-Circuitboard interface", existing_networks)) + var/input = sanitize( tgui_input_text(user, "Which networks would you like to connect this camera console circuit to? Seperate networks with a comma. No Spaces!\nFor example: SS13,Security,Secret ", + "Multitool-Circuitboard interface", existing_networks) ) if(!input) to_chat(usr, "No input found please hang up and try your call again.") return diff --git a/code/game/objects/items/weapons/circuitboards/computer/research.dm b/code/game/objects/items/weapons/circuitboards/computer/research.dm index da2993106c4..181e3b3f899 100644 --- a/code/game/objects/items/weapons/circuitboards/computer/research.dm +++ b/code/game/objects/items/weapons/circuitboards/computer/research.dm @@ -6,8 +6,8 @@ name = T_BOARD("R&D control console") build_path = /obj/machinery/computer/rdconsole/core -/obj/item/circuitboard/rdconsole/attackby(obj/item/I as obj, mob/user as mob) - if(I.isscrewdriver()) +/obj/item/circuitboard/rdconsole/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) user.visible_message("\The [user] adjusts the jumper on \the [src]'s access protocol pins.", "You adjust the jumper on the access protocol pins.") if(src.build_path == /obj/machinery/computer/rdconsole/core) src.name = T_BOARD("RD Console - Robotics") diff --git a/code/game/objects/items/weapons/circuitboards/machinery/power.dm b/code/game/objects/items/weapons/circuitboards/machinery/power.dm index 8ea6681d7c1..21a2d059871 100644 --- a/code/game/objects/items/weapons/circuitboards/machinery/power.dm +++ b/code/game/objects/items/weapons/circuitboards/machinery/power.dm @@ -23,8 +23,8 @@ board_type = "machine" req_components = list("/obj/item/cell" = 3) -/obj/item/circuitboard/ghettosmes/attackby(obj/item/W, mob/user) - if(W.ismultitool()) +/obj/item/circuitboard/ghettosmes/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ismultitool()) var/obj/item/module/power_control/new_circuit = new /obj/item/module/power_control(get_turf(src)) to_chat(user, SPAN_NOTICE("You modify \the [src] into an APC power control module.")) qdel(src) diff --git a/code/game/objects/items/weapons/circuitboards/machinery/unary_atmos.dm b/code/game/objects/items/weapons/circuitboards/machinery/unary_atmos.dm index f63fa7940c2..91409d6b2a2 100644 --- a/code/game/objects/items/weapons/circuitboards/machinery/unary_atmos.dm +++ b/code/game/objects/items/weapons/circuitboards/machinery/unary_atmos.dm @@ -7,16 +7,16 @@ var/machine_dir = SOUTH var/init_dirs = SOUTH -/obj/item/circuitboard/unary_atmos/attackby(obj/item/I as obj, mob/user as mob) - if(I.isscrewdriver()) +/obj/item/circuitboard/unary_atmos/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) machine_dir = turn(machine_dir, 90) init_dirs = machine_dir user.visible_message("\The [user] adjusts the jumper on the [src]'s port configuration pins.", "You adjust the jumper on the port configuration pins. Now set to [dir2text(machine_dir)].") return -/obj/item/circuitboard/unary_atmos/examine() +/obj/item/circuitboard/unary_atmos/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(usr, "The jumper is connecting the [dir2text(machine_dir)] pins.") + . += "The jumper is connecting the [dir2text(machine_dir)] pins." /obj/item/circuitboard/unary_atmos/construct(var/obj/machinery/atmospherics/unary/U) //TODO: Move this stuff into the relevant constructor when pipe/construction.dm is cleaned up. diff --git a/code/game/objects/items/weapons/cloaking_device.dm b/code/game/objects/items/weapons/cloaking_device.dm index e7d928b2868..880d3057eb8 100644 --- a/code/game/objects/items/weapons/cloaking_device.dm +++ b/code/game/objects/items/weapons/cloaking_device.dm @@ -118,17 +118,17 @@ modifier.stop(1) modifier = null -/obj/item/cloaking_device/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W, /obj/item/cell)) +/obj/item/cloaking_device/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/cell)) if(!cell) - user.drop_from_inventory(W,src) - cell = W + user.drop_from_inventory(attacking_item, src) + cell = attacking_item to_chat(user, "You install a cell in [src].") update_icon() else to_chat(user, "[src] already has a cell.") - else if(W.isscrewdriver()) + else if(attacking_item.isscrewdriver()) if(cell) cell.update_icon() cell.forceMove(get_turf(src.loc)) @@ -138,12 +138,12 @@ return ..() -/obj/item/cloaking_device/examine(mob/user) +/obj/item/cloaking_device/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if (!cell) - to_chat(user, "It needs a power cell to function.") + . += SPAN_WARNING("It needs a power cell to function.") else - to_chat(user, "It has [cell.percent()]% power remaining") + . += SPAN_NOTICE("It has [cell.percent()]% power remaining.") /obj/item/cloaking_device/process() if (!cell || !cell.checked_use(power_usage*CELLRATE)) diff --git a/code/game/objects/items/weapons/ecigs.dm b/code/game/objects/items/weapons/ecigs.dm index 064c8f33076..31ce277af73 100644 --- a/code/game/objects/items/weapons/ecigs.dm +++ b/code/game/objects/items/weapons/ecigs.dm @@ -42,12 +42,12 @@ icon_empty = "ccigoff" icon_on = "ccigon" -/obj/item/clothing/mask/smokable/ecig/simple/examine(mob/user) +/obj/item/clothing/mask/smokable/ecig/simple/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(ec_cartridge) - to_chat(user, SPAN_NOTICE("There are [round(ec_cartridge.reagents.total_volume, 1)] unit\s of liquid remaining.")) + . += SPAN_NOTICE("There are [round(ec_cartridge.reagents.total_volume, 1)] unit\s of liquid remaining.") else - to_chat(user, SPAN_NOTICE("There's no cartridge connected.")) + . += SPAN_NOTICE("There's no cartridge connected.") /obj/item/clothing/mask/smokable/ecig/util name = "electronic cigarette" @@ -61,20 +61,20 @@ . = ..() color = pick(ecig_colors) -/obj/item/clothing/mask/smokable/ecig/util/examine(mob/user) +/obj/item/clothing/mask/smokable/ecig/util/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(ec_cartridge) - to_chat(user, SPAN_NOTICE("There are [round(ec_cartridge.reagents.total_volume, 1)] unit\s of liquid remaining.")) + . += SPAN_NOTICE("There are [round(ec_cartridge.reagents.total_volume, 1)] unit\s of liquid remaining.") else - to_chat(user, SPAN_NOTICE("There's no cartridge connected.")) + . += SPAN_NOTICE("There's no cartridge connected.") if(cig_cell) - to_chat(user, SPAN_NOTICE("The power meter shows that there's about [round(cig_cell.percent(), 5)]% power remaining.")) + . += SPAN_NOTICE("The power meter shows that there's about [round(cig_cell.percent(), 5)]% power remaining.") else - to_chat(user, SPAN_NOTICE("There's no power cell connected.")) + . += SPAN_NOTICE("There's no power cell connected.") if(active) - to_chat(user, SPAN_NOTICE("It is currently turned on.")) + . += SPAN_NOTICE("It is currently turned on.") else - to_chat(user, SPAN_NOTICE("It is currently turned off.")) + . += SPAN_NOTICE("It is currently turned off.") /obj/item/clothing/mask/smokable/ecig/deluxe name = "deluxe electronic cigarette" @@ -85,16 +85,16 @@ icon_on = "pcigon" cell_type = /obj/item/cell/device/high -/obj/item/clothing/mask/smokable/ecig/deluxe/examine(mob/user) +/obj/item/clothing/mask/smokable/ecig/deluxe/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(ec_cartridge) - to_chat(user, SPAN_NOTICE("There are [round(ec_cartridge.reagents.total_volume, 1)] unit\s of liquid remaining.")) + . += SPAN_NOTICE("There are [round(ec_cartridge.reagents.total_volume, 1)] unit\s of liquid remaining.") else - to_chat(user, SPAN_NOTICE("There's no cartridge connected.")) + . += SPAN_NOTICE("There's no cartridge connected.") if(cig_cell) - to_chat(user, SPAN_NOTICE("The power meter shows that there's about [round(cig_cell.percent(), 1)]% power remaining.")) + . += SPAN_NOTICE("The power meter shows that there's about [round(cig_cell.percent(), 1)]% power remaining.") else - to_chat(user, SPAN_NOTICE("There's no power cell connected.")) + . += SPAN_NOTICE("There's no power cell connected.") /obj/item/clothing/mask/smokable/ecig/proc/deactivate() active = FALSE @@ -154,17 +154,17 @@ M.update_inv_l_hand(0) M.update_inv_r_hand(1) -/obj/item/clothing/mask/smokable/ecig/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/reagent_containers/ecig_cartridge)) +/obj/item/clothing/mask/smokable/ecig/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/reagent_containers/ecig_cartridge)) if (ec_cartridge)//can't add second one to_chat(user, SPAN_WARNING("A cartridge has already been installed.")) else //fits in new one - user.drop_from_inventory(I,src) - ec_cartridge = I + user.drop_from_inventory(attacking_item, src) + ec_cartridge = attacking_item update_icon() - to_chat(user, SPAN_NOTICE("You insert \the [I] into \the [src].")) + to_chat(user, SPAN_NOTICE("You insert \the [attacking_item] into \the [src].")) - if(I.isscrewdriver()) + if(attacking_item.isscrewdriver()) if(cig_cell) //if contains powercell cig_cell.update_icon() user.put_in_hands(cig_cell) @@ -173,16 +173,16 @@ else //does not contains cell to_chat(user, SPAN_WARNING("There's no battery in \the [src].")) - if (istype(I, /obj/item/cell)) + if (istype(attacking_item, /obj/item/cell)) if(cig_cell) to_chat(user, SPAN_WARNING("\The [src] already has a battery installed.")) return - if (!istype(I, /obj/item/cell/device)) - to_chat(user, SPAN_WARNING("\The [I] is too large to be inserted into \the [src].")) + if (!istype(attacking_item, /obj/item/cell/device)) + to_chat(user, SPAN_WARNING("\The [attacking_item] is too large to be inserted into \the [src].")) return - if(user.unEquip(I)) - I.forceMove(src) - cig_cell = I + if(user.unEquip(attacking_item)) + attacking_item.forceMove(src) + cig_cell = attacking_item to_chat(user, SPAN_NOTICE("You install \the [cig_cell] into \the [src].")) update_icon() @@ -248,9 +248,9 @@ volume = 20 atom_flags = ATOM_FLAG_OPEN_CONTAINER -/obj/item/reagent_containers/ecig_cartridge/examine(mob/user) +/obj/item/reagent_containers/ecig_cartridge/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "The cartridge has [reagents.total_volume] unit\s of liquid remaining.") + . += SPAN_NOTICE("The cartridge has [reagents.total_volume] unit\s of liquid remaining.") //flavours /obj/item/reagent_containers/ecig_cartridge/blank diff --git a/code/game/objects/items/weapons/explosives.dm b/code/game/objects/items/weapons/explosives.dm index 1fcd97f1995..742a19535ef 100644 --- a/code/game/objects/items/weapons/explosives.dm +++ b/code/game/objects/items/weapons/explosives.dm @@ -24,12 +24,12 @@ wires = null return ..() -/obj/item/plastique/attackby(var/obj/item/I, var/mob/user) - if(I.isscrewdriver()) +/obj/item/plastique/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) open_panel = !open_panel to_chat(user, "You [open_panel ? "open" : "close"] the wire panel.") return TRUE - else if(I.iswirecutter() || I.ismultitool() || istype(I, /obj/item/device/assembly/signaler )) + else if(attacking_item.iswirecutter() || attacking_item.ismultitool() || istype(attacking_item, /obj/item/device/assembly/signaler )) wires.interact(user) return TRUE else diff --git a/code/game/objects/items/weapons/extinguisher.dm b/code/game/objects/items/weapons/extinguisher.dm index 19709eb0f04..2a1ef9603d6 100644 --- a/code/game/objects/items/weapons/extinguisher.dm +++ b/code/game/objects/items/weapons/extinguisher.dm @@ -20,17 +20,17 @@ drop_sound = 'sound/items/drop/gascan.ogg' pickup_sound = 'sound/items/pickup/gascan.ogg' -/obj/item/reagent_containers/extinguisher_refill/attackby(obj/item/O, mob/user) - if(O.isscrewdriver()) +/obj/item/reagent_containers/extinguisher_refill/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(is_open_container()) atom_flags &= ~ATOM_FLAG_OPEN_CONTAINER else atom_flags |= ATOM_FLAG_OPEN_CONTAINER - to_chat(user, SPAN_NOTICE("Using \the [O], you [is_open_container() ? "unsecure" : "secure"] the cartridge's lid!")) + to_chat(user, SPAN_NOTICE("Using \the [attacking_item], you [is_open_container() ? "unsecure" : "secure"] the cartridge's lid!")) return TRUE - if(istype(O,/obj/item/extinguisher)) - var/obj/item/extinguisher/E = O + if(istype(attacking_item, /obj/item/extinguisher)) + var/obj/item/extinguisher/E = attacking_item if(is_open_container()) to_chat(user,"\The [src] needs to be secured first!") else if(reagents.total_volume <= 0) @@ -56,21 +56,21 @@ to_chat(user,"\The reagents inside [src] are already secured!") return -/obj/item/reagent_containers/extinguisher_refill/examine(mob/user, distance) //Copied from inhalers. +/obj/item/reagent_containers/extinguisher_refill/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!distance <= 2) return if(is_open_container()) if(LAZYLEN(reagents?.reagent_volumes)) - to_chat(user,"It contains [round(reagents.total_volume, accuracy)] units of non-aerosol mix.") + . += SPAN_NOTICE("It contains [round(reagents.total_volume, accuracy)] units of non-aerosol mix.") else - to_chat(user,"It is empty.") + . += SPAN_NOTICE("It is empty.") else if(LAZYLEN(reagents?.reagent_volumes)) - to_chat(user,"The reagents are secured in the aerosol mix.") + . += SPAN_NOTICE("The reagents are secured in the aerosol mix.") else - to_chat(user,"The cartridge seems spent.") + . += SPAN_NOTICE("The cartridge seems spent.") /obj/item/reagent_containers/extinguisher_refill/filled name = "extinguisher refiller (monoammonium phosphate)" @@ -128,11 +128,11 @@ reagents.add_reagent(/singleton/reagent/toxin/fertilizer/monoammoniumphosphate, max_water) ..() -/obj/item/extinguisher/examine(mob/user, distance) +/obj/item/extinguisher/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 0) - to_chat(user,"\The [src] contains [src.reagents.total_volume] units of reagents.") - to_chat(user,"The safety is [safety ? "on" : "off"].") + . += SPAN_NOTICE("\The [src] contains [src.reagents.total_volume] units of reagents.") + . += SPAN_NOTICE("The safety is [safety ? "on" : "off"].") return /obj/item/extinguisher/attack(mob/living/M, mob/living/user, target_zone) @@ -147,10 +147,10 @@ to_chat(user, "The safety is [safety ? "on" : "off"].") return -/obj/item/extinguisher/attackby(var/obj/O as obj, var/mob/user as mob) +/obj/item/extinguisher/attackby(obj/item/attacking_item, mob/user) - if(istype(O,/obj/item/reagent_containers/extinguisher_refill)) - var/obj/item/reagent_containers/extinguisher_refill/ER = O + if(istype(attacking_item,/obj/item/reagent_containers/extinguisher_refill)) + var/obj/item/reagent_containers/extinguisher_refill/ER = attacking_item if(ER.is_open_container()) to_chat(user,"\The [ER] needs to be secured first!") else if(ER.reagents.total_volume <= 0) diff --git a/code/game/objects/items/weapons/flamethrower.dm b/code/game/objects/items/weapons/flamethrower.dm index d308cbda362..289e6416d34 100644 --- a/code/game/objects/items/weapons/flamethrower.dm +++ b/code/game/objects/items/weapons/flamethrower.dm @@ -34,17 +34,17 @@ welding_tool.forceMove(src) update_icon() -/obj/item/flamethrower/examine(mob/user, distance, is_adjacent) +/obj/item/flamethrower/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(is_adjacent) if(gas_tank) - to_chat(user, SPAN_NOTICE("Release pressure is set to [throw_amount] kPa. The tank has about [round(gas_tank.air_contents.return_pressure(), 10)] kPa left in it.")) + . += SPAN_NOTICE("Release pressure is set to [throw_amount] kPa. The tank has about [round(gas_tank.air_contents.return_pressure(), 10)] kPa left in it.") else - to_chat(user, SPAN_WARNING("It has no gas tank installed.")) + . += SPAN_WARNING("It has no gas tank installed.") if(igniter) - to_chat(user, SPAN_NOTICE("It has \an [igniter] installed.")) + . += SPAN_NOTICE("It has \an [igniter] installed.") else - to_chat(user, SPAN_WARNING("It has no igniter installed.")) + . += SPAN_WARNING("It has no igniter installed.") /obj/item/flamethrower/Destroy() QDEL_NULL(welding_tool) @@ -102,11 +102,11 @@ var/turflist = get_turfs_in_cone(user, Get_Angle(user, target_turf), get_dist(user, target_turf), 30) flame_turf(turflist) -/obj/item/flamethrower/attackby(obj/item/W, mob/user) +/obj/item/flamethrower/attackby(obj/item/attacking_item, mob/user) if(use_check_and_message(user)) return TRUE - if(W.iswrench() && !secured)//Taking this apart + if(attacking_item.iswrench() && !secured)//Taking this apart var/turf/T = get_turf(src) if(welding_tool) welding_tool.forceMove(T) @@ -121,14 +121,14 @@ qdel(src) return TRUE - else if(W.isscrewdriver() && igniter && !lit) + else if(attacking_item.isscrewdriver() && igniter && !lit) secured = !secured to_chat(user, SPAN_NOTICE("[igniter] is now [secured ? "secured" : "unsecured"]!")) update_icon() return TRUE - else if(isigniter(W)) - var/obj/item/device/assembly/igniter/I = W + else if(isigniter(attacking_item)) + var/obj/item/device/assembly/igniter/I = attacking_item if(I.secured) to_chat(user, SPAN_WARNING("\The [I] is not ready to attach yet! Use a screwdriver on it first.")) return TRUE @@ -140,21 +140,21 @@ update_icon() return TRUE - else if(istype(W, /obj/item/tank/phoron) || istype(W, /obj/item/tank/hydrogen)) + else if(istype(attacking_item, /obj/item/tank/phoron) || istype(attacking_item, /obj/item/tank/hydrogen)) if(gas_tank) to_chat(user, SPAN_WARNING("There appears to already be a tank loaded in \the [src]!")) return - user.drop_from_inventory(W, src) - gas_tank = W + user.drop_from_inventory(attacking_item, src) + gas_tank = attacking_item update_icon() return TRUE - else if(istype(W, /obj/item/device/analyzer)) - var/obj/item/device/analyzer/A = W + else if(istype(attacking_item, /obj/item/device/analyzer)) + var/obj/item/device/analyzer/A = attacking_item A.analyze_gases(src, user) return TRUE - else if(W.isFlameSource()) // you can light it with external input, even without an igniter + else if(attacking_item.isFlameSource()) // you can light it with external input, even without an igniter attempt_lighting(user, TRUE) update_icon() return TRUE diff --git a/code/game/objects/items/weapons/grenades/chem_grenade.dm b/code/game/objects/items/weapons/grenades/chem_grenade.dm index 19c9eea958d..19efb133006 100644 --- a/code/game/objects/items/weapons/grenades/chem_grenade.dm +++ b/code/game/objects/items/weapons/grenades/chem_grenade.dm @@ -47,10 +47,10 @@ var/mob/living/carbon/C = user C.throw_mode_on() -/obj/item/grenade/chem_grenade/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/grenade/chem_grenade/attackby(obj/item/attacking_item, mob/user) - if(istype(W,/obj/item/device/assembly_holder) && (!stage || stage==1) && path != 2) - var/obj/item/device/assembly_holder/det = W + if(istype(attacking_item,/obj/item/device/assembly_holder) && (!stage || stage==1) && path != 2) + var/obj/item/device/assembly_holder/det = attacking_item if(istype(det.a_left,det.a_right.type) || (!isigniter(det.a_left) && !isigniter(det.a_right))) to_chat(user, "Assembly must contain one igniter.") return @@ -58,8 +58,8 @@ to_chat(user, "Assembly must be secured with screwdriver.") return path = 1 - to_chat(user, "You add [W] to the metal casing.") - playsound(src.loc, W.usesound, 25, -3) + to_chat(user, "You add [attacking_item] to the metal casing.") + playsound(src.loc, attacking_item.usesound, 25, -3) user.remove_from_mob(det) det.forceMove(src) detonator = det @@ -72,7 +72,7 @@ icon_state = initial(icon_state) +"_ass" name = "unsecured grenade with [beakers.len] containers[detonator?" and detonator":""]" stage = 1 - else if(W.isscrewdriver() && path != 2) + else if(attacking_item.isscrewdriver() && path != 2) if(stage == 1) path = 1 if(beakers.len) @@ -81,7 +81,7 @@ else to_chat(user, "You lock the empty assembly.") name = "fake grenade" - playsound(src.loc, W.usesound, 25, -3) + playsound(src.loc, attacking_item.usesound, 25, -3) icon_state = initial(icon_state) +"_locked" stage = 2 else if(stage == 2) @@ -91,30 +91,30 @@ return else to_chat(user, "You unlock the assembly.") - playsound(src.loc, W.usesound, 25, -3) + playsound(src.loc, attacking_item.usesound, 25, -3) name = "unsecured grenade with [beakers.len] containers[detonator?" and detonator":""]" icon_state = initial(icon_state) + (detonator?"_ass":"") stage = 1 active = 0 - else if(is_type_in_list(W, allowed_containers) && (!stage || stage==1) && path != 2) + else if(is_type_in_list(attacking_item, allowed_containers) && (!stage || stage==1) && path != 2) path = 1 if(beakers.len == 2) to_chat(user, "The grenade can not hold more containers.") return else - if(W.reagents.total_volume) - to_chat(user, "You add \the [W] to the assembly.") - user.drop_from_inventory(W,src) - beakers += W + if(attacking_item.reagents.total_volume) + to_chat(user, "You add \the [attacking_item] to the assembly.") + user.drop_from_inventory(attacking_item,src) + beakers += attacking_item stage = 1 name = "unsecured grenade with [beakers.len] containers[detonator?" and detonator":""]" else - to_chat(user, "\The [W] is empty.") + to_chat(user, "\The [attacking_item] is empty.") -/obj/item/grenade/chem_grenade/examine(mob/user) +/obj/item/grenade/chem_grenade/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(detonator) - to_chat(user, "With attached [detonator.name]") + . += "With attached [detonator.name]" /obj/item/grenade/chem_grenade/activate(mob/user as mob) if(active) return diff --git a/code/game/objects/items/weapons/grenades/dynamite.dm b/code/game/objects/items/weapons/grenades/dynamite.dm index eece9f56317..6f969ce19bd 100644 --- a/code/game/objects/items/weapons/grenades/dynamite.dm +++ b/code/game/objects/items/weapons/grenades/dynamite.dm @@ -8,26 +8,26 @@ /obj/item/grenade/dynamite/attack_self(mob/user) return -/obj/item/grenade/dynamite/attackby(obj/item/W, mob/user) +/obj/item/grenade/dynamite/attackby(obj/item/attacking_item, mob/user) ..() if(active) return - if(W.iswelder()) - var/obj/item/weldingtool/WT = W + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(WT.isOn()) activate(user) - else if(W.isFlameSource()) + else if(attacking_item.isFlameSource()) activate(user) - else if(istype(W, /obj/item/flame/candle)) - var/obj/item/flame/candle/C = W + else if(istype(attacking_item, /obj/item/flame/candle)) + var/obj/item/flame/candle/C = attacking_item if(C.lit) activate(user) - else if(istype(W, /obj/item/grenade/dynamite)) - var/obj/item/grenade/dynamite/C = W + else if(istype(attacking_item, /obj/item/grenade/dynamite)) + var/obj/item/grenade/dynamite/C = attacking_item if(C.active) activate(user) diff --git a/code/game/objects/items/weapons/grenades/grenade.dm b/code/game/objects/items/weapons/grenades/grenade.dm index b6f2bdf0c3c..502853c8653 100644 --- a/code/game/objects/items/weapons/grenades/grenade.dm +++ b/code/game/objects/items/weapons/grenades/grenade.dm @@ -30,19 +30,19 @@ return 0 return 1 -/obj/item/grenade/examine(mob/user, distance, is_adjacent) +/obj/item/grenade/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 0) if(det_time > 1) - to_chat(user, "The timer is set to [det_time/10] seconds.") + . += SPAN_NOTICE("The timer is set to [det_time/10] seconds.") return if(det_time == null) return - to_chat(user, "\The [src] is set for instant detonation.") + . += SPAN_NOTICE("\The [src] is set for instant detonation.") -/obj/item/grenade/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/gun/launcher/grenade)) - var/obj/item/gun/launcher/grenade/G = W +/obj/item/grenade/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/gun/launcher/grenade)) + var/obj/item/gun/launcher/grenade/G = attacking_item G.load(src, user) else ..() diff --git a/code/game/objects/items/weapons/handcuffs.dm b/code/game/objects/items/weapons/handcuffs.dm index 3baf09f8d3f..306cb24516f 100644 --- a/code/game/objects/items/weapons/handcuffs.dm +++ b/code/game/objects/items/weapons/handcuffs.dm @@ -209,17 +209,17 @@ color = pick(COLOR_RED, COLOR_BLUE, COLOR_LIME, COLOR_ORANGE, COLOR_WHITE, COLOR_PINK, COLOR_YELLOW, COLOR_CYAN) . = ..() -/obj/item/handcuffs/cable/attackby(var/obj/item/I, mob/user as mob) +/obj/item/handcuffs/cable/attackby(obj/item/attacking_item, mob/user) ..() - if(istype(I, /obj/item/stack/rods)) - var/obj/item/stack/rods/R = I + if(istype(attacking_item, /obj/item/stack/rods)) + var/obj/item/stack/rods/R = attacking_item if (R.use(1)) var/obj/item/material/wirerod/W = new(get_turf(user), MATERIAL_STEEL, color) user.put_in_hands(W) to_chat(user, SPAN_NOTICE("You wrap \the [src] around the top of the rod.")) qdel(src) update_icon(user) - else if(can_be_cut && I.iswirecutter()) + else if(can_be_cut && attacking_item.iswirecutter()) user.visible_message("[user] cuts the [src].", SPAN_NOTICE("You cut the [src].")) playsound(src.loc, 'sound/items/Wirecutter.ogg', 50, 1) new/obj/item/stack/cable_coil(get_turf(src), 15, color) diff --git a/code/game/objects/items/weapons/implants/implantcase.dm b/code/game/objects/items/weapons/implants/implantcase.dm index 4c747c578fc..d133676779c 100644 --- a/code/game/objects/items/weapons/implants/implantcase.dm +++ b/code/game/objects/items/weapons/implants/implantcase.dm @@ -36,10 +36,10 @@ var/mutable_appearance/overlay_implant_icon = mutable_appearance(icon, overlay_icon_state) add_overlay(overlay_implant_icon) -/obj/item/implantcase/attackby(obj/item/I, mob/user) - if (I.ispen()) +/obj/item/implantcase/attackby(obj/item/attacking_item, mob/user) + if (attacking_item.ispen()) var/t = tgui_input_text(user, "What would you like the label to be?", name, name, MAX_NAME_LEN) - if (user.get_active_hand() != I) + if (user.get_active_hand() != attacking_item) return if((!in_range(src, usr) && loc != user)) return @@ -49,10 +49,10 @@ else src.name = "implant case" desc = "An aluminium case, which can safely contain an implant." - else if(istype(I, /obj/item/reagent_containers/syringe)) - imp.attackby(I, user) - else if (istype(I, /obj/item/implanter)) - var/obj/item/implanter/M = I + else if(istype(attacking_item, /obj/item/reagent_containers/syringe)) + imp.attackby(attacking_item, user) + else if (istype(attacking_item, /obj/item/implanter)) + var/obj/item/implanter/M = attacking_item if (M.imp && !imp && !M.imp.implanted) M.imp.forceMove(src) imp = M.imp @@ -64,17 +64,17 @@ update_description() update_icon() M.update_icon() - else if (istype(I, /obj/item/implant)) + else if (istype(attacking_item, /obj/item/implant)) if(imp == null) - to_chat(user, SPAN_NOTICE("You slide \the [I] into \the [src].")) - user.drop_from_inventory(I,src) - imp = I + to_chat(user, SPAN_NOTICE("You slide \the [attacking_item] into \the [src].")) + user.drop_from_inventory(attacking_item,src) + imp = attacking_item else to_chat(user, SPAN_WARNING("\The [src] already has an implant inside of it!")) update_description() update_icon() - else if(istype(I, /obj/item/implantpad)) - var/obj/item/implantpad/pad = I + else if(istype(attacking_item, /obj/item/implantpad)) + var/obj/item/implantpad/pad = attacking_item if(!pad.case) user.drop_from_inventory(src,pad) pad.case = src diff --git a/code/game/objects/items/weapons/implants/implanter.dm b/code/game/objects/items/weapons/implants/implanter.dm index abcd38e60e6..f402be71a35 100644 --- a/code/game/objects/items/weapons/implants/implanter.dm +++ b/code/game/objects/items/weapons/implants/implanter.dm @@ -23,10 +23,10 @@ overlay_implant_icon.color = imp.implant_color add_overlay(overlay_implant_icon) -/obj/item/implanter/attackby(obj/item/I, mob/user) - if(!imp && istype(I, /obj/item/implant) && user.unEquip(I,src)) - to_chat(usr, SPAN_NOTICE("You slide \the [I] into \the [src].")) - imp = I +/obj/item/implanter/attackby(obj/item/attacking_item, mob/user) + if(!imp && istype(attacking_item, /obj/item/implant) && user.unEquip(attacking_item, src)) + to_chat(usr, SPAN_NOTICE("You slide \the [attacking_item] into \the [src].")) + imp = attacking_item update_icon() else ..() @@ -111,8 +111,8 @@ update_icon() -/obj/item/implanter/ipc_tag/attackby(obj/item/I, mob/user) - if(I.isscrewdriver()) +/obj/item/implanter/ipc_tag/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(!ipc_tag) to_chat(user, SPAN_WARNING("\The [src] doesn't have an IPC tag loaded.")) return @@ -122,12 +122,12 @@ ipc_tag = null update_icon() return - if(istype(I, /obj/item/organ/internal/ipc_tag)) + if(istype(attacking_item, /obj/item/organ/internal/ipc_tag)) if(ipc_tag) to_chat(user, SPAN_WARNING("\The [src] already has an IPC tag loaded.")) return - ipc_tag = I - user.drop_from_inventory(I, src) + ipc_tag = attacking_item + user.drop_from_inventory(attacking_item, src) update_icon() return ..() diff --git a/code/game/objects/items/weapons/implants/implantpad.dm b/code/game/objects/items/weapons/implants/implantpad.dm index a2ffd62317d..61a19c49a12 100644 --- a/code/game/objects/items/weapons/implants/implantpad.dm +++ b/code/game/objects/items/weapons/implants/implantpad.dm @@ -33,11 +33,11 @@ return return ..() -/obj/item/implantpad/attackby(obj/item/C, mob/user) - if(istype(C, /obj/item/implantcase)) +/obj/item/implantpad/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/implantcase)) if(!case) - user.drop_from_inventory(C,src) - case = C + user.drop_from_inventory(attacking_item, src) + case = attacking_item update_icon() else to_chat(user, SPAN_WARNING("\The [src] already has an implant case attached to it!")) diff --git a/code/game/objects/items/weapons/implants/implants/chem.dm b/code/game/objects/items/weapons/implants/implants/chem.dm index 9c25e456d27..76764e4c9ff 100644 --- a/code/game/objects/items/weapons/implants/implants/chem.dm +++ b/code/game/objects/items/weapons/implants/implants/chem.dm @@ -50,14 +50,14 @@ the implant may become unstable and either pre-maturely inject the subject or si if(!reagents.total_volume) to_chat(R, SPAN_WARNING("You hear a faint *click*.")) -/obj/item/implant/chem/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/reagent_containers/syringe)) +/obj/item/implant/chem/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/reagent_containers/syringe)) if(reagents.total_volume >= reagents.maximum_volume) to_chat(user, SPAN_WARNING("\The [src] is full.")) else if(do_after(user, 0.5 SECONDS, src)) - I.reagents.trans_to_obj(src, 5) - to_chat(user, SPAN_NOTICE("You inject 5 units of the solution. The syringe now contains [I.reagents.total_volume] units.")) + attacking_item.reagents.trans_to_obj(src, 5) + to_chat(user, SPAN_NOTICE("You inject 5 units of the solution. The syringe now contains [attacking_item.reagents.total_volume] units.")) else ..() diff --git a/code/game/objects/items/weapons/implants/implants/circuit.dm b/code/game/objects/items/weapons/implants/implants/circuit.dm index a76787b94b4..0887d7982cf 100644 --- a/code/game/objects/items/weapons/implants/implants/circuit.dm +++ b/code/game/objects/items/weapons/implants/implants/circuit.dm @@ -41,9 +41,9 @@ /obj/item/implant/integrated_circuit/examine(mob/user, distance, is_adjacent) return IC.examine(user, distance, is_adjacent) -/obj/item/implant/integrated_circuit/attackby(var/obj/item/O, var/mob/user) - if(O.iscrowbar() || istype(O, /obj/item/device/integrated_electronics) || istype(O, /obj/item/integrated_circuit) || O.isscrewdriver() || istype(O, /obj/item/cell/device) ) - IC.attackby(O, user) +/obj/item/implant/integrated_circuit/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iscrowbar() || istype(attacking_item, /obj/item/device/integrated_electronics) || istype(attacking_item, /obj/item/integrated_circuit) || attacking_item.isscrewdriver() || istype(attacking_item, /obj/item/cell/device) ) + IC.attackby(attacking_item, user) else ..() diff --git a/code/game/objects/items/weapons/implants/implants/compressed_matter.dm b/code/game/objects/items/weapons/implants/implants/compressed_matter.dm index 674d4872853..bf37fe4d84d 100644 --- a/code/game/objects/items/weapons/implants/implants/compressed_matter.dm +++ b/code/game/objects/items/weapons/implants/implants/compressed_matter.dm @@ -10,16 +10,16 @@ hidden = TRUE var/obj/item/scanned = null -/obj/item/implant/compressed/attackby(var/obj/item/T, mob/user) - if(T.isscrewdriver()) +/obj/item/implant/compressed/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(!scanned) to_chat(user, SPAN_NOTICE("There is nothing to remove from the implant.")) else to_chat(user, SPAN_NOTICE("You remove \the [scanned] from the implant.")) user.put_in_hands(scanned) scanned = null - if(istype(T, /obj/item/implanter)) - var/obj/item/implanter/implanter = T + if(istype(attacking_item, /obj/item/implanter)) + var/obj/item/implanter/implanter = attacking_item if(implanter.imp) to_chat(user, SPAN_NOTICE("\The [implanter] already has an implant loaded.")) return diff --git a/code/game/objects/items/weapons/improvised_components.dm b/code/game/objects/items/weapons/improvised_components.dm index 47bd6bcf231..365118615a8 100644 --- a/code/game/objects/items/weapons/improvised_components.dm +++ b/code/game/objects/items/weapons/improvised_components.dm @@ -6,8 +6,8 @@ force_divisor = 0.1 thrown_force_divisor = 0.1 -/obj/item/material/butterflyconstruction/attackby(obj/item/W as obj, mob/user as mob) - if(W.isscrewdriver()) +/obj/item/material/butterflyconstruction/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) to_chat(user, "You finish the concealed blade weapon.") new /obj/item/material/knife/butterfly(user.loc, material.name) qdel(src) @@ -29,12 +29,12 @@ force_divisor = 0.1 thrown_force_divisor = 0.1 -/obj/item/material/butterflyhandle/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W,/obj/item/material/butterflyblade)) - var/obj/item/material/butterflyblade/B = W +/obj/item/material/butterflyhandle/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/material/butterflyblade)) + var/obj/item/material/butterflyblade/B = attacking_item to_chat(user, "You attach the two concealed blade parts.") var/finished = new /obj/item/material/butterflyconstruction(user.loc, B.material.name) - qdel(W) + qdel(attacking_item) qdel(src) user.put_in_hands(finished) return @@ -64,24 +64,24 @@ I.color = cable_color add_overlay(I) -/obj/item/material/wirerod/attackby(var/obj/item/I, mob/user as mob) +/obj/item/material/wirerod/attackby(obj/item/attacking_item, mob/user) ..() var/obj/item/finished - if(istype(I, /obj/item/material/shard) || istype(I, /obj/item/material/spearhead)) - var/obj/item/material/tmp_shard = I + if(istype(attacking_item, /obj/item/material/shard) || istype(attacking_item, /obj/item/material/spearhead)) + var/obj/item/material/tmp_shard = attacking_item finished = new /obj/item/material/twohanded/spear(get_turf(user), tmp_shard.material.name) - to_chat(user, SPAN_NOTICE("You fasten \the [I] to the top of the rod with the cable.")) - else if(I.iswirecutter()) + to_chat(user, SPAN_NOTICE("You fasten \the [attacking_item] to the top of the rod with the cable.")) + else if(attacking_item.iswirecutter()) finished = new /obj/item/melee/baton/cattleprod(get_turf(user), forward_cable_color) to_chat(user, SPAN_NOTICE("You fasten the wirecutters to the top of the rod with the cable, prongs outward.")) - else if(istype(I, /obj/item/material/wirerod)) + else if(istype(attacking_item, /obj/item/material/wirerod)) finished = new /obj/item/trap/tripwire(get_turf(user), forward_cable_color) to_chat(user, SPAN_NOTICE("You attach the two wired rods together, spooling the cable between them.")) if(finished) user.drop_from_inventory(src,finished) - user.drop_from_inventory(I,finished) + user.drop_from_inventory(attacking_item,finished) //TODO: Possible better animation here. - qdel(I) + qdel(attacking_item) qdel(src) user.put_in_hands(finished) update_icon(user) @@ -100,17 +100,17 @@ thrown_force_divisor = 0.1 default_material = "wood" -/obj/item/material/shaft/attackby(var/obj/item/I, mob/user as mob) +/obj/item/material/shaft/attackby(obj/item/attacking_item, mob/user) ..() var/obj/item/finished - if(istype(I, /obj/item/material/spearhead)) - var/obj/item/material/spearhead/tip = I + if(istype(attacking_item, /obj/item/material/spearhead)) + var/obj/item/material/spearhead/tip = attacking_item finished = new /obj/item/material/twohanded/pike(get_turf(user), tip.material.name) - to_chat(user, SPAN_NOTICE("You attach \the [I] to the top of \the [src].")) + to_chat(user, SPAN_NOTICE("You attach \the [attacking_item] to the top of \the [src].")) if(finished) user.drop_from_inventory(src,finished) - user.drop_from_inventory(I,finished) - qdel(I) + user.drop_from_inventory(attacking_item,finished) + qdel(attacking_item) qdel(src) //TODO: Possible better animation here. user.put_in_hands(finished) @@ -139,17 +139,17 @@ thrown_force_divisor = 0.1 default_material = "wood" -/obj/item/material/woodenshield/attackby(var/obj/item/I, mob/user as mob) +/obj/item/material/woodenshield/attackby(obj/item/attacking_item, mob/user) ..() var/obj/item/finished - if(istype(I, /obj/item/material/shieldbits)) - var/obj/item/material/woodenshield/donut = I + if(istype(attacking_item, /obj/item/material/shieldbits)) + var/obj/item/material/woodenshield/donut = attacking_item finished = new /obj/item/shield/buckler(get_turf(user), donut.material.name) - to_chat(user, SPAN_NOTICE("You attach \the [I] to \the [src].")) + to_chat(user, SPAN_NOTICE("You attach \the [attacking_item] to \the [src].")) if(finished) user.drop_from_inventory(src) - user.drop_from_inventory(I) - qdel(I) + user.drop_from_inventory(attacking_item) + qdel(attacking_item) qdel(src) user.put_in_hands(finished) update_icon(user) @@ -171,10 +171,10 @@ item_state = "woodcirclet" w_class = ITEMSIZE_SMALL -/obj/item/woodcirclet/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/woodcirclet/attackby(obj/item/attacking_item, mob/user) var/obj/item/complete = null - if(istype(W, /obj/item/seeds)) // Only allow seeds, since we rely on their structure - var/obj/item/seeds/S = W + if(istype(attacking_item, /obj/item/seeds)) // Only allow seeds, since we rely on their structure + var/obj/item/seeds/S = attacking_item if(istype(S.seed, /datum/seed/flower/poppy)) complete = new /obj/item/clothing/head/poppy_crown(get_turf(user)) else if(istype(S.seed, /datum/seed/flower/sunflower)) @@ -184,9 +184,9 @@ if(complete != null) to_chat(user, SPAN_NOTICE("You attach the " + S.seed.seed_name + " to the circlet and create a beautiful flower crown.")) - user.drop_from_inventory(W) + user.drop_from_inventory(attacking_item) user.drop_from_inventory(src) - qdel(W) + qdel(attacking_item) qdel(src) user.put_in_hands(complete) return diff --git a/code/game/objects/items/weapons/ipc_scanner.dm b/code/game/objects/items/weapons/ipc_scanner.dm index 83f713807cf..dfd0f93a983 100644 --- a/code/game/objects/items/weapons/ipc_scanner.dm +++ b/code/game/objects/items/weapons/ipc_scanner.dm @@ -49,11 +49,11 @@ to_chat(user, SPAN_NOTICE("Ownership Status: [tag.ownership_info]")) to_chat(user, SPAN_NOTICE("Citizenship Info: [tag.citizenship_info]")) -/obj/item/ipc_tag_scanner/attackby(obj/item/W, mob/user) - if(W.isscrewdriver()) +/obj/item/ipc_tag_scanner/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) wires_exposed = !wires_exposed user.visible_message(SPAN_WARNING("\The [user] [wires_exposed ? "exposes the wiring" : "closes the panel"] on \the [src]."), SPAN_WARNING("You [wires_exposed ? "expose the wiring" : "close the panel"] on \the [src]."), 3) - else if(W.iswirecutter() || W.ismultitool()) + else if(attacking_item.iswirecutter() || attacking_item.ismultitool()) if(wires_exposed) wires.interact(user) else diff --git a/code/game/objects/items/weapons/landmines.dm b/code/game/objects/items/weapons/landmines.dm index 57d3169c976..9694241bc15 100644 --- a/code/game/objects/items/weapons/landmines.dm +++ b/code/game/objects/items/weapons/landmines.dm @@ -135,10 +135,10 @@ src.deactivated = TRUE -/obj/item/landmine/attackby(obj/item/I, mob/user) +/obj/item/landmine/attackby(obj/item/attacking_item, mob/user) ..() - if(deactivated && istype(I, /obj/item/stack/cable_coil)) - var/obj/item/stack/cable_coil/C = I + if(deactivated && istype(attacking_item, /obj/item/stack/cable_coil)) + var/obj/item/stack/cable_coil/C = attacking_item if(C.use(1)) to_chat(user, SPAN_NOTICE("You start carefully start rewiring \the [src].")) if(do_after(user, 10 SECONDS, do_flags = DO_REPAIR_CONSTRUCT)) @@ -148,11 +148,11 @@ else to_chat(user, SPAN_WARNING("There's not enough cable to finish the task.")) return - else if(deployed && istype(I, /obj/item/wirecutters)) - var/obj/item/wirecutters/W = I + else if(deployed && istype(attacking_item, /obj/item/wirecutters)) + var/obj/item/wirecutters/W = attacking_item user.visible_message(SPAN_WARNING("\The [user] starts snipping some wires in \the [src] with \the [W]..."), \ SPAN_NOTICE("You start snipping some wires in \the [src] with \the [W]...")) - if(I.use_tool(src, user, 150, volume = 50)) + if(attacking_item.use_tool(src, user, 150, volume = 50)) if(prob(W.bomb_defusal_chance)) to_chat(user, SPAN_NOTICE("You successfully defuse \the [src], though it's missing some essential wiring now.")) deactivate(user) @@ -162,7 +162,7 @@ return to_chat(user, FONT_LARGE(SPAN_DANGER("You slip, snipping the wrong wire!"))) trigger(user) - else if(I.force > 10 && deployed) + else if(attacking_item.force > 10 && deployed) trigger(user) /obj/item/landmine/bullet_act() @@ -328,7 +328,7 @@ src.engaged_by = null . = ..() -/obj/item/landmine/standstill/attackby(obj/item/I, mob/user) +/obj/item/landmine/standstill/attackby(obj/item/attacking_item, mob/user) if(engaged_by && (user == locate(engaged_by))) to_chat(user, SPAN_ALERT("You are unable to reach the mine without moving your foot, and you feel like doing so would not end well...")) else @@ -369,15 +369,15 @@ /obj/item/landmine/claymore/update_icon() icon_state = (src.deployed) ? "[initial(icon_state)]_active" : initial(icon_state) -/obj/item/landmine/claymore/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/device/assembly/signaler)) +/obj/item/landmine/claymore/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/device/assembly/signaler)) if(!isnull(signaler)) to_chat(user, SPAN_NOTICE("There is already a signaler inserted in \the [src].")) return - signaler = I + signaler = attacking_item - user.drop_from_inventory(I, src) + user.drop_from_inventory(attacking_item, src) trigger_wire.attach_assembly(WIRE_EXPLODE, signaler) diff --git a/code/game/objects/items/weapons/material/ashtray.dm b/code/game/objects/items/weapons/material/ashtray.dm index 860360e6af4..6c3b715879f 100644 --- a/code/game/objects/items/weapons/material/ashtray.dm +++ b/code/game/objects/items/weapons/material/ashtray.dm @@ -57,18 +57,18 @@ else desc = "An ashtray made of [material.display_name]." -/obj/item/material/ashtray/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/material/ashtray/attackby(obj/item/attacking_item, mob/user) if (health <= 0) return - if (istype(W,/obj/item/trash/cigbutt) || istype(W,/obj/item/clothing/mask/smokable/cigarette) || istype(W, /obj/item/flame/match)) + if (istype(attacking_item, /obj/item/trash/cigbutt) || istype(attacking_item, /obj/item/clothing/mask/smokable/cigarette) || istype(attacking_item, /obj/item/flame/match)) if (contents.len >= max_butts) to_chat(user, "\The [src] is full.") return - user.remove_from_mob(W) - W.forceMove(src) + user.remove_from_mob(attacking_item) + attacking_item.forceMove(src) - if (istype(W,/obj/item/clothing/mask/smokable/cigarette)) - var/obj/item/clothing/mask/smokable/cigarette/cig = W + if (istype(attacking_item,/obj/item/clothing/mask/smokable/cigarette)) + var/obj/item/clothing/mask/smokable/cigarette/cig = attacking_item if (cig.lit == TRUE) user.visible_message("[user] crushes [cig] in [src], putting it out.", SPAN_NOTICE("You crush [cig] in [src], putting it out.")) playsound(src.loc, 'sound/items/cigs_lighters/cig_snuff.ogg', 50, 1) @@ -76,7 +76,7 @@ var/obj/item/butt = new cig.type_butt(src) cig.transfer_fingerprints_to(butt) qdel(cig) - W = butt + attacking_item = butt //spawn(1) // TemperatureAct(150) else if (cig.lit == FALSE) @@ -85,15 +85,15 @@ SPAN_NOTICE("You place [cig] in [src] without even smoking it. Why would you do that?") ) else - user.visible_message("[user] places [W] in [src].", SPAN_NOTICE("You place [W] in [src].")) + user.visible_message("[user] places [attacking_item] in [src].", SPAN_NOTICE("You place [attacking_item] in [src].")) user.update_inv_l_hand() user.update_inv_r_hand() add_fingerprint(user) update_icon() else - health = max(0,health - W.force) - user.visible_message(user, SPAN_DANGER("[user] hits [src] with [W]!"), SPAN_DANGER("You hit [src] with [W].")) + health = max(0,health - attacking_item.force) + user.visible_message(user, SPAN_DANGER("[user] hits [src] with [attacking_item]!"), SPAN_DANGER("You hit [src] with [attacking_item].")) playsound(get_turf(src), material.hitsound, 25) if (health < 1) shatter() diff --git a/code/game/objects/items/weapons/material/material_armor.dm b/code/game/objects/items/weapons/material/material_armor.dm index 7deebc39038..59787395811 100644 --- a/code/game/objects/items/weapons/material/material_armor.dm +++ b/code/game/objects/items/weapons/material/material_armor.dm @@ -52,9 +52,9 @@ Protectiveness | Armor % thrown_force_divisor = 0.2 var/wired = FALSE -/obj/item/material/armor_plating/attackby(var/obj/O, mob/user) - if(istype(O, /obj/item/stack/cable_coil)) - var/obj/item/stack/cable_coil/S = O +/obj/item/material/armor_plating/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stack/cable_coil)) + var/obj/item/stack/cable_coil/S = attacking_item if(wired) to_chat(user, "This already has enough wires on it.") return @@ -66,8 +66,8 @@ Protectiveness | Armor % else to_chat(user, "You need more wire for that.") return - if(istype(O, /obj/item/material/armor_plating)) - var/obj/item/material/armor_plating/second_plate = O + if(istype(attacking_item, /obj/item/material/armor_plating)) + var/obj/item/material/armor_plating/second_plate = attacking_item if(!wired && !second_plate.wired) to_chat(user, "You need something to hold the two pieces of plating together.") return @@ -111,9 +111,9 @@ Protectiveness | Armor % item_state = "woodbucket" contained_sprite = 1 -/obj/item/clothing/head/helmet/bucket/attackby(var/obj/O, mob/user) - if(istype(O, /obj/item/stack/material)) - var/obj/item/stack/material/S = O +/obj/item/clothing/head/helmet/bucket/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stack/material)) + var/obj/item/stack/material/S = attacking_item if(S.use(2)) to_chat(user, "You apply some [S.material.use_name] to \the [src]. ") var/obj/item/clothing/head/helmet/material/makeshift/helmet = new(null, S.material.name) @@ -151,9 +151,9 @@ Protectiveness | Armor % icon_state = "material_kelly" item_state = "material_kelly" -/obj/item/clothing/suit/armor/material/makeshift/attackby(var/obj/O, mob/user) - if(istype(O, /obj/item/clothing/suit/storage/toggle/trench)) - var/obj/item/clothing/suit/storage/toggle/trench/kelly = O +/obj/item/clothing/suit/armor/material/makeshift/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/clothing/suit/storage/toggle/trench)) + var/obj/item/clothing/suit/storage/toggle/trench/kelly = attacking_item user.drop_from_inventory(src) user.drop_from_inventory(kelly) var/obj/item/clothing/suit/armor/material/makeshift/trenchcoat/new_armor = new(null, src.material.name) diff --git a/code/game/objects/items/weapons/material/shards.dm b/code/game/objects/items/weapons/material/shards.dm index 705948dc580..0f5c7999057 100644 --- a/code/game/objects/items/weapons/material/shards.dm +++ b/code/game/objects/items/weapons/material/shards.dm @@ -54,9 +54,9 @@ color = "#ffffff" alpha = 255 -/obj/item/material/shard/attackby(obj/item/W as obj, mob/user as mob) - if(W.iswelder() && material.shard_can_repair) - var/obj/item/weldingtool/WT = W +/obj/item/material/shard/attackby(obj/item/attacking_item, mob/user as mob) + if(attacking_item.iswelder() && material.shard_can_repair) + var/obj/item/weldingtool/WT = attacking_item if(WT.use(0, user)) material.place_sheet(user.loc) qdel(src) diff --git a/code/game/objects/items/weapons/material/swords.dm b/code/game/objects/items/weapons/material/swords.dm index 2c3631a4ef3..6a2511df571 100644 --- a/code/game/objects/items/weapons/material/swords.dm +++ b/code/game/objects/items/weapons/material/swords.dm @@ -189,9 +189,9 @@ force_divisor = 0.05 thrown_force_divisor = 0.2 -/obj/item/material/sword_hilt/attackby(var/obj/O, mob/user) - if(istype(O, /obj/item/material/sword_blade)) - var/obj/item/material/sword_blade/blade = O +/obj/item/material/sword_hilt/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/material/sword_blade)) + var/obj/item/material/sword_blade/blade = attacking_item var/obj/item/material/sword/improvised_sword/new_sword = new(src.loc, blade.material.name) new_sword.hilt = src user.drop_from_inventory(src,new_sword) @@ -212,9 +212,9 @@ force_divisor = 0.20 thrown_force_divisor = 0.3 -/obj/item/material/sword_blade/attackby(var/obj/O, mob/user) - if(istype(O, /obj/item/material/sword_hilt)) - var/obj/item/material/sword_hilt/hilt = O +/obj/item/material/sword_blade/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/material/sword_hilt)) + var/obj/item/material/sword_hilt/hilt = attacking_item var/obj/item/material/sword/improvised_sword/new_sword = new(src.loc, src.material.name) new_sword.hilt = hilt.material new_sword.assignDescription() diff --git a/code/game/objects/items/weapons/material/twohanded.dm b/code/game/objects/items/weapons/material/twohanded.dm index 6c080525465..75c62978cdb 100644 --- a/code/game/objects/items/weapons/material/twohanded.dm +++ b/code/game/objects/items/weapons/material/twohanded.dm @@ -263,31 +263,31 @@ QDEL_NULL(explosive) return ..() -/obj/item/material/twohanded/spear/examine(mob/user) +/obj/item/material/twohanded/spear/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(explosive) - to_chat(user, "It has \the [explosive] strapped to it.") + . += "It has \the [explosive] strapped to it." -/obj/item/material/twohanded/spear/attackby(var/obj/item/I, var/mob/living/user) - if(istype(I, /obj/item/organ/external/head)) +/obj/item/material/twohanded/spear/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/organ/external/head)) to_chat(user, "You stick the head onto the spear and stand it upright on the ground.") var/obj/structure/headspear/HS = new /obj/structure/headspear(user.loc) var/matrix/M = matrix() - I.transform = M - usr.drop_from_inventory(I,HS) - var/mutable_appearance/MA = new(I) + attacking_item.transform = M + usr.drop_from_inventory(attacking_item, HS) + var/mutable_appearance/MA = new(attacking_item) MA.layer = FLOAT_LAYER HS.add_overlay(MA) - HS.name = "[I.name] on a spear" + HS.name = "[attacking_item.name] on a spear" HS.material = material.name qdel(src) return - if(istype(I, /obj/item/grenade)) - to_chat(user, "You strap \the [I] to \the [src].") - user.unEquip(I) - I.forceMove(src) - explosive = I + if(istype(attacking_item, /obj/item/grenade)) + to_chat(user, "You strap \the [attacking_item] to \the [src].") + user.unEquip(attacking_item) + attacking_item.forceMove(src) + explosive = attacking_item update_icon() return return ..() @@ -472,12 +472,12 @@ RemoveFuel(FuelToRemove) -/obj/item/material/twohanded/chainsaw/examine(mob/user, distance, is_adjacent) +/obj/item/material/twohanded/chainsaw/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1) - to_chat(user, "A heavy-duty chainsaw meant for cutting wood. Contains [round(REAGENT_VOLUME(reagents, fuel_type))] unit\s of fuel.") + . += "A heavy-duty chainsaw meant for cutting wood. Contains [round(REAGENT_VOLUME(reagents, fuel_type))] unit\s of fuel." if(powered) - to_chat(user, SPAN_NOTICE("It is currently powered on.")) + . += SPAN_NOTICE("It is currently powered on.") /obj/item/material/twohanded/chainsaw/attack(mob/M as mob, mob/living/user as mob) . = ..() diff --git a/code/game/objects/items/weapons/mop.dm b/code/game/objects/items/weapons/mop.dm index 0b0d2a9b1e9..4b98db28d02 100644 --- a/code/game/objects/items/weapons/mop.dm +++ b/code/game/objects/items/weapons/mop.dm @@ -61,8 +61,8 @@ if(clean_msg) to_chat(user, SPAN_NOTICE("You have finished mopping!")) -/obj/effect/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/mop) || istype(I, /obj/item/soap)) +/obj/effect/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/mop) || istype(attacking_item, /obj/item/soap)) return FALSE return ..() @@ -111,6 +111,6 @@ if(reagents.total_volume < 30) reagents.add_reagent(refill_reagent, refill_rate) -/obj/item/mop/advanced/examine(mob/user) +/obj/item/mop/advanced/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, SPAN_NOTICE("\The condenser switch is set to [refill_enabled ? "ON" : "OFF"].")) + . += SPAN_NOTICE("\The condenser switch is set to [refill_enabled ? "ON" : "OFF"].") diff --git a/code/game/objects/items/weapons/policetape.dm b/code/game/objects/items/weapons/policetape.dm index 5c538bfd5c2..c36ffc2919d 100644 --- a/code/game/objects/items/weapons/policetape.dm +++ b/code/game/objects/items/weapons/policetape.dm @@ -31,10 +31,10 @@ var/list/tape_roll_applications = list() var/crumpled = 0 var/icon_base -/obj/item/tape/examine(mob/user, distance, is_adjacent) +/obj/item/tape/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(LAZYLEN(crumplers) && is_adjacent) - to_chat(user, SPAN_WARNING("\The [initial(name)] has been crumpled by [english_list(crumplers)].")) + . += SPAN_WARNING("\The [initial(name)] has been crumpled by [english_list(crumplers)].") /obj/item/taperoll/police name = "police tape" @@ -90,13 +90,13 @@ var/list/tape_roll_applications = list() icon_base = "engineering" var/shield_marker = FALSE -/obj/item/tape/engineering/examine(mob/user, distance) +/obj/item/tape/engineering/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(shield_marker) - to_chat(user, SPAN_NOTICE("This strip of tape has been modified to serve as a marker for emergency shield generators to lock onto.")) + . += SPAN_NOTICE("This strip of tape has been modified to serve as a marker for emergency shield generators to lock onto.") -/obj/item/tape/engineering/attackby(obj/item/W, mob/user) - if(W.ismultitool()) +/obj/item/tape/engineering/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ismultitool()) shield_marker = !shield_marker to_chat(user, SPAN_NOTICE("You [shield_marker ? "" : "un"]designate \the [src] as a target for an emergency shield generator.")) if(shield_marker) @@ -222,8 +222,8 @@ var/list/tape_roll_applications = list() crumple(mover) return ..() -/obj/item/tape/attackby(obj/item/W, mob/user) - return breaktape(W, user) +/obj/item/tape/attackby(obj/item/attacking_item, mob/user) + return breaktape(attacking_item, user) /obj/item/tape/attack_hand(mob/user) if(user.a_intent == I_HELP) diff --git a/code/game/objects/items/weapons/shields.dm b/code/game/objects/items/weapons/shields.dm index e921e054deb..12a65575875 100644 --- a/code/game/objects/items/weapons/shields.dm +++ b/code/game/objects/items/weapons/shields.dm @@ -84,10 +84,10 @@ return 0 return base_block_chance -/obj/item/shield/riot/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W, /obj/item/melee/baton)) +/obj/item/shield/riot/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/melee/baton)) if(cooldown < world.time - 25) - user.visible_message("[user] bashes [src] with [W]!") + user.visible_message("[user] bashes [src] with [attacking_item]!") playsound(user.loc, 'sound/effects/shieldbash.ogg', 50, 1) cooldown = world.time else diff --git a/code/game/objects/items/weapons/soap.dm b/code/game/objects/items/weapons/soap.dm index e308b069575..05322add121 100644 --- a/code/game/objects/items/weapons/soap.dm +++ b/code/game/objects/items/weapons/soap.dm @@ -31,11 +31,11 @@ playsound(loc, 'sound/effects/slosh.ogg', 25, 1) reagents.add_reagent(/singleton/reagent/spacecleaner, capacity) -/obj/item/soap/attackby(var/obj/item/I, var/mob/user) - if(istype(I, /obj/item/key)) +/obj/item/soap/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/key)) if(!key_data) - to_chat(user, SPAN_NOTICE("You imprint \the [I] into \the [src].")) - var/obj/item/key/K = I + to_chat(user, SPAN_NOTICE("You imprint \the [attacking_item] into \the [src].")) + var/obj/item/key/K = attacking_item key_data = K.key_data update_icon() return TRUE diff --git a/code/game/objects/items/weapons/storage/backpack.dm b/code/game/objects/items/weapons/storage/backpack.dm index cb2cbef1732..3d674b2c978 100644 --- a/code/game/objects/items/weapons/storage/backpack.dm +++ b/code/game/objects/items/weapons/storage/backpack.dm @@ -94,10 +94,10 @@ storage_cost = 29 empty_delay = 0.8 SECOND -/obj/item/storage/backpack/holding/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W, /obj/item/storage/backpack/holding)) +/obj/item/storage/backpack/holding/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/storage/backpack/holding)) to_chat(user, "The Bluespace interfaces of the two devices conflict and malfunction.") - qdel(W) + qdel(attacking_item) return ..() diff --git a/code/game/objects/items/weapons/storage/bags.dm b/code/game/objects/items/weapons/storage/bags.dm index 95bc4b99681..c29f7e50176 100644 --- a/code/game/objects/items/weapons/storage/bags.dm +++ b/code/game/objects/items/weapons/storage/bags.dm @@ -55,10 +55,10 @@ icon_state = "trashbag2" else icon_state = "trashbag3" -/obj/item/storage/bag/trash/attackby(var/obj/item/I, var/mob/user) - if (istype (I, /obj/item/device/lightreplacer)) +/obj/item/storage/bag/trash/attackby(obj/item/attacking_item, mob/user) + if (istype (attacking_item, /obj/item/device/lightreplacer)) var/count = 0 - var/obj/item/device/lightreplacer/R = I + var/obj/item/device/lightreplacer/R = attacking_item var/bagfull = 0 if (R.store_broken) for(var/obj/item/light/L in R.contents) diff --git a/code/game/objects/items/weapons/storage/bible.dm b/code/game/objects/items/weapons/storage/bible.dm index e3e7670cdd7..5a8cec08409 100644 --- a/code/game/objects/items/weapons/storage/bible.dm +++ b/code/game/objects/items/weapons/storage/bible.dm @@ -37,7 +37,7 @@ A.reagents.del_reagent(/singleton/reagent/water) A.reagents.add_reagent(/singleton/reagent/water/holywater, water2holy) -/obj/item/storage/bible/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/storage/bible/attackby(obj/item/attacking_item, mob/user) if(src.use_sound) playsound(src.loc, src.use_sound, 50, 1, -5) return ..() diff --git a/code/game/objects/items/weapons/storage/boxes.dm b/code/game/objects/items/weapons/storage/boxes.dm index 06ede96bbb3..c2c93594036 100644 --- a/code/game/objects/items/weapons/storage/boxes.dm +++ b/code/game/objects/items/weapons/storage/boxes.dm @@ -90,13 +90,13 @@ damage(damage) ..() -/obj/item/storage/box/examine(var/mob/user) +/obj/item/storage/box/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if (health < maxHealth) if (health >= (maxHealth * 0.5)) - to_chat(user, SPAN_WARNING("It is slightly torn.")) + . += SPAN_WARNING("It is slightly torn.") else - to_chat(user, SPAN_DANGER("It is full of tears and holes.")) + . += SPAN_DANGER("It is full of tears and holes.") // BubbleWrap - A box can be folded up to make card /obj/item/storage/box/attack_self(mob/user as mob) @@ -131,13 +131,13 @@ qdel(src) user.put_in_hands(trash) -/obj/item/storage/box/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/stack/packageWrap)) - var/total_storage_space = W.get_storage_cost() +/obj/item/storage/box/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stack/packageWrap)) + var/total_storage_space = attacking_item.get_storage_cost() for(var/obj/item/I in contents) total_storage_space += I.get_storage_cost() if(total_storage_space <= max_storage_space) - var/question = alert(user, "Will you want to wrap \the [src] or store the item inside?", "Wrap or Store", "Wrap", "Store") + var/question = tgui_input_list(user, "Will you want to wrap \the [src] or store the item inside?", "Wrap or Store", list("Wrap", "Store")) if(question == "Wrap") return else if(question == "Store") @@ -1118,8 +1118,8 @@ else if(length(contents) < 8) icon_state = "paperbag_[choice]-food" -/obj/item/storage/box/papersack/attackby(obj/item/O, mob/user) - if(O.ispen()) +/obj/item/storage/box/papersack/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ispen()) if(!papersack_designs) papersack_designs = sortList(list( "None" = image(icon = src.icon, icon_state = "paperbag_None"), @@ -1150,10 +1150,10 @@ update_icon() return - else if(O.isscrewdriver()) + else if(attacking_item.isscrewdriver()) if(length(contents) == 0) to_chat(user, SPAN_NOTICE("You begin poking holes in \the [src].")) - if(O.use_tool(src, user, 30)) + if(attacking_item.use_tool(src, user, 30)) if(choice == "SmileyFace") var/obj/item/clothing/head/papersack/smiley/S = new() user.put_in_hands(S) @@ -1238,6 +1238,16 @@ . = ..() make_exact_fit() +/obj/item/storage/box/cleaner_tablets + name = "\improper Idris cleaner tablets box" + desc = "A box of advanced formula chemical tablets designed by Idris Incorporated." + desc_extended = "A new generation of cleaning chemicals, according to Idris at least. The instructions on the box reads: \"Dissolve tablet fully in container of water\". A warning label mentions that you should not consume the tablets nor drink the mixture after dissolving them." + illustration = "soapbucket" + max_storage_space = 16 + starts_with = list( + /obj/item/reagent_containers/pill/cleaner_tablet = 16 + ) + /obj/item/storage/box/led_collars name = "box of LED collars" desc = "A box containing eight LED collars, usually worn around the neck of the voidsuit." @@ -1299,3 +1309,4 @@ starts_with = list( /obj/item/reagent_containers/food/snacks/grown/konyang_tea/jaekseol = 7 ) + diff --git a/code/game/objects/items/weapons/storage/fancy.dm b/code/game/objects/items/weapons/storage/fancy.dm index 331a5b05811..bb269e0866d 100644 --- a/code/game/objects/items/weapons/storage/fancy.dm +++ b/code/game/objects/items/weapons/storage/fancy.dm @@ -73,14 +73,14 @@ update_icon() . = ..() -/obj/item/storage/box/fancy/examine(mob/user) +/obj/item/storage/box/fancy/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!icon_type || !storage_type) return if(contents.len <= 0) - to_chat(user, "There are no [src.icon_type]s left in the [src.storage_type].") + . += "There are no [src.icon_type]s left in the [src.storage_type]." else - to_chat(user, "There [src.contents.len == 1 ? "is" : "are"] [src.contents.len] [src.icon_type]\s left in \the [src.storage_type].") + . += "There [src.contents.len == 1 ? "is" : "are"] [src.contents.len] [src.icon_type]\s left in \the [src.storage_type]." /* * Donut Box @@ -226,8 +226,9 @@ for(var/obj/item/pen/crayon/crayon in contents) add_overlay("[crayon.colourName]") -/obj/item/storage/box/fancy/crayons/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W,/obj/item/pen/crayon)) +/obj/item/storage/box/fancy/crayons/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/pen/crayon)) + var/obj/item/pen/crayon/W = attacking_item switch(W:colourName) if("mime") to_chat(usr, "This crayon is too sad to be contained in this box.") @@ -256,7 +257,8 @@ starts_with = list(/obj/item/flame/match = 10) icon_overlays = FALSE -/obj/item/storage/box/fancy/matches/attackby(obj/item/flame/match/W, mob/user) +/obj/item/storage/box/fancy/matches/attackby(obj/item/attacking_item, mob/user) + var/obj/item/flame/match/W = attacking_item if(istype(W) && !W.lit) if(prob(25)) playsound(src.loc, 'sound/items/cigs_lighters/matchstick_lit.ogg', 25, 0, -1) @@ -473,7 +475,7 @@ else add_overlay("ledb") -/obj/item/storage/lockbox/vials/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/storage/lockbox/vials/attackby(attacking_item, mob/user) ..() update_icon() @@ -611,18 +613,18 @@ update_icon() -/obj/item/pizzabox/attackby( obj/item/I as obj, mob/user as mob ) - if( istype(I, /obj/item/pizzabox/) ) - var/obj/item/pizzabox/box = I +/obj/item/pizzabox/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/pizzabox/) ) + var/obj/item/pizzabox/box = attacking_item - if( !box.open && !src.open ) + if(!box.open && !src.open ) // Make a list of all boxes to be added var/list/boxestoadd = list() boxestoadd += box for(var/obj/item/pizzabox/i in box.boxes) boxestoadd += i - if( (boxes.len+1) + boxestoadd.len <= 5 ) + if((boxes.len+1) + boxestoadd.len <= 5) user.drop_from_inventory(box,src) box.boxes = list() // Clear the box boxes so we don't have boxes inside boxes. - Xzibit src.boxes.Add( boxestoadd ) @@ -638,28 +640,28 @@ return - if( istype(I, /obj/item/reagent_containers/food/snacks/sliceable/pizza/) ) // Long ass fucking object name + if(istype(attacking_item, /obj/item/reagent_containers/food/snacks/sliceable/pizza/)) // Long ass fucking object name - if( src.open ) - user.drop_from_inventory(I,src) - src.pizza = I + if(src.open) + user.drop_from_inventory(attacking_item, src) + src.pizza = attacking_item update_icon() - to_chat(user, SPAN_WARNING("You put \the [I] in \the [src]!")) + to_chat(user, SPAN_WARNING("You put \the [attacking_item] in \the [src]!")) else - to_chat(user, SPAN_WARNING("You try to push \the [I] through the lid but it doesn't work!")) + to_chat(user, SPAN_WARNING("You try to push \the [attacking_item] through the lid but it doesn't work!")) return - if( I.ispen() ) + if(attacking_item.ispen()) - if( src.open ) + if(src.open) return - var/t = sanitize(input("Enter what you want to add to the tag:", "Write", null, null) as text, 30) + var/t = sanitize( tgui_input_text(user, "Enter what you want to add to the tag:", "Write", max_length = 30), 30 ) var/obj/item/pizzabox/boxtotagto = src - if( boxes.len > 0 ) + if(boxes.len > 0) boxtotagto = boxes[boxes.len] boxtotagto.boxtag = copytext("[boxtotagto.boxtag][t]", 1, 30) diff --git a/code/game/objects/items/weapons/storage/lockbox.dm b/code/game/objects/items/weapons/storage/lockbox.dm index 6fee9176f1c..dbf943a11e6 100644 --- a/code/game/objects/items/weapons/storage/lockbox.dm +++ b/code/game/objects/items/weapons/storage/lockbox.dm @@ -18,8 +18,8 @@ var/icon_broken = "lockbox+b" -/obj/item/storage/lockbox/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W, /obj/item/card/id)) +/obj/item/storage/lockbox/attackby(attacking_item, mob/user) + if(istype(attacking_item, /obj/item/card/id)) if(src.broken) to_chat(user, "It appears to be broken.") return @@ -37,9 +37,9 @@ return else to_chat(user, "Access Denied") - else if(istype(W, /obj/item/melee/energy/blade)) - if(emag_act(INFINITY, user, W, "The locker has been sliced open by [user] with an energy blade!", "You hear metal being sliced and sparks flying.")) - var/obj/item/melee/energy/blade/blade = W + else if(istype(attacking_item, /obj/item/melee/energy/blade)) + if(emag_act(INFINITY, user, attacking_item, "The locker has been sliced open by [user] with an energy blade!", "You hear metal being sliced and sparks flying.")) + var/obj/item/melee/energy/blade/blade = attacking_item blade.spark_system.queue() playsound(src.loc, 'sound/weapons/blade.ogg', 50, 1) playsound(src.loc, /singleton/sound_category/spark_sound, 50, 1) diff --git a/code/game/objects/items/weapons/storage/misc.dm b/code/game/objects/items/weapons/storage/misc.dm index 56f75a48feb..6edf476fdac 100644 --- a/code/game/objects/items/weapons/storage/misc.dm +++ b/code/game/objects/items/weapons/storage/misc.dm @@ -66,7 +66,7 @@ slot_l_hand_str = 'icons/mob/items/lefthand_cigs_lighters.dmi', slot_r_hand_str = 'icons/mob/items/righthand_cigs_lighters.dmi', ) - w_class = ITEMSIZE_SMALL + w_class = ITEMSIZE_TINY max_storage_space = 10 throwforce = 2 slot_flags = SLOT_BELT @@ -94,7 +94,7 @@ slot_l_hand_str = 'icons/mob/items/lefthand_cigs_lighters.dmi', slot_r_hand_str = 'icons/mob/items/righthand_cigs_lighters.dmi', ) - w_class = ITEMSIZE_SMALL + w_class = ITEMSIZE_TINY starts_with = list(/obj/item/cigarette_filter = 10) drop_sound = 'sound/items/drop/gloves.ogg' pickup_sound = 'sound/items/pickup/gloves.ogg' @@ -205,6 +205,7 @@ slot_l_hand_str = 'icons/mob/items/lefthand_cigs_lighters.dmi', slot_r_hand_str = 'icons/mob/items/righthand_cigs_lighters.dmi', ) + w_class = ITEMSIZE_TINY max_storage_space = 8 drop_sound = 'sound/items/drop/cardboardbox.ogg' pickup_sound = 'sound/items/pickup/cardboardbox.ogg' diff --git a/code/game/objects/items/weapons/storage/mre.dm b/code/game/objects/items/weapons/storage/mre.dm index 96f82f01c36..d2e4b93bea4 100644 --- a/code/game/objects/items/weapons/storage/mre.dm +++ b/code/game/objects/items/weapons/storage/mre.dm @@ -35,9 +35,9 @@ MRE Stuff /obj/item/storage/mre/attack_self(mob/user) open(user) -/obj/item/storage/box/fancy/mre/examine(mob/user) +/obj/item/storage/box/fancy/mre/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, meal_desc) + . += meal_desc /obj/item/storage/box/fancy/mre/menu2 name = "\improper MRE, menu 2" @@ -171,6 +171,20 @@ MRE Stuff /obj/item/storage/box/fancy/mre/menu11/special // antag item meal_desc = "This one doesn't have a menu listing. How odd. It has the initials \"A.B.\" written on the back." +/obj/item/storage/box/fancy/mre/menu12 + name = "k'ois MRE" + meal_desc = "This one is menu 12, k'ois. DO NOT CONSUME IF YOU ARE NOT VAURCA." + icon_state = "koismre" + main_meal = /obj/item/storage/box/fancy/mrebag/menu12 + starts_with = list( + /obj/item/storage/box/fancy/mrebag/dessert/menu12 = 1, + /obj/item/reagent_containers/food/snacks/koisbar_clean = 1, + /obj/random/mre/spread = 1, + /obj/random/mre/drink = 1, + /obj/item/reagent_containers/food/condiment/small/packet/phoron = 1, + /obj/item/material/kitchen/utensil/spork/plastic = 1 + ) + /obj/item/storage/box/fancy/mre/random meal_desc = "The menu label is faded out." main_meal = /obj/random/mre/main @@ -219,6 +233,9 @@ MRE Stuff /obj/item/storage/box/fancy/mrebag/menu10 starts_with = list(/obj/item/reagent_containers/food/snacks/meatcube = 1) +/obj/item/storage/box/fancy/mrebag/menu12 + starts_with = list(/obj/item/reagent_containers/food/snacks/koisjelly = 1) + /obj/item/storage/box/fancy/mrebag/dessert name = "dessert" desc = "A vacuum-sealed bag containing a MRE's dessert." @@ -232,3 +249,6 @@ MRE Stuff /obj/item/storage/box/fancy/mrebag/dessert/menu11 starts_with = list(/obj/item/pen/crayon/rainbow = 1) + +/obj/item/storage/box/fancy/mrebag/dessert/menu12 + starts_with = list(/obj/item/reagent_containers/food/snacks/friedkois = 1) diff --git a/code/game/objects/items/weapons/storage/secure.dm b/code/game/objects/items/weapons/storage/secure.dm index de93e173b54..452001862e5 100644 --- a/code/game/objects/items/weapons/storage/secure.dm +++ b/code/game/objects/items/weapons/storage/secure.dm @@ -28,34 +28,33 @@ max_storage_space = 16 use_sound = 'sound/items/storage/briefcase.ogg' -/obj/item/storage/secure/examine(mob/user, distance, is_adjacent) +/obj/item/storage/secure/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1) - to_chat(user, text("The service panel is [src.open ? "open" : "closed"].")) + . += "The service panel is [src.open ? "open" : "closed"]." -/obj/item/storage/secure/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/storage/secure/attackby(obj/item/attacking_item, mob/user) if(locked) - if (istype(W, /obj/item/melee/energy/blade) && emag_act(INFINITY, user, "You slice through the lock of \the [src]")) - var/obj/item/melee/energy/blade/blade = W + if (istype(attacking_item, /obj/item/melee/energy/blade) && emag_act(INFINITY, user, "You slice through the lock of \the [src]")) + var/obj/item/melee/energy/blade/blade = attacking_item blade.spark_system.queue() playsound(src.loc, 'sound/weapons/blade.ogg', 50, 1) playsound(src.loc, /singleton/sound_category/spark_sound, 50, 1) return - if (W.isscrewdriver()) - if(W.use_tool(src, user, 20, volume = 50)) + if (attacking_item.isscrewdriver()) + if(attacking_item.use_tool(src, user, 20, volume = 50)) src.open =! src.open to_chat(user, SPAN_NOTICE("You [src.open ? "open" : "close"] the service panel.")) return - if ((W.ismultitool()) && (src.open == 1)&& (!src.l_hacking)) + if ((attacking_item.ismultitool()) && (src.open == 1)&& (!src.l_hacking)) to_chat(user, SPAN_NOTICE("Now attempting to reset internal memory, please hold.")) src.l_hacking = 1 if (do_after(usr, 100)) if (prob(40)) src.l_setshort = 1 src.l_set = 0 - to_chat(user, SPAN_NOTICE("Internal memory reset. Please give it a few seconds to reinitialize.")) - sleep(80) + to_chat(user, SPAN_NOTICE("Internal memory reset.")) src.l_setshort = 0 src.l_hacking = 0 else diff --git a/code/game/objects/items/weapons/storage/storage.dm b/code/game/objects/items/weapons/storage/storage.dm index 91787291946..54ba9614a24 100644 --- a/code/game/objects/items/weapons/storage/storage.dm +++ b/code/game/objects/items/weapons/storage/storage.dm @@ -94,10 +94,110 @@ QDEL_NULL(closer) return ..() -/obj/item/storage/examine(mob/user) +/obj/item/storage/resolve_attackby(atom/A, mob/user, click_parameters) + . = ..() + + //Can't be used to pick up things by clicking them + if(!use_to_pickup) + return + + //Pick up everything in a tile + if(collection_mode) + var/turf/location_to_pickup = null + if(isturf(A)) + location_to_pickup = A + else + var/turf/possible_turf_location = get_turf(A) + if(isturf(possible_turf_location)) + location_to_pickup = possible_turf_location + + //If we found a turf, pick up things from there + if(location_to_pickup) + pickup_items_from_loc_and_feedback(user, location_to_pickup) + + //Pick up one thing at a time + else + if(can_be_inserted(A)) + handle_item_insertion(A, FALSE, user) + +/** + * Pick up item from a location, respecting the tick time, and feedback the user + * + * This process can sleep + * + * * user - The user trying to pick up things + * * location - A `/turf` to pick up things from + */ +/obj/item/storage/proc/pickup_items_from_loc_and_feedback(mob/user, turf/location) + set waitfor = FALSE + + //pickup_result[1] is if there's any success, pickup_result[2] is if there's any failure + //both are booleans + var/list/pickup_result = pickup_items_from_loc(user, location) + + //Choose the feedback message depending on what happened and send it to the user + var/pickup_feedback_message + if(pickup_result[1] && !pickup_result[2]) + pickup_feedback_message = SPAN_NOTICE("You put everything in \the [src].") + + else if(pickup_result[1] && pickup_result[2]) + pickup_feedback_message = SPAN_NOTICE("You put some things in \the [src].") + + else if(!pickup_result[1] && pickup_result[2]) + pickup_feedback_message = SPAN_NOTICE("You fail to pick anything up with \the [src].") + + //Check if we got a feedback message and, if so, send it to the user + if(pickup_feedback_message) + to_chat(user, pickup_feedback_message) + +/** + * Pick up item from a location, respecting the tick time + * + * Returns a `/list` in the format of `(SUCCESS, FAILURE)` (both booleans), + * the first indicates if there was any successful pickup, the later if there was any failed pickup + * + * * user - The user trying to pick up things + * * location - A `/turf` to pick up things from + */ +/obj/item/storage/proc/pickup_items_from_loc(mob/user, turf/location) + + //In the format of list(SUCCESS, FAILURE) + var/list/return_status = list(FALSE, FALSE) + RETURN_TYPE(return_status) + + var/list/rejections = list() + + //So we know where the user is when the pickup starts + var/original_location = user ? get_turf(user) : null + + for(var/obj/item/item in location) + if(rejections[item.type]) // To limit bag spamming: any given type only complains once + continue + + if (user && get_turf(user) != original_location) + break + + if(!can_be_inserted(item)) // Note can_be_inserted still makes noise when the answer is no + rejections[item.type] = TRUE // therefore full bags are still a little spammy + return_status[2] = TRUE + CHECK_TICK + continue + + return_status[1] = TRUE + handle_item_insertion_deferred(item, user) + CHECK_TICK // Because people insist on picking up huge-ass piles of stuff. + + //Refresh the icon, add fingerprints and whatnot if we have picked up anything + if(return_status[1]) + handle_storage_deferred(user) + + return return_status + + +/obj/item/storage/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(isobserver(user)) - to_chat(user, "It contains: [counting_english_list(contents)]") + . += "It contains: [counting_english_list(contents)]" /obj/item/storage/MouseDrop(obj/over_object) if(!canremove) @@ -385,64 +485,81 @@ src.slot_orient_objs(row_num, col_count, numbered_contents) return -//This proc return 1 if the item can be picked up and 0 if it can't. -//Set the stop_messages to stop it from printing messages -/obj/item/storage/proc/can_be_inserted(obj/item/W as obj, stop_messages = 0) - if(!istype(W)) return //Not an item +/** + * Checks if an item can be inserted in the storage + * + * Returns `TRUE` if it can be inserted, `FALSE` otherwise + * + * * item_to_check - The `/obj` to check if it can be inserted + * * stop_messages - Boolean, if `TRUE`, prevents this proc from giving feedback messages + */ +/obj/item/storage/proc/can_be_inserted(obj/item/item_to_check, stop_messages = FALSE) + SHOULD_NOT_SLEEP(TRUE) + + if(!istype(item_to_check)) + return FALSE + + if(usr && usr.isEquipped(item_to_check) && !usr.canUnEquip(item_to_check)) + return FALSE - if(usr && usr.isEquipped(W) && !usr.canUnEquip(W)) - return 0 + if(!item_to_check.dropsafety()) + return FALSE - if(!W.dropsafety()) - return 0 + //Check if the item is in the storage already + if(src.loc == item_to_check) + return FALSE - if(src.loc == W) - return 0 //Means the item is already in the storage item + //Check if the storage is full, or in blacklist if(storage_slots != null && contents.len >= storage_slots) - if(!stop_messages || is_type_in_list(W, pickup_blacklist)) // the is_type_in_list is a bit risky, but you tend to not want to pick up things in your blacklist anyway - to_chat(usr, "[src] is full, make some space.") - return 0 //Storage item is full + if(!stop_messages || is_type_in_list(item_to_check, pickup_blacklist)) // the is_type_in_list is a bit risky, but you tend to not want to pick up things in your blacklist anyway + to_chat(usr, SPAN_NOTICE("\The [src] is full, make some space.")) + return FALSE - if(W.anchored) - return 0 + //Check if the item is anchored + if(item_to_check.anchored) + return FALSE + //Whitelist check for item holding if(LAZYLEN(can_hold)) - var/can_hold_item = can_hold_strict ? (W.type in can_hold) : is_type_in_list(W, can_hold) + var/can_hold_item = can_hold_strict ? (item_to_check.type in can_hold) : is_type_in_list(item_to_check, can_hold) if(!can_hold_item) - if(!stop_messages && ! istype(W, /obj/item/device/hand_labeler)) - to_chat(usr, "[src] cannot hold \the [W].") - return 0 - var/max_instances = can_hold[W.type] - if(max_instances && instances_of_type_in_list(W, contents, TRUE) >= max_instances) - if(!stop_messages && !istype(W, /obj/item/device/hand_labeler)) - to_chat(usr, "[src] has no more space specifically for \the [W].") - return 0 - - if(LAZYLEN(cant_hold) && is_type_in_list(W, cant_hold)) + if(!stop_messages && ! istype(item_to_check, /obj/item/device/hand_labeler)) + to_chat(usr, SPAN_NOTICE("\The [src] cannot hold \the [item_to_check].")) + return FALSE + var/max_instances = can_hold[item_to_check.type] + if(max_instances && instances_of_type_in_list(item_to_check, contents, TRUE) >= max_instances) + if(!stop_messages && !istype(item_to_check, /obj/item/device/hand_labeler)) + to_chat(usr, SPAN_NOTICE("\The [src] has no more space specifically for \the [item_to_check].")) + return FALSE + + //Blacklist check for item holding + if(LAZYLEN(cant_hold) && is_type_in_list(item_to_check, cant_hold)) if(!stop_messages) - to_chat(usr, "[src] cannot hold [W].") - return 0 + to_chat(usr, SPAN_NOTICE("\The [src] cannot hold [item_to_check].")) + return FALSE - if (max_w_class != null && W.w_class > max_w_class) + //Size (lenght) check for item holding + if (max_w_class != null && item_to_check.w_class > max_w_class) if(!stop_messages) - to_chat(usr, "[W] is too long for this [src].") - return 0 + to_chat(usr, SPAN_NOTICE("\The [item_to_check] is too long for this [src].")) + return FALSE - var/total_storage_space = W.get_storage_cost() + var/total_storage_space = item_to_check.get_storage_cost() for(var/obj/item/I in contents) total_storage_space += I.get_storage_cost() //Adds up the combined w_classes which will be in the storage item if the item is added to it. if(total_storage_space > max_storage_space) if(!stop_messages) - to_chat(usr, "[src] is too full, make some space.") - return 0 + to_chat(usr, SPAN_NOTICE("\The [src] is too full, make some space.")) + return FALSE - if(W.w_class >= src.w_class && (istype(W, /obj/item/storage))) + //To prevent the stacking of same sized storage items + if(item_to_check.w_class >= src.w_class && (istype(item_to_check, /obj/item/storage))) if(!stop_messages) - to_chat(usr, "[src] cannot hold [W] as it's a storage item of the same size.") - return 0 //To prevent the stacking of same sized storage items. + to_chat(usr, SPAN_NOTICE("\The [src] cannot hold [item_to_check] as it's a storage item of the same size.")) + return FALSE - return 1 + return TRUE //This proc handles items being inserted. It does not perform any checks of whether an item can or can't be inserted. That's done by can_be_inserted() //The stop_warning parameter will stop the insertion message from being displayed. It is intended for cases where you are inserting multiple items at once, @@ -476,8 +593,13 @@ queue_icon_update() return 1 -// This is for inserting more than one thing at a time, you should call handle_storage_deferred after all the items have been inserted. +/** + * This is for inserting more than one thing at a time, + * you should call `handle_storage_deferred` after all the items have been inserted + */ /obj/item/storage/proc/handle_item_insertion_deferred(obj/item/W, mob/user) + SHOULD_NOT_SLEEP(TRUE) + if (!istype(W)) return FALSE @@ -584,14 +706,14 @@ return handle_item_insertion(W, prevent_messages) -/obj/item/storage/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/storage/attackby(obj/item/attacking_item, mob/user) ..() - if(!W.dropsafety()) + if(!attacking_item.dropsafety()) return. - if(istype(W, /obj/item/device/lightreplacer)) - var/obj/item/device/lightreplacer/LP = W + if(istype(attacking_item, /obj/item/device/lightreplacer)) + var/obj/item/device/lightreplacer/LP = attacking_item var/amt_inserted = 0 var/turf/T = get_turf(user) for(var/obj/item/light/L in src.contents) @@ -605,23 +727,23 @@ to_chat(user, "You inserted [amt_inserted] light\s into \the [LP.name]. You have [LP.uses] light\s remaining.") return - if(!can_be_inserted(W)) + if(!can_be_inserted(attacking_item)) return - if(istype(W, /obj/item/tray)) - var/obj/item/tray/T = W + if(istype(attacking_item, /obj/item/tray)) + var/obj/item/tray/T = attacking_item if(T.current_weight > 0) T.spill(user) to_chat(user, "Trying to place a loaded tray into [src] was a bad idea.") return - if(istype(W, /obj/item/device/hand_labeler)) - var/obj/item/device/hand_labeler/HL = W + if(istype(attacking_item, /obj/item/device/hand_labeler)) + var/obj/item/device/hand_labeler/HL = attacking_item if(HL.mode == 1) return - W.add_fingerprint(user) - return handle_item_insertion(W, null, user) + attacking_item.add_fingerprint(user) + return handle_item_insertion(attacking_item, null, user) /obj/item/storage/dropped(mob/user as mob) return ..() diff --git a/code/game/objects/items/weapons/stunbaton.dm b/code/game/objects/items/weapons/stunbaton.dm index b38d2188077..8b7c370deaf 100644 --- a/code/game/objects/items/weapons/stunbaton.dm +++ b/code/game/objects/items/weapons/stunbaton.dm @@ -59,26 +59,26 @@ else set_light(0) -/obj/item/melee/baton/examine(mob/user, distance) +/obj/item/melee/baton/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!distance <= 1) return if(bcell) - to_chat(user, "The baton is [round(bcell.percent())]% charged.") + . += "The baton is [round(bcell.percent())]% charged." else - to_chat(user, "The baton does not have a power source installed.") + . += "The baton does not have a power source installed." -/obj/item/melee/baton/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/cell)) +/obj/item/melee/baton/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/cell)) if(!bcell) - user.drop_from_inventory(W,src) - bcell = W + user.drop_from_inventory(attacking_item, src) + bcell = attacking_item to_chat(user, "You install a cell in [src].") update_icon() else to_chat(user, "[src] already has a cell.") - else if(W.isscrewdriver()) + else if(attacking_item.isscrewdriver()) if(bcell) bcell.update_icon() bcell.forceMove(get_turf(src)) @@ -215,7 +215,7 @@ bcell = R.cell return ..() -/obj/item/melee/baton/robot/attackby(obj/item/W, mob/user) +/obj/item/melee/baton/robot/attackby(obj/item/attacking_item, mob/user) return /obj/item/melee/baton/robot/arm diff --git a/code/game/objects/items/weapons/surgery_tools.dm b/code/game/objects/items/weapons/surgery_tools.dm index 2dd358c129b..7e6e47a5e11 100644 --- a/code/game/objects/items/weapons/surgery_tools.dm +++ b/code/game/objects/items/weapons/surgery_tools.dm @@ -269,7 +269,7 @@ . = ..() update_icon() -/obj/item/storage/box/fancy/tray/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/storage/box/fancy/tray/attackby(obj/item/attacking_item, mob/user) ..() update_icon() diff --git a/code/game/objects/items/weapons/syndie.dm b/code/game/objects/items/weapons/syndie.dm index c43bda6ab12..786ecf7045a 100644 --- a/code/game/objects/items/weapons/syndie.dm +++ b/code/game/objects/items/weapons/syndie.dm @@ -120,10 +120,10 @@ var/recharge_time = 1 MINUTE var/when_recharge = 0 -/obj/item/syndie/teleporter/examine(mob/user, distance) +/obj/item/syndie/teleporter/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!ready_to_use && burglars.is_antagonist(user.mind)) - to_chat(user, SPAN_NOTICE("Charging: [num2loadingbar(world.time / when_recharge)]")) + . += SPAN_NOTICE("Charging: [num2loadingbar(world.time / when_recharge)]") /obj/item/syndie/teleporter/set_initial_maptext() held_maptext = SMALL_FONTS(7, "Ready") diff --git a/code/game/objects/items/weapons/tanks/jetpack.dm b/code/game/objects/items/weapons/tanks/jetpack.dm index 4ed94a43876..5bbb718d6c0 100644 --- a/code/game/objects/items/weapons/tanks/jetpack.dm +++ b/code/game/objects/items/weapons/tanks/jetpack.dm @@ -45,10 +45,10 @@ var/volume_rate = 500 //Needed for borg jetpack transfer action_button_name = "Toggle Jetpack" -/obj/item/tank/jetpack/examine(mob/user) +/obj/item/tank/jetpack/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(air_contents.total_moles < 5) - to_chat(user, "The meter on \the [src] indicates you are almost out of gas!") + . += SPAN_NOTICE("The meter on \the [src] indicates you are almost out of gas!") /obj/item/tank/jetpack/verb/toggle_rockets() set name = "Toggle Jetpack Stabilization" @@ -187,10 +187,6 @@ holder = null . = ..() -/obj/item/tank/jetpack/rig/examine() - to_chat(usr, "It's a jetpack. If you can see this, report it on the bug tracker.") - return TRUE - /obj/item/tank/jetpack/rig/allow_thrust(num, mob/living/user as mob) if(!(src.on)) diff --git a/code/game/objects/items/weapons/tanks/tank_types.dm b/code/game/objects/items/weapons/tanks/tank_types.dm index 80c9ee91d39..613881667fe 100644 --- a/code/game/objects/items/weapons/tanks/tank_types.dm +++ b/code/game/objects/items/weapons/tanks/tank_types.dm @@ -21,10 +21,10 @@ /obj/item/tank/oxygen/adjust_initial_gas() air_contents.adjust_gas(GAS_OXYGEN, (6*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)) -/obj/item/tank/oxygen/examine(mob/user, distance, is_adjacent) +/obj/item/tank/oxygen/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if((is_adjacent) && air_contents.gas[GAS_OXYGEN] < 10) - to_chat(user, text("The meter on \the [src] indicates you are almost out of oxygen!")) + . += SPAN_WARNING("The meter on \the [src] indicates you are almost out of oxygen!") /obj/item/tank/oxygen/yellow desc = "A tank of oxygen, this one is yellow." @@ -76,10 +76,10 @@ /obj/item/tank/air/adjust_initial_gas() air_contents.adjust_multi(GAS_OXYGEN, (6*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C) * O2STANDARD, GAS_NITROGEN, (6*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C) * N2STANDARD) -/obj/item/tank/air/examine(mob/user, distance, is_adjacent) +/obj/item/tank/air/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if((is_adjacent) && air_contents.gas[GAS_OXYGEN] < 1 && loc==user) - to_chat(user, "The meter on the [src.name] indicates you are almost out of air!") + . += SPAN_WARNING("The meter on the [src.name] indicates you are almost out of air!") /* * Phoron @@ -99,11 +99,11 @@ /obj/item/tank/phoron/shuttle/adjust_initial_gas() air_contents.adjust_gas(GAS_PHORON, 4*(3*ONE_ATMOSPHERE)*70/(R_IDEAL_GAS_EQUATION*T20C)) -/obj/item/tank/phoron/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/tank/phoron/attackby(obj/item/attacking_item, mob/user) ..() - if (istype(W, /obj/item/flamethrower)) - var/obj/item/flamethrower/F = W + if (istype(attacking_item, /obj/item/flamethrower)) + var/obj/item/flamethrower/F = attacking_item if ((!F.secured)||(F.gas_tank)) return src.master = F F.gas_tank = src @@ -148,10 +148,10 @@ /obj/item/tank/emergency_oxygen/adjust_initial_gas() air_contents.adjust_gas(GAS_OXYGEN, (3*ONE_ATMOSPHERE)*volume/(R_IDEAL_GAS_EQUATION*T20C)) -/obj/item/tank/emergency_oxygen/examine(mob/user, distance, is_adjacent) +/obj/item/tank/emergency_oxygen/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if((is_adjacent) && air_contents.gas[GAS_OXYGEN] < 0.2 && loc==user) - to_chat(user, text("The meter on the [src.name] indicates you are almost out of air!")) + . += SPAN_WARNING("The meter on the [src.name] indicates you are almost out of air!") /obj/item/tank/emergency_oxygen/engi name = "extended-capacity emergency oxygen tank" diff --git a/code/game/objects/items/weapons/tanks/tanks.dm b/code/game/objects/items/weapons/tanks/tanks.dm index fa9e4ec1047..b7ff0078f34 100644 --- a/code/game/objects/items/weapons/tanks/tanks.dm +++ b/code/game/objects/items/weapons/tanks/tanks.dm @@ -47,7 +47,7 @@ return ..() -/obj/item/tank/examine(mob/user, distance, is_adjacent) +/obj/item/tank/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 0) var/celsius_temperature = air_contents.temperature - T0C @@ -65,21 +65,21 @@ descriptive = "room temperature" else descriptive = "cold" - to_chat(user, "\The [src] feels [descriptive].") + . += SPAN_NOTICE("\The [src] feels [descriptive].") -/obj/item/tank/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/tank/attackby(obj/item/attacking_item, mob/user) ..() - if ((istype(W, /obj/item/device/analyzer)) && get_dist(user, src) <= 1) - var/obj/item/device/analyzer/A = W + if ((istype(attacking_item, /obj/item/device/analyzer)) && get_dist(user, src) <= 1) + var/obj/item/device/analyzer/A = attacking_item A.analyze_gases(src, user) - if (istype(W, /obj/item/toy/balloon)) - var/obj/item/toy/balloon/B = W + if (istype(attacking_item, /obj/item/toy/balloon)) + var/obj/item/toy/balloon/B = attacking_item B.blow(src) src.add_fingerprint(user) - if(istype(W, /obj/item/device/assembly_holder)) - bomb_assemble(W,user) + if(istype(attacking_item, /obj/item/device/assembly_holder)) + bomb_assemble(attacking_item, user) /obj/item/tank/attack_self(mob/user as mob) if (!(src.air_contents)) diff --git a/code/game/objects/items/weapons/tanks/watertank.dm b/code/game/objects/items/weapons/tanks/watertank.dm index f6fafb49873..8b1b5f81f38 100644 --- a/code/game/objects/items/weapons/tanks/watertank.dm +++ b/code/game/objects/items/weapons/tanks/watertank.dm @@ -83,8 +83,8 @@ noz = null return ..() -/obj/item/watertank/attackby(obj/item/W, mob/user, params) - if(W == noz) +/obj/item/watertank/attackby(obj/item/attacking_item, mob/user, params) + if(attacking_item == noz) remove_noz() return TRUE else diff --git a/code/game/objects/items/weapons/teleportation.dm b/code/game/objects/items/weapons/teleportation.dm index cac7ce21fce..e4922c82829 100644 --- a/code/game/objects/items/weapons/teleportation.dm +++ b/code/game/objects/items/weapons/teleportation.dm @@ -158,13 +158,13 @@ Frequency: var/max_portals = 2 -/obj/item/hand_tele/examine(mob/user, distance) +/obj/item/hand_tele/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(linked_pad) var/area/A = get_area(linked_pad) - to_chat(user, SPAN_NOTICE("\The [src] is linked to a teleportation pad in [A.name]")) + . += SPAN_NOTICE("\The [src] is linked to a teleportation pad in [A.name]") else - to_chat(user, SPAN_WARNING("\The [src] isn't linked to any teleportation pads!")) + . += SPAN_WARNING("\The [src] isn't linked to any teleportation pads!") /obj/item/hand_tele/set_initial_maptext() held_maptext = SMALL_FONTS(7, "Ready") diff --git a/code/game/objects/items/weapons/tools.dm b/code/game/objects/items/weapons/tools.dm index 93aba450b13..73a705cb34a 100644 --- a/code/game/objects/items/weapons/tools.dm +++ b/code/game/objects/items/weapons/tools.dm @@ -339,13 +339,13 @@ STOP_PROCESSING(SSprocessing, src) return ..() -/obj/item/weldingtool/examine(mob/user, distance, is_adjacent) +/obj/item/weldingtool/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 0) - to_chat(user, text("[icon2html(src, user)] [] contains []/[] units of fuel!", src.name, get_fuel(),src.max_fuel )) + . += "It contains [get_fuel()]/[max_fuel] units of fuel." -/obj/item/weldingtool/attackby(obj/item/W, mob/user) - if(W.isscrewdriver()) +/obj/item/weldingtool/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(isrobot(loc)) to_chat(user, SPAN_ALERT("You cannot modify your own welder!")) return TRUE @@ -360,8 +360,8 @@ add_fingerprint(user) return TRUE - if(!status && (istype(W, /obj/item/stack/rods))) - var/obj/item/stack/rods/R = W + if(!status && (istype(attacking_item, /obj/item/stack/rods))) + var/obj/item/stack/rods/R = attacking_item R.use(1) add_fingerprint(user) user.drop_from_inventory(src) @@ -576,28 +576,28 @@ STOP_PROCESSING(SSprocessing, src) //Stop processing when destroyed regardless of conditions return ..() -/obj/item/weldingtool/experimental/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/eyeshield)) +/obj/item/weldingtool/experimental/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/eyeshield)) if(eyeshield) to_chat(user, SPAN_WARNING("\The [src] already has an eye shield installed!")) return TRUE - user.drop_from_inventory(I, src) - to_chat(user, SPAN_NOTICE("You install \the [I] into \the [src].")) - eyeshield = I + user.drop_from_inventory(attacking_item, src) + to_chat(user, SPAN_NOTICE("You install \the [attacking_item] into \the [src].")) + eyeshield = attacking_item produces_flash = FALSE add_overlay("eyeshield_attached", TRUE) return TRUE - if(istype(I, /obj/item/overcapacitor)) + if(istype(attacking_item, /obj/item/overcapacitor)) if(overcap) to_chat(user, SPAN_WARNING("\The [src] already has an overcapacitor installed!")) return TRUE - user.drop_from_inventory(I, src) - to_chat(user, SPAN_NOTICE("You install \the [I] into \the [src].")) - overcap = I + user.drop_from_inventory(attacking_item, src) + to_chat(user, SPAN_NOTICE("You install \the [attacking_item] into \the [src].")) + overcap = attacking_item add_overlay("overcap_attached", TRUE) toolspeed *= 2 return TRUE - if(I.isscrewdriver()) + if(attacking_item.isscrewdriver()) if(!eyeshield && !overcap) to_chat(user, SPAN_WARNING("\The [src] doesn't have any accessories to remove!")) return TRUE @@ -795,10 +795,10 @@ tools[tool] = image('icons/obj/tools.dmi', icon_state = "[icon_state]-[tool]") . = ..() -/obj/item/combitool/examine(var/mob/user) +/obj/item/combitool/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(tools.len) - to_chat(user, "It has the following fittings: [english_list(tools)].") + . += "It has the following fittings: [english_list(tools)]." /obj/item/combitool/iswrench() return current_tool == "wrench" @@ -854,12 +854,12 @@ /obj/item/powerdrill/set_initial_maptext() held_maptext = SMALL_FONTS(7, "S") -/obj/item/powerdrill/examine(var/mob/user) +/obj/item/powerdrill/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(tools.len) - to_chat(user, "It has the following fittings:") + . += "It has the following fittings:" for(var/tool in tools) - to_chat(user, "- [tool][tools[current_tool] == tool ? " (selected)" : ""]") + . += "- [tool][tools[current_tool] == tool ? " (selected)" : ""]" /obj/item/powerdrill/MouseEntered(location, control, params) . = ..() @@ -916,14 +916,14 @@ /obj/item/steelwool/isFlameSource() return lit -/obj/item/steelwool/attackby(obj/item/W, mob/user) - if(W.isFlameSource()) - ignite(W, user) +/obj/item/steelwool/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isFlameSource()) + ignite(attacking_item, user) return TRUE - else if(istype(W, /obj/item/cell)) - var/obj/item/cell/S = W + else if(istype(attacking_item, /obj/item/cell)) + var/obj/item/cell/S = attacking_item if(S.charge) - ignite(W, user) + ignite(attacking_item, user) else to_chat(user, SPAN_WARNING("The cell isn't charged!")) return TRUE diff --git a/code/game/objects/items/weapons/traps.dm b/code/game/objects/items/weapons/traps.dm index 73b1a11b4b4..982b58d37cb 100644 --- a/code/game/objects/items/weapons/traps.dm +++ b/code/game/objects/items/weapons/traps.dm @@ -195,17 +195,17 @@ /obj/item/trap/animal/update_icon() icon_state = "[icon_base][deployed]" -/obj/item/trap/animal/examine(mob/user) +/obj/item/trap/animal/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(captured) var/datum/L = captured.resolve() if (L) - to_chat(user, "[L] is trapped inside!") + . += SPAN_WARNING("[L] is trapped inside!") return else if(deployed) - to_chat(user, SPAN_WARNING("It's set up and ready to capture something.")) + . += SPAN_WARNING("It's set up and ready to capture something.") else - to_chat(user, "\The [src] is empty and un-deployed.") + . += SPAN_NOTICE("\The [src] is empty and un-deployed.") /obj/item/trap/animal/Crossed(atom/movable/AM) if(!deployed || !anchored) @@ -373,9 +373,9 @@ release_time = world.time layer = initial(layer) -/obj/item/trap/animal/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/grab)) - var/obj/item/grab/G = W +/obj/item/trap/animal/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/grab)) + var/obj/item/grab/G = attacking_item var/mob/living/M = G.affecting if (G.state == GRAB_PASSIVE || G.state == GRAB_UPGRADING) @@ -393,8 +393,8 @@ return capture(M) - else if(W.iswelder()) - var/obj/item/weldingtool/WT = W + else if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) to_chat(user, SPAN_WARNING("\The [WT] is off!")) return @@ -411,7 +411,7 @@ release(user) qdel(src) - else if(W.isscrewdriver()) + else if(attacking_item.isscrewdriver()) var/turf/T = get_turf(src) if(!T) to_chat(user, "There is nothing to secure [src] to!") @@ -422,7 +422,7 @@ var/sound_to_play = pick(list('sound/items/Screwdriver.ogg', 'sound/items/Screwdriver2.ogg')) playsound(src.loc, sound_to_play, 50, 1) - if(W.use_tool(src, user, 30, volume = 50)) + if(attacking_item.use_tool(src, user, 30, volume = 50)) density = !density anchored = !anchored user.visible_message("[user] [anchored ? "" : "un" ]secures \the [src]!", @@ -588,8 +588,8 @@ else ..() -/obj/item/trap/animal/large/attackby(obj/item/W, mob/user) - if(W.iswrench()) +/obj/item/trap/animal/large/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswrench()) var/turf/T = get_turf(src) if(!T) to_chat(user, "There is nothing to secure [src] to!") @@ -602,12 +602,12 @@ user.visible_message("[user] begins [anchored ? "un" : "" ]securing \the [src]!", "You begin [anchored ? "un" : "" ]securing \the [src]!") - if(W.use_tool(src, user, 30, volume = 50)) + if(attacking_item.use_tool(src, user, 30, volume = 50)) anchored = !anchored user.visible_message("[user] [anchored ? "" : "un" ]secures \the [src]!", "You [anchored ? "" : "un" ]secure \the [src]!") - else if(W.isscrewdriver()) + else if(attacking_item.isscrewdriver()) // Unlike smaller traps, screwdriver shouldn't work on this. return else @@ -647,9 +647,9 @@ force = 5 w_class = ITEMSIZE_HUGE -/obj/item/large_trap_foundation/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/stack/rods)) - var/obj/item/stack/rods/O = W +/obj/item/large_trap_foundation/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stack/rods)) + var/obj/item/stack/rods/O = attacking_item if(O.get_amount() >= 12) to_chat(user, "You are trying to add metal bars to \the [src].") @@ -664,7 +664,7 @@ return else to_chat(user, "You need at least 12 rods to complete \the [src].") - else if(istype(W, /obj/item/screwdriver)) + else if(istype(attacking_item, /obj/item/screwdriver)) return else ..() @@ -796,10 +796,11 @@ victim.visible_message(SPAN_ALERT("You notice something written on a plate inside the trap:
")+SPAN_BAD(message)) -/obj/item/trap/punji/examine(mob/user, distance) +/obj/item/trap/punji/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(src.message && distance < 3) - to_chat(user, SPAN_ALERT("You notice something written on a plate inside the trap:
")+SPAN_BAD(message)) + . += SPAN_ALERT("You notice something written on a plate inside the trap:") + . += SPAN_BAD(message) /obj/item/trap/punji/verb/hide_under() set src in oview(1) diff --git a/code/game/objects/items/weapons/vaurca_items.dm b/code/game/objects/items/weapons/vaurca_items.dm index 4fe24474e18..eb9ac9ff62d 100644 --- a/code/game/objects/items/weapons/vaurca_items.dm +++ b/code/game/objects/items/weapons/vaurca_items.dm @@ -524,11 +524,11 @@ else to_chat(user, "[src] is empty.") -/obj/item/gun/launcher/crossbow/vaurca/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/arrow)) - load(I, user) - if(istype(I, /obj/item/stack/rods)) - var/obj/item/stack/rods/R = I +/obj/item/gun/launcher/crossbow/vaurca/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/arrow)) + load(attacking_item, user) + if(istype(attacking_item, /obj/item/stack/rods)) + var/obj/item/stack/rods/R = attacking_item if (R.use(1)) var/obj/item/arrow/rod/ROD = new /obj/item/arrow/rod(src) load(ROD, user) diff --git a/code/game/objects/items/weapons/weaponry.dm b/code/game/objects/items/weapons/weaponry.dm index 6b5332862c7..f493f334d58 100644 --- a/code/game/objects/items/weapons/weaponry.dm +++ b/code/game/objects/items/weapons/weaponry.dm @@ -104,9 +104,9 @@ user.visible_message(SPAN_WARNING("\The [user] claws at \the [src]!"), SPAN_WARNING("You claw at \the [src]!")) health_check() -/obj/effect/energy_net/attackby(obj/item/W, mob/user) - user.do_attack_animation(src, W) - var/attack_force = W.force +/obj/effect/energy_net/attackby(obj/item/attacking_item, mob/user) + user.do_attack_animation(src, attacking_item) + var/attack_force = attacking_item.force if(user == affecting) attack_force /= 2 health -= attack_force diff --git a/code/game/objects/objs.dm b/code/game/objects/objs.dm index e000adfd28e..bfb33490395 100644 --- a/code/game/objects/objs.dm +++ b/code/game/objects/objs.dm @@ -239,12 +239,12 @@ return ..() -/obj/examine(mob/user) +/obj/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if((obj_flags & OBJ_FLAG_ROTATABLE) || (obj_flags & OBJ_FLAG_ROTATABLE_ANCHORED)) - to_chat(user, SPAN_SUBTLE("Can be rotated with alt-click.")) + . += SPAN_SUBTLE("Can be rotated with alt-click.") if(contaminated) - to_chat(user, SPAN_ALIEN("\The [src] has been contaminated!")) + . += SPAN_ALIEN("\The [src] has been contaminated!") // whether mobs can unequip and drop items into us or not /obj/proc/can_hold_dropped_items() diff --git a/code/game/objects/random/loot.dm b/code/game/objects/random/loot.dm index e16d32ae250..3e6b1c596d2 100644 --- a/code/game/objects/random/loot.dm +++ b/code/game/objects/random/loot.dm @@ -119,6 +119,7 @@ /obj/item/storage/box/lights/colored/yellow = 0.1, /obj/item/storage/box/lights/coloredmixed = 0.2, /obj/item/storage/box/masks = 0.5, + /obj/item/storage/box/cleaner_tablets = 0.4, /obj/item/storage/box/mousetraps = 0.3, /obj/item/storage/box/pineapple = 0.1, /obj/item/storage/box/smokebombs = 0.1, @@ -161,6 +162,7 @@ /obj/item/device/synthesized_instrument/violin = 0.1, /obj/item/device/synthesized_instrument/guitar = 1, /obj/item/device/synthesized_instrument/trumpet = 0.25, + /obj/item/reagent_containers/pill/cleaner_tablet = 0.6, /obj/item/storage/box/fancy/food/pralinebox = 0.1 ) diff --git a/code/game/objects/structures/barricades/_barricade.dm b/code/game/objects/structures/barricades/_barricade.dm index ee8994f4e65..db5016f9769 100644 --- a/code/game/objects/structures/barricades/_barricade.dm +++ b/code/game/objects/structures/barricades/_barricade.dm @@ -31,20 +31,20 @@ update_icon() starting_maxhealth = maxhealth -/obj/structure/barricade/examine(mob/user) +/obj/structure/barricade/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, SPAN_INFO("It is recommended to stand flush to a barricade or one tile away for maximum efficiency.")) + . += SPAN_INFO("It is recommended to stand flush to a barricade or one tile away for maximum efficiency.") if(is_wired) - to_chat(user, SPAN_INFO("There is a length of wire strewn across the top of this barricade.")) + . += SPAN_INFO("There is a length of wire strewn across the top of this barricade.") switch(damage_state) if(BARRICADE_DMG_NONE) - to_chat(user, SPAN_INFO("It appears to be in good shape.")) + . += SPAN_INFO("It appears to be in good shape.") if(BARRICADE_DMG_SLIGHT) - to_chat(user, SPAN_WARNING("It's slightly damaged, but still very functional.")) + . += SPAN_WARNING("It's slightly damaged, but still very functional.") if(BARRICADE_DMG_MODERATE) - to_chat(user, SPAN_WARNING("It's quite beat up, but it's holding together.")) + . += SPAN_WARNING("It's quite beat up, but it's holding together.") if(BARRICADE_DMG_HEAVY) - to_chat(user, SPAN_WARNING("It's crumbling apart, just a few more blows will tear it apart!")) + . += SPAN_WARNING("It's crumbling apart, just a few more blows will tear it apart!") /obj/structure/barricade/update_icon() overlays.Cut() @@ -142,20 +142,20 @@ L.do_attack_animation(src) take_damage(damage) -/obj/structure/barricade/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/stack/barbed_wire)) - var/obj/item/stack/barbed_wire/B = W +/obj/structure/barricade/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stack/barbed_wire)) + var/obj/item/stack/barbed_wire/B = attacking_item if(can_wire) - user.visible_message(SPAN_NOTICE("[user] starts setting up [W.name] on [src]."), - SPAN_NOTICE("You start setting up [W.name] on [src].")) + user.visible_message(SPAN_NOTICE("[user] starts setting up [attacking_item.name] on [src]."), + SPAN_NOTICE("You start setting up [attacking_item.name] on [src].")) if(do_after(user, 20, src, DO_REPAIR_CONSTRUCT) && can_wire) // Make sure there's still enough wire in the stack if(!B.use(1)) return playsound(src.loc, 'sound/effects/barbed_wire_movement.ogg', 25, 1) - user.visible_message(SPAN_NOTICE("[user] sets up [W.name] on [src]."), - SPAN_NOTICE("You set up [W.name] on [src].")) + user.visible_message(SPAN_NOTICE("[user] sets up [attacking_item.name] on [src]."), + SPAN_NOTICE("You set up [attacking_item.name] on [src].")) maxhealth += 50 update_health(-50) @@ -165,7 +165,7 @@ update_icon() return - if(W.iswirecutter()) + if(attacking_item.iswirecutter()) if(is_wired) user.visible_message(SPAN_NOTICE("[user] begin removing the barbed wire on [src]."), SPAN_NOTICE("You begin removing the barbed wire on [src].")) @@ -185,11 +185,11 @@ new /obj/item/stack/barbed_wire(loc) return - if((W.force + W.armor_penetration) > force_level_absorption) + if((attacking_item.force + attacking_item.armor_penetration) > force_level_absorption) ..() if(barricade_hitsound) playsound(src, barricade_hitsound, 25, 1) - hit_barricade(W, user) + hit_barricade(attacking_item, user) /obj/structure/barricade/bullet_act(obj/item/projectile/P) bullet_ping(P) diff --git a/code/game/objects/structures/barricades/liquid.dm b/code/game/objects/structures/barricades/liquid.dm index 204875591b9..4cee55999e9 100644 --- a/code/game/objects/structures/barricades/liquid.dm +++ b/code/game/objects/structures/barricades/liquid.dm @@ -54,9 +54,9 @@ if(changed && is_wired) maxhealth += 50 -/obj/structure/barricade/liquid/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/crowbar) && user.a_intent != I_HURT) - var/obj/item/crowbar/ET = W +/obj/structure/barricade/liquid/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/crowbar) && user.a_intent != I_HURT) + var/obj/item/crowbar/ET = attacking_item user.visible_message(SPAN_NOTICE("[user] starts disassembling [src]."), \ SPAN_NOTICE("You start disassembling [src].")) if(ET.use_tool(src, user, 4 SECONDS)) @@ -65,8 +65,8 @@ barricade_deconstruct(TRUE) return TRUE - if(istype(W, stack_type)) - var/obj/item/stack/liquidbags/SB = W + if(istype(attacking_item, stack_type)) + var/obj/item/stack/liquidbags/SB = attacking_item if(build_stage == BARRICADE_LIQUIDBAG_5) to_chat(user, SPAN_WARNING("You can't stack more on [src].")) return diff --git a/code/game/objects/structures/barricades/metal.dm b/code/game/objects/structures/barricades/metal.dm index 87d3d0834bc..33886d790ac 100644 --- a/code/game/objects/structures/barricades/metal.dm +++ b/code/game/objects/structures/barricades/metal.dm @@ -14,19 +14,19 @@ can_wire = TRUE var/build_state = BARRICADE_BSTATE_SECURED //Look at __game.dm for barricade defines -/obj/structure/barricade/metal/examine(mob/user) +/obj/structure/barricade/metal/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() switch(build_state) if(BARRICADE_BSTATE_SECURED) - to_chat(user, SPAN_INFO("The protection panel is still tighly screwed in place.")) + . += SPAN_INFO("The protection panel is still tighly screwed in place.") if(BARRICADE_BSTATE_UNSECURED) - to_chat(user, SPAN_INFO("The protection panel has been removed, you can see the anchor bolts.")) + . += SPAN_INFO("The protection panel has been removed, you can see the anchor bolts.") if(BARRICADE_BSTATE_MOVABLE) - to_chat(user, SPAN_INFO("The protection panel has been removed and the anchor bolts loosened. It's ready to be taken apart.")) + . += SPAN_INFO("The protection panel has been removed and the anchor bolts loosened. It's ready to be taken apart.") -/obj/structure/barricade/metal/attackby(obj/item/W, mob/user) - if(W.iswelder()) - var/obj/item/weldingtool/WT = W +/obj/structure/barricade/metal/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(damage_state == BARRICADE_DMG_HEAVY) to_chat(user, SPAN_WARNING("[src] has sustained too much structural damage to be repaired.")) return @@ -40,8 +40,8 @@ switch(build_state) if(BARRICADE_BSTATE_SECURED) //Fully constructed step. Use screwdriver to remove the protection panels to reveal the bolts - if(W.isscrewdriver()) - if(!W.use_tool(src, user, 1 SECOND, volume = 40)) + if(attacking_item.isscrewdriver()) + if(!attacking_item.use_tool(src, user, 1 SECOND, volume = 40)) return user.visible_message(SPAN_NOTICE("[user] removes [src]'s protection panel."), SPAN_NOTICE("You remove [src]'s protection panels, exposing the anchor bolts.")) @@ -49,15 +49,15 @@ return if(BARRICADE_BSTATE_UNSECURED) //Protection panel removed step. Screwdriver to put the panel back, wrench to unsecure the anchor bolts - if(W.isscrewdriver()) - if(!W.use_tool(src, user, 2 SECONDS, volume = 40)) + if(attacking_item.isscrewdriver()) + if(!attacking_item.use_tool(src, user, 2 SECONDS, volume = 40)) return user.visible_message(SPAN_NOTICE("[user] screws \the [src]'s protection panel back."), SPAN_NOTICE("You screw \the [src]'s protection panel back.")) build_state = BARRICADE_BSTATE_SECURED return - if(W.iswrench()) - if(!W.use_tool(src, user, 1 SECOND, volume = 40)) + if(attacking_item.iswrench()) + if(!attacking_item.use_tool(src, user, 1 SECOND, volume = 40)) return user.visible_message(SPAN_NOTICE("[user] loosens [src]'s anchor bolts."), SPAN_NOTICE("You loosen [src]'s anchor bolts.")) @@ -66,7 +66,7 @@ update_icon() //unanchored changes layer return if(BARRICADE_BSTATE_MOVABLE) //Anchor bolts loosened step. Apply crowbar to unseat the panel and take apart the whole thing. Apply wrench to resecure anchor bolts - if(W.iswrench()) + if(attacking_item.iswrench()) for(var/obj/structure/barricade/B in loc) if(B != src && B.dir == dir) to_chat(user, SPAN_WARNING("There's already a barricade here.")) @@ -75,7 +75,7 @@ if(!(istype(T)) || istype(T, /turf/space)) to_chat(user, SPAN_WARNING("[src] must be secured on a proper surface!")) return - if(!W.use_tool(src, user, 1 SECOND, volume = 50)) + if(!attacking_item.use_tool(src, user, 1 SECOND, volume = 50)) return user.visible_message(SPAN_NOTICE("[user] secures [src]'s anchor bolts."), SPAN_NOTICE("You secure [src]'s anchor bolts.")) @@ -83,10 +83,10 @@ anchored = TRUE update_icon() //unanchored changes layer return - if(W.iscrowbar()) + if(attacking_item.iscrowbar()) user.visible_message(SPAN_NOTICE("[user] starts unseating [src]'s panels."), SPAN_NOTICE("You start unseating [src]'s panels.")) - if(W.use_tool(src, user, 3 SECONDS, volume = 40)) + if(attacking_item.use_tool(src, user, 3 SECONDS, volume = 40)) user.visible_message(SPAN_NOTICE("[user] takes [src]'s panels apart."), SPAN_NOTICE("You take [src]'s panels apart.")) barricade_deconstruct(TRUE) //Note : Handles deconstruction too ! diff --git a/code/game/objects/structures/barricades/plasteel.dm b/code/game/objects/structures/barricades/plasteel.dm index ff9f8bf6992..83d014edc1f 100644 --- a/code/game/objects/structures/barricades/plasteel.dm +++ b/code/game/objects/structures/barricades/plasteel.dm @@ -42,28 +42,27 @@ else return 0 -/obj/structure/barricade/plasteel/examine(mob/user) +/obj/structure/barricade/plasteel/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - switch(build_state) if(BARRICADE_BSTATE_SECURED) - to_chat(user, SPAN_INFO("The protection panel is still tighly screwed in place.")) + . += SPAN_INFO("The protection panel is still tighly screwed in place.") if(BARRICADE_BSTATE_UNSECURED) - to_chat(user, SPAN_INFO("The protection panel has been removed, you can see the anchor bolts.")) + . += SPAN_INFO("The protection panel has been removed, you can see the anchor bolts.") if(BARRICADE_BSTATE_MOVABLE) - to_chat(user, SPAN_INFO("The protection panel has been removed and the anchor bolts loosened. It's ready to be taken apart.")) + . += SPAN_INFO("The protection panel has been removed and the anchor bolts loosened. It's ready to be taken apart.") /obj/structure/barricade/plasteel/weld_cade(obj/item/W, mob/user) busy = TRUE ..() busy = FALSE -/obj/structure/barricade/plasteel/attackby(obj/item/W, mob/user) - if(W.iswelder()) +/obj/structure/barricade/plasteel/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswelder()) if(busy || tool_cooldown > world.time) return tool_cooldown = world.time + 10 - var/obj/item/weldingtool/WT = W + var/obj/item/weldingtool/WT = attacking_item if(damage_state == BARRICADE_DMG_HEAVY) to_chat(user, SPAN_WARNING("[src] has sustained too much structural damage to be repaired.")) return @@ -77,7 +76,7 @@ switch(build_state) if(2) //Fully constructed step. Use screwdriver to remove the protection panels to reveal the bolts - if(W.isscrewdriver()) + if(attacking_item.isscrewdriver()) if(busy || tool_cooldown > world.time) return tool_cooldown = world.time + 10 @@ -85,13 +84,13 @@ if(B != src && B.dir == dir) to_chat(user, SPAN_WARNING("There's already a barricade here.")) return - if(!W.use_tool(src, user, 10, volume = 50)) + if(!attacking_item.use_tool(src, user, 10, volume = 50)) return user.visible_message(SPAN_NOTICE("[user] removes [src]'s protection panel."), SPAN_NOTICE("You remove [src]'s protection panels, exposing the anchor bolts.")) build_state = BARRICADE_BSTATE_UNSECURED return - if(W.iscrowbar()) + if(attacking_item.iscrowbar()) playsound(src.loc, 'sound/items/crowbar_pry.ogg', 25, 1) if(linked) user.visible_message(SPAN_NOTICE("[user] removes the linking on [src]."), @@ -108,20 +107,20 @@ cade.update_icon() update_icon() if(1) //Protection panel removed step. Screwdriver to put the panel back, wrench to unsecure the anchor bolts - if(W.isscrewdriver()) + if(attacking_item.isscrewdriver()) if(busy || tool_cooldown > world.time) return tool_cooldown = world.time + 10 - if(!W.use_tool(src, user, 10, volume = 50)) + if(!attacking_item.use_tool(src, user, 10, volume = 50)) return user.visible_message(SPAN_NOTICE("[user] set [src]'s protection panel back."), SPAN_NOTICE("You set [src]'s protection panel back.")) build_state = BARRICADE_BSTATE_SECURED return - if(W.iswrench()) + if(attacking_item.iswrench()) if(busy || tool_cooldown > world.time) return - if(!W.use_tool(src, user, 10, volume = 50)) + if(!attacking_item.use_tool(src, user, 10, volume = 50)) return user.visible_message(SPAN_NOTICE("[user] loosens [src]'s anchor bolts."), SPAN_NOTICE("You loosen [src]'s anchor bolts.")) @@ -131,7 +130,7 @@ return if(0) //Anchor bolts loosened step. Apply crowbar to unseat the panel and take apart the whole thing. Apply wrench to rescure anchor bolts - if(W.iswrench()) + if(attacking_item.iswrench()) if(busy || tool_cooldown > world.time) return tool_cooldown = world.time + 10 @@ -139,7 +138,7 @@ if(!(istype(T)) || istype(T, /turf/space)) to_chat(user, SPAN_WARNING("[src] must be secured on a proper surface!")) return - if(!W.use_tool(src, user, 10, volume = 50)) + if(!attacking_item.use_tool(src, user, 10, volume = 50)) return user.visible_message(SPAN_NOTICE("[user] secures [src]'s anchor bolts."), SPAN_NOTICE("You secure [src]'s anchor bolts.")) @@ -147,7 +146,7 @@ build_state = BARRICADE_BSTATE_UNSECURED update_icon() //unanchored changes layer return - if(W.iscrowbar()) + if(attacking_item.iscrowbar()) if(busy || tool_cooldown > world.time) return tool_cooldown = world.time + 10 @@ -155,7 +154,7 @@ SPAN_NOTICE("You start unseating [src]'s panels.")) playsound(src.loc, 'sound/items/crowbar_pry.ogg', 25, 1) busy = 1 - if(W.use_tool(src, user, 8 SECONDS, volume = 50)) + if(attacking_item.use_tool(src, user, 8 SECONDS, volume = 50)) busy = 0 user.visible_message(SPAN_NOTICE("[user] takes [src]'s panels apart."), SPAN_NOTICE("You take [src]'s panels apart.")) diff --git a/code/game/objects/structures/barricades/wood.dm b/code/game/objects/structures/barricades/wood.dm index 3d3313458d0..88a84b5c447 100644 --- a/code/game/objects/structures/barricades/wood.dm +++ b/code/game/objects/structures/barricades/wood.dm @@ -15,9 +15,9 @@ can_wire = FALSE metallic = FALSE -/obj/structure/barricade/wooden/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W, /obj/item/stack/material/wood)) - var/obj/item/stack/material/wood/D = W +/obj/structure/barricade/wooden/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stack/material/wood)) + var/obj/item/stack/material/wood/D = attacking_item if(health < maxhealth) if(D.get_amount() < 1) to_chat(user, SPAN_WARNING("You need one plank of wood to repair [src].")) diff --git a/code/game/objects/structures/barsign.dm b/code/game/objects/structures/barsign.dm index cbb123647bd..5497f844a77 100644 --- a/code/game/objects/structures/barsign.dm +++ b/code/game/objects/structures/barsign.dm @@ -8,10 +8,10 @@ var/cult = 0 var/choice_types = /singleton/sign/double/bar -/obj/structure/sign/double/barsign/attackby(obj/item/I, mob/user) +/obj/structure/sign/double/barsign/attackby(obj/item/attacking_item, mob/user) if(cult) return ..() - var/obj/item/card/id/card = I.GetID() + var/obj/item/card/id/card = attacking_item.GetID() if(istype(card)) if(check_access(card)) set_sign() diff --git a/code/game/objects/structures/bedsheet_bin.dm b/code/game/objects/structures/bedsheet_bin.dm index 5a3ff45cef2..b19d9eb12cd 100644 --- a/code/game/objects/structures/bedsheet_bin.dm +++ b/code/game/objects/structures/bedsheet_bin.dm @@ -176,17 +176,19 @@ LINEN BINS inuse = FALSE return FALSE -/obj/item/bedsheet/attackby(obj/item/I, mob/user) - if(I.isscrewdriver()) - user.visible_message(SPAN_NOTICE("\The [user] begins poking eyeholes in \the [src] with \the [I]."), SPAN_NOTICE("You begin poking eyeholes in \the [src] with \the [I].")) - if(I.use_tool(src, user, 50, volume = 50)) +/obj/item/bedsheet/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) + user.visible_message(SPAN_NOTICE("\The [user] begins poking eyeholes in \the [src] with \the [attacking_item]."), + SPAN_NOTICE("You begin poking eyeholes in \the [src] with \the [attacking_item].")) + if(attacking_item.use_tool(src, user, 50, volume = 50)) to_chat(user, SPAN_NOTICE("You poke eyeholes in \the [src]!")) new /obj/item/bedsheet/costume(get_turf(src)) qdel(src) return TRUE - else if(is_sharp(I)) - user.visible_message(SPAN_NOTICE("\The [user] begins cutting up \the [src] with \the [I]."), SPAN_NOTICE("You begin cutting up \the [src] with \the [I].")) - if(I.use_tool(src, user, 50, volume = 50)) + else if(is_sharp(attacking_item)) + user.visible_message(SPAN_NOTICE("\The [user] begins cutting up \the [src] with \the [attacking_item]."), + SPAN_NOTICE("You begin cutting up \the [src] with \the [attacking_item].")) + if(attacking_item.use_tool(src, user, 50, volume = 50)) to_chat(user, SPAN_NOTICE("You cut \the [src] into pieces!")) new /obj/item/stack/material/cloth(get_turf(src), rand(2, 5)) qdel(src) @@ -376,16 +378,15 @@ LINEN BINS var/obj/item/hidden = null -/obj/structure/bedsheetbin/examine(mob/user) +/obj/structure/bedsheetbin/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - if(amount < 1) - to_chat(user, "There are no bed sheets in the bin.") + . += "There are no bed sheets in the bin." return if(amount == 1) - to_chat(user, "There is one bed sheet in the bin.") + . += "There is one bed sheet in the bin." return - to_chat(user, "There are [amount] bed sheets in the bin.") + . += "There are [amount] bed sheets in the bin." /obj/structure/bedsheetbin/update_icon() @@ -397,16 +398,16 @@ LINEN BINS else icon_state = "linenbin-empty" -/obj/structure/bedsheetbin/attackby(obj/item/I as obj, mob/user as mob) - if(istype(I, /obj/item/bedsheet)) - user.drop_from_inventory(I,src) - sheets.Add(I) +/obj/structure/bedsheetbin/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/bedsheet)) + user.drop_from_inventory(attacking_item,src) + sheets.Add(attacking_item) amount++ - to_chat(user, "You put [I] in [src].") - else if(amount && !hidden && I.w_class < 4) //make sure there's sheets to hide it among, make sure nothing else is hidden in there. - user.drop_from_inventory(I,src) - hidden = I - to_chat(user, "You hide [I] among the sheets.") + to_chat(user, "You put [attacking_item] in [src].") + else if(amount && !hidden && attacking_item.w_class < 4) //make sure there's sheets to hide it among, make sure nothing else is hidden in there. + user.drop_from_inventory(attacking_item,src) + hidden = attacking_item + to_chat(user, "You hide [attacking_item] among the sheets.") /obj/structure/bedsheetbin/attack_hand(mob/user as mob) if(amount >= 1) diff --git a/code/game/objects/structures/bonfire.dm b/code/game/objects/structures/bonfire.dm index 30ffa8d0e80..7c3acbd2226 100644 --- a/code/game/objects/structures/bonfire.dm +++ b/code/game/objects/structures/bonfire.dm @@ -32,22 +32,22 @@ GLOBAL_LIST_EMPTY(total_active_bonfires) GLOB.total_active_bonfires -= src . = ..() -/obj/structure/bonfire/examine(mob/user, distance, is_adjacent) +/obj/structure/bonfire/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance > 2) return if(on_fire) switch(fuel) if(0 to 200) - to_chat(user, "\The [src] is burning weakly.") + . += "\The [src] is burning weakly." if(200 to 600) - to_chat(user, "\The [src] is gently burning.") + . += "\The [src] is gently burning." if(600 to 900) - to_chat(user, "\The [src] is burning steadily.") + . += "\The [src] is burning steadily." if(900 to 1300) - to_chat(user, "The flames are dancing wildly!") + . += "The flames are dancing wildly!" if(1300 to 2000) - to_chat(user, "The fire is roaring!") + . += "The fire is roaring!" /obj/structure/bonfire/update_icon() if(on_fire) @@ -71,40 +71,40 @@ GLOBAL_LIST_EMPTY(total_active_bonfires) var/obj/item/device/flashlight/flare/torch/stick/torch = new(get_turf(user)) H.put_in_active_hand(torch) -/obj/structure/bonfire/attackby(obj/item/W, mob/user) - if(W.isFlameSource() && !on_fire) // needs to go last or else nothing else will work +/obj/structure/bonfire/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isFlameSource() && !on_fire) // needs to go last or else nothing else will work light(user) return - if(on_fire && (istype(W, /obj/item/flame) || istype(W, /obj/item/device/flashlight/flare/torch) || istype(W, /obj/item/clothing/mask/smokable))) //light unlit stuff - W.attackby(src, user) + if(on_fire && (istype(attacking_item, /obj/item/flame) || istype(attacking_item, /obj/item/device/flashlight/flare/torch) || istype(attacking_item, /obj/item/clothing/mask/smokable))) //light unlit stuff + attacking_item.attackby(src, user) return if(fuel < max_fuel) - if(istype(W, /obj/item/stack/material)) - var/obj/item/stack/material/I = W + if(istype(attacking_item, /obj/item/stack/material)) + var/obj/item/stack/material/I = attacking_item if(I.default_type in burnable_materials) I.use(1) fuel = min(fuel + burnable_materials[I.default_type], max_fuel) user.visible_message(SPAN_NOTICE("\The [user] adds some of \the [I] to \the [src].")) return - if(is_type_in_list(W, burnable_other)) - var/fuel_add = burnable_other[W] + if(is_type_in_list(attacking_item, burnable_other)) + var/fuel_add = burnable_other[attacking_item] fuel = min(fuel + fuel_add, max_fuel) - user.visible_message(SPAN_NOTICE("\The [user] tosses \the [W] into \the [src].")) - user.drop_from_inventory(W) - qdel(W) + user.visible_message(SPAN_NOTICE("\The [user] tosses \the [attacking_item] into \the [src].")) + user.drop_from_inventory(attacking_item) + qdel(attacking_item) return - else if(istype(W, /obj/item/material)) - var/obj/item/material/M = W + else if(istype(attacking_item, /obj/item/material)) + var/obj/item/material/M = attacking_item if(M.material.name in burnable_materials) var/fuel_add = burnable_materials[M.material] * (M.w_class / 5) //if you crafted a small item, it's not worth as much fuel fuel = min(fuel + fuel_add, max_fuel) user.visible_message(SPAN_NOTICE("\The [user] tosses \the [M] into \the [src].")) - user.drop_from_inventory(W) - W.forceMove(get_turf(src)) - qdel(W) + user.drop_from_inventory(attacking_item) + attacking_item.forceMove(get_turf(src)) + qdel(attacking_item) return else - var/obj/item/reagent_containers/RC = W + var/obj/item/reagent_containers/RC = attacking_item if(RC.is_open_container()) RC.reagents.trans_to(src, RC.amount_per_transfer_from_this) handle_reagents() diff --git a/code/game/objects/structures/coatrack.dm b/code/game/objects/structures/coatrack.dm index f672012ffa8..1d38bd541f0 100644 --- a/code/game/objects/structures/coatrack.dm +++ b/code/game/objects/structures/coatrack.dm @@ -37,22 +37,22 @@ hat = null update_icon() -/obj/structure/coatrack/attackby(obj/item/W as obj, mob/user as mob) +/obj/structure/coatrack/attackby(obj/item/attacking_item, mob/user) if(use_check_and_message(user)) return - if(!coat && (istype(W, /obj/item/clothing/suit/storage/toggle) || istype(W, /obj/item/clothing/accessory/poncho))) - user.visible_message("[user] hangs [W] on \the [src].", SPAN_NOTICE("You hang [W] on the \the [src].")) - coat = W + if(!coat && (istype(attacking_item, /obj/item/clothing/suit/storage/toggle) || istype(attacking_item, /obj/item/clothing/accessory/poncho))) + user.visible_message("[user] hangs [attacking_item] on \the [src].", SPAN_NOTICE("You hang [attacking_item] on the \the [src].")) + coat = attacking_item user.drop_from_inventory(coat, src) - playsound(src, W.drop_sound, DROP_SOUND_VOLUME) + playsound(src, attacking_item.drop_sound, DROP_SOUND_VOLUME) update_icon() - else if(!hat && istype(W, /obj/item/clothing/head) && !istype(W, /obj/item/clothing/head/helmet)) - user.visible_message("[user] hangs [W] on \the [src].", SPAN_NOTICE("You hang [W] on the \the [src].")) - hat = W + else if(!hat && istype(attacking_item, /obj/item/clothing/head) && !istype(attacking_item, /obj/item/clothing/head/helmet)) + user.visible_message("[user] hangs [attacking_item] on \the [src].", SPAN_NOTICE("You hang [attacking_item] on the \the [src].")) + hat = attacking_item user.drop_from_inventory(hat, src) - playsound(src, W.drop_sound, DROP_SOUND_VOLUME) + playsound(src, attacking_item.drop_sound, DROP_SOUND_VOLUME) update_icon() - else if(istype(W, /obj/item/clothing)) + else if(istype(attacking_item, /obj/item/clothing)) to_chat(user, SPAN_WARNING("You can't hang that up.")) else return ..() diff --git a/code/game/objects/structures/crates_lockers/closets.dm b/code/game/objects/structures/crates_lockers/closets.dm index bc888dbaa26..c869438d18d 100644 --- a/code/game/objects/structures/crates_lockers/closets.dm +++ b/code/game/objects/structures/crates_lockers/closets.dm @@ -90,30 +90,30 @@ /obj/structure/closet/proc/content_info(mob/user, content_size) if(!content_size) - to_chat(user, "\The [src] is empty.") + . = "\The [src] is empty." else if(storage_capacity > content_size*4) - to_chat(user, "\The [src] is barely filled.") + . = "\The [src] is barely filled." else if(storage_capacity > content_size*2) - to_chat(user, "\The [src] is less than half full.") + . = "\The [src] is less than half full." else if(storage_capacity > content_size) - to_chat(user, "\The [src] still has some free space.") + . = "\The [src] still has some free space." else - to_chat(user, "\The [src] is full.") + . = "\The [src] is full." -/obj/structure/closet/examine(mob/user, distance, is_adjacent) +/obj/structure/closet/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1 && !src.opened) var/content_size = 0 for(var/obj/item/I in contents) if(!I.anchored) content_size += Ceiling(I.w_class/2) - content_info(user, content_size) + . += content_info(user, content_size) if(!src.opened && isobserver(user)) - to_chat(user, "It contains: [counting_english_list(contents)]") + . += "It contains: [counting_english_list(contents)]" if(src.opened && linked_teleporter && is_adjacent) - to_chat(user, FONT_SMALL(SPAN_NOTICE("There appears to be a device attached to the interior backplate of \the [src]..."))) + . += FONT_SMALL(SPAN_NOTICE("There appears to be a device attached to the interior backplate of \the [src]...")) /obj/structure/closet/proc/stored_weight() var/content_size = 0 @@ -304,12 +304,12 @@ ..() damage(proj_damage) -/obj/structure/closet/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/closet_teleporter)) +/obj/structure/closet/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/closet_teleporter)) if(linked_teleporter) to_chat(user, SPAN_WARNING("\The [src] already has a linked teleporter!")) return - var/obj/item/closet_teleporter/CT = W + var/obj/item/closet_teleporter/CT = attacking_item user.visible_message(SPAN_NOTICE("\The [user] starts attaching \the [CT] to \the [src]..."), SPAN_NOTICE("You begin attaching \the [CT] to \the [src]..."), range = 3) if(do_after(user, 30, src, DO_REPAIR_CONSTRUCT)) user.visible_message(SPAN_NOTICE("\The [user] attaches \the [CT] to \the [src]."), SPAN_NOTICE("You attach \the [CT] to \the [src]."), range = 3) @@ -318,11 +318,11 @@ user.drop_from_inventory(CT, src) return if(opened) - if(istype(W, /obj/item/grab)) - var/obj/item/grab/G = W + if(istype(attacking_item, /obj/item/grab)) + var/obj/item/grab/G = attacking_item MouseDrop_T(G.affecting, user) //act like they were dragged onto the closet return 0 - if(W.isscrewdriver()) // Moved here so you can only detach linked teleporters when the door is open. So you can like unscrew and bolt the locker normally in most circumstances. + if(attacking_item.isscrewdriver()) // Moved here so you can only detach linked teleporters when the door is open. So you can like unscrew and bolt the locker normally in most circumstances. if(linked_teleporter) user.visible_message(SPAN_NOTICE("\The [user] starts detaching \the [linked_teleporter] from \the [src]..."), SPAN_NOTICE("You begin detaching \the [linked_teleporter] from \the [src]..."), range = 3) if(do_after(user, 30, src, DO_REPAIR_CONSTRUCT)) @@ -331,8 +331,8 @@ user.put_in_hands(linked_teleporter) linked_teleporter = null return - if(W.iswelder()) - var/obj/item/weldingtool/WT = W + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(WT.isOn()) user.visible_message( SPAN_WARNING("[user] begins cutting [src] apart."), @@ -355,8 +355,8 @@ linked_teleporter = null dismantle() return - if(istype(W, /obj/item/storage/laundry_basket) && W.contents.len) - var/obj/item/storage/laundry_basket/LB = W + if(istype(attacking_item, /obj/item/storage/laundry_basket) && attacking_item.contents.len) + var/obj/item/storage/laundry_basket/LB = attacking_item var/turf/T = get_turf(src) for(var/obj/item/I in LB.contents) LB.remove_from_storage(I, T) @@ -366,27 +366,27 @@ SPAN_NOTICE("You hear rustling of clothes.") ) return - if(!W.dropsafety()) + if(!attacking_item.dropsafety()) return - if(W) - user.drop_from_inventory(W,loc) + if(attacking_item) + user.drop_from_inventory(attacking_item,loc) else user.drop_item() - else if(istype(W, /obj/item/device/cratescanner)) - var/obj/item/device/cratescanner/Cscanner = W + else if(istype(attacking_item, /obj/item/device/cratescanner)) + var/obj/item/device/cratescanner/Cscanner = attacking_item if(locked) - to_chat(user, SPAN_WARNING("[W] refuses to scan [src]. Unlock it first!")) + to_chat(user, SPAN_WARNING("[attacking_item] refuses to scan [src]. Unlock it first!")) return if(welded) - to_chat(user, SPAN_WARNING("[W] detects that [src] is welded shut, and refuses to scan.")) + to_chat(user, SPAN_WARNING("[attacking_item] detects that [src] is welded shut, and refuses to scan.")) return Cscanner.print_contents(name, contents, src.loc) - else if(istype(W, /obj/item/stack/packageWrap)) + else if(istype(attacking_item, /obj/item/stack/packageWrap)) return - else if(istype(W, /obj/item/ducttape)) + else if(istype(attacking_item, /obj/item/ducttape)) return - else if(W.iswelder()) - var/obj/item/weldingtool/WT = W + else if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(WT.isOn()) user.visible_message( SPAN_WARNING("[user] begins welding [src] [welded ? "open" : "shut"]."), @@ -394,7 +394,7 @@ "You hear a welding torch on metal." ) playsound(loc, 'sound/items/welder_pry.ogg', 50, 1) - if(!W.use_tool(src, user, 20, volume = 50, extra_checks = CALLBACK(src, PROC_REF(is_closed)))) + if(!attacking_item.use_tool(src, user, 20, volume = 50, extra_checks = CALLBACK(src, PROC_REF(is_closed)))) return if(!WT.use(0,user)) to_chat(user, SPAN_NOTICE("You need more welding fuel to complete this task.")) @@ -407,67 +407,67 @@ ) else attack_hand(user) - else if(W.isscrewdriver() && canbemoved) + else if(attacking_item.isscrewdriver() && canbemoved) if(screwed) to_chat(user, SPAN_NOTICE("You start to unscrew \the [src] from the floor...")) - playsound(loc, W.usesound, 50, 1) - if (do_after(user, 10/W.toolspeed SECONDS, src, DO_REPAIR_CONSTRUCT)) + playsound(loc, attacking_item.usesound, 50, 1) + if (do_after(user, 10/attacking_item.toolspeed SECONDS, src, DO_REPAIR_CONSTRUCT)) to_chat(user, SPAN_NOTICE("You unscrew the locker!")) - playsound(loc, W.usesound, 50, 1) + playsound(loc, attacking_item.usesound, 50, 1) screwed = FALSE else if(!screwed && wrenched) to_chat(user, SPAN_NOTICE("You start to screw the \the [src] to the floor...")) playsound(src, 'sound/items/Welder.ogg', 80, 1) - if (do_after(user, 15/W.toolspeed SECONDS, src, DO_REPAIR_CONSTRUCT)) + if (do_after(user, 15/attacking_item.toolspeed SECONDS, src, DO_REPAIR_CONSTRUCT)) to_chat(user, SPAN_NOTICE("You screw \the [src]!")) - playsound(loc, W.usesound, 50, 1) + playsound(loc, attacking_item.usesound, 50, 1) screwed = TRUE - else if(W.iswrench() && canbemoved) + else if(attacking_item.iswrench() && canbemoved) if(wrenched && !screwed) to_chat(user, SPAN_NOTICE("You start to unfasten the bolts holding \the [src] in place...")) - playsound(loc, W.usesound, 50, 1) - if (do_after(user, 15/W.toolspeed SECONDS, src, DO_REPAIR_CONSTRUCT)) + playsound(loc, attacking_item.usesound, 50, 1) + if (do_after(user, 15/attacking_item.toolspeed SECONDS, src, DO_REPAIR_CONSTRUCT)) to_chat(user, SPAN_NOTICE("You unfasten \the [src]'s bolts!")) - playsound(loc, W.usesound, 50, 1) + playsound(loc, attacking_item.usesound, 50, 1) wrenched = FALSE anchored = FALSE else if(!wrenched) to_chat(user, SPAN_NOTICE("You start to fasten the bolts holding the locker in place...")) - playsound(loc, W.usesound, 50, 1) - if (do_after(user, 15/W.toolspeed SECONDS, src, DO_REPAIR_CONSTRUCT)) + playsound(loc, attacking_item.usesound, 50, 1) + if (do_after(user, 15/attacking_item.toolspeed SECONDS, src, DO_REPAIR_CONSTRUCT)) to_chat(user, SPAN_NOTICE("You fasten the \the [src]'s bolts!")) - playsound(loc, W.usesound, 50, 1) + playsound(loc, attacking_item.usesound, 50, 1) wrenched = TRUE anchored = TRUE - else if(istype(W, /obj/item/device/hand_labeler)) - var/obj/item/device/hand_labeler/HL = W + else if(istype(attacking_item, /obj/item/device/hand_labeler)) + var/obj/item/device/hand_labeler/HL = attacking_item if(HL.mode == 1) return else attack_hand(user) - else if(istype(W,/obj/item/card/id) && secure) + else if(istype(attacking_item,/obj/item/card/id) && secure) togglelock(user) // Secure locker cutting open stuff. else if(!opened && secure) - if(!broken && istype(W,/obj/item/material/twohanded/chainsaw)) - var/obj/item/material/twohanded/chainsaw/ChainSawVar = W + if(!broken && istype(attacking_item,/obj/item/material/twohanded/chainsaw)) + var/obj/item/material/twohanded/chainsaw/ChainSawVar = attacking_item ChainSawVar.cutting = 1 user.visible_message(\ - SPAN_DANGER("[user.name] starts cutting \the [src] with the [W]!"),\ + SPAN_DANGER("[user.name] starts cutting \the [src] with the [attacking_item]!"),\ SPAN_WARNING("You start cutting the [src]..."),\ SPAN_NOTICE("You hear a loud buzzing sound and metal grinding on metal...")\ ) if(do_after(user, ChainSawVar.opendelay SECONDS, user, DO_REPAIR_CONSTRUCT)) user.visible_message(\ - SPAN_WARNING("[user.name] finishes cutting open \the [src] with the [W]."),\ + SPAN_WARNING("[user.name] finishes cutting open \the [src] with the [attacking_item]."),\ SPAN_WARNING("You finish cutting open the [src]."),\ SPAN_NOTICE("You hear a metal clank and some sparks.")\ ) - emag_act(INFINITY, user, SPAN_DANGER("\The [src] has been sliced open by [user] with \an [W]!"), SPAN_DANGER("You hear metal being sliced and sparks flying.")) + emag_act(INFINITY, user, SPAN_DANGER("\The [src] has been sliced open by [user] with \an [attacking_item]!"), SPAN_DANGER("You hear metal being sliced and sparks flying.")) ChainSawVar.cutting = 0 - else if(istype(W, /obj/item/melee/energy/blade))//Attempt to cut open locker if locked - if(emag_act(INFINITY, user, SPAN_DANGER("\The [src] has been sliced open by [user] with \an [W]!"), SPAN_DANGER("You hear metal being sliced and sparks flying."))) + else if(istype(attacking_item, /obj/item/melee/energy/blade))//Attempt to cut open locker if locked + if(emag_act(INFINITY, user, SPAN_DANGER("\The [src] has been sliced open by [user] with \an [attacking_item]!"), SPAN_DANGER("You hear metal being sliced and sparks flying."))) playsound(loc, 'sound/weapons/blade.ogg', 50, 1) else attack_hand(user) diff --git a/code/game/objects/structures/crates_lockers/closets/gimmick.dm b/code/game/objects/structures/crates_lockers/closets/gimmick.dm index 9c7498d22e5..c0701141d17 100644 --- a/code/game/objects/structures/crates_lockers/closets/gimmick.dm +++ b/code/game/objects/structures/crates_lockers/closets/gimmick.dm @@ -10,19 +10,19 @@ door_hinge_alt = 7.5 double_doors = TRUE -/obj/structure/closet/cabinet/attackby(obj/item/W as obj, mob/user as mob) +/obj/structure/closet/cabinet/attackby(obj/item/attacking_item, mob/user) if(opened) - if(istype(W, /obj/item/grab)) - var/obj/item/grab/G = W + if(istype(attacking_item, /obj/item/grab)) + var/obj/item/grab/G = attacking_item MouseDrop_T(G.affecting, user) //act like they were dragged onto the closet return 0 - if(!W.dropsafety()) + if(!attacking_item.dropsafety()) return - if(W) - user.drop_from_inventory(W,loc) + if(attacking_item) + user.drop_from_inventory(attacking_item, loc) else user.drop_item() - else if(istype(W, /obj/item/stack/packageWrap)) + else if(istype(attacking_item, /obj/item/stack/packageWrap)) return else attack_hand(user) diff --git a/code/game/objects/structures/crates_lockers/closets/secure/personal.dm b/code/game/objects/structures/crates_lockers/closets/secure/personal.dm index 3cce3dd2c7c..6ab182c5f49 100644 --- a/code/game/objects/structures/crates_lockers/closets/secure/personal.dm +++ b/code/game/objects/structures/crates_lockers/closets/secure/personal.dm @@ -37,19 +37,19 @@ new /obj/item/device/radio/headset(src) new /obj/item/device/radio/headset/alt(src) -/obj/structure/closet/secure_closet/personal/attackby(obj/item/W as obj, mob/user as mob) +/obj/structure/closet/secure_closet/personal/attackby(obj/item/attacking_item, mob/user) if (opened) - if (istype(W, /obj/item/grab)) - MouseDrop_T(W:affecting, user) //act like they were dragged onto the closet - if(W) - user.drop_from_inventory(W,loc) + if (istype(attacking_item, /obj/item/grab)) + MouseDrop_T(attacking_item:affecting, user) //act like they were dragged onto the closet + if(attacking_item) + user.drop_from_inventory(attacking_item,loc) else user.drop_item() - else if(W.GetID()) + else if(attacking_item.GetID()) if(user.loc == src) to_chat(user, "You can't reach the lock from inside.") return - var/obj/item/card/id/I = W.GetID() + var/obj/item/card/id/I = attacking_item.GetID() if(broken) to_chat(user, "It appears to be broken.") @@ -65,8 +65,8 @@ desc = "Owned by [I.registered_name]." else to_chat(user, "Access Denied") - else if(istype(W, /obj/item/melee/energy/blade)) - var/obj/item/melee/energy/blade/blade = W + else if(istype(attacking_item, /obj/item/melee/energy/blade)) + var/obj/item/melee/energy/blade/blade = attacking_item if(emag_act(INFINITY, user, "The locker has been sliced open by [user] with \an [blade]!", "You hear metal being sliced and sparks flying.")) blade.spark_system.queue() playsound(loc, 'sound/weapons/blade.ogg', 50, 1) diff --git a/code/game/objects/structures/crates_lockers/closets/secure/service.dm b/code/game/objects/structures/crates_lockers/closets/secure/service.dm index 69f9e25aadf..3bed4e24889 100644 --- a/code/game/objects/structures/crates_lockers/closets/secure/service.dm +++ b/code/game/objects/structures/crates_lockers/closets/secure/service.dm @@ -31,6 +31,7 @@ new /obj/item/taperoll/custodial(src) new /obj/item/storage/box/lights/mixed(src) new /obj/item/storage/box/mousetraps(src) + new /obj/item/storage/box/cleaner_tablets(src) // Away Ship/Site Custodial Locker /obj/structure/closet/secure_closet/custodial/offship diff --git a/code/game/objects/structures/crates_lockers/closets/statue.dm b/code/game/objects/structures/crates_lockers/closets/statue.dm index 37660033c98..d48e80ba044 100644 --- a/code/game/objects/structures/crates_lockers/closets/statue.dm +++ b/code/game/objects/structures/crates_lockers/closets/statue.dm @@ -142,11 +142,11 @@ health -= 60 / severity check_health() -/obj/structure/closet/statue/attackby(obj/item/I as obj, mob/user as mob) +/obj/structure/closet/statue/attackby(obj/item/attacking_item, mob/user) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - health -= I.force + health -= attacking_item.force user.do_attack_animation(src) - visible_message("[user] strikes [src] with [I].") + visible_message("[user] strikes [src] with [attacking_item].") check_health() /obj/structure/closet/statue/MouseDrop_T() diff --git a/code/game/objects/structures/crates_lockers/largecrate.dm b/code/game/objects/structures/crates_lockers/largecrate.dm index ce963f79c79..263675176f4 100644 --- a/code/game/objects/structures/crates_lockers/largecrate.dm +++ b/code/game/objects/structures/crates_lockers/largecrate.dm @@ -8,8 +8,8 @@ to_chat(user, SPAN_NOTICE("You need a crowbar to pry this open!")) return -/obj/structure/largecrate/attackby(obj/item/W as obj, mob/user as mob) - if(W.iscrowbar()) +/obj/structure/largecrate/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iscrowbar()) new /obj/item/stack/material/wood(src) var/turf/T = get_turf(src) for(var/atom/movable/AM in contents) diff --git a/code/game/objects/structures/crystals.dm b/code/game/objects/structures/crystals.dm index dde09371dc2..2005c3383a0 100644 --- a/code/game/objects/structures/crystals.dm +++ b/code/game/objects/structures/crystals.dm @@ -27,7 +27,7 @@ if(our_creator) creator = our_creator -/obj/structure/reagent_crystal/examine(mob/user) +/obj/structure/reagent_crystal/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() var/state var/current_damage = health / initial(health) @@ -40,7 +40,7 @@ state = SPAN_WARNING("The crystal has scratches and deeper grooves on its surface.") if(0.8 to 1) state = SPAN_NOTICE("The crystal looks structurally sound.") - to_chat(user, state) + . += state /obj/structure/reagent_crystal/proc/take_damage(var/damage) health -= damage @@ -55,30 +55,30 @@ return return ..() -/obj/structure/reagent_crystal/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/gun/energy/plasmacutter)) - mine_crystal(user, 30 / W.toolspeed, W.usesound) +/obj/structure/reagent_crystal/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/gun/energy/plasmacutter)) + mine_crystal(user, 30 / attacking_item.toolspeed, attacking_item.usesound) - else if(istype(W, /obj/item/melee/energy)) - var/obj/item/melee/energy/WT = W + else if(istype(attacking_item, /obj/item/melee/energy)) + var/obj/item/melee/energy/WT = attacking_item if(WT.active) - mine_crystal(user, 30 / W.toolspeed, W.usesound) + mine_crystal(user, 30 / attacking_item.toolspeed, attacking_item.usesound) else - to_chat(user, SPAN_NOTICE("You need to activate \the [W] to do that!")) + to_chat(user, SPAN_NOTICE("You need to activate \the [attacking_item] to do that!")) return - else if(istype(W, /obj/item/melee/energy/blade)) - mine_crystal(user, 30 / W.toolspeed, W.usesound) + else if(istype(attacking_item, /obj/item/melee/energy/blade)) + mine_crystal(user, 30 / attacking_item.toolspeed, attacking_item.usesound) - else if(istype(W, /obj/item/pickaxe)) - var/obj/item/pickaxe/P = W - mine_crystal(user, P.digspeed, W.usesound) + else if(istype(attacking_item, /obj/item/pickaxe)) + var/obj/item/pickaxe/P = attacking_item + mine_crystal(user, P.digspeed, attacking_item.usesound) - else if(W.force > 5) + else if(attacking_item.force > 5) user.do_attack_animation(src) playsound(get_turf(src), 'sound/weapons/smash.ogg', 50) - visible_message(SPAN_WARNING("\The [user] smashes \the [W] into \the [src].")) - take_damage(W.force * 4) + visible_message(SPAN_WARNING("\The [user] smashes \the [attacking_item] into \the [src].")) + take_damage(attacking_item.force * 4) /obj/structure/reagent_crystal/proc/mine_crystal(var/mob/user, var/time_to_dig, var/use_sound) if(!user) diff --git a/code/game/objects/structures/curtains.dm b/code/game/objects/structures/curtains.dm index 6b233207e6a..b4fb69e412e 100644 --- a/code/game/objects/structures/curtains.dm +++ b/code/game/objects/structures/curtains.dm @@ -39,28 +39,28 @@ if(istype(user, /mob/living/silicon/robot) && Adjacent(user)) // Robots can open/close it, but not the AI. attack_hand(user) -/obj/structure/curtain/attackby(obj/item/W, mob/user) +/obj/structure/curtain/attackby(obj/item/attacking_item, mob/user) - if(W.iswirecutter() || W.sharp && !W.noslice) + if(attacking_item.iswirecutter() || attacking_item.sharp && !attacking_item.noslice) if(manipulating) return manipulating = TRUE visible_message(SPAN_NOTICE("[user] begins cutting down \the [src]."), SPAN_NOTICE("You begin cutting down \the [src].")) - if(!W.use_tool(src, user, 30, volume = 50)) + if(!attacking_item.use_tool(src, user, 30, volume = 50)) manipulating = FALSE return visible_message(SPAN_NOTICE("[user] cuts down \the [src]."), SPAN_NOTICE("You cut down \the [src].")) dismantle() - if(W.isscrewdriver()) //You can anchor/unanchor curtains + if(attacking_item.isscrewdriver()) //You can anchor/unanchor curtains anchored = !anchored var/obj/structure/curtain/C for(C in src.loc) if(C != src && C.anchored) //Can't secure more than one curtain in a tile to_chat(user, "There is already a curtain secured here!") return - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) visible_message(SPAN_NOTICE("\The [src] has been [anchored ? "secured in place" : "unsecured"] by \the [user].")) /obj/structure/curtain/proc/toggle() diff --git a/code/game/objects/structures/displaycase.dm b/code/game/objects/structures/displaycase.dm index 94cb40b7c9f..5992a41054c 100644 --- a/code/game/objects/structures/displaycase.dm +++ b/code/game/objects/structures/displaycase.dm @@ -65,13 +65,13 @@ var/image/I = image(held_obj.icon, src, held_obj.icon_state) underlays += I -/obj/structure/displaycase/attackby(obj/item/W, mob/user) +/obj/structure/displaycase/attackby(obj/item/attacking_item, mob/user) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - if(istype(W, /obj/item/card/id)) + if(istype(attacking_item, /obj/item/card/id)) if(destroyed) to_chat(user, SPAN_WARNING("\The [src] has been destroyed and cannot be unlocked.")) return - var/obj/item/card/id/ID = W + var/obj/item/card/id/ID = attacking_item if(check_access(ID)) user.visible_message("[user] presses their ID against \the [src], [open ? "closing" : "opening"] it.", SPAN_NOTICE("You press your ID against \the [src], [open ? "closing" : "opening"] it.")) open = !open @@ -79,15 +79,15 @@ else to_chat(user, SPAN_WARNING("Access denied.")) else if(!held_obj && (destroyed || open)) - to_chat(user, SPAN_NOTICE("You set \the [W] down on \the [src].")) - user.drop_from_inventory(W, src) - held_obj = W + to_chat(user, SPAN_NOTICE("You set \the [attacking_item] down on \the [src].")) + user.drop_from_inventory(attacking_item, src) + held_obj = attacking_item update_icon() else if(destroyed) to_chat(user, SPAN_WARNING("\The [src] has already been destroyed.")) return - health -= W.force + health -= attacking_item.force health_check() return ..() diff --git a/code/game/objects/structures/door_assembly.dm b/code/game/objects/structures/door_assembly.dm index 14e99640db1..c2884897781 100644 --- a/code/game/objects/structures/door_assembly.dm +++ b/code/game/objects/structures/door_assembly.dm @@ -31,9 +31,9 @@ . = ..() update_state() -/obj/structure/door_assembly/examine(mob/user) +/obj/structure/door_assembly/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "It is currently facing [dir2text(dir)].") + . += "It is currently facing [dir2text(dir)]." /obj/structure/door_assembly/door_assembly_generic base_name = "airlock" @@ -85,8 +85,8 @@ bound_width = world.icon_size bound_height = width * world.icon_size -/obj/structure/door_assembly/attackby(obj/item/W as obj, mob/user as mob) - if(W.ispen()) +/obj/structure/door_assembly/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ispen()) var/door_name = sanitizeSafe(input(user, "Enter the name for the door.", src.name, src.created_name), MAX_NAME_LEN) if(!door_name) return @@ -94,16 +94,16 @@ return created_name = door_name - else if(W.iswelder()) + else if(attacking_item.iswelder()) if(!glass || anchored) to_chat(user, SPAN_WARNING("\The [src] isn't ready to be welded yet. It doesn't have any installed glass to remove, and it has to be unsecured to deconstruct it.")) return - var/obj/item/weldingtool/WT = W + var/obj/item/weldingtool/WT = attacking_item if(WT.use(0, user)) playsound(src.loc, 'sound/items/welder_pry.ogg', 50, 1) if(glass) user.visible_message("[user] starts welding the glass panel out of the airlock assembly.", SPAN_NOTICE("You start welding the glass panel out of the airlock assembly.")) - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src || !WT.isOn()) return to_chat(user, SPAN_NOTICE("You weld the glass panel out.")) @@ -111,7 +111,7 @@ glass = FALSE else if(!anchored) user.visible_message("[user] starts disassembling the airlock assembly.", SPAN_NOTICE("You start disassembling the airlock assembly.")) - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src || !WT.isOn()) return to_chat(user, SPAN_NOTICE("You disassemble the airlock assembly.")) @@ -120,7 +120,7 @@ to_chat(user, SPAN_WARNING("You need more welding fuel.")) return - else if(W.iswrench()) + else if(attacking_item.iswrench()) if(state != STATE_UNWIRED) to_chat(user, SPAN_WARNING("You have to remove the wiring before you can use the wrench on \the [src].")) return @@ -132,30 +132,30 @@ user.visible_message("[user] begins securing the airlock assembly to the floor.", \ SPAN_NOTICE("You start securing the airlock assembly to the floor.")) - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return to_chat(user, SPAN_NOTICE("You [anchored? "un" : ""]secure \the [src].")) anchored = !anchored - else if(W.iscoil()) + else if(attacking_item.iscoil()) if(state > STATE_UNWIRED) to_chat(user, SPAN_WARNING("\The [src] has already been wired.")) return if(!anchored) to_chat(user, SPAN_WARNING("\The [src] must be anchored before it can be wired.")) return - var/obj/item/stack/cable_coil/C = W + var/obj/item/stack/cable_coil/C = attacking_item if (C.get_amount() < 3) to_chat(user, SPAN_WARNING("You need three lengths of coil to wire the airlock assembly.")) return user.visible_message("[user] starts wiring the airlock assembly.", SPAN_NOTICE("You start wiring the airlock assembly.")) - if(W.use_tool(src, user, 40, volume = 50) && state == STATE_UNWIRED && anchored) + if(attacking_item.use_tool(src, user, 40, volume = 50) && state == STATE_UNWIRED && anchored) if(C.use(3)) state = STATE_WIRED to_chat(user, SPAN_NOTICE("You wire the airlock.")) - else if(W.iswirecutter()) + else if(attacking_item.iswirecutter()) if(state == STATE_UNWIRED) to_chat(user, SPAN_WARNING("\The [src] doesn't have any wires to remove.")) return @@ -166,26 +166,26 @@ playsound(src.loc, 'sound/items/Wirecutter.ogg', 100, 1) user.visible_message("[user] starts cutting the wires from the airlock assembly.", SPAN_NOTICE("You start cutting the wires from airlock assembly.")) - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return to_chat(user, SPAN_NOTICE("You cut the airlock wires.")) new /obj/item/stack/cable_coil(src.loc, 1) state = STATE_UNWIRED - else if(istype(W, /obj/item/airlock_electronics)) + else if(istype(attacking_item, /obj/item/airlock_electronics)) if(state == STATE_UNWIRED) to_chat(user, SPAN_WARNING("\The [src] must be wired before you can install electronics into it.")) return else if(state > STATE_WIRED) to_chat(user, SPAN_WARNING("\The [src] already has electronics installed.")) return - var/obj/item/airlock_electronics/EL = W + var/obj/item/airlock_electronics/EL = attacking_item if(!EL.is_installed) playsound(src.loc, 'sound/items/Screwdriver.ogg', 100, 1) user.visible_message("[user] starts installing \the [EL] into the airlock assembly.", SPAN_NOTICE("You start installing \the [EL] into the airlock assembly.")) EL.is_installed = TRUE - if(W.use_tool(src, user, 40, volume = 50) && state == STATE_WIRED) + if(attacking_item.use_tool(src, user, 40, volume = 50) && state == STATE_WIRED) EL.is_installed = FALSE if(!src) return @@ -196,7 +196,7 @@ else EL.is_installed = FALSE - else if(W.iscrowbar()) + else if(attacking_item.iscrowbar()) if(state != STATE_ELECTRONICS_INSTALLED) to_chat(user, SPAN_WARNING("\The [src] has no electronics to remove.")) return @@ -210,7 +210,7 @@ user.visible_message("[user] starts removing the electronics from \the [src].", SPAN_NOTICE("You start removing the electronics from \the [src].")) - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return to_chat(user, SPAN_NOTICE("You remove \the [electronics].")) @@ -218,28 +218,28 @@ electronics.forceMove(src.loc) electronics = null - else if(istype(W, /obj/item/stack/material) && glass_type) + else if(istype(attacking_item, /obj/item/stack/material) && glass_type) if(glass) to_chat(user, SPAN_WARNING("\The [src] already has glass installed.")) return - var/obj/item/stack/S = W + var/obj/item/stack/S = attacking_item var/material_name = S.get_material_name() if(S.get_amount() >= 2) if(material_name == MATERIAL_GLASS_REINFORCED) user.visible_message("[user] starts installing \the [S] into the airlock assembly.", SPAN_WARNING("You start installing \the [S] into the airlock assembly.")) - if(W.use_tool(src, user, 40, volume = 50) && !glass) + if(attacking_item.use_tool(src, user, 40, volume = 50) && !glass) if(S.use(2)) to_chat(user, SPAN_NOTICE("You install reinforced glass windows into the airlock assembly.")) glass = TRUE - else if(W.isscrewdriver()) + else if(attacking_item.isscrewdriver()) if(state != STATE_ELECTRONICS_INSTALLED) to_chat(user, SPAN_WARNING("\The [src] doesn't have any electronics installed.")) return user.visible_message("[user] starts finishing \the [src].", SPAN_NOTICE("You start finishing \the [src].")) - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return to_chat(user, SPAN_NOTICE("You finish the airlock!")) @@ -250,24 +250,24 @@ new airlock_type(loc, dir, FALSE, src) qdel(src) - else if(istype(W, /obj/item/material/twohanded/chainsaw)) - var/obj/item/material/twohanded/chainsaw/ChainSawVar = W + else if(istype(attacking_item, /obj/item/material/twohanded/chainsaw)) + var/obj/item/material/twohanded/chainsaw/ChainSawVar = attacking_item if(!ChainSawVar.wielded) to_chat(user, SPAN_WARNING("Cutting the airlock requires the strength of two hands.")) else if(ChainSawVar.cutting) to_chat(user, SPAN_WARNING("You are already cutting an airlock open.")) else if(!ChainSawVar.powered) - to_chat(user, SPAN_WARNING("\The [W] needs to be on in order to tear \the [src] apart.")) + to_chat(user, SPAN_WARNING("\The [attacking_item] needs to be on in order to tear \the [src] apart.")) else ChainSawVar.cutting = TRUE user.visible_message(\ - SPAN_DANGER("[user] starts cutting \the [src] apart with \the [W]!"), \ + SPAN_DANGER("[user] starts cutting \the [src] apart with \the [attacking_item]!"), \ SPAN_NOTICE("You start cutting \the [src] apart..."), \ SPAN_WARNING("You hear a loud buzzing sound and metal grinding on metal...") \ ) - if(do_after(user, ChainSawVar.opendelay SECONDS, user, extra_checks = CALLBACK(src, PROC_REF(CanChainsaw), W))) + if(do_after(user, ChainSawVar.opendelay SECONDS, user, extra_checks = CALLBACK(src, PROC_REF(CanChainsaw), attacking_item))) user.visible_message(\ - SPAN_DANGER("[user] finishes cutting \the [src] apart with the [W]."), \ + SPAN_DANGER("[user] finishes cutting \the [src] apart with the [attacking_item]."), \ SPAN_NOTICE("You finish cutting \the [src] apart."), \ SPAN_WARNING("You hear a metal clank and some sparks.") \ ) diff --git a/code/game/objects/structures/extinguisher.dm b/code/game/objects/structures/extinguisher.dm index e25860f049e..bab25178488 100644 --- a/code/game/objects/structures/extinguisher.dm +++ b/code/game/objects/structures/extinguisher.dm @@ -40,15 +40,15 @@ pixel_x = dir & (NORTH|SOUTH) ? 0 : (dir == EAST ? 21 : 4) pixel_y = dir & (NORTH|SOUTH) ? (dir == NORTH ? 24 : -23) : 4 -/obj/structure/extinguisher_cabinet/attackby(obj/item/O, mob/user) +/obj/structure/extinguisher_cabinet/attackby(obj/item/attacking_item, mob/user) if(isrobot(user)) return - if(istype(O, /obj/item/extinguisher)) + if(istype(attacking_item, /obj/item/extinguisher)) if(!has_extinguisher && opened) - user.remove_from_mob(O) - contents += O - has_extinguisher = O - to_chat(user, "You place [O] in [src].") + user.remove_from_mob(attacking_item) + contents += attacking_item + has_extinguisher = attacking_item + to_chat(user, "You place [attacking_item] in [src].") playsound(src.loc, 'sound/effects/extin.ogg', 50, 0) else opened = !opened diff --git a/code/game/objects/structures/fireaxe_cabinet.dm b/code/game/objects/structures/fireaxe_cabinet.dm index c2a01c9cba2..bf498e7726b 100644 --- a/code/game/objects/structures/fireaxe_cabinet.dm +++ b/code/game/objects/structures/fireaxe_cabinet.dm @@ -114,25 +114,25 @@ fireaxe = null return ..() -/obj/structure/fireaxecabinet/attackby(var/obj/item/O, var/mob/user) - if(O.ismultitool()) +/obj/structure/fireaxecabinet/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ismultitool()) toggle_lock(user) return - if(istype(O, /obj/item/material/twohanded/fireaxe)) + if(istype(attacking_item, /obj/item/material/twohanded/fireaxe)) if(open) if(fireaxe) to_chat(user, SPAN_ALERT("There is already \a [fireaxe] inside \the [src].")) - else if(user.unEquip(O)) - O.forceMove(src) - fireaxe = O + else if(user.unEquip(attacking_item)) + attacking_item.forceMove(src) + fireaxe = attacking_item to_chat(user, SPAN_NOTICE("You place \the [fireaxe] into \the [src].")) update_icon() return - if(O.force) + if(attacking_item.force) user.setClickCooldown(10) - attack_generic(user, O.force, "bashes") + attack_generic(user, attacking_item.force, "bashes") return return ..() diff --git a/code/game/objects/structures/flags_banners.dm b/code/game/objects/structures/flags_banners.dm index 4432e264bcf..8dd09bc8aee 100644 --- a/code/game/objects/structures/flags_banners.dm +++ b/code/game/objects/structures/flags_banners.dm @@ -263,9 +263,9 @@ if(rip_linked && linked_flag) linked_flag.rip(user, FALSE) // Prevents an infinite ripping loop. -/obj/structure/sign/flag/attackby(obj/item/W, mob/user) +/obj/structure/sign/flag/attackby(obj/item/attacking_item, mob/user) ..() - if(W.isFlameSource()) + if(attacking_item.isFlameSource()) visible_message(SPAN_WARNING("\The [user] starts to burn \the [src] down!")) if(!do_after(user, 2 SECONDS, src)) return FALSE diff --git a/code/game/objects/structures/full_window_frame.dm b/code/game/objects/structures/full_window_frame.dm index 2fde8584026..115ff4ab822 100644 --- a/code/game/objects/structures/full_window_frame.dm +++ b/code/game/objects/structures/full_window_frame.dm @@ -54,20 +54,20 @@ return TRUE return FALSE -/obj/structure/window_frame/attackby(obj/item/W, mob/user) - if((W.isscrewdriver()) && (istype(loc, /turf/simulated) || anchored)) +/obj/structure/window_frame/attackby(obj/item/attacking_item, mob/user) + if((attacking_item.isscrewdriver()) && (istype(loc, /turf/simulated) || anchored)) if(has_glass_installed) to_chat(user, SPAN_NOTICE("You can't unfasten \the [src] if it has glass installed.")) return if(anchored) - if(W.use_tool(src, user, 2 SECONDS, volume = 50)) + if(attacking_item.use_tool(src, user, 2 SECONDS, volume = 50)) anchored = FALSE to_chat(user, SPAN_NOTICE("You unfasten \the [src].")) update_icon() update_nearby_icons() return else - if(W.use_tool(src, user, 2 SECONDS, volume = 50)) + if(attacking_item.use_tool(src, user, 2 SECONDS, volume = 50)) anchored = TRUE to_chat(user, SPAN_NOTICE("You fasten \the [src].")) dir = 2 @@ -75,14 +75,14 @@ update_nearby_icons() return - else if(W.iswelder()) + else if(attacking_item.iswelder()) if(has_glass_installed) to_chat(user, SPAN_NOTICE("You can't disassemble \the [src] if it has glass installed.")) return if(anchored) to_chat(user, SPAN_NOTICE("\The [src] needs to be unanchored to be able to be welded apart.")) return - var/obj/item/weldingtool/WT = W + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) to_chat(user, SPAN_NOTICE("\The [WT] isn't turned on.")) return @@ -92,7 +92,7 @@ SPAN_NOTICE("You start welding \the [src] apart..."), "You hear deconstruction." ) - if(W.use_tool(src, user, 2 SECONDS, volume = 50)) + if(attacking_item.use_tool(src, user, 2 SECONDS, volume = 50)) if(!src || !WT.isOn()) return if(WT.use(0, user)) @@ -102,11 +102,11 @@ qdel(src) return - else if(istype(W, /obj/item/stack/material) && W.get_material_name() == MATERIAL_GLASS_REINFORCED && anchored) + else if(istype(attacking_item, /obj/item/stack/material) && attacking_item.get_material_name() == MATERIAL_GLASS_REINFORCED && anchored) if(has_glass_installed) to_chat(user, SPAN_NOTICE("\The [src] already has glass installed.")) return - var/obj/item/stack/material/G = W + var/obj/item/stack/material/G = attacking_item if(do_after(user, 2 SECONDS)) if(G.use(glass_needed)) playsound(src, 'sound/items/Deconstruct.ogg', 50, 1) @@ -118,11 +118,11 @@ else to_chat(user, SPAN_NOTICE("You need at least [glass_needed] sheets of [MATERIAL_GLASS_REINFORCED] to install a window in \the [src].")) - else if(istype(W, /obj/item/stack/material) && W.get_material_name() == MATERIAL_GLASS_REINFORCED_PHORON && anchored) + else if(istype(attacking_item, /obj/item/stack/material) && attacking_item.get_material_name() == MATERIAL_GLASS_REINFORCED_PHORON && anchored) if(has_glass_installed) to_chat(user, SPAN_NOTICE("\The [src] already has glass installed.")) return - var/obj/item/stack/material/G = W + var/obj/item/stack/material/G = attacking_item if(do_after(user, 2 SECONDS)) if(G.use(glass_needed)) playsound(src, 'sound/items/Deconstruct.ogg', 50, 1) diff --git a/code/game/objects/structures/girders.dm b/code/game/objects/structures/girders.dm index bd83eaf810f..8ea8209328c 100644 --- a/code/game/objects/structures/girders.dm +++ b/code/game/objects/structures/girders.dm @@ -18,20 +18,20 @@ var/reinforcing = 0 var/plating = FALSE -/obj/structure/girder/examine(mob/user, distance, infix, suffix) +/obj/structure/girder/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() var/state var/current_damage = health / initial(health) switch(current_damage) if(0 to 0.2) - state = "The support struts are collapsing!" + state = SPAN_DANGER("The support struts are collapsing!") if(0.2 to 0.4) - state = "The support struts are warped!" + state = SPAN_WARNING("The support struts are warped!") if(0.4 to 0.8) - state = "The support struts are dented, but holding together." + state = SPAN_NOTICE("The support struts are dented, but holding together.") if(0.8 to 1) - state = "The support struts look completely intact." - to_chat(user, state) + state = SPAN_NOTICE("The support struts look completely intact.") + . += state /obj/structure/girder/displaced name = "displaced girder" @@ -72,36 +72,36 @@ if(reinf_material) reinforce_girder() -/obj/structure/girder/attackby(obj/item/W as obj, mob/user as mob) - if(W.iswrench() && state == 0) +/obj/structure/girder/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswrench() && state == 0) if(anchored && !reinf_material) to_chat(user, "Now disassembling the girder...") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return to_chat(user, "You dissasembled the girder!") dismantle() else if(!anchored) to_chat(user, "Now securing the girder...") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) to_chat(user, "You secured the girder!") reset_girder() - else if(istype(W, /obj/item/gun/energy/plasmacutter)) - var/obj/item/gun/energy/plasmacutter/PC = W + else if(istype(attacking_item, /obj/item/gun/energy/plasmacutter)) + var/obj/item/gun/energy/plasmacutter/PC = attacking_item to_chat(user, SPAN_NOTICE("You start lining up \the [PC] to the joints of \the [src]...")) if(do_after(user, 2 SECONDS)) if(!src) return playsound(loc, PC.fire_sound, 100, 1) to_chat(user, SPAN_NOTICE("You blast apart the girder!")) - W.use_resource(user, 1) + attacking_item.use_resource(user, 1) dismantle() - else if(istype(W, /obj/item/melee/energy)) - var/obj/item/melee/energy/WT = W + else if(istype(attacking_item, /obj/item/melee/energy)) + var/obj/item/melee/energy/WT = attacking_item if(WT.active) to_chat(user, "Now slicing apart the girder...") - if(W.use_tool(src, user, 30, volume = 50)) + if(attacking_item.use_tool(src, user, 30, volume = 50)) if(!src) return to_chat(user, "You slice apart the girder!") dismantle() @@ -109,15 +109,15 @@ to_chat(user, "You need to activate the weapon to do that!") return - else if(istype(W, /obj/item/melee/energy/blade)) + else if(istype(attacking_item, /obj/item/melee/energy/blade)) to_chat(user, "Now slicing apart the girder...") - if(W.use_tool(src, user, 30, volume = 50)) + if(attacking_item.use_tool(src, user, 30, volume = 50)) if(!src) return to_chat(user, "You slice apart the girder!") dismantle() - else if(istype(W, /obj/item/melee/chainsword)) - var/obj/item/melee/chainsword/WT = W + else if(istype(attacking_item, /obj/item/melee/chainsword)) + var/obj/item/melee/chainsword/WT = attacking_item if(WT.active) to_chat(user, "Now slicing apart the girder...") if(WT.use_tool(src, user, 60, volume = 50)) @@ -128,11 +128,11 @@ to_chat(user, "You need to activate the weapon to do that!") return - else if(istype(W, /obj/item/pickaxe/diamonddrill)) + else if(istype(attacking_item, /obj/item/pickaxe/diamonddrill)) to_chat(user, "You drill through the girder!") dismantle() - else if(istype(W, /obj/item/melee/arm_blade/)) + else if(istype(attacking_item, /obj/item/melee/arm_blade/)) to_chat(user, "Now slicing apart the girder...") if(do_after(user,150)) if(!src) @@ -140,31 +140,31 @@ to_chat(user, "You slice apart the girder!") dismantle() - else if(W.isscrewdriver()) + else if(attacking_item.isscrewdriver()) if(state == 2) to_chat(user, "Now unsecuring support struts...") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return to_chat(user, "You unsecured the support struts!") state = 1 else if(anchored && !reinf_material) - playsound(src.loc, W.usesound, 50, 1) + playsound(src.loc, attacking_item.usesound, 50, 1) reinforcing = !reinforcing to_chat(user, "\The [src] can now be [reinforcing? "reinforced" : "constructed"]!") return - else if(W.iswirecutter() && state == 1) + else if(attacking_item.iswirecutter() && state == 1) to_chat(user, "Now removing support struts...") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return to_chat(user, "You removed the support struts!") reinf_material = null reset_girder() - else if(W.iscrowbar() && state == 0 && anchored) + else if(attacking_item.iscrowbar() && state == 0 && anchored) to_chat(user, "Now dislodging the girder...") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return to_chat(user, "You dislodged the girder!") icon_state = "displaced" @@ -172,16 +172,16 @@ health = 50 cover = 25 - else if(istype(W, /obj/item/stack/material)) + else if(istype(attacking_item, /obj/item/stack/material)) if(reinforcing && !reinf_material) - if(!reinforce_with_material(W, user)) + if(!reinforce_with_material(attacking_item, user)) return ..() else - if(!construct_wall(W, user)) + if(!construct_wall(attacking_item, user)) return ..() - else if(W.force) - var/damage_to_deal = W.force + else if(attacking_item.force) + var/damage_to_deal = attacking_item.force var/weaken = 0 if(reinf_material) weaken += reinf_material.integrity * 3 //Since girders don't have a secondary material, buff 'em up a bit. @@ -190,10 +190,10 @@ playsound(src, 'sound/weapons/smash.ogg', 50) if(damage_to_deal > weaken && (damage_to_deal > MIN_DAMAGE_TO_HIT)) damage_to_deal -= weaken - visible_message("[user] strikes \the [src] with \the [W], [is_sharp(W) ? "slicing" : "denting"] a support rod!") + visible_message("[user] strikes \the [src] with \the [attacking_item], [is_sharp(attacking_item) ? "slicing" : "denting"] a support rod!") take_damage(damage_to_deal) else - visible_message("[user] strikes \the [src] with \the [W], but it bounces off!") + visible_message("[user] strikes \the [src] with \the [attacking_item], but it bounces off!") user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) return @@ -325,43 +325,43 @@ new /obj/effect/decal/remains/human(get_turf(src)) qdel(src) -/obj/structure/girder/cult/attackby(obj/item/W as obj, mob/user as mob) - if(W.iswrench()) +/obj/structure/girder/cult/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswrench()) to_chat(user, "Now disassembling the girder...") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) to_chat(user, "You dissasembled the girder!") dismantle() - else if(istype(W, /obj/item/gun/energy/plasmacutter)) + else if(istype(attacking_item, /obj/item/gun/energy/plasmacutter)) to_chat(user, "Now slicing apart the girder...") - if(W.use_tool(src, user, 30, volume = 50)) + if(attacking_item.use_tool(src, user, 30, volume = 50)) to_chat(user, "You slice apart the girder!") dismantle() - else if(istype(W, /obj/item/pickaxe/diamonddrill)) + else if(istype(attacking_item, /obj/item/pickaxe/diamonddrill)) to_chat(user, "You drill through the girder!") new /obj/effect/decal/remains/human(get_turf(src)) dismantle() - else if(istype(W, /obj/item/melee/energy)) - var/obj/item/melee/energy/WT = W + else if(istype(attacking_item, /obj/item/melee/energy)) + var/obj/item/melee/energy/WT = attacking_item if(WT.active) to_chat(user, "Now slicing apart the girder...") - if(W.use_tool(src, user, 30, volume = 50)) + if(attacking_item.use_tool(src, user, 30, volume = 50)) to_chat(user, "You slice apart the girder!") dismantle() else to_chat(user, "You need to activate the weapon to do that!") return - else if(istype(W, /obj/item/melee/energy/blade)) + else if(istype(attacking_item, /obj/item/melee/energy/blade)) to_chat(user, "Now slicing apart the girder...") - if(W.use_tool(src, user, 30, volume = 50)) + if(attacking_item.use_tool(src, user, 30, volume = 50)) to_chat(user, "You slice apart the girder!") dismantle() - else if(istype(W, /obj/item/melee/chainsword)) - var/obj/item/melee/chainsword/WT = W + else if(istype(attacking_item, /obj/item/melee/chainsword)) + var/obj/item/melee/chainsword/WT = attacking_item if(WT.active) to_chat(user, "Now slicing apart the girder...") if(WT.use_tool(src, user, 60, volume = 50)) diff --git a/code/game/objects/structures/gore/core.dm b/code/game/objects/structures/gore/core.dm index f04df944274..fa9823aa4a4 100644 --- a/code/game/objects/structures/gore/core.dm +++ b/code/game/objects/structures/gore/core.dm @@ -13,18 +13,18 @@ . = ..() health = maxHealth -/obj/structure/gore/examine(mob/user, distance, is_adjacent) +/obj/structure/gore/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 2) var/health_div = health / maxHealth if(health_div >= 0.9) - to_chat(user, SPAN_NOTICE("\The [src] appears completely intact.")) + . += SPAN_NOTICE("\The [src] appears completely intact.") else if(health_div >= 0.7) - to_chat(user, SPAN_NOTICE("\The [src] is starting to tear somewhat.")) + . += SPAN_NOTICE("\The [src] is starting to tear somewhat.") else if(health_div >= 0.4) - to_chat(user, SPAN_WARNING("\The [src] is starting to fall apart.")) + . += SPAN_WARNING("\The [src] is starting to fall apart.") else - to_chat(user, SPAN_WARNING("\The [src] is barely holding itself together!")) + . += SPAN_WARNING("\The [src] is barely holding itself together!") /obj/structure/gore/proc/healthcheck() if(health <= 0) @@ -66,11 +66,11 @@ /obj/structure/gore/attack_generic() attack_hand(usr) -/obj/structure/gore/attackby(obj/item/W, mob/user) +/obj/structure/gore/attackby(obj/item/attacking_item, mob/user) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - user.do_attack_animation(src, W) - var/force_damage = W.force - if(W.damtype == DAMAGE_BURN) + user.do_attack_animation(src, attacking_item) + var/force_damage = attacking_item.force + if(attacking_item.damtype == DAMAGE_BURN) force_damage *= 1.25 health -= force_damage playsound(loc, 'sound/effects/attackblob.ogg', 80, TRUE) diff --git a/code/game/objects/structures/gore/nest.dm b/code/game/objects/structures/gore/nest.dm index 3afc18124d3..098da1e2df9 100644 --- a/code/game/objects/structures/gore/nest.dm +++ b/code/game/objects/structures/gore/nest.dm @@ -13,18 +13,18 @@ . = ..() health = maxHealth -/obj/structure/bed/nest/examine(mob/user, distance, is_adjacent) +/obj/structure/bed/nest/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 2) var/health_div = health / maxHealth if(health_div >= 0.9) - to_chat(user, SPAN_NOTICE("\The [src] appears completely intact.")) + . += SPAN_NOTICE("\The [src] appears completely intact.") else if(health_div >= 0.7) - to_chat(user, SPAN_NOTICE("\The [src] is starting to tear somewhat.")) + . += SPAN_NOTICE("\The [src] is starting to tear somewhat.") else if(health_div >= 0.4) - to_chat(user, SPAN_WARNING("\The [src] is starting to fall apart.")) + . += SPAN_WARNING("\The [src] is starting to fall apart.") else - to_chat(user, SPAN_WARNING("\The [src] is barely holding itself together!")) + . += SPAN_WARNING("\The [src] is barely holding itself together!") /obj/structure/bed/nest/update_icon() return @@ -50,11 +50,11 @@ buck.old_y = 0 unbuckle() -/obj/structure/bed/nest/attackby(obj/item/W, mob/user) +/obj/structure/bed/nest/attackby(obj/item/attacking_item, mob/user) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - user.do_attack_animation(src, W) - var/force_damage = W.force - if(W.damtype == DAMAGE_BURN) + user.do_attack_animation(src, attacking_item) + var/force_damage = attacking_item.force + if(attacking_item.damtype == DAMAGE_BURN) force_damage *= 1.25 health -= force_damage playsound(loc, 'sound/effects/attackblob.ogg', 80, TRUE) diff --git a/code/game/objects/structures/grille.dm b/code/game/objects/structures/grille.dm index 8cec894e2d8..e8974f14693 100644 --- a/code/game/objects/structures/grille.dm +++ b/code/game/objects/structures/grille.dm @@ -139,30 +139,30 @@ src.health -= damage*0.2 spawn(0) healthcheck() //spawn to make sure we return properly if the grille is deleted -/obj/structure/grille/attackby(obj/item/W, mob/user) - if(W.iswirecutter()) +/obj/structure/grille/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswirecutter()) if(!shock(user, 100)) playsound(loc, 'sound/items/Wirecutter.ogg', 100, 1) new /obj/item/stack/rods(get_turf(src), destroyed ? 1 : 2) qdel(src) - else if(istype(W, /obj/item/gun/energy/plasmacutter)) - var/obj/item/gun/energy/plasmacutter/PC = W + else if(istype(attacking_item, /obj/item/gun/energy/plasmacutter)) + var/obj/item/gun/energy/plasmacutter/PC = attacking_item if(PC.check_power_and_message(user)) return PC.use_resource(user, 1) playsound(loc, PC.fire_sound, 100, TRUE) new /obj/item/stack/rods(get_turf(src), destroyed ? 1 : 2) qdel(src) - else if((W.isscrewdriver()) && (istype(loc, /turf/simulated) || anchored)) + else if((attacking_item.isscrewdriver()) && (istype(loc, /turf/simulated) || anchored)) if(!shock(user, 90)) playsound(loc, 'sound/items/Screwdriver.ogg', 100, 1) anchored = !anchored user.visible_message("[user] [anchored ? "fastens" : "unfastens"] the grille.", \ "You have [anchored ? "fastened the grille to" : "unfastened the grill from"] the floor.") return - else if(istype(W,/obj/item/stack/rods) && destroyed == 1) + else if(istype(attacking_item,/obj/item/stack/rods) && destroyed == 1) if(!shock(user, 90)) - var/obj/item/stack/rods/ROD = W + var/obj/item/stack/rods/ROD = attacking_item health = 10 density = 1 destroyed = 0 @@ -173,8 +173,8 @@ return //window placing begin //TODO CONVERT PROPERLY TO MATERIAL DATUM - else if(istype(W,/obj/item/stack/material)) - var/obj/item/stack/material/ST = W + else if(istype(attacking_item,/obj/item/stack/material)) + var/obj/item/stack/material/ST = attacking_item if(!ST.material.created_window) return 0 @@ -215,15 +215,15 @@ return //window placing end - else if(!(W.obj_flags & OBJ_FLAG_CONDUCTABLE) || !shock(user, 70)) + else if(!(attacking_item.obj_flags & OBJ_FLAG_CONDUCTABLE) || !shock(user, 70)) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) user.do_attack_animation(src) playsound(loc, 'sound/effects/grillehit.ogg', 80, 1) - switch(W.damtype) + switch(attacking_item.damtype) if("fire") - health -= W.force + health -= attacking_item.force if("brute") - health -= W.force * 0.1 + health -= attacking_item.force * 0.1 healthcheck() ..() return diff --git a/code/game/objects/structures/hadii_statue.dm b/code/game/objects/structures/hadii_statue.dm index 20edfd79e61..eeecf4a7460 100644 --- a/code/game/objects/structures/hadii_statue.dm +++ b/code/game/objects/structures/hadii_statue.dm @@ -44,16 +44,16 @@ toppled = TRUE update_icon() -/obj/structure/hadii_statue/attackby(obj/item/W, mob/user) +/obj/structure/hadii_statue/attackby(obj/item/attacking_item, mob/user) if(toppled) return user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) user.do_attack_animation(src) - if(W.force <= 15) - visible_message(SPAN_WARNING("\The [W] bounces off \the [src]!")) + if(attacking_item.force <= 15) + visible_message(SPAN_WARNING("\The [attacking_item] bounces off \the [src]!")) return - visible_message(SPAN_WARNING("\The [user] strikes \the [src] with \the [W]!")) - do_integrity_check(W.force) + visible_message(SPAN_WARNING("\The [user] strikes \the [src] with \the [attacking_item]!")) + do_integrity_check(attacking_item.force) /obj/structure/hadii_statue/proc/do_integrity_check(damage) if(toppled) diff --git a/code/game/objects/structures/inflatable.dm b/code/game/objects/structures/inflatable.dm index bc3019a8cf9..021112f30ff 100644 --- a/code/game/objects/structures/inflatable.dm +++ b/code/game/objects/structures/inflatable.dm @@ -96,17 +96,17 @@ add_fingerprint(user) return -/obj/structure/inflatable/attackby(obj/item/W, mob/user) - if(!istype(W) || istype(W, /obj/item/inflatable_dispenser)) +/obj/structure/inflatable/attackby(obj/item/attacking_item, mob/user) + if(!istype(attacking_item) || istype(attacking_item, /obj/item/inflatable_dispenser)) return if(deflating) return - if(W.can_puncture()) - user.visible_message(SPAN_DANGER("[user] pierces \the [src] with \the [W]!"), SPAN_WARNING("You pierce \the [src] with \the [W]!")) + if(attacking_item.can_puncture()) + user.visible_message(SPAN_DANGER("[user] pierces \the [src] with \the [attacking_item]!"), SPAN_WARNING("You pierce \the [src] with \the [attacking_item]!")) deflate(TRUE) - else if(W.damtype == DAMAGE_BRUTE || W.damtype == DAMAGE_BURN) - hit(W.force) + else if(attacking_item.damtype == DAMAGE_BRUTE || attacking_item.damtype == DAMAGE_BURN) + hit(attacking_item.force) ..() /obj/structure/inflatable/proc/hit(var/damage, var/sound_effect = TRUE) diff --git a/code/game/objects/structures/janicart.dm b/code/game/objects/structures/janicart.dm index 36752503cb4..a4b1682c29a 100644 --- a/code/game/objects/structures/janicart.dm +++ b/code/game/objects/structures/janicart.dm @@ -88,14 +88,14 @@ /obj/structure/janitorialcart/proc/get_short_status() return "Contents: [english_list(contents)]" -/obj/structure/janitorialcart/examine(mob/user, distance, is_adjacent) +/obj/structure/janitorialcart/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1) if (mybucket) var/contains = mybucket.reagents.total_volume - to_chat(user, "[icon2html(src, user)] The bucket contains [contains] unit\s of liquid!") + . += "[icon2html(src, user)] The bucket contains [contains] unit\s of liquid!" else - to_chat(user, "[icon2html(src, user)] There is no bucket mounted on it!") + . += "[icon2html(src, user)] There is no bucket mounted on it!" //everything else is visible, so doesn't need to be mentioned @@ -133,67 +133,67 @@ return mybag.attackby(I, usr) -/obj/structure/janitorialcart/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/mop) || istype(I, /obj/item/reagent_containers/glass/rag) || istype(I, /obj/item/soap)) +/obj/structure/janitorialcart/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/mop) || istype(attacking_item, /obj/item/reagent_containers/glass/rag) || istype(attacking_item, /obj/item/soap)) if (mybucket) - if(I.reagents.total_volume < I.reagents.maximum_volume) + if(attacking_item.reagents.total_volume < attacking_item.reagents.maximum_volume) if(mybucket.reagents.total_volume < 1) to_chat(user, "[mybucket] is empty!") update_icon() else - mybucket.reagents.trans_to_obj(I, 5) // - to_chat(user, "You wet [I] in [mybucket].") + mybucket.reagents.trans_to_obj(attacking_item, 5) // + to_chat(user, "You wet [attacking_item] in [mybucket].") playsound(loc, 'sound/effects/slosh.ogg', 25, 1) update_icon() else - to_chat(user, "[I] can't absorb anymore liquid!") + to_chat(user, "[attacking_item] can't absorb anymore liquid!") else - to_chat(user, "There is no bucket mounted here to dip [I] into!") + to_chat(user, "There is no bucket mounted here to dip [attacking_item] into!") return 1 - else if(istype(I, /obj/item/reagent_containers/spray) && !myspray) - user.drop_from_inventory(I,src) - myspray = I + else if(istype(attacking_item, /obj/item/reagent_containers/spray) && !myspray) + user.drop_from_inventory(attacking_item, src) + myspray = attacking_item update_icon() updateUsrDialog() - to_chat(user, "You put [I] into [src].") + to_chat(user, "You put [attacking_item] into [src].") return 1 - else if(istype(I, /obj/item/device/lightreplacer) && !myreplacer) - user.drop_from_inventory(I,src) - myreplacer = I + else if(istype(attacking_item, /obj/item/device/lightreplacer) && !myreplacer) + user.drop_from_inventory(attacking_item, src) + myreplacer = attacking_item update_icon() updateUsrDialog() - to_chat(user, "You put [I] into [src].") + to_chat(user, "You put [attacking_item] into [src].") return 1 - else if(istype(I, /obj/item/storage/bag/trash) && !mybag) - user.drop_from_inventory(I,src) - mybag = I - I.forceMove(src) + else if(istype(attacking_item, /obj/item/storage/bag/trash) && !mybag) + user.drop_from_inventory(attacking_item, src) + mybag = attacking_item + attacking_item.forceMove(src) update_icon() updateUsrDialog() - to_chat(user, "You put [I] into [src].") + to_chat(user, "You put [attacking_item] into [src].") return 1 - else if(istype(I, /obj/item/clothing/suit/caution)) + else if(istype(attacking_item, /obj/item/clothing/suit/caution)) if(signs < 4) - user.drop_from_inventory(I,src) + user.drop_from_inventory(attacking_item, src) signs++ update_icon() updateUsrDialog() - to_chat(user, "You put [I] into [src].") + to_chat(user, "You put [attacking_item] into [src].") else to_chat(user, "[src] can't hold any more signs.") return 1 else if(mybag) - return mybag.attackby(I, user) + return mybag.attackby(attacking_item, user) //This return will prevent afterattack from executing if the object goes into the trashbag, //This prevents dumb stuff like splashing the cart with the contents of a container, after putting said container into trash - else if (!has_items && (I.iswrench() || I.iswelder() || istype(I, /obj/item/gun/energy/plasmacutter))) - take_apart(user, I) + else if (!has_items && (attacking_item.iswrench() || attacking_item.iswelder() || istype(attacking_item, /obj/item/gun/energy/plasmacutter))) + take_apart(user, attacking_item) return ..() diff --git a/code/game/objects/structures/kitchen_spike.dm b/code/game/objects/structures/kitchen_spike.dm index d2a6291cac4..cc3167664ec 100644 --- a/code/game/objects/structures/kitchen_spike.dm +++ b/code/game/objects/structures/kitchen_spike.dm @@ -12,8 +12,9 @@ var/meat_type var/victim_name = "corpse" -/obj/structure/kitchenspike/attackby(obj/item/grab/G as obj, mob/user as mob) - if(!istype(G, /obj/item/grab) || !G.affecting) +/obj/structure/kitchenspike/attackby(obj/item/attacking_item, mob/user) + var/obj/item/grab/G = attacking_item + if(!istype(G) || !G.affecting) return if(occupied) to_chat(user, SPAN_DANGER("The spike already has something on it, finish collecting its meat first!")) diff --git a/code/game/objects/structures/lattice.dm b/code/game/objects/structures/lattice.dm index 7b5289d6bdc..ca4f4a0dccc 100644 --- a/code/game/objects/structures/lattice.dm +++ b/code/game/objects/structures/lattice.dm @@ -49,19 +49,19 @@ qdel(src) return -/obj/structure/lattice/attackby(obj/item/C, mob/user) - if (istype(C, /obj/item/stack/tile/floor)) +/obj/structure/lattice/attackby(obj/item/attacking_item, mob/user) + if (istype(attacking_item, /obj/item/stack/tile/floor)) var/turf/T = get_turf(src) - T.attackby(C, user) //BubbleWrap - hand this off to the underlying turf instead + T.attackby(attacking_item, user) //BubbleWrap - hand this off to the underlying turf instead return - if (C.iswelder()) - var/obj/item/weldingtool/WT = C + if (attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(WT.use(1, user)) to_chat(user, "Slicing lattice joints ...") new /obj/item/stack/rods(src.loc) qdel(src) - if (istype(C, /obj/item/stack/rods)) - var/obj/item/stack/rods/R = C + if (istype(attacking_item, /obj/item/stack/rods)) + var/obj/item/stack/rods/R = attacking_item if (R.use(2)) to_chat(user, "Constructing catwalk ...") playsound(src, 'sound/weapons/Genhit.ogg', 50, 1) @@ -87,22 +87,22 @@ can_be_unanchored = TRUE layer = 2.7 // Above wires. -/obj/structure/lattice/catwalk/attackby(obj/item/C, mob/user) - if(C.iswelder()) - var/obj/item/weldingtool/WT = C +/obj/structure/lattice/catwalk/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.use(1, user)) to_chat(user, SPAN_WARNING("You need more welding fuel to complete this task.")) return - if(C.use_tool(src, user, 5, volume = 50)) + if(attacking_item.use_tool(src, user, 5, volume = 50)) to_chat(user, SPAN_NOTICE("You slice apart [src].")) var/obj/item/stack/rods/R = new /obj/item/stack/rods(get_turf(src)) R.amount = return_amount R.update_icon() qdel(src) -/obj/structure/lattice/catwalk/indoor/attackby(obj/item/C, mob/user) - if(C.isscrewdriver()) - if(C.use_tool(src, user, 5, volume = 50)) +/obj/structure/lattice/catwalk/indoor/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) + if(attacking_item.use_tool(src, user, 5, volume = 50)) anchored = !anchored to_chat(user, SPAN_NOTICE("You [anchored ? "" : "un"]anchor [src].")) SSicon_smooth.add_to_queue(src) @@ -127,10 +127,10 @@ var/base_icon_state = "grate" var/damaged = FALSE -/obj/structure/lattice/catwalk/indoor/grate/attackby(obj/item/C, mob/user) - if(C.iswelder() && damaged) - var/obj/item/weldingtool/WT = C - if(C.use_tool(src, user, 5, volume = 50) && WT.use(1, user)) +/obj/structure/lattice/catwalk/indoor/grate/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswelder() && damaged) + var/obj/item/weldingtool/WT = attacking_item + if(attacking_item.use_tool(src, user, 5, volume = 50) && WT.use(1, user)) user.visible_message( SPAN_NOTICE("\The [user] slices apart \the [src], leaving nothing useful behind."), SPAN_NOTICE("You slice apart \the [src], leaving nothing useful behind."), diff --git a/code/game/objects/structures/mirror.dm b/code/game/objects/structures/mirror.dm index 041537b8902..cadd924a155 100644 --- a/code/game/objects/structures/mirror.dm +++ b/code/game/objects/structures/mirror.dm @@ -65,16 +65,16 @@ playsound(src, 'sound/effects/hit_on_shattered_glass.ogg', 70, 1) ..() -/obj/structure/mirror/attackby(obj/item/I as obj, mob/user as mob) +/obj/structure/mirror/attackby(obj/item/attacking_item, mob/user) if(shattered) playsound(src.loc, 'sound/effects/hit_on_shattered_glass.ogg', 70, 1) return - if(prob(I.force * 2)) - visible_message("[user] smashes [src] with [I]!") + if(prob(attacking_item.force * 2)) + visible_message("[user] smashes [src] with [attacking_item]!") shatter() else - visible_message("[user] hits [src] with [I]!") + visible_message("[user] hits [src] with [attacking_item]!") playsound(src.loc, 'sound/effects/glass_hit.ogg', 70, 1) /obj/structure/mirror/attack_generic(var/mob/user, var/damage) diff --git a/code/game/objects/structures/mop_bucket.dm b/code/game/objects/structures/mop_bucket.dm index 626c8cb316e..2cc37cf68d9 100644 --- a/code/game/objects/structures/mop_bucket.dm +++ b/code/game/objects/structures/mop_bucket.dm @@ -18,18 +18,18 @@ GLOB.janitorial_supplies -= src return ..() -/obj/structure/mopbucket/examine(mob/user, distance, is_adjacent) +/obj/structure/mopbucket/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1) - to_chat(user, "Contains [reagents.total_volume] unit\s of water.") + . += "It contains [reagents.total_volume] unit\s of water." -/obj/structure/mopbucket/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/mop)) +/obj/structure/mopbucket/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/mop)) if(reagents.total_volume < 1) to_chat(user, "\The [src] is out of water!") else - reagents.trans_to_obj(I, 5) - to_chat(user, "You wet \the [I] in \the [src].") + reagents.trans_to_obj(attacking_item, 5) + to_chat(user, "You wet \the [attacking_item] in \the [src].") playsound(loc, 'sound/effects/slosh.ogg', 25, 1) return ..() update_icon() diff --git a/code/game/objects/structures/morgue.dm b/code/game/objects/structures/morgue.dm index 1d05a12eba7..bc0946f51f2 100644 --- a/code/game/objects/structures/morgue.dm +++ b/code/game/objects/structures/morgue.dm @@ -92,10 +92,10 @@ return attack_hand(user) else return ..() -/obj/structure/morgue/attackby(obj/P, mob/user) - if(P.ispen()) +/obj/structure/morgue/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ispen()) var/t = tgui_input_text(user, "What would you like the label to be?", "Morgue", "", MAX_NAME_LEN) - if(user.get_active_hand() != P) + if(user.get_active_hand() != attacking_item) return if((!in_range(src, usr) > 1 && src.loc != user)) return diff --git a/code/game/objects/structures/noticeboard.dm b/code/game/objects/structures/noticeboard.dm index 44ea88f3efc..1d26a17a3e4 100644 --- a/code/game/objects/structures/noticeboard.dm +++ b/code/game/objects/structures/noticeboard.dm @@ -17,12 +17,12 @@ icon_state = "nboard0[notices]" //attaching papers!! -/obj/structure/noticeboard/attackby(var/obj/item/O as obj, var/mob/user as mob) - if(istype(O, /obj/item/paper)) +/obj/structure/noticeboard/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/paper)) if(notices < 5) - O.add_fingerprint(user) + attacking_item.add_fingerprint(user) add_fingerprint(user) - user.drop_from_inventory(O,src) + user.drop_from_inventory(attacking_item,src) notices++ icon_state = "nboard0[notices]" //update sprite to_chat(user, "You pin the paper to the noticeboard.") @@ -34,7 +34,7 @@ // Since Topic() never seems to interact with usr on more than a superficial // level, it should be fine to let anyone mess with the board other than ghosts. -/obj/structure/noticeboard/examine(mob/user, distance, is_adjacent) +/obj/structure/noticeboard/examine(mob/user, distance, is_adjacent, infix, suffix) if(is_adjacent) var/dat = "Noticeboard
" for(var/obj/item/paper/P in src) diff --git a/code/game/objects/structures/plasticflaps.dm b/code/game/objects/structures/plasticflaps.dm index 4ba9e654f82..aa18b97fb5e 100644 --- a/code/game/objects/structures/plasticflaps.dm +++ b/code/game/objects/structures/plasticflaps.dm @@ -89,13 +89,13 @@ if (prob(5)) qdel(src) -/obj/structure/plasticflaps/attackby(obj/item/W, mob/user) +/obj/structure/plasticflaps/attackby(obj/item/attacking_item, mob/user) if(manipulating) return - if(W.iswirecutter() || W.sharp && !W.noslice) + if(attacking_item.iswirecutter() || attacking_item.sharp && !attacking_item.noslice) manipulating = TRUE visible_message(SPAN_NOTICE("[user] begins cutting down \the [src]."), SPAN_NOTICE("You begin cutting down \the [src].")) - if(!W.use_tool(src, user, 30, volume = 50)) + if(!attacking_item.use_tool(src, user, 30, volume = 50)) manipulating = FALSE return visible_message(SPAN_NOTICE("[user] cuts down \the [src]."), SPAN_NOTICE("You cut down \the [src].")) diff --git a/code/game/objects/structures/railing.dm b/code/game/objects/structures/railing.dm index a5ee93a8fa1..752b0630ca5 100644 --- a/code/game/objects/structures/railing.dm +++ b/code/game/objects/structures/railing.dm @@ -71,18 +71,18 @@ R.update_icon() return ..() -/obj/structure/railing/examine(mob/user) +/obj/structure/railing/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(health < maxhealth) switch(health / maxhealth) if(0.0 to 0.5) - to_chat(user, SPAN_WARNING("It looks severely damaged!")) + . += SPAN_WARNING("It looks severely damaged!") if(0.25 to 0.5) - to_chat(user, SPAN_WARNING("It looks damaged!")) + . += SPAN_WARNING("It looks damaged!") if(0.5 to 1.0) - to_chat(user, SPAN_NOTICE("It has a few scrapes and dents.")) - to_chat(user, FONT_SMALL(SPAN_NOTICE("\The [src] is [density ? "closed" : "open"] to passage."))) - to_chat(user, FONT_SMALL(SPAN_NOTICE("\The [src] is [anchored ? "" : "not"] screwed to the floor."))) + . += SPAN_NOTICE("It has a few scrapes and dents.") + . += FONT_SMALL(SPAN_NOTICE("\The [src] is [density ? "closed" : "open"] to passage.")) + . += FONT_SMALL(SPAN_NOTICE("\The [src] is [anchored ? "" : "not"] screwed to the floor.")) /obj/structure/railing/CanPass(atom/movable/mover, turf/target, height=0, air_group=0) if(istype(mover,/obj/item/projectile)) @@ -198,10 +198,10 @@ return FALSE return TRUE -/obj/structure/railing/attackby(var/obj/item/W, var/mob/user) +/obj/structure/railing/attackby(obj/item/attacking_item, mob/user) // Handle harm intent grabbing/tabling. - if(istype(W, /obj/item/grab) && user.Adjacent(src)) - var/obj/item/grab/G = W + if(istype(attacking_item, /obj/item/grab) && user.Adjacent(src)) + var/obj/item/grab/G = attacking_item if(ishuman(G.affecting)) var/obj/occupied = turf_is_crowded(TRUE) if(occupied) @@ -225,10 +225,10 @@ return // Dismantle - if(W.iswrench()) + if(attacking_item.iswrench()) if(!anchored) user.visible_message(SPAN_NOTICE("\The [user] starts dismantling \the [src]..."), SPAN_NOTICE("You start dismantling \the [src]...")) - if(W.use_tool(src, user, 20, volume = 50)) + if(attacking_item.use_tool(src, user, 20, volume = 50)) if(anchored) return user.visible_message(SPAN_NOTICE("\The [user] dismantles \the [src]."), SPAN_NOTICE("You dismantle \the [src].")) @@ -237,7 +237,7 @@ return // Wrench Open else - playsound(get_turf(src), W.usesound, 50, TRUE) + playsound(get_turf(src), attacking_item.usesound, 50, TRUE) if(density) user.visible_message(SPAN_NOTICE("\The [user] wrenches \the [src] open."), SPAN_NOTICE("You wrench \the [src] open.")) density = FALSE @@ -247,13 +247,13 @@ update_icon() return // Repair - if(W.iswelder()) - var/obj/item/weldingtool/F = W + if(attacking_item.iswelder()) + var/obj/item/weldingtool/F = attacking_item if(F.isOn()) if(health >= maxhealth) to_chat(user, SPAN_WARNING("\The [src] does not need repairs.")) return - playsound(get_turf(src), W.usesound, 50, TRUE) + playsound(get_turf(src), attacking_item.usesound, 50, TRUE) if(do_after(user, 20, src)) if(health >= maxhealth) return @@ -262,22 +262,22 @@ return // Install - if(W.isscrewdriver()) + if(attacking_item.isscrewdriver()) if(!density) to_chat(user, SPAN_NOTICE("You need to wrench \the [src] from back into place first.")) return user.visible_message(anchored ? "\The [user] begins unscrewing \the [src]." : "\The [user] begins fastening \the [src]." ) - playsound(get_turf(src), W.usesound, 75, TRUE) + playsound(get_turf(src), attacking_item.usesound, 75, TRUE) if(do_after(user, 10, src) && density) to_chat(user, (anchored ? "You have unfastened \the [src] from the floor." : "You have fastened \the [src] to the floor.")) anchored = !anchored update_icon() return - if(W.force && (W.damtype == DAMAGE_BURN || W.damtype == DAMAGE_BRUTE)) + if(attacking_item.force && (attacking_item.damtype == DAMAGE_BURN || attacking_item.damtype == DAMAGE_BRUTE)) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - visible_message(SPAN_WARNING("\The [src] has been [LAZYLEN(W.attack_verb) ? pick(W.attack_verb) : "attacked"] with \the [W] by \the [user]!")) - take_damage(W.force) + visible_message(SPAN_WARNING("\The [src] has been [LAZYLEN(attacking_item.attack_verb) ? pick(attacking_item.attack_verb) : "attacked"] with \the [attacking_item] by \the [user]!")) + take_damage(attacking_item.force) return . = ..() diff --git a/code/game/objects/structures/safe.dm b/code/game/objects/structures/safe.dm index c98836e4ca8..3fab4824e8c 100644 --- a/code/game/objects/structures/safe.dm +++ b/code/game/objects/structures/safe.dm @@ -44,13 +44,13 @@ FLOOR SAFES space += I.w_class I.forceMove(src) -/obj/structure/safe/examine(mob/user) +/obj/structure/safe/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(broken) - to_chat(user, SPAN_WARNING("\The [src]'s locking system has been drilled open!")) + . += SPAN_WARNING("\The [src]'s locking system has been drilled open!") else if(time_to_drill < 300 SECONDS) var/time_left = max(round(time_to_drill / 10), 0) - to_chat(user, SPAN_WARNING("There are only [time_left] second\s of drilling left until \the [src] is broken!")) + . += SPAN_WARNING("There are only [time_left] second\s of drilling left until \the [src] is broken!") /obj/structure/safe/Destroy() if(drill) @@ -215,29 +215,29 @@ FLOOR SAFES updateUsrDialog() -/obj/structure/safe/attackby(obj/item/I as obj, mob/user as mob) +/obj/structure/safe/attackby(obj/item/attacking_item, mob/user) if(open) - if(I.w_class + space <= maxspace) - space += I.w_class - user.drop_from_inventory(I,src) - to_chat(user, SPAN_NOTICE("You put [I] in [src].")) + if(attacking_item.w_class + space <= maxspace) + space += attacking_item.w_class + user.drop_from_inventory(attacking_item, src) + to_chat(user, SPAN_NOTICE("You put [attacking_item] in [src].")) updateUsrDialog() return else - to_chat(user, SPAN_NOTICE("[I] won't fit in [src].")) + to_chat(user, SPAN_NOTICE("[attacking_item] won't fit in [src].")) return else - if(istype(I, /obj/item/clothing/accessory/stethoscope)) + if(istype(attacking_item, /obj/item/clothing/accessory/stethoscope)) attack_hand(user) - else if(istype(I, /obj/item/thermal_drill)) + else if(istype(attacking_item, /obj/item/thermal_drill)) if(drill) to_chat(user, SPAN_WARNING("There is already a drill attached!")) else if(do_after(user, 2 SECONDS)) - user.drop_from_inventory(I, src) - drill = I + user.drop_from_inventory(attacking_item, src) + drill = attacking_item update_icon() else - to_chat(user, SPAN_WARNING("You can't put [I] into the safe while it is closed!")) + to_chat(user, SPAN_WARNING("You can't put [attacking_item] into the safe while it is closed!")) /obj/structure/safe/process() if(!drill) diff --git a/code/game/objects/structures/sarcophagus.dm b/code/game/objects/structures/sarcophagus.dm index f945bd32cd2..2dfe8425764 100644 --- a/code/game/objects/structures/sarcophagus.dm +++ b/code/game/objects/structures/sarcophagus.dm @@ -7,12 +7,12 @@ anchored = 0 var/open = FALSE -/obj/structure/sarcophagus/examine(mob/user) +/obj/structure/sarcophagus/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!open) - to_chat(user, "\The [src]'s lid is closed shut.") + . += "\The [src]'s lid is closed shut." else - to_chat(user, "\The [src]'s lid is open.") + . += "\The [src]'s lid is open." /obj/structure/sarcophagus/Initialize() . = ..() @@ -37,11 +37,11 @@ open() return -/obj/structure/sarcophagus/attackby(obj/item/I as obj, mob/user as mob) +/obj/structure/sarcophagus/attackby(obj/item/attacking_item, mob/user) if(open) return - if(istype(I, /obj/item/sarcophagus_key)) - to_chat(usr, "You slide \the [I] inside an opening in \the [src].") + if(istype(attacking_item, /obj/item/sarcophagus_key)) + to_chat(usr, "You slide \the [attacking_item] inside an opening in \the [src].") open() /obj/structure/sarcophagus/proc/open() diff --git a/code/game/objects/structures/signs.dm b/code/game/objects/structures/signs.dm index c30643c2ece..429419916eb 100644 --- a/code/game/objects/structures/signs.dm +++ b/code/game/objects/structures/signs.dm @@ -16,10 +16,10 @@ /obj/structure/sign/ex_act(severity) qdel(src) -/obj/structure/sign/attackby(obj/item/tool, mob/user) // Deconstruction. - if(tool.isscrewdriver() && !istype(src, /obj/structure/sign/double)) +/obj/structure/sign/attackby(obj/item/attacking_item, mob/user) // Deconstruction. + if(attacking_item.isscrewdriver() && !istype(src, /obj/structure/sign/double)) user.visible_message(SPAN_NOTICE("\The [user] starts to unfasten \the [src]."), SPAN_NOTICE("You start to unfasten \the [src].")) - if(tool.use_tool(src, user, 0, volume = 50)) + if(attacking_item.use_tool(src, user, 0, volume = 50)) unfasten(user) else ..() @@ -39,8 +39,8 @@ w_class = ITEMSIZE_HUGE var/sign_state = "" -/obj/item/sign/attackby(obj/item/tool, mob/user) // Construction. - if(tool.isscrewdriver() && isturf(user.loc)) +/obj/item/sign/attackby(obj/item/attacking_item, mob/user) // Construction. + if(attacking_item.isscrewdriver() && isturf(user.loc)) var/direction = tgui_input_list(user, "In which direction?", "Select Direction", list("North", "East", "South", "West", "Cancel")) if(direction == "Cancel") return if(QDELETED(src)) //Prevents spawning multiple new signs with queued dialogues @@ -59,7 +59,7 @@ S.name = name S.desc = desc S.icon_state = sign_state - to_chat(user, "You fasten \the [S] with your [tool].") + to_chat(user, "You fasten \the [S] with your [attacking_item].") qdel(src) else ..() diff --git a/code/game/objects/structures/simple_doors.dm b/code/game/objects/structures/simple_doors.dm index c462be99ddc..b703a715a6f 100644 --- a/code/game/objects/structures/simple_doors.dm +++ b/code/game/objects/structures/simple_doors.dm @@ -58,10 +58,10 @@ lock = null return ..() -/obj/structure/simple_door/examine(mob/user) +/obj/structure/simple_door/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(lock) - to_chat(user, "It appears to have a lock.") + . += SPAN_NOTICE("It appears to have a lock.") /obj/structure/simple_door/CollidedWith(atom/user) ..() @@ -147,26 +147,26 @@ else icon_state = material.door_icon_base -/obj/structure/simple_door/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W, /obj/item/key) && lock) - var/obj/item/key/K = W - if(!lock.toggle(W)) +/obj/structure/simple_door/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/key) && lock) + var/obj/item/key/K = attacking_item + if(!lock.toggle(attacking_item)) to_chat(user, "\The [K] does not fit in the lock!") return - if(lock && lock.pick_lock(W,user)) + if(lock && lock.pick_lock(attacking_item, user)) return - if(istype(W,/obj/item/material/lock_construct)) + if(istype(attacking_item, /obj/item/material/lock_construct)) if(lock) to_chat(user, "\The [src] already has a lock.") else - var/obj/item/material/lock_construct/L = W + var/obj/item/material/lock_construct/L = attacking_item lock = L.create_lock(src,user) return - else if(istype(W,/obj/item)) - var/obj/item/I = W + else if(istype(attacking_item, /obj/item)) + var/obj/item/I = attacking_item user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) if(I.damtype == DAMAGE_BRUTE || I.damtype == DAMAGE_BURN) if(I.force < 10) @@ -175,8 +175,8 @@ user.do_attack_animation(src) shake_animation() user.visible_message("\The [user] forcefully strikes \the [src] with \the [I]!") - playsound(src.loc, material.hitsound, W.get_clamped_volume(), 1) - src.health -= W.force * 1 + playsound(src.loc, material.hitsound, attacking_item.get_clamped_volume(), 1) + src.health -= attacking_item.force * 1 CheckHealth() else diff --git a/code/game/objects/structures/stool_bed_chair_nest/bed.dm b/code/game/objects/structures/stool_bed_chair_nest/bed.dm index f2bf279757c..954c5369af5 100644 --- a/code/game/objects/structures/stool_bed_chair_nest/bed.dm +++ b/code/game/objects/structures/stool_bed_chair_nest/bed.dm @@ -146,26 +146,26 @@ qdel(src) return -/obj/structure/bed/attackby(obj/item/W as obj, mob/user as mob) - if(W.iswrench()) +/obj/structure/bed/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswrench()) if(can_dismantle) - dismantle(W, user) - else if(istype(W,/obj/item/stack)) + dismantle(attacking_item, user) + else if(istype(attacking_item,/obj/item/stack)) if(!can_pad) return if(padding_material) to_chat(user, "\The [src] is already padded.") return - var/obj/item/stack/C = W + var/obj/item/stack/C = attacking_item if(C.get_amount() < 1) // How?? to_chat(user, SPAN_WARNING("You don't have enough [C]!")) qdel(C) return var/padding_type //This is awful but it needs to be like this until tiles are given a material var. - if(istype(W,/obj/item/stack/tile/carpet)) + if(istype(attacking_item,/obj/item/stack/tile/carpet)) padding_type = "carpet" - else if(istype(W,/obj/item/stack/material)) - var/obj/item/stack/material/M = W + else if(istype(attacking_item,/obj/item/stack/material)) + var/obj/item/stack/material/M = attacking_item if(M.material && (M.material.flags & MATERIAL_PADDING)) padding_type = "[M.material.name]" if(!padding_type) @@ -179,7 +179,7 @@ add_padding(padding_type) return - else if (W.iswirecutter()) + else if (attacking_item.iswirecutter()) if(!can_pad) return if(!padding_material) @@ -190,7 +190,7 @@ painted_colour = null remove_padding() - else if (W.isscrewdriver()) + else if (attacking_item.isscrewdriver()) if(anchored) anchored = FALSE to_chat(user, "You unfasten \the [src] from floor.") @@ -199,8 +199,8 @@ to_chat(user, "You fasten \the [src] to the floor.") playsound(src, 'sound/items/Screwdriver.ogg', 100, 1) - else if(istype(W, /obj/item/grab)) - var/obj/item/grab/G = W + else if(istype(attacking_item, /obj/item/grab)) + var/obj/item/grab/G = attacking_item var/mob/living/affecting = G.affecting user.visible_message("[user] attempts to buckle [affecting] into \the [src]!") if(do_after(user, 2 SECONDS, affecting, DO_UNIQUE)) @@ -211,22 +211,22 @@ SPAN_DANGER("[affecting.name] is buckled to [src] by [user.name]!"),\ SPAN_DANGER("You are buckled to [src] by [user.name]!"),\ SPAN_NOTICE("You hear metal clanking.")) - qdel(W) + qdel(attacking_item) - else if(istype(W, /obj/item/gripper) && buckled) - var/obj/item/gripper/G = W + else if(istype(attacking_item, /obj/item/gripper) && buckled) + var/obj/item/gripper/G = attacking_item if(!G.wrapped) user_unbuckle(user) - else if(istype(W, /obj/item/disk)) - user.drop_from_inventory(W, get_turf(src)) - W.pixel_x = 10 //make sure they reach the pillow - W.pixel_y = -6 + else if(istype(attacking_item, /obj/item/disk)) + user.drop_from_inventory(attacking_item, get_turf(src)) + attacking_item.pixel_x = 10 //make sure they reach the pillow + attacking_item.pixel_y = -6 - else if(istype(W, /obj/item/device/paint_sprayer)) + else if(istype(attacking_item, /obj/item/device/paint_sprayer)) return - else if(!istype(W, /obj/item/bedsheet)) + else if(!istype(attacking_item, /obj/item/bedsheet)) ..() /obj/structure/bed/proc/remove_padding() @@ -417,24 +417,24 @@ vitals.update_monitor() vis_contents += vitals -/obj/structure/bed/roller/attackby(obj/item/I, mob/user) - if(iswrench(I) || istype(I, /obj/item/stack) || iswirecutter(I)) +/obj/structure/bed/roller/attackby(obj/item/attacking_item, mob/user) + if(iswrench(attacking_item) || istype(attacking_item, /obj/item/stack) || iswirecutter(attacking_item)) return 1 - if(istype(I, /obj/item/vitals_monitor)) + if(istype(attacking_item, /obj/item/vitals_monitor)) if(vitals) to_chat(user, SPAN_WARNING("\The [src] already has a vitals monitor attached!")) return - to_chat(user, SPAN_NOTICE("You attach \the [I] to \the [src].")) - user.drop_from_inventory(I, src) - vitals = I + to_chat(user, SPAN_NOTICE("You attach \the [attacking_item] to \the [src].")) + user.drop_from_inventory(attacking_item, src) + vitals = attacking_item vitals.bed = src update_icon() return - if(iv_stand && !beaker && is_type_in_list(I, accepted_containers)) - if(!user.unEquip(I, target = src)) + if(iv_stand && !beaker && is_type_in_list(attacking_item, accepted_containers)) + if(!user.unEquip(attacking_item, target = src)) return - to_chat(user, SPAN_NOTICE("You attach \the [I] to \the [src].")) - beaker = I + to_chat(user, SPAN_NOTICE("You attach \the [attacking_item] to \the [src].")) + beaker = attacking_item update_icon() return 1 ..() @@ -599,9 +599,9 @@ if(!T.density) deploy_roller(user, T) -/obj/item/roller/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W,/obj/item/roller_holder)) - var/obj/item/roller_holder/RH = W +/obj/item/roller/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/roller_holder)) + var/obj/item/roller_holder/RH = attacking_item if(!RH.held) to_chat(user, SPAN_NOTICE("You collect the roller bed.")) src.forceMove(RH) diff --git a/code/game/objects/structures/survey_probe.dm b/code/game/objects/structures/survey_probe.dm new file mode 100644 index 00000000000..5a5691b477a --- /dev/null +++ b/code/game/objects/structures/survey_probe.dm @@ -0,0 +1,136 @@ +/obj/structure/survey_probe + name = "survey probe" + desc = "\ + All-in-one survey probe, able to provide preliminary analysis of planetary bodies. \ + " + desc_extended = "\ + It has different devices, samplers, and drill bits, as well as internal processing computers, \ + to inspect the atmosphere, ground, soil, crust, and many other properties and qualities of planetary bodies. \ + Commonly used by surveyors, explorers, pioneers, all over the Spur, looking for planets that are actually worth settling or exploiting for resources. \ + This probe was manufactured by Orion Express, but it is based on on older model designed by Hephaestus Industries.\ + " + desc_info = "\ + The probe has to be deployed first before it is used. Wrench it to deploy, then click with empty hand to activate.\ + " + icon = 'icons/obj/xenoarchaeology.dmi' + icon_state = "surveying_probe" + density = FALSE + /// If false, probe is not deployed. + /// If true, it is deployed and ready to survey. + anchored = FALSE + /// Timer of the survey process. + /// If null, it is not currently surveying. + var/timer_id = null + +/obj/structure/survey_probe/attackby(obj/item/item, mob/living/user) + if(!timer_id && item.iswrench()) + if(!anchored) + user.visible_message( + SPAN_NOTICE("\The [user] unfastens the locking bolts on \the [src], deploying it."), + SPAN_NOTICE("You unfasten the locking bolts on \the [src], and it deploys, lowering its devices and drill bits to the ground. It is ready to survey."), + ) + item.play_tool_sound(user, 30) + anchored = TRUE + density = TRUE + icon_state = "surveying_probe_deployed" + else + user.visible_message( + SPAN_NOTICE("\The [user] fastens the locking bolts on \the [src], stowing it."), + SPAN_NOTICE("You fasten the locking bolts \the [src], stowing it. It retracts its devices and drill bits."), + ) + item.play_tool_sound(user, 30) + anchored = FALSE + density = FALSE + icon_state = "surveying_probe" + +/obj/structure/survey_probe/attack_hand(mob/user as mob) + if(timer_id) + to_chat(user, SPAN_NOTICE("\The [src] is active, sampling the ground and atmosphere.")) + return + + if(anchored) + user.visible_message( + SPAN_NOTICE("\The [user] activates \the [src], starting the surveying process."), + SPAN_NOTICE("You activate \the [src], starting the surveying process. It begins drilling into the ground and sampling the atmosphere."), + ) + timer_id = addtimer(CALLBACK(src, PROC_REF(survey_end)), 20 SECONDS) + icon_state = "surveying_probe_active" + else + to_chat(user, SPAN_NOTICE("You try to activate \the [src], but its devices and drill bits are not deployed yet.")) + +/obj/structure/survey_probe/proc/survey_end() + if(timer_id) + // message + src.visible_message( + SPAN_NOTICE("\The [src] finishes the surveying process, and prints out a report."), + ) + + // report vars and default vals + var/report_location = "unknown/invalid" + var/ground_report = "Invalid or insufficient data, ground survey unsuccessful. " + var/atmos_report = "Invalid or insufficient data, atmospheric survey unsuccessful. " + + // turf + var/turf/turf = get_turf(src) + var/turf_is_exoplanet = istype(turf, /turf/simulated/floor/exoplanet) + var/turf_is_asteroid = istype(turf, /turf/unsimulated/floor/asteroid) + var/turf_is_hard_floor = istype(turf, /turf/simulated/floor/tiled) + var/turf_is_fake_grass = istype(turf, /turf/simulated/floor/grass) + + // atmos + var/datum/gas_mixture/air = turf.return_air() + if(air.total_moles>0) + atmos_report = english_list(atmosanalyzer_scan(turf, air)) + + // not exoplanet turf + if(turf_is_hard_floor) + ground_report += "The probe cannot penetrate the hard metal floor." + else if(turf_is_fake_grass) + ground_report += "The probe detects soft soil, but it cannot penetrate the ground deep enough to get any meaningful data." + else if(!(turf_is_exoplanet || turf_is_asteroid)) + ground_report += "The probe cannot penetrate the ground deep enough to get any meaningful data." + + // ground survey from sector / exoplanet + if((turf_is_exoplanet || turf_is_asteroid) && SSatlas.current_map.use_overmap) + var/obj/effect/overmap/visitable/sector/sector = GLOB.map_sectors["[z]"] + var/obj/effect/overmap/visitable/sector/exoplanet/exoplanet = sector + if(istype(sector)) + report_location = sector.name + ground_report = "" + if(istype(exoplanet)) + ground_report += "Estimated Mass and Volume: [exoplanet.massvolume]BSS(Biesels)" + ground_report += "
Surface Gravity: [exoplanet.surfacegravity]Gs" + ground_report += "
Geological Variables: [exoplanet.geology]" + ground_report += "
Surface Water Coverage: [exoplanet.surfacewater]" + ground_report += "
Apparent Weather Data: [exoplanet.weather]" + ground_report += "
" + if(sector.ground_survey_result) + ground_report += sector.ground_survey_result + + // report text + var/timestamp = "[GLOB.game_year]-[time2text(world.realtime, "MM-DD")] [worldtime2text()]" + var/report_name = "surveying report - [report_location]" + var/report_contents = "\ +
Survey target: [report_location]\ +
Timestamp of survey: [timestamp]\ +
Signature of surveyor: \ +

\ +
Ground survey results:\ +
[ground_report]\ +

\ +
Atmospheric survey results:\ +
[atmos_report]\ +

\ +
Additional notes: \ +
\ +

\ + " + + // print the report + playsound(get_turf(src), 'sound/machines/dotprinter.ogg', 30, 1) + new/obj/item/paper/(get_turf(src), report_contents, report_name) + + // fin + timer_id = null + icon_state = "surveying_probe_deployed" + diff --git a/code/game/objects/structures/tank_dispenser.dm b/code/game/objects/structures/tank_dispenser.dm index 1aead171d40..063053a4d96 100644 --- a/code/game/objects/structures/tank_dispenser.dm +++ b/code/game/objects/structures/tank_dispenser.dm @@ -49,32 +49,32 @@ dispenser_win.set_content(dat) dispenser_win.open() -/obj/structure/dispenser/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/tank/oxygen) || istype(I, /obj/item/tank/air) || istype(I, /obj/item/tank/anesthetic)) +/obj/structure/dispenser/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/tank/oxygen) || istype(attacking_item, /obj/item/tank/air) || istype(attacking_item, /obj/item/tank/anesthetic)) if(oxygentanks < 10) - user.drop_from_inventory(I, src) - oxytanks.Add(I) + user.drop_from_inventory(attacking_item, src) + oxytanks.Add(attacking_item) oxygentanks++ - to_chat(user, SPAN_NOTICE("You put \the [I] into \the [src].")) + to_chat(user, SPAN_NOTICE("You put \the [attacking_item] into \the [src].")) if(oxygentanks < 5) update_icon() else to_chat(user, SPAN_WARNING("\The [src] is full.")) updateUsrDialog() return - if(istype(I, /obj/item/tank/phoron)) + if(istype(attacking_item, /obj/item/tank/phoron)) if(phorontanks < 10) - user.drop_from_inventory(I, src) - platanks.Add(I) + user.drop_from_inventory(attacking_item, src) + platanks.Add(attacking_item) phorontanks++ - to_chat(user, SPAN_NOTICE("You put \the [I] into \the [src].")) + to_chat(user, SPAN_NOTICE("You put \the [attacking_item] into \the [src].")) if(oxygentanks < 6) update_icon() else to_chat(user, SPAN_WARNING("\The [src] is full.")) updateUsrDialog() return - if(I.iswrench()) + if(attacking_item.iswrench()) if(anchored) to_chat(user, SPAN_NOTICE("You lean down and unwrench [src].")) anchored = FALSE diff --git a/code/game/objects/structures/target_stake.dm b/code/game/objects/structures/target_stake.dm index 797f1bfce8b..3febb4c3382 100644 --- a/code/game/objects/structures/target_stake.dm +++ b/code/game/objects/structures/target_stake.dm @@ -13,16 +13,16 @@ . = ..() material = SSmaterials.get_material_by_name(MATERIAL_STEEL) -/obj/structure/target_stake/attackby(var/obj/item/W, var/mob/user) - if(istype(W, /obj/item/target)) +/obj/structure/target_stake/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/target)) if(pinned_target) to_chat(user, SPAN_WARNING("\The [src] already has a target.")) return - if(user.unEquip(W, FALSE, get_turf(src))) - to_chat(user, SPAN_NOTICE("You slide \the [W] into the stake.")) - set_target(W) + if(user.unEquip(attacking_item, FALSE, get_turf(src))) + to_chat(user, SPAN_NOTICE("You slide \the [attacking_item] into the stake.")) + set_target(attacking_item) return - if(W.iswrench()) + if(attacking_item.iswrench()) if(pinned_target) to_chat(user, SPAN_WARNING("You cannot dismantle \the [src] while it has a target attached.")) return diff --git a/code/game/objects/structures/therapy.dm b/code/game/objects/structures/therapy.dm index 40e3ad6e1af..28eba94e4ad 100644 --- a/code/game/objects/structures/therapy.dm +++ b/code/game/objects/structures/therapy.dm @@ -179,9 +179,9 @@ . = ..() START_PROCESSING(SSfast_process, src) -/obj/structure/metronome/attackby(obj/item/W as obj, mob/user as mob) - if(W.iswrench()) - playsound(src.loc, W.usesound, 50, 1) +/obj/structure/metronome/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswrench()) + playsound(src.loc, attacking_item.usesound, 50, 1) if(anchored) to_chat(user, "You unanchor \the [src] and it destabilizes.") STOP_PROCESSING(SSfast_process, src) diff --git a/code/game/objects/structures/tranqcabinet.dm b/code/game/objects/structures/tranqcabinet.dm index 16136c189f6..62562a6ad98 100644 --- a/code/game/objects/structures/tranqcabinet.dm +++ b/code/game/objects/structures/tranqcabinet.dm @@ -12,15 +12,15 @@ ..() has_tranq = new/obj/item/gun/projectile/heavysniper/tranq(src) -/obj/structure/tranqcabinet/attackby(obj/item/O, mob/user) +/obj/structure/tranqcabinet/attackby(obj/item/attacking_item, mob/user) if(isrobot(user)) return - if(istype(O, /obj/item/gun/projectile/heavysniper/tranq)) + if(istype(attacking_item, /obj/item/gun/projectile/heavysniper/tranq)) if(!has_tranq && opened) - user.remove_from_mob(O) - contents += O - has_tranq = O - to_chat(user, "You place [O] in [src].") + user.remove_from_mob(attacking_item) + contents += attacking_item + has_tranq = attacking_item + to_chat(user, "You place [attacking_item] in [src].") else opened = !opened else diff --git a/code/game/objects/structures/urban.dm b/code/game/objects/structures/urban.dm index 0d660e48fc9..959111ca8fd 100644 --- a/code/game/objects/structures/urban.dm +++ b/code/game/objects/structures/urban.dm @@ -131,8 +131,8 @@ anchored = TRUE var/open = 0 -/obj/structure/manhole/attackby(obj/item/W as obj, mob/user as mob) - if(W.iscrowbar()) +/obj/structure/manhole/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iscrowbar()) playsound(src.loc, 'sound/effects/stonedoor_openclose.ogg', 50, 1) to_chat(user, "You forcibly relocate the manhole, hopefully in the right way.") if(!open) @@ -160,6 +160,14 @@ layer = ABOVE_ALL_MOB_LAYER anchored = TRUE +/obj/structure/urban_grate + name = "water drain grate" + desc = "A grate which funnels water into underground passageways." + icon = 'icons/obj/structure/urban/infrastructure.dmi' + icon_state = "grate" + layer = 2.01 + anchored = TRUE + /obj/structure/parking_meter name = "parking meter" desc = "A parking meter that seems to be turned off." @@ -392,6 +400,27 @@ icon_state = "exit" layer = ABOVE_ALL_MOB_LAYER +/obj/structure/sign/billboard + name = "commercial billboard" + desc = "A large and typically roadside billboard rented out for advertisement space." + icon = 'icons/obj/structure/urban/billboard.dmi' + icon_state = "board-l" + density = TRUE + layer = ABOVE_ALL_MOB_LAYER + +/obj/structure/sign/billboard/advert + name = "billboard advertisement" + desc = null + icon_state = "sign" + density = TRUE + layer = 4.6 + +/obj/structure/sign/billboard/advert/random/Initialize(mapload) + . = ..() + cut_overlays() + icon_state = "sign[rand(1, 14)]" + return + /obj/structure/sign/urban/drive_thru name = "drive thru sign" desc = "A drive-thru sign." @@ -426,10 +455,10 @@ menu_text = pencode2html(new_text) update_icon() -/obj/structure/restaurant_menu/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/paper)) - var/obj/item/paper/P = I - to_chat(user, SPAN_NOTICE("You scan \the [I.name] into \the [name].")) +/obj/structure/restaurant_menu/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/paper)) + var/obj/item/paper/P = attacking_item + to_chat(user, SPAN_NOTICE("You scan \the [attacking_item.name] into \the [name].")) menu_text = P.info menu_text = replacetext(menu_text, "color=black>", "color=white>") icon_state = "menu_active" @@ -619,11 +648,11 @@ flick("[base_icon]c1", src) return -/obj/machinery/door/urban/attackby(obj/item/I, mob/user) +/obj/machinery/door/urban/attackby(obj/item/attacking_item, mob/user) - if(istype(I, /obj/item/key/door_key)) + if(istype(attacking_item, /obj/item/key/door_key)) - if(check_access(I)) + if(check_access(attacking_item)) if(src.density && !(length(previous_req_one_access) || length(previous_req_access))) //Only say that it's unlocked if there actually was an access list that did the locking @@ -713,7 +742,7 @@ * * * accesses - A list with accesses that the key has, or null if defined in either the map, public access door or other means */ -/obj/item/key/door_key/Initialize(var/list/accesses = null) +/obj/item/key/door_key/Initialize(var/mapload, var/list/accesses) SHOULD_CALL_PARENT(TRUE) . = ..() diff --git a/code/game/objects/structures/vr/_remote_chair.dm b/code/game/objects/structures/vr/_remote_chair.dm index c2a1f6233c8..5299bd406b4 100644 --- a/code/game/objects/structures/vr/_remote_chair.dm +++ b/code/game/objects/structures/vr/_remote_chair.dm @@ -17,16 +17,16 @@ STOP_PROCESSING(SSprocessing, src) return ..() -/obj/structure/bed/stool/chair/remote/examine(mob/user) +/obj/structure/bed/stool/chair/remote/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(portable_type) - to_chat(user, FONT_SMALL(SPAN_NOTICE("Can be packed up by using a wrench on it."))) + . += FONT_SMALL(SPAN_NOTICE("Can be packed up by using a wrench on it.")) /obj/structure/bed/stool/chair/remote/update_icon() return -/obj/structure/bed/stool/chair/remote/attackby(obj/item/W, mob/user) - if(portable_type && W.iswrench()) +/obj/structure/bed/stool/chair/remote/attackby(obj/item/attacking_item, mob/user) + if(portable_type && attacking_item.iswrench()) user.visible_message(SPAN_NOTICE("\The [user] starts dismantling \the [src]..."), SPAN_NOTICE("You start dismantling \the [src]...")) if(do_after(user, 20 SECONDS, src, DO_REPAIR_CONSTRUCT)) user.visible_message(SPAN_NOTICE("\The [user] dismantles \the [src]."), SPAN_NOTICE("You dismantle \the [src].")) diff --git a/code/game/objects/structures/watercloset.dm b/code/game/objects/structures/watercloset.dm index 87fecbb1c36..cf28960382f 100644 --- a/code/game/objects/structures/watercloset.dm +++ b/code/game/objects/structures/watercloset.dm @@ -44,19 +44,19 @@ /obj/structure/toilet/update_icon() icon_state = "toilet[open][cistern]" -/obj/structure/toilet/attackby(obj/item/I as obj, mob/living/user as mob) - if(I.iscrowbar()) +/obj/structure/toilet/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iscrowbar()) to_chat(user, SPAN_NOTICE("You start to [cistern ? "replace the lid on the cistern" : "lift the lid off the cistern"].")) playsound(loc, 'sound/effects/stonedoor_openclose.ogg', 50, 1) - if(I.use_tool(src, user, 30, volume = 0)) + if(attacking_item.use_tool(src, user, 30, volume = 0)) user.visible_message(SPAN_NOTICE("[user] [cistern ? "replaces the lid on the cistern" : "lifts the lid off the cistern"]!"), SPAN_NOTICE("You [cistern ? "replace the lid on the cistern" : "lift the lid off the cistern"]!"), "You hear grinding porcelain.") cistern = !cistern update_icon() return - if(istype(I, /obj/item/grab)) + if(istype(attacking_item, /obj/item/grab)) usr.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - var/obj/item/grab/G = I + var/obj/item/grab/G = attacking_item if(isliving(G.affecting)) var/mob/living/GM = G.affecting @@ -81,15 +81,15 @@ to_chat(user, SPAN_NOTICE("You need a tighter grip.")) if(cistern && !istype(user,/mob/living/silicon/robot)) //STOP PUTTING YOUR MODULES IN THE TOILET. - if(I.w_class > 3) - to_chat(user, SPAN_NOTICE("\The [I] does not fit.")) + if(attacking_item.w_class > 3) + to_chat(user, SPAN_NOTICE("\The [attacking_item] does not fit.")) return - if(w_items + I.w_class > 5) + if(w_items + attacking_item.w_class > 5) to_chat(user, SPAN_NOTICE("The cistern is full.")) return - user.drop_from_inventory(I,src) - w_items += I.w_class - to_chat(user, "You carefully place \the [I] into the cistern.") + user.drop_from_inventory(attacking_item,src) + w_items += attacking_item.w_class + to_chat(user, "You carefully place \the [attacking_item] into the cistern.") return /obj/structure/toilet/noose @@ -109,9 +109,9 @@ density = 0 anchored = 1 -/obj/structure/urinal/attackby(obj/item/I, mob/user) - if(istype(I, /obj/item/grab)) - var/obj/item/grab/G = I +/obj/structure/urinal/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/grab)) + var/obj/item/grab/G = attacking_item if(isliving(G.affecting)) var/mob/living/GM = G.affecting if(G.state>1) @@ -173,15 +173,15 @@ for (var/atom/movable/G in src.loc) G.clean_blood() -/obj/machinery/shower/attackby(obj/item/I as obj, mob/user as mob) - if(I.type == /obj/item/device/analyzer) +/obj/machinery/shower/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.type == /obj/item/device/analyzer) to_chat(user, SPAN_NOTICE("The water temperature seems to be [watertemp].")) - if(I.iswrench()) + if(attacking_item.iswrench()) var/newtemp = input(user, "What setting would you like to set the temperature valve to?", "Water Temperature Valve") in temperature_settings - to_chat(user, SPAN_NOTICE("You begin to adjust the temperature valve with \the [I].")) - if(I.use_tool(src, user, 50, volume = 50)) + to_chat(user, SPAN_NOTICE("You begin to adjust the temperature valve with \the [attacking_item].")) + if(attacking_item.use_tool(src, user, 50, volume = 50)) watertemp = newtemp - user.visible_message(SPAN_NOTICE("[user] adjusts the shower with \the [I]."), SPAN_NOTICE("You adjust the shower with \the [I].")) + user.visible_message(SPAN_NOTICE("[user] adjusts the shower with \the [attacking_item]."), SPAN_NOTICE("You adjust the shower with \the [attacking_item].")) add_fingerprint(user) /obj/machinery/shower/update_icon() //this is terribly unreadable, but basically it makes the shower mist up @@ -451,13 +451,13 @@ SPAN_NOTICE("[user] washes their hands using \the [src]."), \ SPAN_NOTICE("You wash your hands using \the [src].")) -/obj/structure/sink/attackby(obj/item/O as obj, mob/user as mob) +/obj/structure/sink/attackby(obj/item/attacking_item, mob/user) if(busy) to_chat(user, SPAN_WARNING("Someone's already washing here.")) return // Filling/emptying open reagent containers - var/obj/item/reagent_containers/RG = O + var/obj/item/reagent_containers/RG = attacking_item if (istype(RG) && RG.is_open_container()) var/atype = alert(usr, "Do you want to fill or empty \the [RG] at \the [src]?", "Fill or Empty", "Fill", "Empty", "Cancel") @@ -490,8 +490,8 @@ return // Filling/empying Syringes - else if (istype(O, /obj/item/reagent_containers/syringe)) - var/obj/item/reagent_containers/syringe/S = O + else if (istype(attacking_item, /obj/item/reagent_containers/syringe)) + var/obj/item/reagent_containers/syringe/S = attacking_item switch(S.mode) if(0) // draw if(S.reagents.total_volume >= S.volume) @@ -513,8 +513,8 @@ SPAN_NOTICE("You empty [trans] units of water into \the [src]. \The [S] now contains [S.reagents.total_volume] units.")) return - else if (istype(O, /obj/item/melee/baton)) - var/obj/item/melee/baton/B = O + else if (istype(attacking_item, /obj/item/melee/baton)) + var/obj/item/melee/baton/B = attacking_item if(B.bcell) if(B.bcell.charge > 0 && B.status == 1) flick("baton_active", src) @@ -526,19 +526,19 @@ R.cell.charge -= 20 else B.deductcharge(B.hitcost) - user.visible_message(SPAN_DANGER("[user] was stunned by \the [O]!")) + user.visible_message(SPAN_DANGER("[user] was stunned by \the [attacking_item]!")) return 1 // Short of a rewrite, this is necessary to stop monkeycubes being washed. - else if(istype(O, /obj/item/reagent_containers/food/snacks/monkeycube)) + else if(istype(attacking_item, /obj/item/reagent_containers/food/snacks/monkeycube)) return - else if(istype(O, /obj/item/mop)) - O.reagents.add_reagent(/singleton/reagent/water, 5) - to_chat(user, SPAN_NOTICE("You wet \the [O] in \the [src].")) + else if(istype(attacking_item, /obj/item/mop)) + attacking_item.reagents.add_reagent(/singleton/reagent/water, 5) + to_chat(user, SPAN_NOTICE("You wet \the [attacking_item] in \the [src].")) playsound(loc, 'sound/effects/slosh.ogg', 25, 1) return - else if(istype(O, /obj/item/reagent_containers/bowl)) - var/obj/item/reagent_containers/bowl/B = O + else if(istype(attacking_item, /obj/item/reagent_containers/bowl)) + var/obj/item/reagent_containers/bowl/B = attacking_item if(B.grease) B.grease = FALSE B.update_icon() @@ -546,7 +546,7 @@ var/turf/location = user.loc if(!isturf(location)) return - var/obj/item/I = O + var/obj/item/I = attacking_item if(!I || !istype(I,/obj/item)) return to_chat(usr, SPAN_NOTICE("You start washing \the [I].")) @@ -581,7 +581,7 @@ ..() icon_state = "puddle" -/obj/structure/sink/puddle/attackby(obj/item/O as obj, mob/user as mob) +/obj/structure/sink/puddle/attackby(obj/item/attacking_item, mob/user) icon_state = "puddle-splash" ..() icon_state = "puddle" diff --git a/code/game/objects/structures/weapon_rack.dm b/code/game/objects/structures/weapon_rack.dm index f36c1863817..8ce8ddd1b01 100644 --- a/code/game/objects/structures/weapon_rack.dm +++ b/code/game/objects/structures/weapon_rack.dm @@ -14,17 +14,17 @@ held_weapon = new held_weapon(src) icon_state = initial(icon_state) + "_[held_weapon.icon_state]" -/obj/structure/weapon_rack/attackby(obj/item/W, mob/user) +/obj/structure/weapon_rack/attackby(obj/item/attacking_item, mob/user) if(isrobot(user)) return - if((initial(icon_state) + "_[W.icon_state]") in icon_states(icon)) - user.unEquip(W) - W.forceMove(src) - held_weapon = W - to_chat(user, SPAN_NOTICE("You place \the [W] on \the [src].")) - icon_state = initial(icon_state) + "_[W.icon_state]" + if((initial(icon_state) + "_[attacking_item.icon_state]") in icon_states(icon)) + user.unEquip(attacking_item) + attacking_item.forceMove(src) + held_weapon = attacking_item + to_chat(user, SPAN_NOTICE("You place \the [attacking_item] on \the [src].")) + icon_state = initial(icon_state) + "_[attacking_item.icon_state]" else - to_chat(user, SPAN_NOTICE("[W] does not fit on \the [src].")) + to_chat(user, SPAN_NOTICE("[attacking_item] does not fit on \the [src].")) /obj/structure/weapon_rack/attack_hand(mob/user) if(isrobot(user)) diff --git a/code/game/objects/structures/windoor_assembly.dm b/code/game/objects/structures/windoor_assembly.dm index b836c658eb7..03681d5763b 100644 --- a/code/game/objects/structures/windoor_assembly.dm +++ b/code/game/objects/structures/windoor_assembly.dm @@ -66,17 +66,17 @@ return 1 -/obj/structure/windoor_assembly/attackby(obj/item/W as obj, mob/user as mob) +/obj/structure/windoor_assembly/attackby(obj/item/attacking_item, mob/user) //I really should have spread this out across more states but thin little windoors are hard to sprite. switch(state) if("01") - if(W.iswelder() && !anchored) - var/obj/item/weldingtool/WT = W + if(attacking_item.iswelder() && !anchored) + var/obj/item/weldingtool/WT = attacking_item if (WT.use(0,user)) user.visible_message("[user] dissassembles the windoor assembly.", "You start to dissassemble the windoor assembly.") playsound(src.loc, 'sound/items/welder_pry.ogg', 50, 1) - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src || !WT.isOn()) return to_chat(user, "You dissasembled the windoor assembly!") new /obj/item/stack/material/glass/reinforced(get_turf(src), 5) @@ -88,10 +88,10 @@ return //Wrenching an unsecure assembly anchors it in place. Step 4 complete - if(W.iswrench() && !anchored) + if(attacking_item.iswrench() && !anchored) user.visible_message("[user] secures the windoor assembly to the floor.", "You start to secure the windoor assembly to the floor.") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return to_chat(user, "You've secured the windoor assembly!") src.anchored = 1 @@ -101,10 +101,10 @@ src.name = "Anchored Windoor Assembly" //Unwrenching an unsecure assembly un-anchors it. Step 4 undone - else if(W.iswrench() && anchored) + else if(attacking_item.iswrench() && anchored) user.visible_message("[user] unsecures the windoor assembly to the floor.", "You start to unsecure the windoor assembly to the floor.") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return to_chat(user, "You've unsecured the windoor assembly!") src.anchored = 0 @@ -114,14 +114,14 @@ src.name = "Windoor Assembly" //Adding plasteel makes the assembly a secure windoor assembly. Step 2 (optional) complete. - else if(istype(W, /obj/item/stack/rods) && !secure) - var/obj/item/stack/rods/R = W + else if(istype(attacking_item, /obj/item/stack/rods) && !secure) + var/obj/item/stack/rods/R = attacking_item if(R.get_amount() < 4) to_chat(user, "You need more rods to do this.") return to_chat(user, "You start to reinforce the windoor with rods.") - if(W.use_tool(src, user, 40, volume = 50) && !secure) + if(attacking_item.use_tool(src, user, 40, volume = 50) && !secure) if (R.use(4)) to_chat(user, "You reinforce the windoor.") src.secure = "secure_" @@ -131,11 +131,11 @@ src.name = "Secure Windoor Assembly" //Adding cable to the assembly. Step 5 complete. - else if(W.iscoil() && anchored) + else if(attacking_item.iscoil() && anchored) user.visible_message("[user] wires the windoor assembly.", "You start to wire the windoor assembly.") - var/obj/item/stack/cable_coil/CC = W - if(W.use_tool(src, user, 40, volume = 50)) + var/obj/item/stack/cable_coil/CC = attacking_item + if(attacking_item.use_tool(src, user, 40, volume = 50)) if (CC.use(1)) to_chat(user, "You wire the windoor!") src.state = "02" @@ -149,11 +149,11 @@ if("02") //Removing wire from the assembly. Step 5 undone. - if(W.iswirecutter() && !src.electronics) + if(attacking_item.iswirecutter() && !src.electronics) playsound(src.loc, 'sound/items/Wirecutter.ogg', 100, 1) user.visible_message("[user] cuts the wires from the airlock assembly.", "You start to cut the wires from airlock assembly.") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return to_chat(user, "You cut the windoor wires.!") @@ -165,8 +165,8 @@ src.name = "Anchored Windoor Assembly" //Adding airlock electronics for access. Step 6 complete. - else if(istype(W, /obj/item/airlock_electronics) && W:icon_state != "door_electronics_smoked") - var/obj/item/airlock_electronics/EL = W + else if(istype(attacking_item, /obj/item/airlock_electronics) && attacking_item:icon_state != "door_electronics_smoked") + var/obj/item/airlock_electronics/EL = attacking_item if(!EL.is_installed) playsound(src.loc, 'sound/items/Screwdriver.ogg', 100, 1) user.visible_message("[user] installs the electronics into the airlock assembly.", "You start to install electronics into the airlock assembly.") @@ -182,10 +182,10 @@ EL.is_installed = 0 //Screwdriver to remove airlock electronics. Step 6 undone. - else if(W.isscrewdriver() && src.electronics) + else if(attacking_item.isscrewdriver() && src.electronics) user.visible_message("[user] removes the electronics from the airlock assembly.", "You start to uninstall electronics from the airlock assembly.") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src || !src.electronics) return to_chat(user, "You've removed the airlock electronics!") if(src.secure) @@ -197,14 +197,14 @@ ae.forceMove(src.loc) //Crowbar to complete the assembly, Step 7 complete. - else if(W.iscrowbar()) + else if(attacking_item.iscrowbar()) if(!src.electronics) to_chat(usr, "The assembly is missing electronics.") return usr << browse(null, "window=windoor_access") user.visible_message("[user] pries the windoor into the frame.", "You start prying the windoor into the frame.") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) if(!src) return diff --git a/code/game/objects/structures/window.dm b/code/game/objects/structures/window.dm index 83518b0894b..933ac553af6 100644 --- a/code/game/objects/structures/window.dm +++ b/code/game/objects/structures/window.dm @@ -33,28 +33,28 @@ atmos_canpass = CANPASS_PROC -/obj/structure/window/examine(mob/user) +/obj/structure/window/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(health == maxhealth) - to_chat(user, SPAN_NOTICE("It looks fully intact.")) + . += SPAN_NOTICE("It looks fully intact.") else var/perc = health / maxhealth if(perc > 0.75) - to_chat(user, SPAN_NOTICE("It has a few cracks.")) + . += SPAN_NOTICE("It has a few cracks.") else if(perc > 0.5) - to_chat(user, SPAN_WARNING("It looks slightly damaged.")) + . += SPAN_WARNING("It looks slightly damaged.") else if(perc > 0.25) - to_chat(user, SPAN_WARNING("It looks moderately damaged.")) + . += SPAN_WARNING("It looks moderately damaged.") else - to_chat(user, SPAN_DANGER("It looks heavily damaged.")) + . += SPAN_DANGER("It looks heavily damaged.") if(silicate) if (silicate < 30) - to_chat(user, SPAN_NOTICE("It has a thin layer of silicate.")) + . += SPAN_NOTICE("It has a thin layer of silicate.") else if (silicate < 70) - to_chat(user, SPAN_NOTICE("It is covered in silicate.")) + . += SPAN_NOTICE("It is covered in silicate.") else - to_chat(user, SPAN_NOTICE("There is a thick layer of silicate covering it.")) + . += SPAN_NOTICE("There is a thick layer of silicate covering it.") /obj/structure/window/proc/update_nearby_icons() SSicon_smooth.add_to_queue_neighbors(src) @@ -249,42 +249,42 @@ playsound(loc, 'sound/effects/glass_hit.ogg', 50, 1) return TRUE -/obj/structure/window/attackby(obj/item/W, mob/user) - if(!istype(W) || istype(W, /obj/item/flag)) +/obj/structure/window/attackby(obj/item/attacking_item, mob/user) + if(!istype(attacking_item) || istype(attacking_item, /obj/item/flag)) return - if(istype(W, /obj/item/grab) && get_dist(src,user)<2) - var/obj/item/grab/G = W + if(istype(attacking_item, /obj/item/grab) && get_dist(src,user)<2) + var/obj/item/grab/G = attacking_item if(istype(G.affecting,/mob/living)) grab_smash_attack(G, DAMAGE_BRUTE) return - if(W.item_flags & ITEM_FLAG_NO_BLUDGEON) + if(attacking_item.item_flags & ITEM_FLAG_NO_BLUDGEON) return - if(W.isscrewdriver() && user.a_intent != I_HURT) + if(attacking_item.isscrewdriver() && user.a_intent != I_HURT) if(reinf && state >= 1) state = 3 - state update_nearby_icons() - playsound(loc, W.usesound, 75, 1) + playsound(loc, attacking_item.usesound, 75, 1) to_chat(user, (state == 1 ? SPAN_NOTICE("You have unfastened the window from the frame.") : SPAN_NOTICE("You have fastened the window to the frame."))) else if(reinf && state == 0) anchored = !anchored update_icon() update_nearby_icons() - playsound(loc, W.usesound, 75, 1) + playsound(loc, attacking_item.usesound, 75, 1) to_chat(user, (anchored ? SPAN_NOTICE("You have fastened the frame to the floor.") : SPAN_NOTICE("You have unfastened the frame from the floor."))) else if(!reinf) anchored = !anchored update_nearby_icons() - playsound(loc, W.usesound, 75, 1) + playsound(loc, attacking_item.usesound, 75, 1) to_chat(user, (anchored ? SPAN_NOTICE("You have fastened the window to the floor.") : SPAN_NOTICE("You have unfastened the window."))) update_icon() update_nearby_icons() - else if(W.iscrowbar() && reinf && state <= 1 && user.a_intent != I_HURT) + else if(attacking_item.iscrowbar() && reinf && state <= 1 && user.a_intent != I_HURT) state = 1 - state - playsound(loc, W.usesound, 75, 1) + playsound(loc, attacking_item.usesound, 75, 1) to_chat(user, (state ? SPAN_NOTICE("You have pried the window into the frame.") : SPAN_NOTICE("You have pried the window out of the frame."))) - else if(W.iswrench() && !anchored && (!state || !reinf) && user.a_intent != I_HURT) + else if(attacking_item.iswrench() && !anchored && (!state || !reinf) && user.a_intent != I_HURT) if(!glasstype) to_chat(user, SPAN_NOTICE("You're not sure how to dismantle \the [src] properly.")) else @@ -292,19 +292,19 @@ dismantle_window() else user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - if(W.damtype == DAMAGE_BRUTE || W.damtype == DAMAGE_BURN) + if(attacking_item.damtype == DAMAGE_BRUTE || attacking_item.damtype == DAMAGE_BURN) if(reinf) user.do_attack_animation(src) - if(W.force >= REINFORCED_WINDOW_DAMAGE_FORCE) - user.visible_message(SPAN_DANGER("\The [user] forcefully strikes \the [src] with \the [W]!")) - playsound(src, hitsound, W.get_clamped_volume(), 1) - hit(W.force) + if(attacking_item.force >= REINFORCED_WINDOW_DAMAGE_FORCE) + user.visible_message(SPAN_DANGER("\The [user] forcefully strikes \the [src] with \the [attacking_item]!")) + playsound(src, hitsound, attacking_item.get_clamped_volume(), 1) + hit(attacking_item.force) else - user.visible_message(SPAN_WARNING("[user] hits \the [src] with \the [W], but it glances off, doing no damage.")) - playsound(src, hitsound, W.get_clamped_volume(), 1) + user.visible_message(SPAN_WARNING("[user] hits \the [src] with \the [attacking_item], but it glances off, doing no damage.")) + playsound(src, hitsound, attacking_item.get_clamped_volume(), 1) else user.do_attack_animation(src) - hit(W.force) + hit(attacking_item.force) if(health <= 7) anchored = 0 update_nearby_icons() @@ -656,61 +656,61 @@ WF.has_glass_installed = FALSE return ..() -/obj/structure/window/full/attackby(obj/item/W, mob/user) - if(!istype(W) || istype(W, /obj/item/flag)) +/obj/structure/window/full/attackby(obj/item/attacking_item, mob/user) + if(!istype(attacking_item) || istype(attacking_item, /obj/item/flag)) return - if(istype(W, /obj/item/grab) && get_dist(src,user)<2) - var/obj/item/grab/G = W + if(istype(attacking_item, /obj/item/grab) && get_dist(src,user)<2) + var/obj/item/grab/G = attacking_item if(istype(G.affecting,/mob/living)) grab_smash_attack(G, DAMAGE_BRUTE) return - if(W.item_flags & ITEM_FLAG_NO_BLUDGEON) + if(attacking_item.item_flags & ITEM_FLAG_NO_BLUDGEON) return - if(W.isscrewdriver() && user.a_intent != I_HURT) + if(attacking_item.isscrewdriver() && user.a_intent != I_HURT) if(state == 2) - if(W.use_tool(src, user, 2 SECONDS, volume = 50)) + if(attacking_item.use_tool(src, user, 2 SECONDS, volume = 50)) to_chat(user, SPAN_NOTICE("You have unfastened the glass from the window frame.")) state-- update_nearby_icons() else if(state == 1) - if(W.use_tool(src, user, 2 SECONDS, volume = 50)) + if(attacking_item.use_tool(src, user, 2 SECONDS, volume = 50)) to_chat(user, SPAN_NOTICE("You have fastened the glass to the window frame.")) state++ update_nearby_icons() - else if(W.iscrowbar() && user.a_intent != I_HURT) + else if(attacking_item.iscrowbar() && user.a_intent != I_HURT) if(state == 1) - if(W.use_tool(src, user, 2 SECONDS, volume = 50)) + if(attacking_item.use_tool(src, user, 2 SECONDS, volume = 50)) to_chat(user, SPAN_NOTICE("You pry the glass out of the window frame.")) state-- update_nearby_icons() else if(state == 0) - if(W.use_tool(src, user, 2 SECONDS, volume = 50)) + if(attacking_item.use_tool(src, user, 2 SECONDS, volume = 50)) to_chat(user, SPAN_NOTICE("You pry the glass into the window frame.")) state++ update_nearby_icons() - else if(W.iswrench() && user.a_intent != I_HURT) + else if(attacking_item.iswrench() && user.a_intent != I_HURT) if(state == 0) user.visible_message(SPAN_DANGER("\The [user] is dismantling \the [src]!")) - if(W.use_tool(src, user, 2 SECONDS, volume = 50)) + if(attacking_item.use_tool(src, user, 2 SECONDS, volume = 50)) to_chat(user, SPAN_NOTICE("You undo the safety bolts and remove the glass from \the [src].")) dismantle_window() else user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) - if(W.damtype == DAMAGE_BRUTE || W.damtype == DAMAGE_BURN) + if(attacking_item.damtype == DAMAGE_BRUTE || attacking_item.damtype == DAMAGE_BURN) if(reinf) user.do_attack_animation(src) - if(W.force >= FULL_REINFORCED_WINDOW_DAMAGE_FORCE) - user.visible_message(SPAN_DANGER("\The [user] forcefully strikes \the [src] with \the [W]!")) - playsound(src, hitsound, W.get_clamped_volume(), 1) - hit(W.force) + if(attacking_item.force >= FULL_REINFORCED_WINDOW_DAMAGE_FORCE) + user.visible_message(SPAN_DANGER("\The [user] forcefully strikes \the [src] with \the [attacking_item]!")) + playsound(src, hitsound, attacking_item.get_clamped_volume(), 1) + hit(attacking_item.force) else - user.visible_message(SPAN_WARNING("[user] hits \the [src] with \the [W], but it glances off, doing no damage.")) - playsound(src, hitsound, W.get_clamped_volume(), 1) + user.visible_message(SPAN_WARNING("[user] hits \the [src] with \the [attacking_item], but it glances off, doing no damage.")) + playsound(src, hitsound, attacking_item.get_clamped_volume(), 1) else user.do_attack_animation(src) - hit(W.force) + hit(attacking_item.force) else playsound(src, hitsound, 10, 1) return diff --git a/code/game/turfs/flooring/urban.dm b/code/game/turfs/flooring/urban.dm index f1d73024e3e..7e77ef15061 100644 --- a/code/game/turfs/flooring/urban.dm +++ b/code/game/turfs/flooring/urban.dm @@ -37,6 +37,25 @@ . = ..() icon_state = "blocks[rand(1,3)]" +/turf/simulated/floor/sidewalk/dark + icon_state = "sidewalk_alt" + +/turf/simulated/floor/sidewalk/dark/detail + icon_state = "sidewalk_alt_detail" + +/turf/simulated/floor/sidewalk/dark/grid + icon_state = "sidewalk_alt_grid" + +/turf/simulated/floor/foundation + name = "foundation" + desc = "The unclean but highly compacted solid foundation for a building or structure." + icon = 'icons/turf/flooring/urban_turfs.dmi' + icon_state = "rust" + +/turf/simulated/floor/foundation/Initialize(mapload) + . = ..() + icon_state = "rust[rand(1,12)]" + /turf/simulated/floor/roofing_tiles name = "roofing tiles" desc = "You're on top of the world!" diff --git a/code/game/turfs/simulated/floor.dm b/code/game/turfs/simulated/floor.dm index 1be669c8752..0de988c20c5 100644 --- a/code/game/turfs/simulated/floor.dm +++ b/code/game/turfs/simulated/floor.dm @@ -20,7 +20,7 @@ heat_capacity = 10000 var/lava = 0 -/turf/simulated/floor/examine(mob/user, distance, infix, suffix) +/turf/simulated/floor/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(flooring) var/list/can_remove_with = list() @@ -37,7 +37,7 @@ if(flooring.flags & TURF_REMOVE_WELDER) can_remove_with += "welding tools" if(length(can_remove_with)) - to_chat(user, SPAN_NOTICE("\The [src] can be removed with: [english_list(can_remove_with)].")) + . += SPAN_NOTICE("\The [src] can be removed with: [english_list(can_remove_with)].") /turf/simulated/floor/is_plating() return !flooring diff --git a/code/game/turfs/simulated/floor_attackby.dm b/code/game/turfs/simulated/floor_attackby.dm index c872ee03dc0..af7d216f865 100644 --- a/code/game/turfs/simulated/floor_attackby.dm +++ b/code/game/turfs/simulated/floor_attackby.dm @@ -1,10 +1,10 @@ -/turf/simulated/floor/attackby(obj/item/C as obj, mob/user as mob) +/turf/simulated/floor/attackby(obj/item/attacking_item, mob/user) - if(!C || !user) + if(!attacking_item || !user) return 0 if(flooring && (!ismob(user) || user.a_intent != I_HURT)) - if(C.iscrowbar()) + if(attacking_item.iscrowbar()) if(broken || burnt) to_chat(user, "You remove the broken [flooring.descriptor].") make_plating() @@ -18,50 +18,50 @@ return playsound(src, 'sound/items/crowbar_tile.ogg', 80, 1) return - else if(C.isscrewdriver() && (flooring.flags & TURF_REMOVE_SCREWDRIVER)) + else if(attacking_item.isscrewdriver() && (flooring.flags & TURF_REMOVE_SCREWDRIVER)) if(broken || burnt) return to_chat(user, "You unscrew and remove the [flooring.descriptor].") make_plating(1) - playsound(src, C.usesound, 80, 1) + playsound(src, attacking_item.usesound, 80, 1) return - else if(C.iswrench() && (flooring.flags & TURF_REMOVE_WRENCH)) + else if(attacking_item.iswrench() && (flooring.flags & TURF_REMOVE_WRENCH)) to_chat(user, "You unwrench and remove the [flooring.descriptor].") make_plating(1) - playsound(src, C.usesound, 80, 1) + playsound(src, attacking_item.usesound, 80, 1) return - else if(istype(C, /obj/item/shovel) && (flooring.flags & TURF_REMOVE_SHOVEL)) + else if(istype(attacking_item, /obj/item/shovel) && (flooring.flags & TURF_REMOVE_SHOVEL)) to_chat(user, "You shovel off the [flooring.descriptor].") make_plating(1) - playsound(src, C.usesound, 80, 1) + playsound(src, attacking_item.usesound, 80, 1) return - else if(C.iswelder() && (flooring.flags & TURF_REMOVE_WELDER)) - var/obj/item/weldingtool/WT = C + else if(attacking_item.iswelder() && (flooring.flags & TURF_REMOVE_WELDER)) + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) to_chat(user, SPAN_WARNING("\The [WT] isn't turned on.")) return if(WT.use(0, user)) to_chat(user, SPAN_NOTICE("You use \the [WT] to remove \the [src].")) make_plating(1) - playsound(src, C.usesound, 80, 1) + playsound(src, attacking_item.usesound, 80, 1) return - else if(C.iscoil()) + else if(attacking_item.iscoil()) to_chat(user, "You must remove the [flooring.descriptor] first.") return else - if(C.iscoil()) + if(attacking_item.iscoil()) if(broken || burnt) to_chat(user, "This section is too damaged to support anything. Use a welder to fix the damage.") return - var/obj/item/stack/cable_coil/coil = C + var/obj/item/stack/cable_coil/coil = attacking_item coil.turf_place(src, user) return - else if(istype(C, /obj/item/stack)) + else if(istype(attacking_item, /obj/item/stack)) if(broken || burnt) to_chat(user, "This section is too damaged to support anything. Use a welder to fix the damage.") return - var/obj/item/stack/S = C + var/obj/item/stack/S = attacking_item var/singleton/flooring/use_flooring var/list/decls = GET_SINGLETON_SUBTYPE_MAP(/singleton/flooring) for(var/flooring_type in decls) @@ -88,7 +88,7 @@ playsound(src, 'sound/items/Deconstruct.ogg', 80, 1) return // Repairs and deconstruction - else if(C.iscrowbar()) + else if(attacking_item.iscrowbar()) if(broken || burnt) playsound(src, 'sound/items/crowbar_tile.ogg', 80, 1) visible_message("[user] has begun prying off the damaged plating.") @@ -108,8 +108,8 @@ T.visible_message("The ceiling above has been pried off!") return return - else if(C.iswelder()) - var/obj/item/weldingtool/welder = C + else if(attacking_item.iswelder()) + var/obj/item/weldingtool/welder = attacking_item if(welder.isOn() && (is_plating())) if(broken || burnt) if(do_after(user, 5 SECONDS)) @@ -131,8 +131,8 @@ playsound(src, 'sound/items/Welder.ogg', 80, 1) return - if(istype(C,/obj/item/floor_frame)) - var/obj/item/floor_frame/F = C + if(istype(attacking_item,/obj/item/floor_frame)) + var/obj/item/floor_frame/F = attacking_item F.try_build(src, user) return diff --git a/code/game/turfs/simulated/floor_static.dm b/code/game/turfs/simulated/floor_static.dm index fe6474c3795..de428f949c7 100644 --- a/code/game/turfs/simulated/floor_static.dm +++ b/code/game/turfs/simulated/floor_static.dm @@ -7,8 +7,8 @@ icon_state = "tiled_preview" initial_flooring = null -/turf/simulated/floor/fixed/attackby(var/obj/item/C, var/mob/user) - if(istype(C, /obj/item/stack) && !C.iscoil()) +/turf/simulated/floor/fixed/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stack) && !attacking_item.iscoil()) return return ..() diff --git a/code/game/turfs/simulated/shuttle_turfs.dm b/code/game/turfs/simulated/shuttle_turfs.dm index 10ca566298e..b52a7b0d571 100644 --- a/code/game/turfs/simulated/shuttle_turfs.dm +++ b/code/game/turfs/simulated/shuttle_turfs.dm @@ -190,6 +190,7 @@ icon_state = "wall2" health = 500 maxhealth = 500 + alpha = 255 smoothing_flags = null canSmoothWith = null can_be_unanchored = FALSE diff --git a/code/game/turfs/simulated/wall_attacks.dm b/code/game/turfs/simulated/wall_attacks.dm index 7351dc86690..b39e9622a92 100644 --- a/code/game/turfs/simulated/wall_attacks.dm +++ b/code/game/turfs/simulated/wall_attacks.dm @@ -103,7 +103,7 @@ return success_smash(user) return fail_smash(user, wallbreaker) -/turf/simulated/wall/attackby(obj/item/W, mob/user) +/turf/simulated/wall/attackby(obj/item/attacking_item, mob/user) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) if(!user) return @@ -112,49 +112,49 @@ if(!istype(user.loc, /turf)) return //can't do this stuff whilst inside objects and such - if(istype(W, /obj/item/plastique)) + if(istype(attacking_item, /obj/item/plastique)) return - if(W) + if(attacking_item) radiate() - if(is_hot(W)) - burn(is_hot(W)) + if(is_hot(attacking_item)) + burn(is_hot(attacking_item)) if(locate(/obj/effect/overlay/wallrot) in src) - if(W.iswelder()) - var/obj/item/weldingtool/WT = W + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(WT.use(0,user)) to_chat(user, SPAN_NOTICE("You burn away the fungi with \the [WT].")) playsound(src, 'sound/items/Welder.ogg', 10, 1) for(var/obj/effect/overlay/wallrot/WR in src) qdel(WR) return - else if(W.sharp) - user.visible_message("[user] starts scraping the rot away with \the [W].", SPAN_NOTICE("You start scraping the rot away with \the [W].")) - if(W.use_tool(src, user, rand(3 SECONDS, 5 SECONDS), volume = 50)) - user.visible_message("[user] scrapes away the rot with \the [W].", SPAN_NOTICE("You start scraping away the rot with \the [W].")) - playsound(src, W.hitsound, W.get_clamped_volume(), TRUE) + else if(attacking_item.sharp) + user.visible_message("[user] starts scraping the rot away with \the [attacking_item].", SPAN_NOTICE("You start scraping the rot away with \the [attacking_item].")) + if(attacking_item.use_tool(src, user, rand(3 SECONDS, 5 SECONDS), volume = 50)) + user.visible_message("[user] scrapes away the rot with \the [attacking_item].", SPAN_NOTICE("You start scraping away the rot with \the [attacking_item].")) + playsound(src, attacking_item.hitsound, attacking_item.get_clamped_volume(), TRUE) for(var/obj/effect/overlay/wallrot/WR in src) WR.scrape(user) return - else if(W.force >= 10) - user.do_attack_animation(src, W) - to_chat(user, SPAN_NOTICE("\The [src] crumbles away under the force of your [W].")) + else if(attacking_item.force >= 10) + user.do_attack_animation(src, attacking_item) + to_chat(user, SPAN_NOTICE("\The [src] crumbles away under the force of your [attacking_item].")) dismantle_wall(TRUE) return //THERMITE related stuff. Calls src.thermitemelt() which handles melting simulated walls and the relevant effects if(thermite) - if(W.isFlameSource()) + if(attacking_item.isFlameSource()) thermitemelt(user) return - else if(istype(W, /obj/item/gun/energy/plasmacutter)) + else if(istype(attacking_item, /obj/item/gun/energy/plasmacutter)) thermitemelt(user) return - else if( istype(W, /obj/item/melee/energy/blade) ) - var/obj/item/melee/energy/blade/EB = W + else if( istype(attacking_item, /obj/item/melee/energy/blade) ) + var/obj/item/melee/energy/blade/EB = attacking_item spark(EB, 5) to_chat(user, SPAN_NOTICE("You slash \the [src] with \the [EB], igniting the thermite!")) @@ -166,9 +166,9 @@ var/turf/T = user.loc //get user's location for delay checks - if(damage && W.iswelder()) + if(damage && attacking_item.iswelder()) - var/obj/item/weldingtool/WT = W + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) return @@ -192,8 +192,8 @@ var/dismantle_verb var/dismantle_sound - if(W.iswelder()) - var/obj/item/weldingtool/WT = W + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) return if(!WT.use(0,user)) @@ -202,15 +202,15 @@ dismantle_verb = "cutting" dismantle_sound = 'sound/items/Welder.ogg' cut_delay *= 0.7 - else if(istype(W, /obj/item/gun/energy/plasmacutter)) - var/obj/item/gun/energy/plasmacutter/PC = W + else if(istype(attacking_item, /obj/item/gun/energy/plasmacutter)) + var/obj/item/gun/energy/plasmacutter/PC = attacking_item if(PC.check_power_and_message(user)) return dismantle_sound = PC.fire_sound dismantle_verb = "slicing" cut_delay *= 0.8 - else if(istype(W,/obj/item/melee/energy)) - var/obj/item/melee/energy/WT = W + else if(istype(attacking_item, /obj/item/melee/energy)) + var/obj/item/melee/energy/WT = attacking_item if(WT.active) dismantle_sound = /singleton/sound_category/spark_sound dismantle_verb = "slicing" @@ -218,12 +218,12 @@ else to_chat(user, SPAN_NOTICE("You need to activate the weapon to do that!")) return - else if(istype(W,/obj/item/melee/energy/blade)) + else if(istype(attacking_item, /obj/item/melee/energy/blade)) dismantle_sound = /singleton/sound_category/spark_sound dismantle_verb = "slicing" cut_delay *= 0.5 - else if(istype(W,/obj/item/melee/chainsword)) - var/obj/item/melee/chainsword/WT = W + else if(istype(attacking_item, /obj/item/melee/chainsword)) + var/obj/item/melee/chainsword/WT = attacking_item if(WT.active) dismantle_sound = 'sound/weapons/saw/chainsawhit.ogg' dismantle_verb = "slicing" @@ -231,12 +231,12 @@ else to_chat(user, SPAN_NOTICE("You need to activate the weapon to do that!")) return - else if(istype(W,/obj/item/pickaxe)) - var/obj/item/pickaxe/P = W + else if(istype(attacking_item, /obj/item/pickaxe)) + var/obj/item/pickaxe/P = attacking_item dismantle_verb = P.drill_verb dismantle_sound = P.drill_sound cut_delay -= P.digspeed - else if(istype(W,/obj/item/melee/arm_blade/)) + else if(istype(attacking_item,/obj/item/melee/arm_blade/)) dismantle_sound = /singleton/sound_category/pickaxe_sound dismantle_verb = "slicing and stabbing" cut_delay *= 1.5 @@ -247,7 +247,7 @@ if(cut_delay<0) cut_delay = 1 - if(!W.use_tool(src, user, cut_delay, volume = 50)) + if(!attacking_item.use_tool(src, user, cut_delay, volume = 50)) return //This prevents runtime errors if someone clicks the same wall more than once @@ -256,7 +256,7 @@ if(dismantle_sound) playsound(src, dismantle_sound, 100, 1) - W.use_resource(user, 1) + attacking_item.use_resource(user, 1) dismantle_wall() user.visible_message(SPAN_WARNING("The wall was torn open by \the [user]!"), SPAN_NOTICE("You remove the outer plating.")) return @@ -265,24 +265,24 @@ else switch(construction_stage) if(6) - if (W.iswirecutter()) + if (attacking_item.iswirecutter()) playsound(src, 'sound/items/Wirecutter.ogg', 100, 1) construction_stage = 5 to_chat(user, SPAN_NOTICE("You cut the outer grille.")) update_icon() return if(5) - if (W.isscrewdriver()) + if (attacking_item.isscrewdriver()) to_chat(user, SPAN_NOTICE("You begin removing the support lines.")) - playsound(src, W.usesound, 100, 1) - if(!W.use_tool(src, user, 60, volume = 50) || !istype(src, /turf/simulated/wall) || construction_stage != 5) + playsound(src, attacking_item.usesound, 100, 1) + if(!attacking_item.use_tool(src, user, 60, volume = 50) || !istype(src, /turf/simulated/wall) || construction_stage != 5) return construction_stage = 4 update_icon() to_chat(user, SPAN_NOTICE("You remove the support lines.")) return - else if( istype(W, /obj/item/stack/rods) ) - var/obj/item/stack/O = W + else if( istype(attacking_item, /obj/item/stack/rods) ) + var/obj/item/stack/O = attacking_item if(O.get_amount()>0) O.use(1) construction_stage = 6 @@ -291,8 +291,8 @@ return if(4) var/cut_cover - if(W.iswelder()) - var/obj/item/weldingtool/WT = W + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) return if(WT.use(0,user)) @@ -300,29 +300,29 @@ else to_chat(user, SPAN_NOTICE("You need more welding fuel to complete this task.")) return - else if (istype(W, /obj/item/gun/energy/plasmacutter)) + else if (istype(attacking_item, /obj/item/gun/energy/plasmacutter)) cut_cover = 1 if(cut_cover) to_chat(user, SPAN_NOTICE("You begin slicing through the metal cover.")) - if(!W.use_tool(src, user , 60, volume = 50) || !istype(src, /turf/simulated/wall) || construction_stage != 4) + if(!attacking_item.use_tool(src, user , 60, volume = 50) || !istype(src, /turf/simulated/wall) || construction_stage != 4) return construction_stage = 3 update_icon() to_chat(user, SPAN_NOTICE("You press firmly on the cover, dislodging it.")) return if(3) - if (W.iscrowbar()) + if (attacking_item.iscrowbar()) to_chat(user, SPAN_NOTICE("You struggle to pry off the cover.")) - if(!W.use_tool(src, user , 100, volume = 50) || !istype(src, /turf/simulated/wall) || construction_stage != 3) + if(!attacking_item.use_tool(src, user , 100, volume = 50) || !istype(src, /turf/simulated/wall) || construction_stage != 3) return construction_stage = 2 update_icon() to_chat(user, SPAN_NOTICE("You pry off the cover.")) return if(2) - if (W.iswrench()) + if (attacking_item.iswrench()) to_chat(user, SPAN_NOTICE("You start loosening the anchoring bolts which secure the support rods to their frame.")) - if(!W.use_tool(src, user , 40, volume = 50) || !istype(src, /turf/simulated/wall) || construction_stage != 2) + if(!attacking_item.use_tool(src, user , 40, volume = 50) || !istype(src, /turf/simulated/wall) || construction_stage != 2) return construction_stage = 1 update_icon() @@ -330,18 +330,18 @@ return if(1) var/cut_cover - if(W.iswelder()) - var/obj/item/weldingtool/WT = W + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if( WT.use(0,user) ) cut_cover=1 else to_chat(user, SPAN_NOTICE("You need more welding fuel to complete this task.")) return - else if(istype(W, /obj/item/gun/energy/plasmacutter)) + else if(istype(attacking_item, /obj/item/gun/energy/plasmacutter)) cut_cover = 1 if(cut_cover) to_chat(user, SPAN_NOTICE("You begin slicing through the support rods.")) - if(!W.use_tool(src, user , 70, volume = 50) || !istype(src, /turf/simulated/wall) || construction_stage != 1) + if(!attacking_item.use_tool(src, user , 70, volume = 50) || !istype(src, /turf/simulated/wall) || construction_stage != 1) return construction_stage = 0 update_icon() @@ -349,30 +349,30 @@ to_chat(user, SPAN_NOTICE("The support rods drop out as you cut them loose from the frame.")) return if(0) - if(W.iscrowbar()) + if(attacking_item.iscrowbar()) to_chat(user, SPAN_NOTICE("You struggle to pry off the outer sheath.")) - if(!W.use_tool(src, user , 100, volume = 50)) return - if(!istype(src, /turf/simulated/wall) || !user || !W || !T ) return - if(user.loc == T && user.get_active_hand() == W ) + if(!attacking_item.use_tool(src, user , 100, volume = 50)) return + if(!istype(src, /turf/simulated/wall) || !user || !attacking_item || !T ) return + if(user.loc == T && user.get_active_hand() == attacking_item ) to_chat(user, SPAN_NOTICE("You pry off the outer sheath.")) dismantle_wall() return - if(istype(W, /obj/item/device/electronic_assembly/wallmount)) - var/obj/item/device/electronic_assembly/wallmount/IC = W + if(istype(attacking_item, /obj/item/device/electronic_assembly/wallmount)) + var/obj/item/device/electronic_assembly/wallmount/IC = attacking_item IC.mount_assembly(src, user) return - if(istype(W,/obj/item/frame)) - var/obj/item/frame/F = W + if(istype(attacking_item,/obj/item/frame)) + var/obj/item/frame/F = attacking_item F.try_build(src, user) return - else if(!istype(W,/obj/item/rfd/construction) && !istype(W, /obj/item/reagent_containers)) - if(user.a_intent != I_HURT || !W.force) + else if(!istype(attacking_item,/obj/item/rfd/construction) && !istype(attacking_item, /obj/item/reagent_containers)) + if(user.a_intent != I_HURT || !attacking_item.force) return - var/damage_to_deal = W.force + var/damage_to_deal = attacking_item.force var/weaken = 0 var/sound_to_play = 'sound/weapons/smash.ogg' if(material) @@ -387,9 +387,9 @@ //Plasteel walls take 24 & 15 minimum damage. //Steel walls take 3 & 15 minimum damage. damage_to_deal -= weaken - visible_message(SPAN_WARNING("[user] strikes \the [src] with \the [W], [is_sharp(W) ? "slicing some of the plating" : "putting a heavy dent on it"]!")) + visible_message(SPAN_WARNING("[user] strikes \the [src] with \the [attacking_item], [is_sharp(attacking_item) ? "slicing some of the plating" : "putting a heavy dent on it"]!")) take_damage(damage_to_deal) else - visible_message(SPAN_WARNING("[user] strikes \the [src] with \the [W], but it bounces off!")) + visible_message(SPAN_WARNING("[user] strikes \the [src] with \the [attacking_item], but it bounces off!")) playsound(src, hitsound, 25, 1) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) diff --git a/code/game/turfs/simulated/walls.dm b/code/game/turfs/simulated/walls.dm index 2aea1535d12..40fa92a509f 100644 --- a/code/game/turfs/simulated/walls.dm +++ b/code/game/turfs/simulated/walls.dm @@ -131,22 +131,22 @@ ..(newtype) //Appearance -/turf/simulated/wall/examine(mob/user) +/turf/simulated/wall/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!damage) - to_chat(user, SPAN_NOTICE("It looks fully intact.")) + . += SPAN_NOTICE("It looks fully intact.") else var/dam = damage / material.integrity if(dam <= 0.3) - to_chat(user, SPAN_WARNING("It looks slightly damaged.")) + . += SPAN_WARNING("It looks slightly damaged.") else if(dam <= 0.6) - to_chat(user, SPAN_WARNING("It looks moderately damaged.")) + . += SPAN_WARNING("It looks moderately damaged.") else - to_chat(user, SPAN_DANGER("It looks heavily damaged.")) + . += SPAN_DANGER("It looks heavily damaged.") if(locate(/obj/effect/overlay/wallrot) in src) - to_chat(user, SPAN_WARNING("There is fungus growing on [src].")) + . += SPAN_WARNING("There is fungus growing on [src].") //Damage diff --git a/code/game/turfs/space/space.dm b/code/game/turfs/space/space.dm index 138b88dfb0a..f96803759ea 100644 --- a/code/game/turfs/space/space.dm +++ b/code/game/turfs/space/space.dm @@ -79,23 +79,23 @@ else set_light(0) -/turf/space/attackby(obj/item/C as obj, mob/user as mob) +/turf/space/attackby(obj/item/attacking_item, mob/user) - if (istype(C, /obj/item/stack/rods)) + if (istype(attacking_item, /obj/item/stack/rods)) var/obj/structure/lattice/L = locate(/obj/structure/lattice, src) if(L) return - var/obj/item/stack/rods/R = C + var/obj/item/stack/rods/R = attacking_item if (R.use(1)) to_chat(user, "Constructing support lattice ...") playsound(src, 'sound/weapons/Genhit.ogg', 50, 1) ReplaceWithLattice() return - if (istype(C, /obj/item/stack/tile/floor)) + if (istype(attacking_item, /obj/item/stack/tile/floor)) var/obj/structure/lattice/L = locate(/obj/structure/lattice, src) if(L) - var/obj/item/stack/tile/floor/S = C + var/obj/item/stack/tile/floor/S = attacking_item if (S.get_amount() < 1) return qdel(L) @@ -106,7 +106,7 @@ else to_chat(user, "The plating is going to need some support.") - ..(C, user) + ..() // Ported from unstable r355 diff --git a/code/game/turfs/space/transit.dm b/code/game/turfs/space/transit.dm index e30c1c4d74a..9246ccefdc6 100644 --- a/code/game/turfs/space/transit.dm +++ b/code/game/turfs/space/transit.dm @@ -5,7 +5,7 @@ var/pushdirection //Overwrite because we dont want people building rods in space. -/turf/space/transit/attackby(obj/O, mob/user) +/turf/space/transit/attackby(obj/item/attacking_item, mob/user) return FALSE //generates a list used to randomize transit animations so they aren't in lockstep diff --git a/code/game/turfs/turf.dm b/code/game/turfs/turf.dm index 852d8617829..c06a4464785 100644 --- a/code/game/turfs/turf.dm +++ b/code/game/turfs/turf.dm @@ -320,12 +320,12 @@ var/const/enterloopsanity = 100 /turf/proc/can_lay_cable() return can_have_cabling() -/turf/attackby(obj/item/C, mob/user) - if(istype(C, /obj/item/grab)) - var/obj/item/grab/grab = C +/turf/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/grab)) + var/obj/item/grab/grab = attacking_item step(grab.affecting, get_dir(grab.affecting, src)) - if (can_lay_cable() && C.iscoil()) - var/obj/item/stack/cable_coil/coil = C + if (can_lay_cable() && attacking_item.iscoil()) + var/obj/item/stack/cable_coil/coil = attacking_item coil.turf_place(src, user) else ..() diff --git a/code/modules/admin/admin_verbs.dm b/code/modules/admin/admin_verbs.dm index 143da660c88..7c8c0c554a3 100644 --- a/code/modules/admin/admin_verbs.dm +++ b/code/modules/admin/admin_verbs.dm @@ -28,9 +28,7 @@ var/list/admin_verbs_admin = list( /client/proc/cmd_admin_delete, /*delete an instance/object/mob/etc*/ /client/proc/cmd_admin_check_contents, /*displays the contents of an instance*/ /datum/admins/proc/access_news_network, /*allows access of newscasters*/ - /client/proc/giveruntimelog, /*allows us to give access to runtime logs to somebody*/ /client/proc/getserverlog, /*allows us to fetch server logs (diary) for other days*/ - /client/proc/view_signal_log, /*allows admins to check the log of signaler uses*/ /client/proc/jumptocoord, /*we ghost and jump to a coordinate*/ /client/proc/jumptozlevel, /client/proc/jumptoshuttle, @@ -393,7 +391,6 @@ var/list/admin_verbs_hideable = list( /datum/admins/proc/ccannoucment, /client/proc/cmd_display_init_log, /client/proc/getruntimelog, - /client/proc/giveruntimelog, /client/proc/toggledebuglogs, /client/proc/getserverlog, /client/proc/view_chemical_reaction_logs, @@ -467,7 +464,6 @@ var/list/admin_verbs_dev = list( //will need to be altered - Ryan784 /client/proc/debug_variables, /client/proc/dsay, /client/proc/getruntimelog, - /client/proc/giveruntimelog, /client/proc/hide_most_verbs, /client/proc/kill_air, /client/proc/kill_airgroup, diff --git a/code/modules/admin/verbs/getlogs.dm b/code/modules/admin/verbs/getlogs.dm index d59605e4967..769e68fc2f3 100644 --- a/code/modules/admin/verbs/getlogs.dm +++ b/code/modules/admin/verbs/getlogs.dm @@ -13,40 +13,15 @@ codebase for the entire /TG/station commuity a TONNE easier :3 Thanks for your help! */ - -//This proc allows Game Masters to grant a client access to the .getruntimelog verb -//Permissions expire at the end of each round. -//Runtimes can be used to meta or spot game-crashing exploits so it's advised to only grant coders that -//you trust access. Also, it may be wise to ensure that they are not going to play in the current round. -/client/proc/giveruntimelog() - set name = ".giveruntimelog" - set desc = "Give somebody access to any session logfiles saved to the /log/runtime/ folder." - set category = null - - if(!src.holder) - to_chat(src, "Only Admins may use this command.") - return - - var/client/target = input(src,"Choose somebody to grant access to the server's runtime logs (permissions expire at the end of each round):","Grant Permissions",null) as null|anything in GLOB.clients - if(!istype(target,/client)) - to_chat(src, "Error: giveruntimelog(): Client not found.") - return - - add_verb(target, /client/proc/getruntimelog) - to_chat(target, "You have been granted access to runtime logs. Please use them responsibly or risk being banned.") - return - - -//This proc allows download of runtime logs saved within the data/logs/ folder by dreamdeamon. -//It works similarly to show-server-log. +/** + * Allows a client that has this proc to download the runtime logs of the current round + */ /client/proc/getruntimelog() set name = ".getruntimelog" set desc = "Retrieve any session logfiles saved by dreamdeamon." set category = null - var/path = browse_files("data/logs/_runtime/") - if(!path) - return + var/path = LOGPATH(GLOB.config.logfiles["world_runtime_log"]) if(file_spam_check()) return @@ -54,17 +29,21 @@ message_admins("[key_name_admin(src)] accessed file: [path]") src << run( file(path) ) to_chat(src, "Attempting to send file, this may take a fair few minutes if the file is very large.") - return //This proc allows download of past server logs saved within the data/logs/ folder. //It works similarly to show-server-log. +/** + * Allows a client that has this proc the download of a log file of the active round + * + * Assigned only to admins currently + */ /client/proc/getserverlog() set name = ".getserverlog" set desc = "Fetch logfiles from data/logs" set category = null - var/path = browse_files("data/logs/") + var/path = browse_files(LOGPATH("")) //Prompt for which file to download, understands subfolders from files if(!path) return @@ -74,20 +53,3 @@ message_admins("[key_name_admin(src)] accessed file: [path]") src << run( file(path) ) to_chat(src, "Attempting to send file, this may take a fair few minutes if the file is very large.") - return - - -//Other log stuff put here for the sake of organisation - -/client/proc/view_signal_log() - set name = "View Signaler Log" - set desc = "Use this to view who sent signaler signals to things." - set category = "Admin" - - var/text_signal_log = "" - for(var/log in GLOB.signal_log) - text_signal_log += "[log]
" - - var/datum/browser/signal_win = new(usr, "signallog", "Signal Log", 550, 500) - signal_win.set_content(text_signal_log) - signal_win.open() diff --git a/code/modules/assembly/assembly.dm b/code/modules/assembly/assembly.dm index 2ef1f7b0477..f10bf48e4fb 100644 --- a/code/modules/assembly/assembly.dm +++ b/code/modules/assembly/assembly.dm @@ -89,13 +89,13 @@ return TRUE return FALSE -/obj/item/device/assembly/attackby(obj/item/W, mob/user) - if(isassembly(W)) - var/obj/item/device/assembly/A = W +/obj/item/device/assembly/attackby(obj/item/attacking_item, mob/user) + if(isassembly(attacking_item)) + var/obj/item/device/assembly/A = attacking_item if(!A.secured && !secured) attach_assembly(A, user) return - if(W.isscrewdriver()) + if(attacking_item.isscrewdriver()) if(toggle_secure()) to_chat(user, SPAN_NOTICE("\The [src] is ready!")) else @@ -108,13 +108,13 @@ return -/obj/item/device/assembly/examine(mob/user, distance, is_adjacent) +/obj/item/device/assembly/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1 || loc == user) if(secured) - to_chat(user, "\The [src] is ready!") + . += "\The [src] is ready!" else - to_chat(user, "\The [src] can be attached!") + . += "\The [src] can be attached!" /obj/item/device/assembly/attack_self(mob/user) diff --git a/code/modules/assembly/bomb.dm b/code/modules/assembly/bomb.dm index f71d2f7b123..295e875a364 100644 --- a/code/modules/assembly/bomb.dm +++ b/code/modules/assembly/bomb.dm @@ -23,11 +23,11 @@ add_overlay(bombassembly) add_overlay("bomb_assembly") -/obj/item/device/onetankbomb/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/device/analyzer)) - bombtank.attackby(W, user) +/obj/item/device/onetankbomb/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/device/analyzer)) + bombtank.attackby(attacking_item, user) return - if(!status && (W.iswrench() || istype(W, /obj/item/wirecutters/bomb))) //This is basically bomb assembly code inverted. apparently it works. + if(!status && (attacking_item.iswrench() || istype(attacking_item, /obj/item/wirecutters/bomb))) //This is basically bomb assembly code inverted. apparently it works. to_chat(user, SPAN_NOTICE("You disassemble \the [src].")) bombassembly.forceMove(get_turf(user)) @@ -41,8 +41,8 @@ qdel(src) return - if(W.iswelder()) - var/obj/item/weldingtool/WT = W + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.welding) return if(!status) diff --git a/code/modules/assembly/holder.dm b/code/modules/assembly/holder.dm index 33a5aee9c87..1ab471904e2 100644 --- a/code/modules/assembly/holder.dm +++ b/code/modules/assembly/holder.dm @@ -76,13 +76,13 @@ if(master) master.update_icon() -/obj/item/device/assembly_holder/examine(mob/user, distance, is_adjacent) +/obj/item/device/assembly_holder/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1 || src.loc == user) if (src.secured) - to_chat(user, SPAN_NOTICE("\The [src] is ready!")) + . += SPAN_NOTICE("\The [src] is ready!") else - to_chat(user, SPAN_NOTICE("\The [src] can be attached!")) + . += SPAN_NOTICE("\The [src] can be attached!") /obj/item/device/assembly_holder/HasProximity(atom/movable/AM as mob|obj) if(a_left) @@ -123,8 +123,8 @@ a_right.holder_movement() return ..() -/obj/item/device/assembly_holder/attackby(obj/item/W, mob/user) - if(W.isscrewdriver()) +/obj/item/device/assembly_holder/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) if(!a_left || !a_right) to_chat(user, SPAN_DANGER("BUG: Assembly part missing, please report this!")) return @@ -137,8 +137,8 @@ to_chat(user, SPAN_NOTICE("\The [src] can now be taken apart!")) update_icon() return - else if(W.IsSpecialAssembly()) - attach_special(W, user) + else if(attacking_item.IsSpecialAssembly()) + attach_special(attacking_item, user) else return ..() diff --git a/code/modules/assembly/infrared.dm b/code/modules/assembly/infrared.dm index 16524fd5296..c7e921cf14f 100644 --- a/code/modules/assembly/infrared.dm +++ b/code/modules/assembly/infrared.dm @@ -58,11 +58,10 @@ to_chat(user, SPAN_NOTICE("You rotate \the [src] to face [direction_text].")) QDEL_NULL(first) -/obj/item/device/assembly/infra/examine(mob/user) +/obj/item/device/assembly/infra/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() var/direction_text = dir2text(dir) - to_chat(user, SPAN_NOTICE("It is facing [direction_text].")) - + . += SPAN_NOTICE("It is facing [direction_text].") /obj/item/device/assembly/infra/process() diff --git a/code/modules/assembly/mousetrap.dm b/code/modules/assembly/mousetrap.dm index 4fb5a490851..61b5b75d8c9 100644 --- a/code/modules/assembly/mousetrap.dm +++ b/code/modules/assembly/mousetrap.dm @@ -13,10 +13,10 @@ matter = list(DEFAULT_WALL_MATERIAL = 100) var/armed = FALSE -/obj/item/device/assembly/mousetrap/examine(mob/user) +/obj/item/device/assembly/mousetrap/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(armed) - to_chat(user, "It looks like it's armed.") + . += "It looks like it's armed." /obj/item/device/assembly/mousetrap/update_icon() icon_state = armed ? "mousetraparmed" : "mousetrap" diff --git a/code/modules/atmospherics/atmospherics.dm b/code/modules/atmospherics/atmospherics.dm index 88af869ef36..22bc949ee16 100644 --- a/code/modules/atmospherics/atmospherics.dm +++ b/code/modules/atmospherics/atmospherics.dm @@ -54,8 +54,8 @@ Pipelines + Other Objects -> Pipe network /obj/machinery/atmospherics/LateInitialize() atmos_init() -/obj/machinery/atmospherics/attackby(atom/A, mob/user as mob) - if(istype(A, /obj/item/device/pipe_painter)) +/obj/machinery/atmospherics/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/device/pipe_painter)) return FALSE ..() diff --git a/code/modules/atmospherics/components/binary_devices/circulator.dm b/code/modules/atmospherics/components/binary_devices/circulator.dm index 55dc309c6ba..baf32ac7cb9 100644 --- a/code/modules/atmospherics/components/binary_devices/circulator.dm +++ b/code/modules/atmospherics/components/binary_devices/circulator.dm @@ -93,9 +93,9 @@ return TRUE -/obj/machinery/atmospherics/binary/circulator/attackby(obj/item/W as obj, mob/user as mob) - if(W.iswrench()) - playsound(src.loc, W.usesound, 50, 1) +/obj/machinery/atmospherics/binary/circulator/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswrench()) + playsound(src.loc, attacking_item.usesound, 50, 1) anchored = !anchored user.visible_message("[user.name] [anchored ? "secures" : "unsecures"] the bolts holding [src.name] to the floor.", \ "You [anchored ? "secure" : "unsecure"] the bolts holding [src] to the floor.", \ diff --git a/code/modules/atmospherics/components/binary_devices/oxyregenerator.dm b/code/modules/atmospherics/components/binary_devices/oxyregenerator.dm index 7e2427362ff..d45fa1d5a41 100644 --- a/code/modules/atmospherics/components/binary_devices/oxyregenerator.dm +++ b/code/modules/atmospherics/components/binary_devices/oxyregenerator.dm @@ -53,12 +53,12 @@ power_rating *= initial(power_rating) ..() -/obj/machinery/atmospherics/binary/oxyregenerator/examine(user) +/obj/machinery/atmospherics/binary/oxyregenerator/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user,"Its outlet port is to the [dir2text(dir)]") + . += "Its outlet port is to the [dir2text(dir)]." -/obj/machinery/atmospherics/binary/oxyregenerator/attackby(obj/item/O as obj, mob/user as mob) - if(O.iswrench()) +/obj/machinery/atmospherics/binary/oxyregenerator/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswrench()) playsound(src.loc, 'sound/items/Ratchet.ogg', 75, 1) anchored = !anchored user.visible_message("[user.name] [anchored ? "secures" : "unsecures"] the bolts holding [src.name] to the floor.", \ diff --git a/code/modules/atmospherics/components/binary_devices/passive_gate.dm b/code/modules/atmospherics/components/binary_devices/passive_gate.dm index b3a903a962c..478478ad395 100644 --- a/code/modules/atmospherics/components/binary_devices/passive_gate.dm +++ b/code/modules/atmospherics/components/binary_devices/passive_gate.dm @@ -321,8 +321,8 @@ src.add_fingerprint(usr) return -/obj/machinery/atmospherics/binary/passive_gate/attackby(var/obj/item/W as obj, var/mob/user as mob) - if (!W.iswrench()) +/obj/machinery/atmospherics/binary/passive_gate/attackby(obj/item/attacking_item, mob/user) + if (!attacking_item.iswrench()) return ..() if (unlocked) to_chat(user, "You cannot unwrench \the [src], turn it off first.") @@ -335,7 +335,7 @@ add_fingerprint(user) return TRUE to_chat(user, "You begin to unfasten \the [src]...") - if(W.use_tool(src, user, istype(W, /obj/item/pipewrench) ? 80 : 40, volume = 50)) + if(attacking_item.use_tool(src, user, istype(attacking_item, /obj/item/pipewrench) ? 80 : 40, volume = 50)) user.visible_message( \ "\The [user] unfastens \the [src].", \ "You have unfastened \the [src].", \ diff --git a/code/modules/atmospherics/components/binary_devices/pump.dm b/code/modules/atmospherics/components/binary_devices/pump.dm index a7f0f3c3589..41798ebecd1 100644 --- a/code/modules/atmospherics/components/binary_devices/pump.dm +++ b/code/modules/atmospherics/components/binary_devices/pump.dm @@ -249,8 +249,8 @@ Thus, the two variables affect pump operation are set in New(): if(old_stat != stat) update_icon() -/obj/machinery/atmospherics/binary/pump/attackby(var/obj/item/W as obj, var/mob/user as mob) - if (!W.iswrench() && !istype(W, /obj/item/pipewrench)) +/obj/machinery/atmospherics/binary/pump/attackby(obj/item/attacking_item, mob/user) + if (!attacking_item.iswrench() && !istype(attacking_item, /obj/item/pipewrench)) return ..() if (!(stat & NOPOWER) && use_power) to_chat(user, "You cannot unwrench this [src], turn it off first.") @@ -258,14 +258,14 @@ Thus, the two variables affect pump operation are set in New(): var/datum/gas_mixture/int_air = return_air() if (!loc) return FALSE var/datum/gas_mixture/env_air = loc.return_air() - if ((int_air.return_pressure()-env_air.return_pressure()) > PRESSURE_EXERTED && !istype(W, /obj/item/pipewrench)) + if ((int_air.return_pressure()-env_air.return_pressure()) > PRESSURE_EXERTED && !istype(attacking_item, /obj/item/pipewrench)) to_chat(user, "You cannot unwrench this [src], it's too exerted due to internal pressure.") add_fingerprint(user) return TRUE else to_chat(user, "You struggle to unwrench \the [src] with your pipe wrench.") to_chat(user, "You begin to unfasten \the [src]...") - if(W.use_tool(src, user, istype(W, /obj/item/pipewrench) ? 80 : 40, volume = 50)) + if(attacking_item.use_tool(src, user, istype(attacking_item, /obj/item/pipewrench) ? 80 : 40, volume = 50)) user.visible_message( \ "\The [user] unfastens \the [src].", \ "You have unfastened \the [src].", \ diff --git a/code/modules/atmospherics/components/omni_devices/omni_base.dm b/code/modules/atmospherics/components/omni_devices/omni_base.dm index 480a58d3592..df0dd862159 100644 --- a/code/modules/atmospherics/components/omni_devices/omni_base.dm +++ b/code/modules/atmospherics/components/omni_devices/omni_base.dm @@ -81,8 +81,8 @@ if(old_stat != stat) update_icon() -/obj/machinery/atmospherics/omni/attackby(var/obj/item/W as obj, var/mob/user as mob) - if(!W.iswrench()) +/obj/machinery/atmospherics/omni/attackby(obj/item/attacking_item, mob/user) + if(!attacking_item.iswrench()) return ..() var/int_pressure = 0 @@ -95,7 +95,7 @@ add_fingerprint(user) return TRUE to_chat(user, "You begin to unfasten \the [src]...") - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) user.visible_message( \ "\The [user] unfastens \the [src].", \ "You have unfastened \the [src].", \ diff --git a/code/modules/atmospherics/components/portables_connector.dm b/code/modules/atmospherics/components/portables_connector.dm index 6e861bab1da..4724b8892ae 100644 --- a/code/modules/atmospherics/components/portables_connector.dm +++ b/code/modules/atmospherics/components/portables_connector.dm @@ -142,8 +142,8 @@ return null -/obj/machinery/atmospherics/portables_connector/attackby(var/obj/item/W as obj, var/mob/user as mob) - if (!W.iswrench()) +/obj/machinery/atmospherics/portables_connector/attackby(obj/item/attacking_item, mob/user) + if (!attacking_item.iswrench()) return ..() if (connected_device) to_chat(user, "You cannot unwrench \the [src], dettach \the [connected_device] first.") @@ -158,7 +158,7 @@ add_fingerprint(user) return TRUE to_chat(user, "You begin to unfasten \the [src]...") - if(W.use_tool(src, user, istype(W, /obj/item/pipewrench) ? 80 : 40, volume = 50)) + if(attacking_item.use_tool(src, user, istype(attacking_item, /obj/item/pipewrench) ? 80 : 40, volume = 50)) user.visible_message( \ "\The [user] unfastens \the [src].", \ "You have unfastened \the [src].", \ diff --git a/code/modules/atmospherics/components/tvalve.dm b/code/modules/atmospherics/components/tvalve.dm index ba145719610..ffb07a7b87a 100644 --- a/code/modules/atmospherics/components/tvalve.dm +++ b/code/modules/atmospherics/components/tvalve.dm @@ -343,8 +343,8 @@ else go_to_side() -/obj/machinery/atmospherics/tvalve/attackby(var/obj/item/W as obj, var/mob/user as mob) - if (!W.iswrench()) +/obj/machinery/atmospherics/tvalve/attackby(obj/item/attacking_item, mob/user) + if (!attacking_item.iswrench()) return ..() if (istype(src, /obj/machinery/atmospherics/tvalve/digital)) to_chat(user, "You cannot unwrench \the [src], it's too complicated.") @@ -357,7 +357,7 @@ add_fingerprint(user) return TRUE to_chat(user, "You begin to unfasten \the [src]...") - if(W.use_tool(src, user, istype(W, /obj/item/pipewrench) ? 80 : 40, volume = 50)) + if(attacking_item.use_tool(src, user, istype(attacking_item, /obj/item/pipewrench) ? 80 : 40, volume = 50)) user.visible_message( \ "\The [user] unfastens \the [src].", \ "You have unfastened \the [src].", \ diff --git a/code/modules/atmospherics/components/unary/cold_sink.dm b/code/modules/atmospherics/components/unary/cold_sink.dm index 0bb8e90d267..330ae509527 100644 --- a/code/modules/atmospherics/components/unary/cold_sink.dm +++ b/code/modules/atmospherics/components/unary/cold_sink.dm @@ -171,17 +171,17 @@ power_setting = new_power_setting power_rating = max_power_rating * (power_setting/100) -/obj/machinery/atmospherics/unary/freezer/attackby(var/obj/item/O as obj, var/mob/user as mob) - if(default_deconstruction_screwdriver(user, O)) +/obj/machinery/atmospherics/unary/freezer/attackby(obj/item/attacking_item, mob/user) + if(default_deconstruction_screwdriver(user, attacking_item)) return TRUE - if(default_deconstruction_crowbar(user, O)) + if(default_deconstruction_crowbar(user, attacking_item)) return TRUE - if(default_part_replacement(user, O)) + if(default_part_replacement(user, attacking_item)) return TRUE return ..() -/obj/machinery/atmospherics/unary/freezer/examine(mob/user) +/obj/machinery/atmospherics/unary/freezer/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(panel_open) - to_chat(user, "The maintenance hatch is open.") + . += "The maintenance hatch is open." diff --git a/code/modules/atmospherics/components/unary/heat_exchanger.dm b/code/modules/atmospherics/components/unary/heat_exchanger.dm index d31e31d5921..09b6f4a1caf 100644 --- a/code/modules/atmospherics/components/unary/heat_exchanger.dm +++ b/code/modules/atmospherics/components/unary/heat_exchanger.dm @@ -63,8 +63,8 @@ return TRUE -/obj/machinery/atmospherics/unary/heat_exchanger/attackby(var/obj/item/W as obj, var/mob/user as mob) - if(!W.iswrench()) +/obj/machinery/atmospherics/unary/heat_exchanger/attackby(obj/item/attacking_item, mob/user) + if(!attacking_item.iswrench()) return ..() var/turf/T = src.loc if(level == 1 && isturf(T) && !T.is_plating()) @@ -78,7 +78,7 @@ add_fingerprint(user) return TRUE to_chat(user, SPAN_NOTICE("You begin to unfasten \the [src]...")) - if(W.use_tool(src, user, istype(W, /obj/item/pipewrench) ? 80 : 40, volume = 50)) + if(attacking_item.use_tool(src, user, istype(attacking_item, /obj/item/pipewrench) ? 80 : 40, volume = 50)) user.visible_message( SPAN_NOTICE("\The [user] unfastens \the [src]."), SPAN_NOTICE("You have unfastened \the [src]."), diff --git a/code/modules/atmospherics/components/unary/heat_source.dm b/code/modules/atmospherics/components/unary/heat_source.dm index 8b371f6ede3..352fe777d37 100644 --- a/code/modules/atmospherics/components/unary/heat_source.dm +++ b/code/modules/atmospherics/components/unary/heat_source.dm @@ -159,17 +159,17 @@ power_setting = new_power_setting power_rating = max_power_rating * (power_setting/100) -/obj/machinery/atmospherics/unary/heater/attackby(var/obj/item/O as obj, var/mob/user as mob) - if(default_deconstruction_screwdriver(user, O)) +/obj/machinery/atmospherics/unary/heater/attackby(obj/item/attacking_item, mob/user) + if(default_deconstruction_screwdriver(user, attacking_item)) return TRUE - if(default_deconstruction_crowbar(user, O)) + if(default_deconstruction_crowbar(user, attacking_item)) return TRUE - if(default_part_replacement(user, O)) + if(default_part_replacement(user, attacking_item)) return TRUE return ..() -/obj/machinery/atmospherics/unary/heater/examine(mob/user) +/obj/machinery/atmospherics/unary/heater/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(panel_open) - to_chat(user, "The maintenance hatch is open.") + . += "The maintenance hatch is open." diff --git a/code/modules/atmospherics/components/unary/vent_pump.dm b/code/modules/atmospherics/components/unary/vent_pump.dm index 7d83fc01bfa..b436c22448d 100644 --- a/code/modules/atmospherics/components/unary/vent_pump.dm +++ b/code/modules/atmospherics/components/unary/vent_pump.dm @@ -373,14 +373,14 @@ broadcast_status_next_process = TRUE update_icon() -/obj/machinery/atmospherics/unary/vent_pump/attackby(obj/item/W, mob/user) - if(W.iswelder()) - var/obj/item/weldingtool/WT = W +/obj/machinery/atmospherics/unary/vent_pump/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if (!WT.welding) to_chat(user, SPAN_DANGER("\The [WT] must be turned on!")) else if (WT.use(0,user)) to_chat(user, SPAN_NOTICE("Now welding the vent.")) - if(W.use_tool(src, user, 30, volume = 50)) + if(attacking_item.use_tool(src, user, 30, volume = 50)) if(!src || !WT.isOn()) return TRUE welded = !welded @@ -394,19 +394,19 @@ else to_chat(user, SPAN_WARNING("You need more welding fuel to complete this task.")) return TRUE - else if(istype(W, /obj/item/melee/arm_blade)) + else if(istype(attacking_item, /obj/item/melee/arm_blade)) if(!welded) - to_chat(user, SPAN_WARNING("\The [W] can only be used to tear open welded air vents!")) + to_chat(user, SPAN_WARNING("\The [attacking_item] can only be used to tear open welded air vents!")) return TRUE - user.visible_message(SPAN_WARNING("\The [user] starts using \the [W] to hack open \the [src]!"), SPAN_NOTICE("You start hacking open \the [src] with \the [W]...")) - user.do_attack_animation(src, W) + user.visible_message(SPAN_WARNING("\The [user] starts using \the [attacking_item] to hack open \the [src]!"), SPAN_NOTICE("You start hacking open \the [src] with \the [attacking_item]...")) + user.do_attack_animation(src, attacking_item) playsound(loc, 'sound/weapons/smash.ogg', 60, TRUE) var/cut_amount = 3 for(var/i = 0; i <= cut_amount; i++) - if(!W || !do_after(user, 30, src)) + if(!attacking_item || !do_after(user, 30, src)) return TRUE - user.do_attack_animation(src, W) - user.visible_message(SPAN_WARNING("\The [user] smashes \the [W] into \the [src]!"), SPAN_NOTICE("You smash \the [W] into \the [src].")) + user.do_attack_animation(src, attacking_item) + user.visible_message(SPAN_WARNING("\The [user] smashes \the [attacking_item] into \the [src]!"), SPAN_NOTICE("You smash \the [attacking_item] into \the [src].")) playsound(loc, 'sound/weapons/smash.ogg', 60, TRUE) if(i == cut_amount) welded = FALSE @@ -416,14 +416,14 @@ else return ..() -/obj/machinery/atmospherics/unary/vent_pump/examine(mob/user, distance, is_adjacent) +/obj/machinery/atmospherics/unary/vent_pump/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1) - to_chat(user, "A small gauge in the corner reads [round(last_flow_rate, 0.1)] L/s; [round(last_power_draw)] W") + . += "A small gauge in the corner reads [round(last_flow_rate, 0.1)] L/s at [round(last_power_draw)] W." else - to_chat(user, "You are too far away to read the gauge.") + . += "You are too far away to read the gauge." if(welded) - to_chat(user, "It seems welded shut.") + . += "It seems welded shut." /obj/machinery/atmospherics/unary/vent_pump/power_change() var/old_stat = stat @@ -431,8 +431,8 @@ if(old_stat != stat) update_icon() -/obj/machinery/atmospherics/unary/vent_pump/attackby(var/obj/item/W as obj, var/mob/user as mob) - if (!W.iswrench()) +/obj/machinery/atmospherics/unary/vent_pump/attackby(obj/item/attacking_item, mob/user) + if (!attacking_item.iswrench()) return ..() if (!(stat & NOPOWER) && use_power) to_chat(user, SPAN_WARNING("You cannot unwrench \the [src], turn it off first.")) @@ -449,7 +449,7 @@ add_fingerprint(user) return TRUE to_chat(user, SPAN_NOTICE("You begin to unfasten \the [src]...")) - if(W.use_tool(src, user, istype(W, /obj/item/pipewrench) ? 80 : 40, volume = 50)) + if(attacking_item.use_tool(src, user, istype(attacking_item, /obj/item/pipewrench) ? 80 : 40, volume = 50)) user.visible_message( \ SPAN_NOTICE("\The [user] unfastens \the [src]."), \ SPAN_NOTICE("You have unfastened \the [src]."), \ diff --git a/code/modules/atmospherics/components/unary/vent_scrubber.dm b/code/modules/atmospherics/components/unary/vent_scrubber.dm index 3df33f5c9f5..1b20fd508a6 100644 --- a/code/modules/atmospherics/components/unary/vent_scrubber.dm +++ b/code/modules/atmospherics/components/unary/vent_scrubber.dm @@ -344,8 +344,8 @@ if(old_stat != stat) update_icon() -/obj/machinery/atmospherics/unary/vent_scrubber/attackby(var/obj/item/W as obj, var/mob/user as mob) - if (W.iswrench()) +/obj/machinery/atmospherics/unary/vent_scrubber/attackby(obj/item/attacking_item, mob/user) + if (attacking_item.iswrench()) if (!(stat & NOPOWER) && use_power) to_chat(user, SPAN_WARNING("You cannot unwrench \the [src], turn it off first.")) return TRUE @@ -361,7 +361,7 @@ add_fingerprint(user) return TRUE to_chat(user, SPAN_NOTICE("You begin to unfasten \the [src]...")) - if(W.use_tool(src, user, 40, volume = 50)) + if(attacking_item.use_tool(src, user, 40, volume = 50)) user.visible_message( \ SPAN_NOTICE("\The [user] unfastens \the [src]."), \ SPAN_NOTICE("You have unfastened \the [src]."), \ @@ -370,8 +370,8 @@ qdel(src) return TRUE - if(W.iswelder()) - var/obj/item/weldingtool/WT = W + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(!WT.isOn()) to_chat(user, SPAN_NOTICE("\The [WT] needs to be on to start this task.")) @@ -394,19 +394,19 @@ "You hear welding.") return TRUE - if(istype(W, /obj/item/melee/arm_blade)) + if(istype(attacking_item, /obj/item/melee/arm_blade)) if(!welded) - to_chat(user, SPAN_WARNING("\The [W] can only be used to tear open welded scrubbers!")) + to_chat(user, SPAN_WARNING("\The [attacking_item] can only be used to tear open welded scrubbers!")) return TRUE - user.visible_message(SPAN_WARNING("\The [user] starts using \the [W] to hack open \the [src]!"), SPAN_NOTICE("You start hacking open \the [src] with \the [W]...")) - user.do_attack_animation(src, W) + user.visible_message(SPAN_WARNING("\The [user] starts using \the [attacking_item] to hack open \the [src]!"), SPAN_NOTICE("You start hacking open \the [src] with \the [attacking_item]...")) + user.do_attack_animation(src, attacking_item) playsound(loc, 'sound/weapons/smash.ogg', 60, TRUE) var/cut_amount = 3 for(var/i = 0; i <= cut_amount; i++) - if(!W || !do_after(user, 30, src)) + if(!attacking_item || !do_after(user, 30, src)) return TRUE - user.do_attack_animation(src, W) - user.visible_message(SPAN_WARNING("\The [user] smashes \the [W] into \the [src]!"), SPAN_NOTICE("You smash \the [W] into \the [src].")) + user.do_attack_animation(src, attacking_item) + user.visible_message(SPAN_WARNING("\The [user] smashes \the [attacking_item] into \the [src]!"), SPAN_NOTICE("You smash \the [attacking_item] into \the [src].")) playsound(loc, 'sound/weapons/smash.ogg', 60, TRUE) if(i == cut_amount) welded = FALSE @@ -417,11 +417,11 @@ return ..() -/obj/machinery/atmospherics/unary/vent_scrubber/examine(mob/user, distance, is_adjacent) +/obj/machinery/atmospherics/unary/vent_scrubber/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1) - to_chat(user, "A small gauge in the corner reads [round(last_flow_rate, 0.1)] L/s; [round(last_power_draw)] W") + . += "A small gauge in the corner reads [round(last_flow_rate, 0.1)] L/s at [round(last_power_draw)] W." else - to_chat(user, "You are too far away to read the gauge.") + . += "You are too far away to read the gauge." if(welded) - to_chat(user, "It seems welded shut.") + . += "It seems welded shut." diff --git a/code/modules/atmospherics/components/valve.dm b/code/modules/atmospherics/components/valve.dm index 34bfc2d7dae..478da8609ee 100644 --- a/code/modules/atmospherics/components/valve.dm +++ b/code/modules/atmospherics/components/valve.dm @@ -301,8 +301,8 @@ else open() -/obj/machinery/atmospherics/valve/attackby(var/obj/item/W as obj, var/mob/user as mob) - if (!W.iswrench()) +/obj/machinery/atmospherics/valve/attackby(obj/item/attacking_item, mob/user) + if (!attacking_item.iswrench()) return ..() if (istype(src, /obj/machinery/atmospherics/valve/digital)) to_chat(user, "You cannot unwrench \the [src], it's too complicated.") @@ -315,7 +315,7 @@ add_fingerprint(user) return TRUE to_chat(user, "You begin to unfasten \the [src]...") - if(W.use_tool(src, user, istype(W, /obj/item/pipewrench) ? 80 : 40, volume = 50)) + if(attacking_item.use_tool(src, user, istype(attacking_item, /obj/item/pipewrench) ? 80 : 40, volume = 50)) user.visible_message( \ "\The [user] unfastens \the [src].", \ "You have unfastened \the [src].", \ @@ -324,6 +324,6 @@ qdel(src) return TRUE -/obj/machinery/atmospherics/valve/examine(mob/user) +/obj/machinery/atmospherics/valve/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, "It is [open ? "open" : "closed"].") + . += "It is [open ? "open" : "closed"]." diff --git a/code/modules/atmospherics/pipes.dm b/code/modules/atmospherics/pipes.dm index dc5bd0fe485..b68fc5ba307 100644 --- a/code/modules/atmospherics/pipes.dm +++ b/code/modules/atmospherics/pipes.dm @@ -74,19 +74,19 @@ return ..() -/obj/machinery/atmospherics/pipe/attackby(var/obj/item/W as obj, var/mob/user as mob) +/obj/machinery/atmospherics/pipe/attackby(obj/item/attacking_item, mob/user) if (istype(src, /obj/machinery/atmospherics/pipe/tank)) return ..() - if(istype(W,/obj/item/device/pipe_painter)) + if(istype(attacking_item,/obj/item/device/pipe_painter)) return FALSE - if(istype(W, /obj/item/device/analyzer) && Adjacent(user)) - var/obj/item/device/analyzer/A = W + if(istype(attacking_item, /obj/item/device/analyzer) && Adjacent(user)) + var/obj/item/device/analyzer/A = attacking_item A.analyze_gases(src, user) return FALSE - if (!W.iswrench() && !istype(W, /obj/item/pipewrench)) + if (!attacking_item.iswrench() && !istype(attacking_item, /obj/item/pipewrench)) return ..() var/turf/T = src.loc if (level==1 && isturf(T) && !T.is_plating()) @@ -96,14 +96,14 @@ if(!loc) return FALSE var/datum/gas_mixture/env_air = loc.return_air() if ((int_air.return_pressure()-env_air.return_pressure()) > PRESSURE_EXERTED) - if(!istype(W, /obj/item/pipewrench)) + if(!istype(attacking_item, /obj/item/pipewrench)) to_chat(user, "You cannot unwrench \the [src], it is too exerted due to internal pressure.") add_fingerprint(user) return TRUE else to_chat(user, "You struggle to unwrench \the [src] with your pipe wrench.") to_chat(user, "You begin to unfasten \the [src]...") - if(W.use_tool(src, user, istype(W, /obj/item/pipewrench) ? 80 : 40, volume = 50)) + if(attacking_item.use_tool(src, user, istype(attacking_item, /obj/item/pipewrench) ? 80 : 40, volume = 50)) user.visible_message( \ "\The [user] unfastens \the [src].", \ "You have unfastened \the [src].", \ @@ -1369,12 +1369,12 @@ return null -/obj/machinery/atmospherics/pipe/tank/attackby(var/obj/item/W as obj, var/mob/user as mob) - if(istype(W, /obj/item/device/pipe_painter)) +/obj/machinery/atmospherics/pipe/tank/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/device/pipe_painter)) return FALSE - if(istype(W, /obj/item/device/analyzer) && in_range(user, src)) - var/obj/item/device/analyzer/A = W + if(istype(attacking_item, /obj/item/device/analyzer) && in_range(user, src)) + var/obj/item/device/analyzer/A = attacking_item A.analyze_gases(src, user) return TRUE diff --git a/code/modules/awaymissions/gateway.dm b/code/modules/awaymissions/gateway.dm index ad846b77491..b526f90d3ab 100644 --- a/code/modules/awaymissions/gateway.dm +++ b/code/modules/awaymissions/gateway.dm @@ -132,8 +132,8 @@ return -/obj/machinery/gateway/centerstation/attackby(obj/item/device/W as obj, mob/user as mob) - if(W.ismultitool()) +/obj/machinery/gateway/centerstation/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ismultitool()) to_chat(user, "\black The gate is already calibrated, there is no work for you to do here.") return @@ -228,8 +228,8 @@ M.set_dir(SOUTH) -/obj/machinery/gateway/centeraway/attackby(obj/item/device/W as obj, mob/user as mob) - if(W.ismultitool()) +/obj/machinery/gateway/centeraway/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ismultitool()) if(calibrated) to_chat(user, "\black The gate is already calibrated, there is no work for you to do here.") return diff --git a/code/modules/background/citizenship/ipc.dm b/code/modules/background/citizenship/ipc.dm index 2a80f12ff60..bdb64f1b951 100644 --- a/code/modules/background/citizenship/ipc.dm +++ b/code/modules/background/citizenship/ipc.dm @@ -34,7 +34,7 @@ /datum/outfit/job/representative/consular/golden name = "Golden Deep Consular Officer" - uniform = /obj/item/clothing/under/suit_jacket/burgundy + uniform = /obj/item/clothing/under/goldendeep/suit backpack_contents = list( - /obj/item/gun/energy/pistol = 1 + /obj/item/gun/energy/pistol/goldendeep = 1 ) diff --git a/code/modules/background/origins/origins/unathi/spaceborn.dm b/code/modules/background/origins/origins/unathi/spaceborn.dm index d386697c8c7..c5014964b5f 100644 --- a/code/modules/background/origins/origins/unathi/spaceborn.dm +++ b/code/modules/background/origins/origins/unathi/spaceborn.dm @@ -14,7 +14,7 @@ important_information = "Outside of the Hegemony, records should say they have some kind of visa instead of citizenship." possible_accents = list(ACCENT_TRAD_PEASANT, ACCENT_HEARTLAND_PEASANT, ACCENT_TRAD_NOBLE, ACCENT_TZA_PEASANT, ACCENT_TZA_NOBLE, ACCENT_SOUTHLANDS_NOBLE, ACCENT_SOUTHLANDS_PEASANT, ACCENT_TORN, ACCENT_ZAZ_LOW, ACCENT_ZAZ_HIGH, ACCENT_BROKEN_PEASANT, ACCENT_BROKEN_NOBLE, ACCENT_WASTELAND, ACCENT_UNATHI_SPACER, ACCENT_HAZANA, ACCENT_OUEREA) possible_citizenships = list(CITIZENSHIP_IZWESKI, CITIZENSHIP_BIESEL, CITIZENSHIP_COALITION) - possible_religions = list(RELIGION_THAKH, RELIGION_SKAKH, RELIGION_AUTAKH, RELIGION_OTHER, RELIGION_NONE) + possible_religions = list(RELIGION_THAKH, RELIGION_SKAKH, RELIGION_AUTAKH, RELIGION_SIAKH, RELIGION_OTHER, RELIGION_NONE) /singleton/origin_item/origin/ouerea name = "Ouerea" @@ -23,7 +23,7 @@ with human, Skrell and Unathi culture blending into something strange, new and altogether unique within the Orion Spur." possible_accents = list(ACCENT_OUEREA) possible_citizenships = list(CITIZENSHIP_IZWESKI, CITIZENSHIP_BIESEL, CITIZENSHIP_COALITION) - possible_religions = list(RELIGION_THAKH, RELIGION_SKAKH, RELIGION_AUTAKH, RELIGION_OTHER, RELIGION_NONE) + possible_religions = list(RELIGION_THAKH, RELIGION_SKAKH, RELIGION_AUTAKH, RELIGION_SIAKH, RELIGION_OTHER, RELIGION_NONE) /singleton/origin_item/origin/colonist name = "Colonist" @@ -55,6 +55,6 @@ and have integrated into the population smoothly. Following the Republic of Biesel's annexation of Mictlan, the Unathi of the planet have largely refused to involve themselves in the ongoing struggle between the Samaritan movement and Biesel, simply wishing not to see another home consumed in war." possible_accents = list(ACCENT_MICTLAN) possible_citizenships = list(CITIZENSHIP_BIESEL) - possible_religions = list(RELIGION_THAKH, RELIGION_SKAKH, RELIGION_NONE) + possible_religions = list(RELIGION_THAKH, RELIGION_SKAKH, RELIGION_SIAKH, RELIGION_NONE) origin_traits = list(TRAIT_ORIGIN_IGNORE_CAPSAICIN) origin_traits_descriptions = list("are not affected by spicy foods") diff --git a/code/modules/battlemonsters/items/card.dm b/code/modules/battlemonsters/items/card.dm index 22fa9185a47..8b9e68f89a3 100644 --- a/code/modules/battlemonsters/items/card.dm +++ b/code/modules/battlemonsters/items/card.dm @@ -19,9 +19,9 @@ . = ..() Generate_Card(prefix, root, title, trap, spell) -/obj/item/battle_monsters/card/attackby(var/obj/item/attacking, var/mob/user) - if(istype(attacking,/obj/item/battle_monsters/card) && attacking != src) - var/obj/item/battle_monsters/card/adding_card = attacking +/obj/item/battle_monsters/card/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item,/obj/item/battle_monsters/card) && attacking_item != src) + var/obj/item/battle_monsters/card/adding_card = attacking_item make_deck(user,adding_card) /obj/item/battle_monsters/card/resolve_attackby(atom/A, mob/user, var/click_parameters) @@ -164,12 +164,11 @@ transform = M -/obj/item/battle_monsters/card/examine(mob/user, distance, is_adjacent) - +/obj/item/battle_monsters/card/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(facedown && src.loc != user) - to_chat(user, SPAN_NOTICE("You can't examine \the [src] while it's face down!")) + . += SPAN_NOTICE("You can't examine \the [src] while it's face down!") return if(trap_datum) diff --git a/code/modules/battlemonsters/items/deck.dm b/code/modules/battlemonsters/items/deck.dm index eab95edcdf2..db2bd3f51f0 100644 --- a/code/modules/battlemonsters/items/deck.dm +++ b/code/modules/battlemonsters/items/deck.dm @@ -136,9 +136,9 @@ else . = ..() -/obj/item/battle_monsters/deck/attackby(var/obj/item/attacking, var/mob/user) - if(istype(attacking,/obj/item/battle_monsters/card) && attacking != src) - var/obj/item/battle_monsters/card/adding_card = attacking +/obj/item/battle_monsters/deck/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item,/obj/item/battle_monsters/card) && attacking_item != src) + var/obj/item/battle_monsters/card/adding_card = attacking_item add_card(user,adding_card) /obj/item/battle_monsters/deck/attack_self(mob/user) diff --git a/code/modules/battlemonsters/items/furniture/dueling_area.dm b/code/modules/battlemonsters/items/furniture/dueling_area.dm index 7425f204720..37f63a94e23 100644 --- a/code/modules/battlemonsters/items/furniture/dueling_area.dm +++ b/code/modules/battlemonsters/items/furniture/dueling_area.dm @@ -23,16 +23,16 @@ #define CELLS 8 #define CELLSIZE (world.icon_size/CELLS) -/obj/structure/dueling_table/attackby(obj/item/W as obj, mob/user as mob, var/click_parameters) - if(user.unEquip(W, 0, src.loc)) - if(!W.center_of_mass) - W.randpixel_xy() +/obj/structure/dueling_table/attackby(obj/item/attacking_item, mob/user , params) + if(user.unEquip(attacking_item, 0, src.loc)) + if(!attacking_item.center_of_mass) + attacking_item.randpixel_xy() return - if(!click_parameters) + if(!params) return - var/list/mouse_control = mouse_safe_xy(click_parameters) + var/list/mouse_control = mouse_safe_xy(params) var/mouse_x = mouse_control["icon-x"] var/mouse_y = mouse_control["icon-y"] @@ -40,10 +40,10 @@ var/cell_x = max(0, min(CELLS-1, round(mouse_x/CELLSIZE))) var/cell_y = max(0, min(CELLS-1, round(mouse_y/CELLSIZE))) - W.pixel_x = (CELLSIZE * (0.5 + cell_x)) - W.center_of_mass["x"] - W.pixel_y = (CELLSIZE * (0.5 + cell_y)) - W.center_of_mass["y"] + attacking_item.pixel_x = (CELLSIZE * (0.5 + cell_x)) - attacking_item.center_of_mass["x"] + attacking_item.pixel_y = (CELLSIZE * (0.5 + cell_y)) - attacking_item.center_of_mass["y"] - W.layer = src.layer + 0.1 + attacking_item.layer = src.layer + 0.1 #undef CELLS #undef CELLSIZE diff --git a/code/modules/blob/blob.dm b/code/modules/blob/blob.dm index ff485dcedd3..2d34e701a76 100644 --- a/code/modules/blob/blob.dm +++ b/code/modules/blob/blob.dm @@ -201,11 +201,11 @@ take_damage((Proj.damage / laser_resist) / fire_resist) return FALSE -/obj/effect/blob/attackby(obj/item/W, mob/user) +/obj/effect/blob/attackby(obj/item/attacking_item, mob/user) user.setClickCooldown(DEFAULT_ATTACK_COOLDOWN) user.do_attack_animation(src) playsound(get_turf(src), 'sound/effects/attackblob.ogg', 50, TRUE) - if(W.iswirecutter()) + if(attacking_item.iswirecutter()) if(!pruned) to_chat(user, SPAN_NOTICE("You collect a sample from \the [src].")) var/obj/P = new product(get_turf(user)) @@ -217,13 +217,13 @@ return var/damage = 0 - switch(W.damtype) + switch(attacking_item.damtype) if(DAMAGE_BURN) - damage = (W.force / fire_resist) - if(W.iswelder()) + damage = (attacking_item.force / fire_resist) + if(attacking_item.iswelder()) playsound(get_turf(src), 'sound/items/Welder.ogg', 100, TRUE) if(DAMAGE_BRUTE) - damage = (W.force / brute_resist) + damage = (attacking_item.force / brute_resist) take_damage(damage) diff --git a/code/modules/cargo/delivery/backpack.dm b/code/modules/cargo/delivery/backpack.dm index 4635b85366b..8f9f847d679 100644 --- a/code/modules/cargo/delivery/backpack.dm +++ b/code/modules/cargo/delivery/backpack.dm @@ -17,10 +17,10 @@ QDEL_LIST(contained_packages) return ..() -/obj/item/cargo_backpack/examine(mob/user, distance) +/obj/item/cargo_backpack/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(length(contained_packages)) - to_chat(user, FONT_SMALL(SPAN_NOTICE("\[?\] There are some packages loaded. \[Show Package Data\]"))) + . += FONT_SMALL(SPAN_NOTICE("\[?\] There are some packages loaded. \[Show Package Data\]")) /obj/item/cargo_backpack/Topic(href, href_list) if(href_list["show_package_data"]) @@ -99,24 +99,24 @@ LAZYREMOVE(contained_packages, package) update_state() -/obj/item/cargo_backpack/attackby(obj/item/item, mob/living/carbon/human/user) +/obj/item/cargo_backpack/attackby(obj/item/attacking_item, mob/user) if(!ishuman(user)) return ..() if(user.back != src) - if(istype(item, /obj/item/cargo_package)) + if(istype(attacking_item, /obj/item/cargo_package)) to_chat(user, SPAN_WARNING("Put \the [src] on your back before you load packages onto it!")) return return ..() - if(!istype(item, /obj/item/cargo_package)) + if(!istype(attacking_item, /obj/item/cargo_package)) return ..() if(LAZYLEN(contained_packages) >= 2) to_chat(user, SPAN_WARNING("\The [src] is already fully loaded!")) return - user.visible_message("[user] starts loading \the [item] onto \the [src]...", SPAN_NOTICE("You start loading \the [item] onto \the [src]...")) + user.visible_message("[user] starts loading \the [attacking_item] onto \the [src]...", SPAN_NOTICE("You start loading \the [attacking_item] onto \the [src]...")) if(do_after(user, 1 SECONDS, src, DO_UNIQUE)) - user.visible_message("[user] loads \the [item] onto \the [src]!", SPAN_NOTICE("You load \the [item] onto \the [src]!")) - user.drop_from_inventory(item, src) - LAZYADD(contained_packages, item) + user.visible_message("[user] loads \the [attacking_item] onto \the [src]!", SPAN_NOTICE("You load \the [attacking_item] onto \the [src]!")) + user.drop_from_inventory(attacking_item, src) + LAZYADD(contained_packages, attacking_item) update_state() diff --git a/code/modules/cargo/delivery/package.dm b/code/modules/cargo/delivery/package.dm index 13a0734f6c8..b559d499ef2 100644 --- a/code/modules/cargo/delivery/package.dm +++ b/code/modules/cargo/delivery/package.dm @@ -35,7 +35,7 @@ delivery_point_sector = delivery_point.delivery_sector delivery_point_coordinates = "[delivery_point.x]-[delivery_point.y]" -/obj/item/cargo_package/examine(mob/user, distance) +/obj/item/cargo_package/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(delivery_point_id) var/delivery_site = "Unknown" @@ -43,8 +43,8 @@ var/obj/effect/overmap/visitable/delivery_sector = delivery_point_sector.resolve() if(delivery_sector) delivery_site = delivery_sector.name - to_chat(user, SPAN_NOTICE("The label on the package reads: SITE: [delivery_site] | COORD: [delivery_point_coordinates] | ID: [delivery_point_id]")) - to_chat(user, SPAN_NOTICE("The price tag on the package reads: [pay_amount]电")) + . += SPAN_NOTICE("The label on the package reads: SITE: [delivery_site] | COORD: [delivery_point_coordinates] | ID: [delivery_point_id]") + . += SPAN_NOTICE("The price tag on the package reads: [pay_amount]电.") /obj/item/cargo_package/do_additional_pickup_checks(var/mob/living/carbon/human/user) if(!ishuman(user)) @@ -132,10 +132,10 @@ var/obj/structure/cargo_receptacle/selected_delivery_point = pick(eligible_delivery_points) setup_delivery_point(selected_delivery_point) -/obj/item/cargo_package/offship/examine(mob/user, distance) +/obj/item/cargo_package/offship/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(!delivery_point_id) - to_chat(user, SPAN_NOTICE("Delivery site still being calculated, please check back later!")) + . += SPAN_NOTICE("Delivery site still being calculated, please check back later!") /obj/item/cargo_package/offship/to_horizon horizon_delivery = TRUE diff --git a/code/modules/cargo/delivery/receptacle.dm b/code/modules/cargo/delivery/receptacle.dm index c61901b7a46..4010a41c769 100644 --- a/code/modules/cargo/delivery/receptacle.dm +++ b/code/modules/cargo/delivery/receptacle.dm @@ -51,9 +51,9 @@ var/global/list/all_cargo_receptacles = list() all_cargo_receptacles -= src return ..() -/obj/structure/cargo_receptacle/attackby(obj/item/item, mob/user) - if(istype(item, /obj/item/cargo_package)) - var/obj/item/cargo_package/package = item +/obj/structure/cargo_receptacle/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/cargo_package)) + var/obj/item/cargo_package/package = attacking_item if(!package.associated_delivery_point) to_chat(user, SPAN_WARNING("Something's wrong with the cargo package, submit a bug report. ERRCODE: 0")) return @@ -63,11 +63,11 @@ var/global/list/all_cargo_receptacles = list() visible_message(SPAN_WARNING("\The [src] buzzes harshly, \"Invalid package! Check the delivery ID!\"")) return - user.visible_message("[user] starts heaving \the [item] into \the [src]...", SPAN_NOTICE("You start heaving \the [item] into \the [src]...")) + user.visible_message("[user] starts heaving \the [attacking_item] into \the [src]...", SPAN_NOTICE("You start heaving \the [attacking_item] into \the [src]...")) if(do_after(user, 1 SECONDS, src, DO_UNIQUE)) - user.drop_from_inventory(item, src) - pay_account(user, item) - qdel(item) + user.drop_from_inventory(attacking_item, src) + pay_account(user, attacking_item) + qdel(attacking_item) return return ..() diff --git a/code/modules/client/preference_setup/loadout/items/accessories.dm b/code/modules/client/preference_setup/loadout/items/accessories.dm index b0c216f4d6f..263f1c0ba44 100644 --- a/code/modules/client/preference_setup/loadout/items/accessories.dm +++ b/code/modules/client/preference_setup/loadout/items/accessories.dm @@ -1,8 +1,11 @@ /datum/gear/accessory + abstract_type = /datum/gear/accessory + sort_category = "Accessories" + +/datum/gear/accessory/locket display_name = "silver locket" path = /obj/item/clothing/accessory/locket slot = slot_tie - sort_category = "Accessories" /datum/gear/accessory/suspenders display_name = "suspenders" diff --git a/code/modules/client/preference_setup/loadout/items/computer.dm b/code/modules/client/preference_setup/loadout/items/computer.dm index 1f58de84074..fed3e136e59 100644 --- a/code/modules/client/preference_setup/loadout/items/computer.dm +++ b/code/modules/client/preference_setup/loadout/items/computer.dm @@ -4,6 +4,9 @@ sort_category = "Modular Computers" cost = 2 +/datum/gear/computer/handheld + abstract_type = /datum/gear/computer/handheld + /datum/gear/computer/handheld/tablet display_name = "tablet" path = /obj/item/modular_computer/handheld/preset @@ -23,6 +26,9 @@ tablets["machinist tablet"] = /obj/item/modular_computer/handheld/preset/supply/machinist gear_tweaks += new /datum/gear_tweak/path(tablets) +/datum/gear/computer/handheld/wristbound + abstract_type = /datum/gear/computer/handheld/wristbound + /datum/gear/computer/handheld/wristbound/selection display_name = "wristbound computer selection" path = /obj/item/modular_computer/handheld/wristbound/preset diff --git a/code/modules/client/preference_setup/loadout/items/general.dm b/code/modules/client/preference_setup/loadout/items/general.dm index ee168f37630..cf26f4c2973 100644 --- a/code/modules/client/preference_setup/loadout/items/general.dm +++ b/code/modules/client/preference_setup/loadout/items/general.dm @@ -410,26 +410,17 @@ description = "A commemorative miniature of the NSS Aurora." path = /obj/item/toy/aurora -/datum/gear/guitar - display_name = "guitar" - description = "A wooden musical instrument with six strings. This one looks like it may actually work." - path = /obj/item/device/synthesized_instrument/guitar +/datum/gear/instruments + display_name = "instrument selection" + description = "A selection of instruments for the musically inclined." + path = /obj/item/device/synthesized_instrument allowed_roles = list("Off-Duty Crew Member", "Passenger") -/datum/gear/polyguitar - display_name = "polyguitar" - description = "An instrument for a more ass-kicking era." - path = /obj/item/device/synthesized_instrument/guitar/multi - allowed_roles = list("Off-Duty Crew Member", "Passenger") - -/datum/gear/violin - display_name = "violin" - description = "A wooden musical instrument with four strings and a bow, it is quite old." - path = /obj/item/device/synthesized_instrument/violin - allowed_roles = list("Off-Duty Crew Member", "Passenger") - -/datum/gear/trumpet - display_name = "Omnitrumpet" - description = "The Omnitrumptet series 400 with more than 30 sound samples and fully customizable high fidelity output provides the ultimate means to toot your own horn." - path = /obj/item/device/synthesized_instrument/trumpet - allowed_roles = list("Off-Duty Crew Member", "Passenger") +/datum/gear/instruments/New() + ..() + var/list/instruments = list() + instruments["guitar"] = /obj/item/device/synthesized_instrument/guitar + instruments["polyguitar"] = /obj/item/device/synthesized_instrument/guitar/multi + instruments["violin"] = /obj/item/device/synthesized_instrument/violin + instruments["Omnitrumpet"] = /obj/item/device/synthesized_instrument/trumpet + gear_tweaks += new /datum/gear_tweak/path(instruments) diff --git a/code/modules/client/preference_setup/loadout/items/religion.dm b/code/modules/client/preference_setup/loadout/items/religion.dm index 776102a4300..0b2e6ddad13 100644 --- a/code/modules/client/preference_setup/loadout/items/religion.dm +++ b/code/modules/client/preference_setup/loadout/items/religion.dm @@ -1,14 +1,20 @@ /datum/gear/religion - display_name = "trinary perfection mask" - path = /obj/item/clothing/mask/trinary_mask - slot = slot_wear_mask + abstract_type = /datum/gear/religion sort_category = "Religion" flags = GEAR_HAS_DESC_SELECTION +/datum/gear/religion/shaman_staff + display_name = "shaman staff" + path = /obj/item/cane/shaman + slot = slot_l_hand + /datum/gear/religion/trinary - display_name = "trinary perfection brooch" - path = /obj/item/clothing/accessory/badge/trinary - slot = slot_tie + abstract_type = /datum/gear/religion/trinary + +/datum/gear/religion/trinary/mask + display_name = "trinary perfection mask" + path = /obj/item/clothing/mask/trinary_mask + slot = slot_wear_mask /datum/gear/religion/trinary/coif display_name = "trinary perfection coif" @@ -98,6 +104,9 @@ slot = slot_tie flags = GEAR_HAS_DESC_SELECTION | GEAR_HAS_COLOR_SELECTION +/datum/gear/religion/dominia + abstract_type = /datum/gear/religion/dominia + /datum/gear/religion/dominia/robe display_name = "dominian robe selection" description = "A selection of robes belonging to Dominia's Moroz Holy Tribunal." @@ -142,21 +151,6 @@ cape["tribunalist surcoat"] = /obj/item/clothing/accessory/poncho/dominia/red/surcoat gear_tweaks += new /datum/gear_tweak/path(cape) -/datum/gear/religion/assunzione/robe - display_name = "assunzione robe selection" - description = "A selection of robes worn by adherents to Luceism." - path = /obj/item/clothing/accessory/poncho/assunzione - slot = slot_wear_suit - origin_restriction = list(/singleton/origin_item/origin/assunzione, /singleton/origin_item/origin/ipc_assunzione) - -/datum/gear/religion/assunzione/robe/New() - ..() - var/list/assunzionerobe = list() - assunzionerobe["assunzione robe"] = /obj/item/clothing/accessory/poncho/assunzione - assunzionerobe["assunzione vine-inlaid robe"] = /obj/item/clothing/accessory/poncho/assunzione/vine - assunzionerobe["assunzione gold-inlaid robe"] = /obj/item/clothing/accessory/poncho/assunzione/gold - gear_tweaks += new /datum/gear_tweak/path(assunzionerobe) - /datum/gear/religion/dominia/accessory display_name = "tribunal necklace" path = /obj/item/clothing/accessory/dominia @@ -186,11 +180,6 @@ allowed_roles = list("Chief Medical Officer", "Physician", "Surgeon", "Pharmacist", "First Responder", "Medical Intern", "Medical Personnel") culture_restriction = list(/singleton/origin_item/culture/dominia, /singleton/origin_item/culture/dominian_unathi) -/datum/gear/religion/shaman_staff - display_name = "shaman staff" - path = /obj/item/cane/shaman - slot = slot_l_hand - /datum/gear/religion/dominia/robe_consular display_name = "tribunalist consular uniform" description = "The traditional red-black-gold uniform of a priestly member of His Majesty's Diplomatic Service." @@ -215,24 +204,6 @@ allowed_roles = list("Consular Officer") culture_restriction = list(/singleton/origin_item/culture/dominia, /singleton/origin_item/culture/dominian_unathi) -/datum/gear/religion/assunzione/accessory - display_name = "luceian amulet" - path = /obj/item/clothing/accessory/assunzione - slot = slot_tie - origin_restriction = list(/singleton/origin_item/origin/assunzione, /singleton/origin_item/origin/ipc_assunzione) - -/datum/gear/religion/assunzioneorb - display_name = "assunzione warding sphere" - description = "A religious artefact commonly associated with Luceism." - path = /obj/item/assunzioneorb - origin_restriction = list(/singleton/origin_item/origin/assunzione, /singleton/origin_item/origin/ipc_assunzione) - -/datum/gear/religion/assunzionesheath - display_name = "assunzione warding sphere sheath" - description = "A small metal shell designed to hold a warding sphere." - path = /obj/item/storage/assunzionesheath - origin_restriction = list(/singleton/origin_item/origin/assunzione, /singleton/origin_item/origin/ipc_assunzione) - /datum/gear/religion/dominia/codex display_name = "tribunal codex" path = /obj/item/device/versebook/tribunal @@ -254,3 +225,36 @@ dominiaicon["icon of the martyr, matteo"] = /obj/item/sign/painting_frame/martyr/matteo dominiaicon["icon of the martyr, valeria"] = /obj/item/sign/painting_frame/martyr/valeria gear_tweaks += new /datum/gear_tweak/path(dominiaicon) + +/datum/gear/religion/assunzione + abstract_type = /datum/gear/religion/assunzione + origin_restriction = list(/singleton/origin_item/origin/assunzione, /singleton/origin_item/origin/ipc_assunzione) + +/datum/gear/religion/assunzione/robe + display_name = "assunzione robe selection" + description = "A selection of robes worn by adherents to Luceism." + path = /obj/item/clothing/accessory/poncho/assunzione + slot = slot_wear_suit + +/datum/gear/religion/assunzione/robe/New() + ..() + var/list/assunzionerobe = list() + assunzionerobe["assunzione robe"] = /obj/item/clothing/accessory/poncho/assunzione + assunzionerobe["assunzione vine-inlaid robe"] = /obj/item/clothing/accessory/poncho/assunzione/vine + assunzionerobe["assunzione gold-inlaid robe"] = /obj/item/clothing/accessory/poncho/assunzione/gold + gear_tweaks += new /datum/gear_tweak/path(assunzionerobe) + +/datum/gear/religion/assunzione/accessory + display_name = "luceian amulet" + path = /obj/item/clothing/accessory/assunzione + slot = slot_tie + +/datum/gear/religion/assunzione/orb + display_name = "assunzione warding sphere" + description = "A religious artefact commonly associated with Luceism." + path = /obj/item/assunzioneorb + +/datum/gear/religion/assunzione/sheath + display_name = "assunzione warding sphere sheath" + description = "A small metal shell designed to hold a warding sphere." + path = /obj/item/storage/assunzionesheath diff --git a/code/modules/client/preference_setup/loadout/items/suit.dm b/code/modules/client/preference_setup/loadout/items/suit.dm index 36352c7ad88..46cfe6ebe95 100644 --- a/code/modules/client/preference_setup/loadout/items/suit.dm +++ b/code/modules/client/preference_setup/loadout/items/suit.dm @@ -375,6 +375,8 @@ jacket["departmental jacket, service"] = /obj/item/clothing/suit/storage/toggle/serv_dep_jacket gear_tweaks += new /datum/gear_tweak/path(jacket) +/datum/gear/suit/miscellaneous + abstract_type = /datum/gear/suit/miscellaneous /datum/gear/suit/miscellaneous/peacoat display_name = "peacoat" diff --git a/code/modules/client/preference_setup/loadout/items/utility.dm b/code/modules/client/preference_setup/loadout/items/utility.dm index b24cc03e72d..359eee1beec 100644 --- a/code/modules/client/preference_setup/loadout/items/utility.dm +++ b/code/modules/client/preference_setup/loadout/items/utility.dm @@ -42,6 +42,12 @@ folders["yellow folder"] = /obj/item/folder/yellow gear_tweaks += new /datum/gear_tweak/path(folders) +/datum/gear/utility/journal + display_name = "journal" + description = "A journal, kind of like a folder, but bigger! And personal." + path = /obj/item/journal + flags = GEAR_HAS_NAME_SELECTION | GEAR_HAS_DESC_SELECTION | GEAR_HAS_COLOR_SELECTION + /datum/gear/utility/fountainpen display_name = "fountain pen selection" description = "A selection of fountain pens." diff --git a/code/modules/client/preference_setup/loadout/items/xeno/diona.dm b/code/modules/client/preference_setup/loadout/items/xeno/diona.dm index 0939ce06ee9..c9815e532fd 100644 --- a/code/modules/client/preference_setup/loadout/items/xeno/diona.dm +++ b/code/modules/client/preference_setup/loadout/items/xeno/diona.dm @@ -8,6 +8,9 @@ flags = GEAR_NO_SELECTION culture_restriction = list(/singleton/origin_item/culture/diona_sol) +/datum/gear/suit/diona + abstract_type = /datum/gear/suit/diona + /datum/gear/suit/diona/eternal display_name = "mesh weave robes" description = "A set of mesh weave robes worn almost exclusively by priests of the Orthodox Eternal faith." @@ -122,8 +125,9 @@ whitelisted = list(SPECIES_DIONA, SPECIES_DIONA_COEUS) sort_category = "Xenowear - Diona" culture_restriction = list(/singleton/origin_item/culture/dionae_nralakk, /singleton/origin_item/culture/eum, /singleton/origin_item/culture/xrim) - -/datum/gear/accessory/skrell_passport/diona +/datum/gear/accessory/diona + abstract_type = /datum/gear/accessory/diona +/datum/gear/accessory/diona/skrell_passport display_name = "dionae nralakk federation passport" path = /obj/item/clothing/accessory/badge/passport/nralakk whitelisted = list(SPECIES_DIONA, SPECIES_DIONA_COEUS) diff --git a/code/modules/client/preference_setup/loadout/items/xeno/machine.dm b/code/modules/client/preference_setup/loadout/items/xeno/machine.dm index 55668aec408..ffa5f9cecb1 100644 --- a/code/modules/client/preference_setup/loadout/items/xeno/machine.dm +++ b/code/modules/client/preference_setup/loadout/items/xeno/machine.dm @@ -140,6 +140,9 @@ goldendeep["golden deep skirtsuit"] = /obj/item/clothing/under/goldendeep/skirtsuit gear_tweaks += new /datum/gear_tweak/path(goldendeep) +/datum/gear/augment/machine + abstract_type = /datum/gear/augment/machine + /datum/gear/augment/machine/gustatorial display_name = "gustatorial centre (tongue)" description = "An extremely complex augment, capable of translating taste into binary code, allowing synthetic beings to experience food." diff --git a/code/modules/client/preference_setup/loadout/items/xeno/skrell.dm b/code/modules/client/preference_setup/loadout/items/xeno/skrell.dm index 662dead4a4d..556287fe684 100644 --- a/code/modules/client/preference_setup/loadout/items/xeno/skrell.dm +++ b/code/modules/client/preference_setup/loadout/items/xeno/skrell.dm @@ -1,3 +1,6 @@ +/datum/gear/ears/skrell + abstract_type = /datum/gear/ears/skrell + /datum/gear/ears/skrell/chains //Chains display_name = "headtail chain selection" path = /obj/item/clothing/ears/skrell/chain @@ -295,6 +298,9 @@ var/datum/gear_tweak/social_credit/social_credit_tweak = new() outfit["iqi medical"] = /obj/item/clothing/under/skrell/nralakk/iqi/med gear_tweaks += new /datum/gear_tweak/path(outfit) +/datum/gear/suit/skrell + abstract_type = /datum/gear/suit/skrell + /datum/gear/suit/skrell/jacket display_name = "work jackets" path = /obj/item/clothing/suit/storage/toggle/skrell @@ -327,6 +333,8 @@ var/datum/gear_tweak/social_credit/social_credit_tweak = new() jacket["iqi medical"] = /obj/item/clothing/suit/storage/toggle/skrell/iqi/med gear_tweaks += new /datum/gear_tweak/path(jacket) +/datum/gear/accessory/skrell + abstract_type = /datum/gear/accessory/skrell /datum/gear/accessory/skrell/starcoat display_name = "star coat" path = /obj/item/clothing/suit/storage/toggle/skrell/starcoat diff --git a/code/modules/client/preference_setup/loadout/items/xeno/tajara.dm b/code/modules/client/preference_setup/loadout/items/xeno/tajara.dm index b1dca0efba1..921db40c2ce 100644 --- a/code/modules/client/preference_setup/loadout/items/xeno/tajara.dm +++ b/code/modules/client/preference_setup/loadout/items/xeno/tajara.dm @@ -1,3 +1,6 @@ +/datum/gear/shoes/tajara + abstract_type = /datum/gear/shoes/tajara + /datum/gear/shoes/tajara/boots display_name = "tajaran boots selection" description = "A selection of boots fitted for Tajara." diff --git a/code/modules/client/preference_setup/loadout/items/xeno/vaurca.dm b/code/modules/client/preference_setup/loadout/items/xeno/vaurca.dm index b33a664a55f..a69846d5604 100644 --- a/code/modules/client/preference_setup/loadout/items/xeno/vaurca.dm +++ b/code/modules/client/preference_setup/loadout/items/xeno/vaurca.dm @@ -230,6 +230,9 @@ gear_tweaks += new /datum/gear_tweak/path(lunchboxes) gear_tweaks += new /datum/gear_tweak/contents(lunchables_vaurca(), lunchables_vaurca_snack(), lunchables_drinks(), lunchables_utensil()) +/datum/gear/ears/vaurca + abstract_type = /datum/gear/ears/vaurca + /datum/gear/ears/vaurca/rings display_name = "bulwark horn rings" description = "Rings worn by Bulwarks to decorate their horns." diff --git a/code/modules/client/preference_setup/loadout/loadout.dm b/code/modules/client/preference_setup/loadout/loadout.dm index 22b3953350d..9e99ce1ecfc 100644 --- a/code/modules/client/preference_setup/loadout/loadout.dm +++ b/code/modules/client/preference_setup/loadout/loadout.dm @@ -15,6 +15,10 @@ var/list/gear_datums = list() for(var/geartype in subtypesof(/datum/gear)) var/datum/gear/G = geartype + //We do not want placeholders + if(G.type == G.abstract_type) + continue + var/use_name = initial(G.display_name) var/use_category = initial(G.sort_category) @@ -406,19 +410,74 @@ var/list/gear_datums = list() return ..() /datum/gear - var/display_name //Name/index. Must be unique. - var/description //Description of this gear. If left blank will default to the description of the pathed item. - var/path //Path to item. - var/cost = 1 //Number of points used. Items in general cost 1 point, storage/armor/gloves/special use costs 2 points. - var/slot //Slot to equip to. - var/list/allowed_roles //Roles that can spawn with this item. - var/whitelisted //Term to check the whitelist for.. - var/faction //Is this item whitelisted for a faction? - var/list/culture_restriction //Is this item restricted to certain cultures? The contents are paths. - var/list/origin_restriction //Is this item restricted to certain origins? The contents are paths. + /** + * Name and index, _must be unique_ + * + * Otherwise, if this is just a placeholder, set the `abstract_type` variable to the path of itself + */ + var/display_name + + /** + * Description of this gear + * + * If left blank will default to the description of the pathed item. + */ + var/description + + ///The path to item to spawn + var/path + + ///Number of points used. Items in general cost 1 point, storage/armor/gloves/special use costs 2 points. + var/cost = 1 + + /** + * Slot to equip to, one of the `slot_*` defines, see `code\__DEFINES\items_clothing.dm` + * + * If `null`, it will be sent to the storage (eg. backpack) + */ + var/slot + + /** + * A `/list` of roles that can spawn with this item + * + * If left `null`, any role can spawn with this item + */ + var/list/allowed_roles + + /** + * A `/list` of `SPECIES_*` that can spawn with this item + * + * If left `null`, any specie can spawn with this item + */ + var/list/whitelisted + + /** + * A string of the faction that can use this item + * + * If left `null`, any faction can spawn with this item + */ + var/faction + + /** + * A `/list` of [/singleton/origin_item/culture] paths that can use this item + */ + var/list/singleton/origin_item/culture/culture_restriction + + /** + * A `/list` of [/singleton/origin_item/origin] paths that can use this item + */ + var/list/singleton/origin_item/origin/origin_restriction + + ///A string of the category this item will be listed in var/sort_category = "General" - var/list/gear_tweaks = list() //List of datums which will alter the item after it has been spawned. + + ///A `/list` of [/datum/gear_tweak] to apply + var/list/datum/gear_tweak/gear_tweaks = list() + + ///Bitflag field of `GEAR_*`, see `code\modules\client\preference_setup\loadout\_defines.dm` var/flags = GEAR_HAS_NAME_SELECTION | GEAR_HAS_DESC_SELECTION + + ///Boolean, if this gear is an augment var/augment = FALSE /datum/gear/New() diff --git a/code/modules/clothing/clothing.dm b/code/modules/clothing/clothing.dm index 60895022d65..c9f9bdfb051 100644 --- a/code/modules/clothing/clothing.dm +++ b/code/modules/clothing/clothing.dm @@ -397,10 +397,10 @@ OE.attack_hand(H) qdel(src) -/obj/item/clothing/ears/offear/attackby(obj/item/I, mob/user) +/obj/item/clothing/ears/offear/attackby(obj/item/attacking_item, mob/user) var/mob/living/carbon/human/H = loc // we will never not be on a humanoid var/obj/item/clothing/ears/OE = (H.l_ear == src ? H.r_ear : H.l_ear) - OE.attackby(I, user) + OE.attackby(attacking_item, user) /////////////////////////////////////////////////////////////////////// //Gloves @@ -458,9 +458,9 @@ /obj/item/clothing/gloves/proc/Touch(var/atom/A, mob/user, var/proximity) return 0 // return 1 to cancel attack_hand() -/obj/item/clothing/gloves/attackby(obj/item/W, mob/user) +/obj/item/clothing/gloves/attackby(obj/item/attacking_item, mob/user) ..() - if(is_sharp(W)) + if(is_sharp(attacking_item)) if(clipped) to_chat(user, SPAN_NOTICE("\The [src] have already been clipped!")) update_icon() @@ -879,15 +879,15 @@ return -/obj/item/clothing/shoes/attackby(var/obj/item/I, var/mob/user) - if(can_hold_knife && is_type_in_list(I, list(/obj/item/material/shard, /obj/item/material/kitchen/utensil, /obj/item/material/knife))) +/obj/item/clothing/shoes/attackby(obj/item/attacking_item, mob/user) + if(can_hold_knife && is_type_in_list(attacking_item, list(/obj/item/material/shard, /obj/item/material/kitchen/utensil, /obj/item/material/knife))) if(holding) to_chat(user, SPAN_WARNING("\The [src] is already holding \a [holding].")) return - user.unEquip(I) - I.forceMove(src) - holding = I - user.visible_message(SPAN_NOTICE("\The [user] shoves \the [I] into \the [src].")) + user.unEquip(attacking_item) + attacking_item.forceMove(src) + holding = attacking_item + user.visible_message(SPAN_NOTICE("\The [user] shoves \the [attacking_item] into \the [src].")) playsound(get_turf(src), 'sound/weapons/holster/holster_knife.ogg', 25) verbs |= /obj/item/clothing/shoes/proc/draw_knife update_icon() @@ -1204,18 +1204,18 @@ M.update_inv_w_uniform() playsound(M, /singleton/sound_category/rustle_sound, 15, 1, -5) -/obj/item/clothing/under/examine(mob/user, distance, is_adjacent) +/obj/item/clothing/under/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(has_sensor) switch(src.sensor_mode) if(SUIT_SENSOR_OFF) - to_chat(user, "Its sensors appear to be disabled.") + . += "Its sensors appear to be disabled." if(SUIT_SENSOR_BINARY) - to_chat(user, "Its binary life sensors appear to be enabled.") + . += "Its binary life sensors appear to be enabled." if(SUIT_SENSOR_VITAL) - to_chat(user, "Its vitals tracker appears to be enabled.") + . += "Its vitals tracker appears to be enabled." if(SUIT_SENSOR_TRACKING) - to_chat(user, "Its vitals tracker and tracking beacon appear to be enabled.") + . += "Its vitals tracker and tracking beacon appear to be enabled." /obj/item/clothing/under/proc/set_sensors(mob/user as mob) var/mob/M = user diff --git a/code/modules/clothing/clothing_accessories.dm b/code/modules/clothing/clothing_accessories.dm index ad33c7f265a..fa8f07d8f1d 100644 --- a/code/modules/clothing/clothing_accessories.dm +++ b/code/modules/clothing/clothing_accessories.dm @@ -8,14 +8,14 @@ if (AC.slot == A.slot) return 0 -/obj/item/clothing/attackby(var/obj/item/I, var/mob/user) - if(istype(I, /obj/item/clothing/accessory)) +/obj/item/clothing/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/clothing/accessory)) if(!valid_accessory_slots || !valid_accessory_slots.len) to_chat(usr, "You cannot attach accessories of any kind to \the [src].") return - var/obj/item/clothing/accessory/A = I + var/obj/item/clothing/accessory/A = attacking_item if(can_attach_accessory(A)) user.drop_item() attach_accessory(user, A) @@ -26,7 +26,7 @@ if(LAZYLEN(accessories)) for(var/obj/item/clothing/accessory/A in accessories) - A.attackby(I, user) + A.attackby(attacking_item, user) return ..() @@ -91,11 +91,11 @@ return main_ear -/obj/item/clothing/examine(mob/user, distance, is_adjacent) +/obj/item/clothing/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(LAZYLEN(accessories)) for(var/obj/item/clothing/accessory/A in accessories) - to_chat(user, SPAN_NOTICE("\A [A] [A.gender == PLURAL ? "are" : "is"] attached to it.")) + . += SPAN_NOTICE("\A [A] [A.gender == PLURAL ? "are" : "is"] attached to it.") /obj/item/clothing/equipped(mob/user, slot, assisted_equip) . = ..() diff --git a/code/modules/clothing/glasses/glasses.dm b/code/modules/clothing/glasses/glasses.dm index 2cc9d75350f..0e7e34e7f7e 100644 --- a/code/modules/clothing/glasses/glasses.dm +++ b/code/modules/clothing/glasses/glasses.dm @@ -525,19 +525,19 @@ BLIND // can't see anything prescription = 7 body_parts_covered = 0 -/obj/item/clothing/glasses/regular/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W, /obj/item/clothing/glasses/hud/health)) - user.drop_item(W) - qdel(W) +/obj/item/clothing/glasses/regular/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/clothing/glasses/hud/health)) + user.drop_item(attacking_item) + qdel(attacking_item) to_chat(user, SPAN_NOTICE("You attach a set of medical HUDs to your glasses.")) playsound(src.loc, 'sound/weapons/blade_open.ogg', 50, 1) var/obj/item/clothing/glasses/hud/health/prescription/P = new /obj/item/clothing/glasses/hud/health/prescription(user.loc) P.glasses_type = src.type user.put_in_hands(P) qdel(src) - if(istype(W, /obj/item/clothing/glasses/hud/security)) - user.drop_item(W) - qdel(W) + if(istype(attacking_item, /obj/item/clothing/glasses/hud/security)) + user.drop_item(attacking_item) + qdel(attacking_item) to_chat(user, SPAN_NOTICE("You attach a set of security HUDs to your glasses.")) playsound(src.loc, 'sound/weapons/blade_open.ogg', 50, 1) var/obj/item/clothing/glasses/hud/security/prescription/P = new /obj/item/clothing/glasses/hud/security/prescription(user.loc) diff --git a/code/modules/clothing/gloves/attackby.dm b/code/modules/clothing/gloves/attackby.dm index 214616bd581..e75bb7f5ba7 100644 --- a/code/modules/clothing/gloves/attackby.dm +++ b/code/modules/clothing/gloves/attackby.dm @@ -1,6 +1,6 @@ -/obj/item/clothing/gloves/attackby(obj/item/W, mob/user) - if(W.ismultitool()) +/obj/item/clothing/gloves/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ismultitool()) var/siemens_percentage = 100 * siemens_coefficient - to_chat(user, SPAN_NOTICE("You probe \the [src] with \the [W]. The gloves will let [siemens_percentage]% of an electric shock through.")) + to_chat(user, SPAN_NOTICE("You probe \the [src] with \the [attacking_item]. The gloves will let [siemens_percentage]% of an electric shock through.")) return return ..() diff --git a/code/modules/clothing/gloves/boxing.dm b/code/modules/clothing/gloves/boxing.dm index 5511c5c2d1d..74ef5141f70 100644 --- a/code/modules/clothing/gloves/boxing.dm +++ b/code/modules/clothing/gloves/boxing.dm @@ -5,8 +5,8 @@ item_state = "boxing" species_restricted = list("exclude",BODYTYPE_VAURCA_BREEDER,BODYTYPE_VAURCA_WARFORM,BODYTYPE_VAURCA_BULWARK) -/obj/item/clothing/gloves/boxing/attackby(obj/item/W, mob/user) - if(W.iswirecutter() || istype(W, /obj/item/surgery/scalpel)) +/obj/item/clothing/gloves/boxing/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.iswirecutter() || istype(attacking_item, /obj/item/surgery/scalpel)) to_chat(user, "That won't work.") //Nope) return ..() diff --git a/code/modules/clothing/gloves/miscellaneous.dm b/code/modules/clothing/gloves/miscellaneous.dm index a259eb2e21c..d2e31561551 100644 --- a/code/modules/clothing/gloves/miscellaneous.dm +++ b/code/modules/clothing/gloves/miscellaneous.dm @@ -67,9 +67,9 @@ pickup_sound = 'sound/items/pickup/rubber.ogg' var/balloon = /obj/item/toy/balloon/latex -/obj/item/clothing/gloves/latex/attackby(var/obj/O, mob/user as mob) - if(istype(O, /obj/item/stack/cable_coil)) - var/obj/item/stack/cable_coil/C = O +/obj/item/clothing/gloves/latex/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stack/cable_coil)) + var/obj/item/stack/cable_coil/C = attacking_item if(C.use(1)) var/obj/item/L = new src.balloon user.drop_from_inventory(L,get_turf(src)) @@ -335,10 +335,10 @@ spark(user, 3, GLOB.alldirs) mounted.Fire(L, user) -/obj/item/clothing/gloves/ballistic/attackby(obj/item/W, mob/user) +/obj/item/clothing/gloves/ballistic/attackby(obj/item/attacking_item, mob/user) ..() if(mounted) - mounted.load_ammo(W, user) + mounted.load_ammo(attacking_item, user) return /obj/item/clothing/gloves/ballistic/verb/unload_shells() diff --git a/code/modules/clothing/gloves/stungloves.dm b/code/modules/clothing/gloves/stungloves.dm index c2b1018a66d..795973c7ed9 100644 --- a/code/modules/clothing/gloves/stungloves.dm +++ b/code/modules/clothing/gloves/stungloves.dm @@ -1,4 +1,4 @@ -/obj/item/clothing/gloves/attackby(obj/item/W, mob/user) +/obj/item/clothing/gloves/attackby(obj/item/attacking_item, mob/user) if(istype(src, /obj/item/clothing/gloves/boxing)) //quick fix for stunglove overlay not working nicely with boxing gloves. to_chat(user, "That won't work.") //i'm not putting my lips on that!) ..() @@ -9,8 +9,8 @@ return //add wires - if(W.iscoil()) - var/obj/item/stack/cable_coil/C = W + if(attacking_item.iscoil()) + var/obj/item/stack/cable_coil/C = attacking_item if (clipped) to_chat(user, "The [src] are too badly mangled for wiring.") return @@ -31,18 +31,18 @@ return //add cell - else if(wired && istype(W, /obj/item/cell)) + else if(wired && istype(attacking_item, /obj/item/cell)) if(cell) to_chat(user, "\A [cell] is already attached to the [src].") return - user.drop_from_inventory(W,src) - cell = W + user.drop_from_inventory(attacking_item, src) + cell = attacking_item w_class = ITEMSIZE_NORMAL to_chat(user, "You attach \the [cell] to the [src].") update_icon() return - else if((cell || wired) && (W.iswirecutter() || istype(W, /obj/item/surgery/scalpel))) + else if((cell || wired) && (attacking_item.iswirecutter() || istype(attacking_item, /obj/item/surgery/scalpel))) //stunglove stuff if(cell) diff --git a/code/modules/clothing/head/helmet.dm b/code/modules/clothing/head/helmet.dm index a452d1610e6..023d259b474 100644 --- a/code/modules/clothing/head/helmet.dm +++ b/code/modules/clothing/head/helmet.dm @@ -65,11 +65,11 @@ return TRUE return FALSE -/obj/item/clothing/head/helmet/attackby(obj/item/W, mob/user) +/obj/item/clothing/head/helmet/attackby(obj/item/attacking_item, mob/user) . = ..() - if(!has_storage || istype(W, /obj/item/clothing/accessory)) + if(!has_storage || istype(attacking_item, /obj/item/clothing/accessory)) return - hold.attackby(W, user) + hold.attackby(attacking_item, user) /obj/item/clothing/head/helmet/emp_act(severity) . = ..() @@ -98,11 +98,11 @@ else to_chat(usr, SPAN_NOTICE("Camera deactivated.")) -/obj/item/clothing/head/helmet/space/examine(mob/user, distance, is_adjacent) +/obj/item/clothing/head/helmet/space/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if((distance <= 1) && camera) - to_chat(user, FONT_SMALL(SPAN_NOTICE("To toggle the helmet camera, right click the helmet and press Toggle Helmet Camera."))) - to_chat(user, "This helmet has a built-in camera. It's [!ispath(camera) && camera.status ? "" : "in"]active.") + . += FONT_SMALL(SPAN_NOTICE("To toggle the helmet camera, right click the helmet and press Toggle Helmet Camera.")) + . += "This helmet has a built-in camera. It's [!ispath(camera) && camera.status ? "" : "in"]active." /obj/item/clothing/head/helmet/hos name = "head of security helmet" diff --git a/code/modules/clothing/head/misc_special.dm b/code/modules/clothing/head/misc_special.dm index 4097f2925a2..b679c5b6ea6 100644 --- a/code/modules/clothing/head/misc_special.dm +++ b/code/modules/clothing/head/misc_special.dm @@ -134,16 +134,16 @@ throwforce = 1 throw_speed = 0.5 -/obj/item/clothing/head/pumpkin/attackby(var/obj/O, mob/user as mob) - if(istype(O, /obj/item/flame/candle)) - var/obj/item/flame/candle/c = O +/obj/item/clothing/head/pumpkin/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/flame/candle)) + var/obj/item/flame/candle/c = attacking_item var/candle_wax = c.wax if(c.lit) - to_chat(user, SPAN_NOTICE("You should extinguish \the [O] first!")) + to_chat(user, SPAN_NOTICE("You should extinguish \the [attacking_item] first!")) return - to_chat(user, "You add \the [O] to \the [src].") + to_chat(user, "You add \the [attacking_item] to \the [src].") playsound(src.loc, 'sound/items/drop/gloves.ogg', 50, 1) - qdel(O) + qdel(attacking_item) var/obj/item/clothing/head/pumpkin/lantern/L = new /obj/item/clothing/head/pumpkin/lantern(user.loc) L.wax = candle_wax user.put_in_hands(L) @@ -165,18 +165,18 @@ M.update_inv_l_hand(0) M.update_inv_r_hand(1) -/obj/item/clothing/head/pumpkin/lantern/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/clothing/head/pumpkin/lantern/attackby(obj/item/attacking_item, mob/user) ..() - if(W.iswelder()) - var/obj/item/weldingtool/WT = W + if(attacking_item.iswelder()) + var/obj/item/weldingtool/WT = attacking_item if(WT.isOn()) //Badasses dont get blinded by lighting their candle with a welding tool light() - to_chat(user, SPAN_NOTICE("\The [user] casually lights \the [name] with [W].")) - else if(W.isFlameSource()) + to_chat(user, SPAN_NOTICE("\The [user] casually lights \the [name] with [attacking_item].")) + else if(attacking_item.isFlameSource()) light() to_chat(user, SPAN_NOTICE("\The [user] lights \the [name].")) - else if(istype(W, /obj/item/flame/candle)) - var/obj/item/flame/candle/C = W + else if(istype(attacking_item, /obj/item/flame/candle)) + var/obj/item/flame/candle/C = attacking_item if(C.lit) light() to_chat(user, SPAN_NOTICE("\The [user] lights \the [name].")) diff --git a/code/modules/clothing/sets/laser_tag.dm b/code/modules/clothing/sets/laser_tag.dm index 235ad1dbf4f..c0a2f13baa5 100644 --- a/code/modules/clothing/sets/laser_tag.dm +++ b/code/modules/clothing/sets/laser_tag.dm @@ -45,9 +45,9 @@ return return ..() -/obj/item/clothing/suit/armor/riot/laser_tag/attackby(obj/item/I, mob/user) - if(I.ismultitool()) - var/chosen_color = input(user, "Which color do you wish your vest to be?", "Color Selection") as null|anything in list("blue", "red") +/obj/item/clothing/suit/armor/riot/laser_tag/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ismultitool()) + var/chosen_color = tgui_input_list(user, "Which color do you wish your vest to be?", "Color Selection", list("blue", "red")) if(!chosen_color) return laser_tag_color = chosen_color @@ -85,9 +85,9 @@ . = ..() get_tag_color(laser_tag_color) -/obj/item/clothing/head/helmet/riot/laser_tag/attackby(obj/item/I, mob/user) - if(I.ismultitool()) - var/chosen_color = input(user, "Which color do you wish your helmet to be?", "Color Selection") as null|anything in list("blue", "red") +/obj/item/clothing/head/helmet/riot/laser_tag/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.ismultitool()) + var/chosen_color = tgui_input_list(user, "Which color do you wish your helmet to be?", "Color Selection", list("blue", "red")) if(!chosen_color) return laser_tag_color = chosen_color diff --git a/code/modules/clothing/shoes/magboots.dm b/code/modules/clothing/shoes/magboots.dm index e2a6a8f2885..ab658a48800 100644 --- a/code/modules/clothing/shoes/magboots.dm +++ b/code/modules/clothing/shoes/magboots.dm @@ -105,12 +105,12 @@ if (.) INVOKE_ASYNC(src, PROC_REF(update_wearer)) -/obj/item/clothing/shoes/magboots/examine(mob/user) +/obj/item/clothing/shoes/magboots/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() var/state = "disabled" if(item_flags & ITEM_FLAG_NO_SLIP) state = "enabled" - to_chat(user, "Its mag-pulse traction system appears to be [state].") + . += "Its mag-pulse traction system appears to be [state]." /obj/item/clothing/shoes/magboots/hegemony name = "hegemony magboots" diff --git a/code/modules/clothing/shoes/sneakers.dm b/code/modules/clothing/shoes/sneakers.dm index 9770dde5160..7292e17cede 100644 --- a/code/modules/clothing/shoes/sneakers.dm +++ b/code/modules/clothing/shoes/sneakers.dm @@ -47,10 +47,10 @@ ..() remove_cuffs(user) -/obj/item/clothing/shoes/sneakers/orange/attackby(H as obj, mob/user as mob) +/obj/item/clothing/shoes/sneakers/orange/attackby(obj/item/attacking_item, mob/user) ..() - if (istype(H, /obj/item/handcuffs)) - attach_cuffs(H, user) + if (istype(attacking_item, /obj/item/handcuffs)) + attach_cuffs(attacking_item, user) /obj/item/clothing/shoes/sneakers/yellow name = "yellow shoes" diff --git a/code/modules/clothing/spacesuits/breaches.dm b/code/modules/clothing/spacesuits/breaches.dm index 4fe229ec66e..38c09b0b45d 100644 --- a/code/modules/clothing/spacesuits/breaches.dm +++ b/code/modules/clothing/spacesuits/breaches.dm @@ -177,10 +177,10 @@ var/global/list/breach_burn_descriptors = list( //Handles repairs (and also upgrades). -/obj/item/clothing/suit/space/attackby(obj/item/W as obj, mob/user as mob) - if(istype(W,/obj/item/stack/material)) +/obj/item/clothing/suit/space/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stack/material)) var/repair_power = 0 - switch(W.get_material_name()) + switch(attacking_item.get_material_name()) if(DEFAULT_WALL_MATERIAL) repair_power = 2 if("plastic") @@ -197,13 +197,13 @@ var/global/list/breach_burn_descriptors = list( to_chat(user, "There is no surface damage on \the [src] to repair.") return - var/obj/item/stack/P = W + var/obj/item/stack/P = attacking_item var/use_amt = min(P.get_amount(), 3) if(use_amt && P.use(use_amt)) repair_breaches(DAMAGE_BURN, use_amt * repair_power, user) return - else if(W.iswelder()) + else if(attacking_item.iswelder()) if(istype(src.loc,/mob/living)) to_chat(user, "How do you intend to patch a voidsuit while someone is wearing it?") @@ -213,7 +213,7 @@ var/global/list/breach_burn_descriptors = list( to_chat(user, "There is no structural damage on \the [src] to repair.") return - var/obj/item/weldingtool/WT = W + var/obj/item/weldingtool/WT = attacking_item if(!WT.use(5)) to_chat(user, "You need more welding fuel to repair this suit.") return @@ -223,11 +223,11 @@ var/global/list/breach_burn_descriptors = list( ..() -/obj/item/clothing/suit/space/examine(mob/user) +/obj/item/clothing/suit/space/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(can_breach && breaches && breaches.len) for(var/datum/breach/B in breaches) - to_chat(user, "It has \a [B.descriptor].") + . += "It has \a [B.descriptor]." /obj/item/clothing/suit/space/get_pressure_weakness(pressure) . = ..() diff --git a/code/modules/clothing/spacesuits/rig/modules/modules.dm b/code/modules/clothing/spacesuits/rig/modules/modules.dm index 897b7b87b70..80c2f17bad6 100644 --- a/code/modules/clothing/spacesuits/rig/modules/modules.dm +++ b/code/modules/clothing/spacesuits/rig/modules/modules.dm @@ -61,33 +61,33 @@ var/list/stat_rig_module/stat_modules = new() var/category // Use for restricting modules for specific suits, to specialize -/obj/item/rig_module/examine(mob/user) +/obj/item/rig_module/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() switch(damage) if(0) - to_chat(user, SPAN_NOTICE("It is undamaged.")) + . += SPAN_NOTICE("It is undamaged.") if(1) - to_chat(user, SPAN_WARNING("It is badly damaged.")) + . += SPAN_WARNING("It is badly damaged.") if(2) - to_chat(user, SPAN_DANGER("It is almost completely destroyed.")) + . += SPAN_DANGER("It is almost completely destroyed.") -/obj/item/rig_module/attackby(obj/item/W, mob/user) - if(istype(W, /obj/item/stack/nanopaste)) +/obj/item/rig_module/attackby(obj/item/attacking_item, mob/user) + if(istype(attacking_item, /obj/item/stack/nanopaste)) if(damage == 0) to_chat(user, SPAN_WARNING("There is no damage to mend.")) return to_chat(user, SPAN_NOTICE("You start mending the damaged portions of \the [src]...")) - if(!do_after(user,30) || !W || !src) + if(!do_after(user,30) || !attacking_item || !src) return - var/obj/item/stack/nanopaste/paste = W + var/obj/item/stack/nanopaste/paste = attacking_item damage = 0 - to_chat(user, SPAN_NOTICE("You mend the damage to \the [src] with \the [W].")) + to_chat(user, SPAN_NOTICE("You mend the damage to \the [src] with \the [attacking_item].")) paste.use(1) return - else if(W.iscoil()) + else if(attacking_item.iscoil()) switch(damage) if(0) to_chat(user, SPAN_WARNING("There is no damage to mend.")) @@ -96,17 +96,17 @@ to_chat(user, SPAN_WARNING("\The [src] is too damaged to repair with cable coil, it needs nanopaste.")) return - var/obj/item/stack/cable_coil/cable = W + var/obj/item/stack/cable_coil/cable = attacking_item if(!cable.amount >= 5) to_chat(user, SPAN_WARNING("You need five units of cable to repair \the [src].")) return to_chat(user, SPAN_NOTICE("You start mending the damaged portions of \the [src]...")) - if(!do_after(user, 30) || !W || !src) + if(!do_after(user, 30) || !attacking_item || !src) return damage = 1 - to_chat(user, SPAN_NOTICE("You mend some of damage to \the [src] with \the [W], but you will need more advanced tools to fix it completely.")) + to_chat(user, SPAN_NOTICE("You mend some of damage to \the [src] with \the [attacking_item], but you will need more advanced tools to fix it completely.")) cable.use(5) return ..() diff --git a/code/modules/clothing/spacesuits/rig/rig.dm b/code/modules/clothing/spacesuits/rig/rig.dm index 5137c0daa45..028166cb990 100644 --- a/code/modules/clothing/spacesuits/rig/rig.dm +++ b/code/modules/clothing/spacesuits/rig/rig.dm @@ -102,17 +102,17 @@ var/allowed_module_types = MODULE_GENERAL // All rigs by default should have access to general var/list/species_restricted = list(BODYTYPE_HUMAN,BODYTYPE_TAJARA,BODYTYPE_UNATHI, BODYTYPE_SKRELL, BODYTYPE_IPC, BODYTYPE_IPC_BISHOP, BODYTYPE_IPC_ZENGHU) -/obj/item/rig/examine() +/obj/item/rig/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(wearer) for(var/obj/item/piece in list(helmet,gloves,chest,boots)) if(!piece || piece.loc != wearer) continue - to_chat(usr, "[icon2html(piece, usr)] \The [piece] [piece.gender == PLURAL ? "are" : "is"] deployed.") + . += "[icon2html(piece, usr)] \The [piece] [piece.gender == PLURAL ? "are" : "is"] deployed." if(src.loc == usr) - to_chat(usr, "The maintenance panel is [open ? "open" : "closed"].") - to_chat(usr, "Hardsuit systems are [offline ? "offline" : "online"].") + . += "The maintenance panel is [open ? "open" : "closed"]." + . += "Hardsuit systems are [offline ? "offline" : "online"]." /obj/item/rig/Initialize() . = ..() diff --git a/code/modules/clothing/spacesuits/rig/rig_attackby.dm b/code/modules/clothing/spacesuits/rig/rig_attackby.dm index a4f130c7cb9..e910821f6ad 100644 --- a/code/modules/clothing/spacesuits/rig/rig_attackby.dm +++ b/code/modules/clothing/spacesuits/rig/rig_attackby.dm @@ -1,4 +1,4 @@ -/obj/item/rig/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/rig/attackby(obj/item/attacking_item, mob/user) if(!istype(user,/mob/living)) return 0 @@ -7,11 +7,11 @@ return // Pass repair items on to the chestpiece. - if(chest && (istype(W,/obj/item/stack/material) || W.iswelder())) - return chest.attackby(W,user) + if(chest && (istype(attacking_item, /obj/item/stack/material) || attacking_item.iswelder())) + return chest.attackby(attacking_item,user) // Lock or unlock the access panel. - if(W.GetID()) + if(attacking_item.GetID()) if(subverted) locked = 0 to_chat(user, "It looks like the locking system has been shorted out.") @@ -30,7 +30,7 @@ to_chat(user, "You [locked ? "lock" : "unlock"] \the [src] access panel.") return - else if(W.iscrowbar()) + else if(attacking_item.iscrowbar()) if(!open && locked) to_chat(user, "The access panel is locked shut.") @@ -43,7 +43,7 @@ if(open) // Hacking. - if(W.iswirecutter() || W.ismultitool()) + if(attacking_item.iswirecutter() || attacking_item.ismultitool()) if(open) wires.interact(user) @@ -52,22 +52,22 @@ return // Air tank. - if(istype(W,/obj/item/tank)) //Todo, some kind of check for suits without integrated air supplies. + if(istype(attacking_item,/obj/item/tank)) //Todo, some kind of check for suits without integrated air supplies. if(air_supply) to_chat(user, "\The [src] already has a tank installed.") return - if(!user.unEquip(W)) return - air_supply = W - W.forceMove(src) - to_chat(user, "You slot [W] into [src] and tighten the connecting valve.") + if(!user.unEquip(attacking_item)) return + air_supply = attacking_item + attacking_item.forceMove(src) + to_chat(user, "You slot [attacking_item] into [src] and tighten the connecting valve.") return // Check if this is a hardsuit upgrade or a modification. - else if(istype(W,/obj/item/rig_module)) + else if(istype(attacking_item,/obj/item/rig_module)) - var/obj/item/rig_module/module = W + var/obj/item/rig_module/module = attacking_item if(istype(src.loc,/mob/living/carbon/human)) var/mob/living/carbon/human/H = src.loc if(H.back == src) @@ -83,15 +83,15 @@ if(installed_modules.len) for(var/obj/item/rig_module/installed_mod in installed_modules) - if(!installed_mod.redundant && istype(installed_mod,W)) + if(!installed_mod.redundant && istype(installed_mod, attacking_item)) to_chat(user, "The hardsuit already has a module of that class installed.") return 1 - var/obj/item/rig_module/mod = W + var/obj/item/rig_module/mod = attacking_item to_chat(user, "You begin installing \the [mod] into \the [src].") if(!do_after(user,40)) return - if(!user || !W) + if(!user || !attacking_item) return if(!user.unEquip(mod)) return to_chat(user, "You install \the [mod] into \the [src].") @@ -101,15 +101,15 @@ update_icon() return 1 - else if(!cell && istype(W,/obj/item/cell)) + else if(!cell && istype(attacking_item,/obj/item/cell)) - if(!user.unEquip(W)) return - to_chat(user, "You jack \the [W] into \the [src]'s battery mount.") - W.forceMove(src) - src.cell = W + if(!user.unEquip(attacking_item)) return + to_chat(user, "You jack \the [attacking_item] into \the [src]'s battery mount.") + attacking_item.forceMove(src) + src.cell = attacking_item return - else if(W.iswrench()) + else if(attacking_item.iswrench()) if(!air_supply) to_chat(user, "There is not tank to remove.") @@ -123,7 +123,7 @@ air_supply = null return - else if(W.isscrewdriver()) + else if(attacking_item.isscrewdriver()) var/list/current_mounts = list() if(cell) current_mounts += "cell" @@ -178,8 +178,8 @@ installed_modules -= removed update_icon() - else if(istype(W,/obj/item/stack/nanopaste)) //EMP repair - var/obj/item/stack/S = W + else if(istype(attacking_item,/obj/item/stack/nanopaste)) //EMP repair + var/obj/item/stack/S = attacking_item if(malfunctioning || malfunction_delay) if(S.use(1)) to_chat(user, "You pour some of \the [S] over \the [src]'s control circuitry.") @@ -193,7 +193,7 @@ // If we've gotten this far, all we have left to do before we pass off to root procs // is check if any of the loaded modules want to use the item we've been given. for(var/obj/item/rig_module/module in installed_modules) - if(module.accepts_item(W,user)) //Item is handled in this proc + if(module.accepts_item(attacking_item, user)) //Item is handled in this proc return ..() diff --git a/code/modules/clothing/spacesuits/rig/rig_construction.dm b/code/modules/clothing/spacesuits/rig/rig_construction.dm index ecf19d138fc..573f1a5d3d0 100644 --- a/code/modules/clothing/spacesuits/rig/rig_construction.dm +++ b/code/modules/clothing/spacesuits/rig/rig_construction.dm @@ -35,10 +35,10 @@ . = ..() -/obj/item/rig_assembly/examine(mob/user, distance) +/obj/item/rig_assembly/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(construct) - to_chat(user, construct.get_desc()) + . += construct.get_desc() /obj/item/rig_assembly/MouseEntered(location, control, params) . = ..() @@ -52,8 +52,8 @@ . = ..() closeToolTip(usr) -/obj/item/rig_assembly/attackby(obj/item/W as obj, mob/user as mob) - if(!construct || !construct.action(W, user)) +/obj/item/rig_assembly/attackby(obj/item/attacking_item, mob/user) + if(!construct || !construct.action(attacking_item, user)) ..() return diff --git a/code/modules/clothing/spacesuits/syndi.dm b/code/modules/clothing/spacesuits/syndi.dm index 2c42cd09992..8da055468d5 100644 --- a/code/modules/clothing/spacesuits/syndi.dm +++ b/code/modules/clothing/spacesuits/syndi.dm @@ -48,10 +48,10 @@ item_state = "softsuit_helmet" contained_sprite = TRUE -/obj/item/clothing/head/helmet/space/syndicate/covert/examine(mob/user, distance) +/obj/item/clothing/head/helmet/space/syndicate/covert/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(distance <= 1) - to_chat(user, SPAN_NOTICE("This helmet has extra armor compared to a normal softsuit helmet.")) + . += SPAN_NOTICE("This helmet has extra armor compared to a normal softsuit helmet.") /obj/item/clothing/suit/space/syndicate/covert name = "softsuit" @@ -62,10 +62,10 @@ item_state = "softsuit" contained_sprite = TRUE -/obj/item/clothing/suit/space/syndicate/covert/examine(mob/user, distance) - ..() +/obj/item/clothing/suit/space/syndicate/covert/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) + . = ..() if(distance <= 1) - to_chat(user, SPAN_NOTICE("This suit has extra armor compared to a normal softsuit.")) + . += SPAN_NOTICE("This suit has extra armor compared to a normal softsuit.") //Green syndicate space suit /obj/item/clothing/head/helmet/space/syndicate/green diff --git a/code/modules/clothing/spacesuits/void/void.dm b/code/modules/clothing/spacesuits/void/void.dm index 14bc25148be..aeac4536ec2 100644 --- a/code/modules/clothing/spacesuits/void/void.dm +++ b/code/modules/clothing/spacesuits/void/void.dm @@ -93,16 +93,16 @@ var/obj/item/tank/tank = null // Deployable tank, if any. var/obj/item/device/suit_cooling_unit/cooler = null // Deployable suit cooler, if any -/obj/item/clothing/suit/space/void/examine(mob/user, distance, is_adjacent) +/obj/item/clothing/suit/space/void/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() var/list/part_list = new for(var/obj/item/I in list(helmet,boots,tank,cooler)) part_list += "\a [I]" - to_chat(user, "\The [src] has [english_list(part_list)] installed.") + . += "\The [src] has [english_list(part_list)] installed." if(tank && distance <= 1) - to_chat(user, SPAN_NOTICE("The wrist-mounted pressure gauge reads [max(round(tank.air_contents.return_pressure()),0)] kPa remaining in \the [tank].")) + . += SPAN_NOTICE("The wrist-mounted pressure gauge reads [max(round(tank.air_contents.return_pressure()),0)] kPa remaining in \the [tank].") if (cooler && distance <= 1) - to_chat(user, SPAN_NOTICE("The mounted cooler's battery charge reads [round(cooler.cell.percent())]%")) + . += SPAN_NOTICE("The mounted cooler's battery charge reads [round(cooler.cell.percent())]%") /obj/item/clothing/suit/space/void/refit_for_species(var/target_species) ..() @@ -261,18 +261,18 @@ /obj/item/clothing/suit/space/void/attack_self() toggle_helmet() -/obj/item/clothing/suit/space/void/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/clothing/suit/space/void/attackby(obj/item/attacking_item, mob/user) if(!istype(user,/mob/living)) return - if(istype(W,/obj/item/clothing/accessory) || istype(W, /obj/item/device/hand_labeler)) + if(istype(attacking_item, /obj/item/clothing/accessory) || istype(attacking_item, /obj/item/device/hand_labeler)) return ..() if(user.get_inventory_slot(src) == slot_wear_suit) to_chat(user, SPAN_WARNING("You cannot modify \the [src] while it is being worn.")) return - if(W.isscrewdriver()) + if(attacking_item.isscrewdriver()) if(helmet || boots || tank || cooler) var/choice = tgui_input_list(usr, "What component would you like to remove?", "Component Removal", list(helmet,boots,tank,cooler)) if(!choice) return @@ -297,42 +297,42 @@ else to_chat(user, "\The [src] does not have anything installed.") return - else if(istype(W,/obj/item/clothing/head/helmet/space)) + else if(istype(attacking_item,/obj/item/clothing/head/helmet/space)) if(helmet) to_chat(user, "\The [src] already has a helmet installed.") else playsound(src, 'sound/items/Deconstruct.ogg', 30, 1) - to_chat(user, "You attach \the [W] to \the [src]'s helmet mount.") - user.drop_from_inventory(W,src) - src.helmet = W + to_chat(user, "You attach \the [attacking_item] to \the [src]'s helmet mount.") + user.drop_from_inventory(attacking_item, src) + src.helmet = attacking_item return - else if(istype(W,/obj/item/clothing/shoes/magboots)) + else if(istype(attacking_item,/obj/item/clothing/shoes/magboots)) if(boots) to_chat(user, "\The [src] already has magboots installed.") else playsound(src, 'sound/items/Deconstruct.ogg', 30, 1) - to_chat(user, "You attach \the [W] to \the [src]'s boot mounts.") - user.drop_from_inventory(W,src) - boots = W + to_chat(user, "You attach \the [attacking_item] to \the [src]'s boot mounts.") + user.drop_from_inventory(attacking_item, src) + boots = attacking_item return - else if(istype(W,/obj/item/tank)) + else if(istype(attacking_item,/obj/item/tank)) if(tank) to_chat(user, "\The [src] already has an airtank installed.") - else if(istype(W,/obj/item/tank/phoron)) - to_chat(user, "\The [W] cannot be inserted into \the [src]'s storage compartment.") + else if(istype(attacking_item,/obj/item/tank/phoron)) + to_chat(user, "\The [attacking_item] cannot be inserted into \the [src]'s storage compartment.") else playsound(src, 'sound/items/Deconstruct.ogg', 30, 1) - to_chat(user, "You insert \the [W] into \the [src]'s storage compartment.") - user.drop_from_inventory(W,src) - tank = W + to_chat(user, "You insert \the [attacking_item] into \the [src]'s storage compartment.") + user.drop_from_inventory(attacking_item, src) + tank = attacking_item return - else if (istype(W, /obj/item/device/suit_cooling_unit)) + else if (istype(attacking_item, /obj/item/device/suit_cooling_unit)) if(cooler) to_chat(user, "\The [src] already has a suit cooler installed.") else playsound(src, 'sound/items/Deconstruct.ogg', 30, 1) - to_chat(user, "You insert \the [W] into \the [src]'s storage compartment.") - user.drop_from_inventory(W,src) - cooler = W + to_chat(user, "You insert \the [attacking_item] into \the [src]'s storage compartment.") + user.drop_from_inventory(attacking_item, src) + cooler = attacking_item return ..() diff --git a/code/modules/clothing/suits/armor.dm b/code/modules/clothing/suits/armor.dm index 7bc00cbc159..c576a244471 100644 --- a/code/modules/clothing/suits/armor.dm +++ b/code/modules/clothing/suits/armor.dm @@ -45,13 +45,13 @@ else ..(over_object) -/obj/item/clothing/suit/armor/attackby(obj/item/W, mob/user) +/obj/item/clothing/suit/armor/attackby(obj/item/attacking_item, mob/user) ..() - if(istype(W, /obj/item/clothing/accessory/armor_plate)) - if(W in accessories) //We already attached this. Don't try to put it in our pockets + if(istype(attacking_item, /obj/item/clothing/accessory/armor_plate)) + if(attacking_item in accessories) //We already attached this. Don't try to put it in our pockets return if(pockets) - pockets.attackby(W, user) + pockets.attackby(attacking_item, user) /obj/item/clothing/suit/armor/emp_act(severity) . = ..() @@ -217,9 +217,9 @@ QDEL_NULL(pockets) //Tactical armor has internal holster instead of pockets, so we null this out cut_overlays() // Remove the holster's overlay. -/obj/item/clothing/suit/armor/tactical/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/clothing/suit/armor/tactical/attackby(obj/item/attacking_item, mob/user) ..() - holster.attackby(W, user) + holster.attackby(attacking_item, user) /obj/item/clothing/suit/armor/tactical/attack_hand(mob/user as mob) if (loc == user)//If we're wearing the suit and we click it with an empty hand @@ -557,6 +557,14 @@ ) contained_sprite = TRUE +/obj/item/clothing/suit/storage/vest/konyang + name = "konyang police vest" + desc = "A fairly dated armor vest in bright blue issued to the various police forces of Konyang. It comes with a prominent silver emblem on the front." + icon = 'icons/clothing/under/uniforms/konyang_uniforms.dmi' + icon_state = "police_vest" + item_state = "police_vest" + contained_sprite = TRUE + /obj/item/clothing/suit/storage/vest/kala name = "kala armor vest" desc = "A simple armor vest issued to all of the Kala. It's made of an advanced lightweight alloy." diff --git a/code/modules/clothing/suits/storage.dm b/code/modules/clothing/suits/storage.dm index bfc75fa2fb1..ef737ca1739 100644 --- a/code/modules/clothing/suits/storage.dm +++ b/code/modules/clothing/suits/storage.dm @@ -27,11 +27,11 @@ return TRUE return FALSE -/obj/item/clothing/suit/storage/attackby(obj/item/W as obj, mob/user as mob) +/obj/item/clothing/suit/storage/attackby(obj/item/attacking_item, mob/user) ..() - if(istype(W, /obj/item/clothing/accessory)) + if(istype(attacking_item, /obj/item/clothing/accessory)) return - pockets.attackby(W, user) + pockets.attackby(attacking_item, user) /obj/item/clothing/suit/storage/emp_act(severity) . = ..() diff --git a/code/modules/clothing/under/accessories/accessory.dm b/code/modules/clothing/under/accessories/accessory.dm index 67971c2e400..62e339c751d 100644 --- a/code/modules/clothing/under/accessories/accessory.dm +++ b/code/modules/clothing/under/accessories/accessory.dm @@ -117,7 +117,7 @@ return ..() //default attackby behaviour -/obj/item/clothing/accessory/attackby(obj/item/I, mob/user) +/obj/item/clothing/accessory/attackby(obj/item/attacking_item, mob/user) ..() //default attack_hand behaviour diff --git a/code/modules/clothing/under/accessories/badges.dm b/code/modules/clothing/under/accessories/badges.dm index f6389081852..9b86cdb9032 100644 --- a/code/modules/clothing/under/accessories/badges.dm +++ b/code/modules/clothing/under/accessories/badges.dm @@ -141,10 +141,10 @@ to_chat(user, "You crack the holobadge security checks.") return 1 -/obj/item/clothing/accessory/badge/holo/attackby(var/obj/item/O as obj, var/mob/user as mob) - if(O.GetID()) +/obj/item/clothing/accessory/badge/holo/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.GetID()) - var/obj/item/card/id/id_card = O.GetID() + var/obj/item/card/id/id_card = attacking_item.GetID() if(!istype(id_card)) return @@ -589,9 +589,9 @@ var/credit_score = 5 var/species_tag = "" -/obj/item/clothing/accessory/badge/passport/nralakk/examine(mob/user) +/obj/item/clothing/accessory/badge/passport/nralakk/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, SPAN_NOTICE("The passport displays the owner's social credit score as: [credit_score].")) + . += SPAN_NOTICE("The passport displays the owner's social credit score as: [credit_score].") /obj/item/clothing/accessory/badge/passport/nralakk/update_icon() icon_state = "[initial(icon_state)][open ? "_o[species_tag]" : ""]" diff --git a/code/modules/clothing/under/accessories/holster.dm b/code/modules/clothing/under/accessories/holster.dm index 79e45969e91..65308757a59 100644 --- a/code/modules/clothing/under/accessories/holster.dm +++ b/code/modules/clothing/under/accessories/holster.dm @@ -89,8 +89,8 @@ ..(user) -/obj/item/clothing/accessory/holster/attackby(obj/item/W, mob/user) - holster(W, user) +/obj/item/clothing/accessory/holster/attackby(obj/item/attacking_item, mob/user) + holster(attacking_item, user) /obj/item/clothing/accessory/holster/emp_act(severity) . = ..() @@ -98,12 +98,12 @@ if (holstered) holstered.emp_act(severity) -/obj/item/clothing/accessory/holster/examine(mob/user) +/obj/item/clothing/accessory/holster/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if (holstered) - to_chat(user, "A [holstered] is holstered here.") + . += "A [holstered] is holstered here." else - to_chat(user, "It is empty.") + . += "It is empty." /obj/item/clothing/accessory/holster/on_attached(obj/item/clothing/under/S, mob/user) ..() diff --git a/code/modules/clothing/under/accessories/lockets.dm b/code/modules/clothing/under/accessories/lockets.dm index e2af2625e3a..8b67ff02b90 100644 --- a/code/modules/clothing/under/accessories/lockets.dm +++ b/code/modules/clothing/under/accessories/lockets.dm @@ -34,17 +34,17 @@ else icon_state = "[base_icon]" -/obj/item/clothing/accessory/locket/attackby(var/obj/item/O as obj, mob/user as mob) +/obj/item/clothing/accessory/locket/attackby(obj/item/attacking_item, mob/user) if(!open) to_chat(user, "You have to open it first.") return - if(istype(O,/obj/item/paper) || istype(O, /obj/item/photo)) + if(istype(attacking_item,/obj/item/paper) || istype(attacking_item, /obj/item/photo)) if(held) to_chat(usr, "\The [src] already has something inside it.") else - to_chat(usr, "You slip [O] into [src].") - user.drop_from_inventory(O,src) - src.held = O + to_chat(usr, "You slip [attacking_item] into [src].") + user.drop_from_inventory(attacking_item, src) + src.held = attacking_item return ..() diff --git a/code/modules/clothing/under/accessories/storage.dm b/code/modules/clothing/under/accessories/storage.dm index 88cd0382017..6cea6456756 100644 --- a/code/modules/clothing/under/accessories/storage.dm +++ b/code/modules/clothing/under/accessories/storage.dm @@ -29,8 +29,8 @@ if (hold.handle_mousedrop(usr, over_object)) ..(over_object) -/obj/item/clothing/accessory/storage/attackby(obj/item/W as obj, mob/user as mob) - return hold.attackby(W, user) +/obj/item/clothing/accessory/storage/attackby(obj/item/attacking_item, mob/user) + return hold.attackby(attacking_item, user) /obj/item/clothing/accessory/storage/emp_act(severity) . = ..() diff --git a/code/modules/clothing/wrists/watches.dm b/code/modules/clothing/wrists/watches.dm index ff215b7127c..0bffcea3911 100644 --- a/code/modules/clothing/wrists/watches.dm +++ b/code/modules/clothing/wrists/watches.dm @@ -74,16 +74,17 @@ else usr.visible_message (SPAN_NOTICE("[usr] taps their foot on the floor, arrogantly pointing at the [src] on their wrist with a look of derision in their eyes, not noticing it's broken."), SPAN_NOTICE("You point down at the [src] with an arrogant look about your eyes.")) -/obj/item/clothing/wrists/watch/attackby(obj/item/W, mob/user) - if(W.isscrewdriver()) - user.visible_message(SPAN_NOTICE("[user] [screwed ? "unscrews" : "screws"] the cover of the [src] [screwed ? "open" : "closed"]."), SPAN_NOTICE("You [screwed ? "unscrews" : "screws"] the cover of the [src] [screwed ? "open" : "closed"].")) +/obj/item/clothing/wrists/watch/attackby(obj/item/attacking_item, mob/user) + if(attacking_item.isscrewdriver()) + user.visible_message(SPAN_NOTICE("[user] [screwed ? "unscrews" : "screws"] the cover of the [src] [screwed ? "open" : "closed"]."), + SPAN_NOTICE("You [screwed ? "unscrews" : "screws"] the cover of the [src] [screwed ? "open" : "closed"].")) playsound(src.loc, 'sound/items/Screwdriver.ogg', 100, 1) screwed = !screwed return if(wired) return - if(W.iscoil()) - var/obj/item/stack/cable_coil/C = W + if(attacking_item.iscoil()) + var/obj/item/stack/cable_coil/C = attacking_item if(screwed) to_chat(user, SPAN_NOTICE("The [src] is not open.")) return diff --git a/code/modules/cooking/machinery/cooking_machines/_appliance.dm b/code/modules/cooking/machinery/cooking_machines/_appliance.dm index 8aff68aa929..249a4486ce6 100644 --- a/code/modules/cooking/machinery/cooking_machines/_appliance.dm +++ b/code/modules/cooking/machinery/cooking_machines/_appliance.dm @@ -71,21 +71,20 @@ qdel(CI) return ..() -/obj/machinery/appliance/examine(mob/user, distance, is_adjacent) +/obj/machinery/appliance/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(is_adjacent) - list_contents(user) - return TRUE + . += list_contents(user) /obj/machinery/appliance/proc/list_contents(var/mob/user) + . = list() if (isemptylist(cooking_objs)) - to_chat(user, SPAN_NOTICE("It is empty.")) + . = SPAN_NOTICE("It is empty.") return - var/string = "Contains...
    " + . = "Contains...
      " for (var/datum/cooking_item/CI in cooking_objs) - string += "
    • \a [CI.container.label(null, CI.combine_target)], [report_progress(CI)]
    • " - string += "
    " - to_chat(user, string) + . += "\a [CI.container.label(null, CI.combine_target)], [report_progress(CI)]" + . += "
" /obj/machinery/appliance/proc/report_progress(var/datum/cooking_item/CI) if (!CI || !CI.max_cookwork) @@ -199,29 +198,29 @@ return FALSE return TRUE -/obj/machinery/appliance/attackby(var/obj/item/I, var/mob/user) +/obj/machinery/appliance/attackby(obj/item/attacking_item, mob/user) if(!cook_type || (stat & (BROKEN))) to_chat(user, SPAN_WARNING("[src] is not working.")) return - var/result = can_insert(I, user) + var/result = can_insert(attacking_item, user) if(result == CANNOT_INSERT) - if(default_deconstruction_screwdriver(user, I)) + if(default_deconstruction_screwdriver(user, attacking_item)) return - else if(default_part_replacement(user, I)) + else if(default_part_replacement(user, attacking_item)) return - else if(default_deconstruction_crowbar(user, I)) + else if(default_deconstruction_crowbar(user, attacking_item)) return return if(result == INSERT_GRABBED) - var/obj/item/grab/G = I + var/obj/item/grab/G = attacking_item if (G && istype(G) && G.affecting) cook_mob(G.affecting, user) return //From here we can start cooking food - add_content(I, user) + add_content(attacking_item, user) update_icon() diff --git a/code/modules/cooking/machinery/cooking_machines/_cooker.dm b/code/modules/cooking/machinery/cooking_machines/_cooker.dm index 0ef550aa706..170e2a53203 100644 --- a/code/modules/cooking/machinery/cooking_machines/_cooker.dm +++ b/code/modules/cooking/machinery/cooking_machines/_cooker.dm @@ -18,17 +18,17 @@ var/temperature = T20C var/starts_with = list() -/obj/machinery/appliance/cooker/examine(mob/user, distance, is_adjacent) +/obj/machinery/appliance/cooker/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if (is_adjacent) if (!stat) if (temperature < min_temp) - to_chat(user, SPAN_WARNING("[src] is still heating up and is too cold to cook anything yet.")) + . += SPAN_WARNING("[src] is still heating up and is too cold to cook anything yet.") else - to_chat(user, SPAN_NOTICE("It is running at [round(get_efficiency(), 0.1)]% efficiency!")) - to_chat(user, "Temperature: [round(temperature - T0C, 0.1)]C / [round(optimal_temp - T0C, 0.1)]C") + . += SPAN_NOTICE("It is running at [round(get_efficiency(), 0.1)]% efficiency!") + . += "Temperature: [round(temperature - T0C, 0.1)]C / [round(optimal_temp - T0C, 0.1)]C" else - to_chat(user, SPAN_WARNING("It is switched off.")) + . += SPAN_WARNING("It is switched off.") /obj/machinery/appliance/cooker/MouseEntered(location, control, params) . = ..() diff --git a/code/modules/cooking/machinery/cooking_machines/_mixer.dm b/code/modules/cooking/machinery/cooking_machines/_mixer.dm index 1138278542f..ced401e4354 100644 --- a/code/modules/cooking/machinery/cooking_machines/_mixer.dm +++ b/code/modules/cooking/machinery/cooking_machines/_mixer.dm @@ -17,9 +17,9 @@ fundamental differences idle_power_usage = 50 appliancetype = 0 -/obj/machinery/appliance/mixer/examine(mob/user, distance, is_adjacent) +/obj/machinery/appliance/mixer/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() - to_chat(user, SPAN_NOTICE("It is currently set to make a [selected_option]")) + . += SPAN_NOTICE("It is currently set to make a [selected_option]") /obj/machinery/appliance/mixer/Initialize() . = ..() diff --git a/code/modules/cooking/machinery/cooking_machines/container.dm b/code/modules/cooking/machinery/cooking_machines/container.dm index 845338be40b..2c216d01bdc 100644 --- a/code/modules/cooking/machinery/cooking_machines/container.dm +++ b/code/modules/cooking/machinery/cooking_machines/container.dm @@ -38,12 +38,12 @@ . = ..() update_icon() -/obj/item/reagent_containers/cooking_container/examine(var/mob/user) +/obj/item/reagent_containers/cooking_container/get_examine_text(mob/user, distance, is_adjacent, infix, suffix) . = ..() if(length(contents)) - to_chat(user, SPAN_NOTICE(get_content_info())) + . += SPAN_NOTICE(get_content_info()) if(reagents.total_volume) - to_chat(user, SPAN_NOTICE(get_reagent_info())) + . += SPAN_NOTICE(get_reagent_info()) /obj/item/reagent_containers/cooking_container/proc/get_content_info() var/string = "It contains: