Deconflict

This commit is contained in:
variableundefined
2019-09-11 23:00:13 -04:00
122 changed files with 1161 additions and 846 deletions
@@ -79,7 +79,7 @@
holds_charge = TRUE
unique_frequency = TRUE
/obj/item/gun/energy/kinetic_accelerator/New()
/obj/item/gun/energy/kinetic_accelerator/Initialize(mapload)
. = ..()
if(!holds_charge)
empty()
@@ -98,8 +98,7 @@
if(!QDELING(src) && !holds_charge)
// Put it on a delay because moving item from slot to hand
// calls dropped().
spawn(2)
empty_if_not_held()
addtimer(CALLBACK(src, .proc/empty_if_not_held), 2)
/obj/item/gun/energy/kinetic_accelerator/proc/empty_if_not_held()
if(!ismob(loc))
@@ -143,17 +142,17 @@
overheat = FALSE
/obj/item/gun/energy/kinetic_accelerator/update_icon()
overlays.Cut()
cut_overlays()
if(empty_state && !can_shoot())
overlays += empty_state
add_overlay(empty_state)
if(gun_light && can_flashlight)
var/iconF = "flight"
if(gun_light.on)
iconF = "flight_on"
overlays += image(icon = icon, icon_state = iconF, pixel_x = flight_x_offset, pixel_y = flight_y_offset)
add_overlay(image(icon = icon, icon_state = iconF, pixel_x = flight_x_offset, pixel_y = flight_y_offset))
if(bayonet && can_bayonet)
overlays += knife_overlay
add_overlay(knife_overlay)
/obj/item/gun/energy/kinetic_accelerator/experimental
@@ -165,12 +165,18 @@
/obj/item/gun/energy/plasmacutter/attackby(obj/item/A, mob/user)
if(istype(A, /obj/item/stack/sheet/mineral/plasma))
if(power_supply.charge >= power_supply.maxcharge)
to_chat(user,"<span class='notice'>[src] is already fully charged.")
return
var/obj/item/stack/sheet/S = A
S.use(1)
power_supply.give(1000)
on_recharge()
to_chat(user, "<span class='notice'>You insert [A] in [src], recharging it.</span>")
else if(istype(A, /obj/item/stack/ore/plasma))
if(power_supply.charge >= power_supply.maxcharge)
to_chat(user,"<span class='notice'>[src] is already fully charged.")
return
var/obj/item/stack/ore/S = A
S.use(1)
power_supply.give(500)
+4 -2
View File
@@ -10,7 +10,6 @@
mouse_opacity = MOUSE_OPACITY_TRANSPARENT
hitsound = 'sound/weapons/pierce.ogg'
var/hitsound_wall = ""
pressure_resistance = INFINITY
burn_state = LAVA_PROOF
var/def_zone = "" //Aiming at
var/mob/firer = null//Who shot it
@@ -98,7 +97,7 @@
var/turf/simulated/wall/W = target_loca
if(impact_effect_type)
new impact_effect_type(target_loca, hitx, hity)
W.add_dent(WALL_DENT_SHOT, hitx, hity)
return 0
if(alwayslog)
@@ -334,3 +333,6 @@ obj/item/projectile/Crossed(atom/movable/AM, oldloc) //A mob moving on a tile wi
/obj/item/projectile/proc/setAngle(new_angle) //wrapper for overrides.
Angle = new_angle
return TRUE
/obj/item/projectile/experience_pressure_difference()
return