@@ -313,7 +313,7 @@
|
||||
if(M.get_ear_protection() == FALSE)
|
||||
M.confused += 6
|
||||
audible_message("<font color='red' size='7'>HUMAN HARM</font>")
|
||||
playsound(get_turf(src), 'sound/ai/harmalarm.ogg', 70, 3)
|
||||
playsound(get_turf(src), 'sound/effects/harmalarm.ogg', 70, 3)
|
||||
cooldown = world.time + 200
|
||||
log_game("[key_name(user)] used a Cyborg Harm Alarm in [AREACOORD(user)]")
|
||||
if(iscyborg(user))
|
||||
@@ -430,7 +430,7 @@
|
||||
A.BB.nodamage = FALSE
|
||||
A.BB.speed = 0.5
|
||||
playsound(src.loc, 'sound/machines/click.ogg', 50, 1)
|
||||
A.fire_casing(target, user, params, 0, 0, null, 0)
|
||||
A.fire_casing(target, user, params, 0, 0, null, 0, src)
|
||||
user.visible_message("<span class='warning'>[user] blasts a flying lollipop at [target]!</span>")
|
||||
check_amount()
|
||||
|
||||
@@ -446,7 +446,7 @@
|
||||
A.BB.speed = 0.5
|
||||
A.BB.color = rgb(rand(0, 255), rand(0, 255), rand(0, 255))
|
||||
playsound(src.loc, 'sound/weapons/bulletflyby3.ogg', 50, 1)
|
||||
A.fire_casing(target, user, params, 0, 0, null, 0)
|
||||
A.fire_casing(target, user, params, 0, 0, null, 0, src)
|
||||
user.visible_message("<span class='warning'>[user] shoots a high-velocity gumball at [target]!</span>")
|
||||
check_amount()
|
||||
|
||||
@@ -746,3 +746,73 @@
|
||||
..()
|
||||
hud = new /obj/item/clothing/glasses/hud/security(src)
|
||||
return
|
||||
|
||||
|
||||
/**********************************************************************
|
||||
Grippers oh god oh fuck
|
||||
***********************************************************************/
|
||||
|
||||
/obj/item/weapon/gripper
|
||||
name = "circuit gripper"
|
||||
desc = "A simple grasping tool for inserting circuitboards into machinary."
|
||||
icon = 'icons/obj/device.dmi'
|
||||
icon_state = "gripper"
|
||||
|
||||
item_flags = NOBLUDGEON
|
||||
|
||||
//Has a list of items that it can hold.
|
||||
var/list/can_hold = list(
|
||||
/obj/item/circuitboard
|
||||
)
|
||||
|
||||
var/obj/item/wrapped = null // Item currently being held.
|
||||
|
||||
/obj/item/weapon/gripper/attack_self()
|
||||
if(wrapped)
|
||||
wrapped.forceMove(get_turf(wrapped))
|
||||
wrapped = null
|
||||
return ..()
|
||||
|
||||
/obj/item/weapon/gripper/afterattack(var/atom/target, var/mob/living/user, proximity, params)
|
||||
|
||||
if(!proximity)
|
||||
return
|
||||
|
||||
if(!wrapped)
|
||||
for(var/obj/item/thing in src.contents)
|
||||
wrapped = thing
|
||||
break
|
||||
|
||||
if(wrapped) //Already have an item.
|
||||
//Temporary put wrapped into user so target's attackby() checks pass.
|
||||
wrapped.loc = user
|
||||
|
||||
//Pass the attack on to the target. This might delete/relocate wrapped.
|
||||
var/resolved = target.attackby(wrapped,user)
|
||||
if(!resolved && wrapped && target)
|
||||
wrapped.afterattack(target,user,1)
|
||||
//If wrapped was neither deleted nor put into target, put it back into the gripper.
|
||||
if(wrapped && user && (wrapped.loc == user))
|
||||
wrapped.loc = src
|
||||
else
|
||||
wrapped = null
|
||||
return
|
||||
|
||||
else if(istype(target,/obj/item))
|
||||
|
||||
var/obj/item/I = target
|
||||
|
||||
var/grab = 0
|
||||
for(var/typepath in can_hold)
|
||||
if(istype(I,typepath))
|
||||
grab = 1
|
||||
break
|
||||
|
||||
//We can grab the item, finally.
|
||||
if(grab)
|
||||
to_chat(user, "You collect \the [I].")
|
||||
I.loc = src
|
||||
wrapped = I
|
||||
return
|
||||
else
|
||||
to_chat(user, "<span class='danger'>Your gripper cannot hold \the [target].</span>")
|
||||
|
||||
@@ -89,32 +89,36 @@
|
||||
R.speed = initial(R.speed)
|
||||
|
||||
/obj/item/borg/upgrade/disablercooler
|
||||
name = "cyborg rapid disabler cooling module"
|
||||
desc = "Used to cool a mounted disabler, increasing the potential current in it and thus its recharge rate."
|
||||
name = "cyborg rapid energy blaster cooling module"
|
||||
desc = "Used to cool a mounted energy-based firearm, increasing the potential current in it and thus its recharge rate."
|
||||
icon_state = "cyborg_upgrade3"
|
||||
require_module = 1
|
||||
|
||||
/obj/item/borg/upgrade/disablercooler/action(mob/living/silicon/robot/R, user = usr)
|
||||
. = ..()
|
||||
if(.)
|
||||
var/obj/item/gun/energy/disabler/cyborg/T = locate() in R.module.modules
|
||||
if(!T)
|
||||
to_chat(user, "<span class='notice'>There's no disabler in this unit!</span>")
|
||||
var/successflag
|
||||
for(var/obj/item/gun/energy/T in R.module.modules)
|
||||
if(T.charge_delay <= 2)
|
||||
successflag = successflag || 2
|
||||
continue
|
||||
T.charge_delay = max(2, T.charge_delay - 4)
|
||||
successflag = 1
|
||||
if(!successflag)
|
||||
to_chat(user, "<span class='notice'>There's no energy-based firearm in this unit!</span>")
|
||||
return FALSE
|
||||
if(T.charge_delay <= 2)
|
||||
if(successflag == 2)
|
||||
to_chat(R, "<span class='notice'>A cooling unit is already installed!</span>")
|
||||
to_chat(user, "<span class='notice'>There's no room for another cooling unit!</span>")
|
||||
return FALSE
|
||||
|
||||
T.charge_delay = max(2 , T.charge_delay - 4)
|
||||
|
||||
/obj/item/borg/upgrade/disablercooler/deactivate(mob/living/silicon/robot/R, user = usr)
|
||||
. = ..()
|
||||
if (.)
|
||||
var/obj/item/gun/energy/disabler/cyborg/T = locate() in R.module.modules
|
||||
if(!T)
|
||||
return FALSE
|
||||
T.charge_delay = initial(T.charge_delay)
|
||||
for(var/obj/item/gun/energy/T in R.module.modules)
|
||||
T.charge_delay = initial(T.charge_delay)
|
||||
return .
|
||||
return FALSE
|
||||
|
||||
/obj/item/borg/upgrade/thrusters
|
||||
name = "ion thruster upgrade"
|
||||
@@ -199,7 +203,7 @@
|
||||
desc = "A trash bag of holding replacement for the janiborg's standard trash bag."
|
||||
icon_state = "cyborg_upgrade3"
|
||||
require_module = 1
|
||||
module_type = list(/obj/item/robot_module/janitor, /obj/item/robot_module/scrubpup)
|
||||
module_type = list(/obj/item/robot_module/butler)
|
||||
|
||||
/obj/item/borg/upgrade/tboh/action(mob/living/silicon/robot/R)
|
||||
. = ..()
|
||||
@@ -226,7 +230,7 @@
|
||||
desc = "An advanced mop replacement for the janiborg's standard mop."
|
||||
icon_state = "cyborg_upgrade3"
|
||||
require_module = 1
|
||||
module_type = list(/obj/item/robot_module/janitor, /obj/item/robot_module/scrubpup)
|
||||
module_type = list(/obj/item/robot_module/butler)
|
||||
|
||||
/obj/item/borg/upgrade/amop/action(mob/living/silicon/robot/R)
|
||||
. = ..()
|
||||
@@ -518,8 +522,7 @@
|
||||
module_type = list(
|
||||
/obj/item/robot_module/medical,
|
||||
/obj/item/robot_module/syndicate_medical,
|
||||
/obj/item/robot_module/medihound,
|
||||
/obj/item/robot_module/borgi)
|
||||
/obj/item/robot_module/medihound)
|
||||
|
||||
/obj/item/borg/upgrade/advhealth/action(mob/living/silicon/robot/R, user = usr)
|
||||
. = ..()
|
||||
@@ -598,25 +601,32 @@
|
||||
R.update_transform()
|
||||
|
||||
/obj/item/borg/upgrade/rped
|
||||
name = "engineering cyborg RPED"
|
||||
name = "engineering cyborg BSRPED"
|
||||
desc = "A rapid part exchange device for the engineering cyborg."
|
||||
icon = 'icons/obj/storage.dmi'
|
||||
icon_state = "borgrped"
|
||||
icon_state = "borg_BS_RPED"
|
||||
require_module = TRUE
|
||||
module_type = list(/obj/item/robot_module/engineering)
|
||||
module_type = list(/obj/item/robot_module/engineering, /obj/item/robot_module/saboteur)
|
||||
|
||||
/obj/item/borg/upgrade/rped/action(mob/living/silicon/robot/R, user = usr)
|
||||
. = ..()
|
||||
if(.)
|
||||
|
||||
var/obj/item/storage/part_replacer/bluespace/cyborg/BSRPED = locate() in R
|
||||
var/obj/item/storage/part_replacer/cyborg/RPED = locate() in R
|
||||
if(RPED)
|
||||
to_chat(user, "<span class='warning'>This unit is already equipped with a RPED module.</span>")
|
||||
if(!RPED)
|
||||
RPED = locate() in R.module
|
||||
if(!BSRPED)
|
||||
BSRPED = locate() in R.module //There's gotta be a smarter way to do this.
|
||||
if(BSRPED)
|
||||
to_chat(user, "<span class='warning'>This unit is already equipped with a BSRPED module.</span>")
|
||||
return FALSE
|
||||
|
||||
RPED = new(R.module)
|
||||
R.module.basic_modules += RPED
|
||||
R.module.add_module(RPED, FALSE, TRUE)
|
||||
BSRPED = new(R.module)
|
||||
SEND_SIGNAL(RPED, COMSIG_TRY_STORAGE_QUICK_EMPTY)
|
||||
qdel(RPED)
|
||||
R.module.basic_modules += BSRPED
|
||||
R.module.add_module(BSRPED, FALSE, TRUE)
|
||||
|
||||
/obj/item/borg/upgrade/rped/deactivate(mob/living/silicon/robot/R, user = usr)
|
||||
. = ..()
|
||||
@@ -680,7 +690,7 @@
|
||||
action_icon_state = "Chevron_State_0"
|
||||
|
||||
var/currentState = 0
|
||||
var/maxReduction = 2
|
||||
var/maxReduction = 1
|
||||
|
||||
|
||||
/obj/effect/proc_holder/silicon/cyborg/vtecControl/Click(mob/living/silicon/robot/user)
|
||||
@@ -688,14 +698,14 @@
|
||||
|
||||
currentState = (currentState + 1) % 3
|
||||
|
||||
if(usr)
|
||||
if(istype(self))
|
||||
switch(currentState)
|
||||
if (0)
|
||||
self.speed = maxReduction
|
||||
self.speed = initial(self.speed)
|
||||
if (1)
|
||||
self.speed -= maxReduction*0.5
|
||||
self.speed = initial(self.speed) - maxReduction * 0.5
|
||||
if (2)
|
||||
self.speed -= maxReduction*1.25
|
||||
self.speed = initial(self.speed) - maxReduction * 1
|
||||
|
||||
action.button_icon_state = "Chevron_State_[currentState]"
|
||||
action.UpdateButtonIcon()
|
||||
|
||||
Reference in New Issue
Block a user