mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-07-20 19:44:09 +01:00
Merge pull request #8752 from Citinited/pipes-exploit-fix
Restricts RPD use to certain turf types
This commit is contained in:
@@ -66,6 +66,7 @@
|
||||
|
||||
//turf-only flags
|
||||
#define NOJAUNT 1
|
||||
#define RPD_ALLOWED_HERE 2//By default, RPD is disabled on turfs.
|
||||
|
||||
//ITEM INVENTORY SLOT BITMASKS
|
||||
#define SLOT_OCLOTHING 1
|
||||
|
||||
@@ -180,9 +180,12 @@ var/list/pipemenu = list(
|
||||
/obj/item/weapon/rpd/afterattack(atom/target, mob/user, proximity)
|
||||
..()
|
||||
var/turf/T = get_turf(target)
|
||||
if(src.loc != user || ismob(target) || istype(target, /obj/structure/window) || !proximity || world.time < lastused + spawndelay)
|
||||
if(loc != user || ismob(target) || istype(target, /obj/structure/window) || !proximity || world.time < lastused + spawndelay)
|
||||
return
|
||||
if(mode == ATMOS_MODE && !istype(T, /turf/simulated/shuttle)) //No pipes on shuttles nerds
|
||||
if(!(T.flags & RPD_ALLOWED_HERE))
|
||||
to_chat(user, "<span class='notice'>[src] beeps, \"Unable to interface with [T]. Please try again later.\"</span>")
|
||||
return
|
||||
if(mode == ATMOS_MODE)
|
||||
if(istype(T, /turf/simulated/wall)) //Drilling into walls takes time
|
||||
playsound(loc, "sound/weapons/circsawhit.ogg", 50, 1)
|
||||
user.visible_message("<span class = 'notice'>[user] starts drilling a hole in [T]...</span>", "<span class = 'notice'>You start drilling a hole in [T]...</span>", "<span class = 'warning'>You hear a drill.</span>")
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
var/image/wet_overlay = null
|
||||
|
||||
var/thermite = 0
|
||||
flags = RPD_ALLOWED_HERE
|
||||
oxygen = MOLES_O2STANDARD
|
||||
nitrogen = MOLES_N2STANDARD
|
||||
var/to_be_destroyed = 0 //Used for fire, if a melting temperature was reached, it will be destroyed
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
/turf/simulated/shuttle
|
||||
name = "shuttle"
|
||||
icon = 'icons/turf/shuttle.dmi'
|
||||
flags = null
|
||||
thermal_conductivity = 0.05
|
||||
heat_capacity = 0
|
||||
layer = 2
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
name = "\proper space"
|
||||
icon_state = "0"
|
||||
dynamic_lighting = 0
|
||||
flags = RPD_ALLOWED_HERE
|
||||
luminosity = 1
|
||||
|
||||
temperature = TCMB
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
/turf/space/transit
|
||||
flags = null
|
||||
var/pushdirection // push things that get caught in the transit tile this direction
|
||||
|
||||
//Overwrite because we dont want people building rods in space.
|
||||
|
||||
Reference in New Issue
Block a user