Merge pull request #11092 from VOREStation/Fixes/11005

Fixes #11005
This commit is contained in:
Aronai Sieyes
2021-07-15 15:03:15 -04:00
committed by Chompstation Bot
parent 9989a4f437
commit 4983148996
2 changed files with 6 additions and 8 deletions

View File

@@ -73,13 +73,14 @@
charging = null
charge_state = CHARGER_EMPTY
update_icon()
if((stat & (BROKEN|NOPOWER)) || !anchored)
update_use_power(USE_POWER_OFF)
else
update_use_power(USE_POWER_IDLE)
update_icon()
/obj/machinery/cell_charger/examine(mob/user)
. = ..()
if(get_dist(user, src) <= 5)
@@ -130,16 +131,13 @@
if(charging)
remove_item(user)
user.visible_message("[user] removes [charging] from [src].", "You remove [charging] from [src].")
update_icon()
/obj/machinery/cell_charger/attack_ai(mob/user)
if(istype(user, /mob/living/silicon/robot) && Adjacent(user)) // Borgs can remove the cell if they are near enough
if(charging)
user.visible_message("[user] removes [charging] from [src].", "You remove [charging] from [src].")
charging.loc = src.loc
charging.update_icon()
charging = null
update_icon()
remove_item(user)
user.visible_message("[user] disconnects [charging] from [src].", "You disconnect [charging] from [src].")
/obj/machinery/cell_charger/emp_act(severity)
if(stat & (BROKEN|NOPOWER))

View File

@@ -116,7 +116,7 @@
charging = null
update_icon()
/obj/machinery/cell_charger/attack_ai(mob/user)
/obj/machinery/recharger/attack_ai(mob/user)
if(istype(user, /mob/living/silicon/robot) && Adjacent(user)) // Borgs can remove the cell if they are near enough
if(charging)
user.visible_message("[user] removes [charging] from [src].", "You remove [charging] from [src].")