Removes Weapons (#7415)

* Adds icon and hitsound where needed.

* Moves alt_attack to /obj/item and deletes weapons.dm

* Replaced /obj/item/weapon with /obj/item

* Fixes merge issues.

* Fix merge issues.
This commit is contained in:
Werner
2019-11-16 18:36:13 +01:00
committed by GitHub
parent 128ca2235b
commit af16a489a6
1123 changed files with 27193 additions and 27175 deletions
@@ -85,7 +85,7 @@
return 1
/obj/machinery/atmospherics/binary/circulator/attackby(obj/item/weapon/W as obj, mob/user as mob)
/obj/machinery/atmospherics/binary/circulator/attackby(obj/item/W as obj, mob/user as mob)
if (W.iswrench())
playsound(src.loc, W.usesound, 75, 1)
anchored = !anchored
@@ -234,7 +234,7 @@
src.add_fingerprint(usr)
return
/obj/machinery/atmospherics/binary/passive_gate/attackby(var/obj/item/weapon/W as obj, var/mob/user as mob)
/obj/machinery/atmospherics/binary/passive_gate/attackby(var/obj/item/W as obj, var/mob/user as mob)
if (!W.iswrench())
return ..()
if (unlocked)
@@ -85,7 +85,7 @@
if (kin_energy > 1000000)
add_overlay("hi-turb")
attackby(obj/item/weapon/W as obj, mob/user as mob)
attackby(obj/item/W as obj, mob/user as mob)
if(W.iswrench())
anchored = !anchored
to_chat(user, "<span class='notice'>You [anchored ? "secure" : "unsecure"] the bolts holding \the [src] to the floor.</span>")
@@ -259,7 +259,7 @@
add_avail(power_generated)
attackby(obj/item/weapon/W as obj, mob/user as mob)
attackby(obj/item/W as obj, mob/user as mob)
if(W.iswrench())
anchored = !anchored
turbine = null
@@ -213,15 +213,15 @@ 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/weapon/W as obj, var/mob/user as mob)
if (!W.iswrench() && !istype(W, /obj/item/weapon/pipewrench))
/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))
return ..()
if (!(stat & NOPOWER) && use_power)
to_chat(user, "<span class='warning'>You cannot unwrench this [src], turn it off first.</span>")
return 1
var/datum/gas_mixture/int_air = return_air()
var/datum/gas_mixture/env_air = loc.return_air()
if ((int_air.return_pressure()-env_air.return_pressure()) > 2*ONE_ATMOSPHERE && !istype(W, /obj/item/weapon/pipewrench))
if ((int_air.return_pressure()-env_air.return_pressure()) > 2*ONE_ATMOSPHERE && !istype(W, /obj/item/pipewrench))
to_chat(user, "<span class='warning'>You cannot unwrench this [src], it's too exerted due to internal pressure.</span>")
add_fingerprint(user)
return 1
@@ -229,7 +229,7 @@ Thus, the two variables affect pump operation are set in New():
to_chat(user, "<span class='warning'>You struggle to unwrench \the [src] with your pipe wrench.</span>")
playsound(src.loc, W.usesound, 50, 1)
to_chat(user, "<span class='notice'>You begin to unfasten \the [src]...</span>")
if (do_after(user, istype(W, /obj/item/weapon/pipewrench) ? 80/W.toolspeed : 40/W.toolspeed, act_target = src))
if (do_after(user, istype(W, /obj/item/pipewrench) ? 80/W.toolspeed : 40/W.toolspeed, act_target = src))
user.visible_message( \
"<span class='notice'>\The [user] unfastens \the [src].</span>", \
"<span class='notice'>You have unfastened \the [src].</span>", \
@@ -82,7 +82,7 @@
if(old_stat != stat)
update_icon()
/obj/machinery/atmospherics/omni/attackby(var/obj/item/weapon/W as obj, var/mob/user as mob)
/obj/machinery/atmospherics/omni/attackby(var/obj/item/W as obj, var/mob/user as mob)
if(!W.iswrench())
return ..()
@@ -130,7 +130,7 @@
return null
/obj/machinery/atmospherics/portables_connector/attackby(var/obj/item/weapon/W as obj, var/mob/user as mob)
/obj/machinery/atmospherics/portables_connector/attackby(var/obj/item/W as obj, var/mob/user as mob)
if (!W.iswrench())
return ..()
if (connected_device)
@@ -128,7 +128,7 @@
set_frequency(frequency)
..()
/obj/machinery/atmospherics/trinary/filter/attackby(var/obj/item/weapon/W as obj, var/mob/user as mob)
/obj/machinery/atmospherics/trinary/filter/attackby(var/obj/item/W as obj, var/mob/user as mob)
if (!W.iswrench())
return ..()
var/datum/gas_mixture/int_air = return_air()
@@ -103,7 +103,7 @@
return 1
/obj/machinery/atmospherics/trinary/mixer/attackby(var/obj/item/weapon/W as obj, var/mob/user as mob)
/obj/machinery/atmospherics/trinary/mixer/attackby(var/obj/item/W as obj, var/mob/user as mob)
if (!W.iswrench())
return ..()
var/datum/gas_mixture/int_air = return_air()
+1 -1
View File
@@ -341,7 +341,7 @@
else
go_to_side()
/obj/machinery/atmospherics/tvalve/attackby(var/obj/item/weapon/W as obj, var/mob/user as mob)
/obj/machinery/atmospherics/tvalve/attackby(var/obj/item/W as obj, var/mob/user as mob)
if (!W.iswrench())
return ..()
if (istype(src, /obj/machinery/atmospherics/tvalve/digital))
@@ -21,10 +21,10 @@
var/cooling = 0
component_types = list(
/obj/item/weapon/circuitboard/unary_atmos/cooler,
/obj/item/weapon/stock_parts/matter_bin,
/obj/item/weapon/stock_parts/capacitor = 2,
/obj/item/weapon/stock_parts/manipulator,
/obj/item/circuitboard/unary_atmos/cooler,
/obj/item/stock_parts/matter_bin,
/obj/item/stock_parts/capacitor = 2,
/obj/item/stock_parts/manipulator,
/obj/item/stack/cable_coil{amount = 2}
)
@@ -153,7 +153,7 @@
var/cap_rating = 0
var/manip_rating = 0
var/bin_rating = 0
for(var/obj/item/weapon/stock_parts/P in component_parts)
for(var/obj/item/stock_parts/P in component_parts)
if(iscapacitor(P))
cap_rating += P.rating
else if(ismanipulator(P))
@@ -65,7 +65,7 @@
return 1
attackby(var/obj/item/weapon/W as obj, var/mob/user as mob)
attackby(var/obj/item/W as obj, var/mob/user as mob)
if (!W.iswrench())
return ..()
var/turf/T = src.loc
@@ -21,9 +21,9 @@
var/heating = 0 //mainly for icon updates
component_types = list(
/obj/item/weapon/circuitboard/unary_atmos/heater,
/obj/item/weapon/stock_parts/matter_bin,
/obj/item/weapon/stock_parts/capacitor = 2,
/obj/item/circuitboard/unary_atmos/heater,
/obj/item/stock_parts/matter_bin,
/obj/item/stock_parts/capacitor = 2,
/obj/item/stack/cable_coil{amount = 5}
)
@@ -141,7 +141,7 @@
..()
var/cap_rating = 0
var/bin_rating = 0
for(var/obj/item/weapon/stock_parts/P in component_parts)
for(var/obj/item/stock_parts/P in component_parts)
if(iscapacitor(P))
cap_rating += P.rating
else if(ismatterbin(P))
@@ -346,7 +346,7 @@
/obj/machinery/atmospherics/unary/vent_pump/attackby(obj/item/W, mob/user)
if(W.iswelder())
var/obj/item/weapon/weldingtool/WT = W
var/obj/item/weldingtool/WT = W
if (!WT.welding)
to_chat(user, "<span class='danger'>\The [WT] must be turned on!</span>")
else if (WT.remove_fuel(0,user))
@@ -384,7 +384,7 @@
if(old_stat != stat)
update_icon()
/obj/machinery/atmospherics/unary/vent_pump/attackby(var/obj/item/weapon/W as obj, var/mob/user as mob)
/obj/machinery/atmospherics/unary/vent_pump/attackby(var/obj/item/W as obj, var/mob/user as mob)
if (!W.iswrench())
return ..()
if (!(stat & NOPOWER) && use_power)
@@ -252,7 +252,7 @@
if(old_stat != stat)
update_icon()
/obj/machinery/atmospherics/unary/vent_scrubber/attackby(var/obj/item/weapon/W as obj, var/mob/user as mob)
/obj/machinery/atmospherics/unary/vent_scrubber/attackby(var/obj/item/W as obj, var/mob/user as mob)
if (W.iswrench())
if (!(stat & NOPOWER) && use_power)
to_chat(user, "<span class='warning'>You cannot unwrench \the [src], turn it off first.</span>")
@@ -279,7 +279,7 @@
return 1
if(W.iswelder())
var/obj/item/weapon/weldingtool/WT = W
var/obj/item/weldingtool/WT = W
if (!WT.welding)
to_chat(user, "<span class='danger'>\The [WT] must be turned on!</span>")
else if (WT.remove_fuel(0,user))
+1 -1
View File
@@ -299,7 +299,7 @@
else
open()
/obj/machinery/atmospherics/valve/attackby(var/obj/item/weapon/W as obj, var/mob/user as mob)
/obj/machinery/atmospherics/valve/attackby(var/obj/item/W as obj, var/mob/user as mob)
if (!W.iswrench())
return ..()
if (istype(src, /obj/machinery/atmospherics/valve/digital))