mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 18:32:03 +00:00
Fix #6001
Removes any code associated with obj/item/borg/sight Adds the necessary unequip to uneq_all for borgs so #6001 is fixed Removes a duplicate robot_upgrades.dm
This commit is contained in:
@@ -462,10 +462,7 @@
|
|||||||
if(isrobot(usr))
|
if(isrobot(usr))
|
||||||
var/mob/living/silicon/robot/person = usr
|
var/mob/living/silicon/robot/person = usr
|
||||||
person.sensor_mode()
|
person.sensor_mode()
|
||||||
if(person.sensor_mode == 0)
|
person.update_sight_hud()
|
||||||
icon_state = "sight"
|
|
||||||
else
|
|
||||||
icon_state = "sight+a"
|
|
||||||
|
|
||||||
if("module1")
|
if("module1")
|
||||||
if(istype(usr, /mob/living/silicon/robot))
|
if(istype(usr, /mob/living/silicon/robot))
|
||||||
|
|||||||
@@ -195,11 +195,11 @@
|
|||||||
var/dat = {"
|
var/dat = {"
|
||||||
<TITLE>Mr. V.A.L.I.D. Portable Threat Detector</TITLE><h3>Menu:</h3><h4>
|
<TITLE>Mr. V.A.L.I.D. Portable Threat Detector</TITLE><h3>Menu:</h3><h4>
|
||||||
|
|
||||||
Citizens must carry ID: <A href='?src=\ref[src];action=idmode'>Turn [idmode ? "Off" : "On"]</A>
|
<br>Citizens must carry ID: <A href='?src=\ref[src];action=idmode'>Turn [idmode ? "Off" : "On"]</A>
|
||||||
|
|
||||||
Intrusive Scan: <A href='?src=\ref[src];action=scanmode'>Turn [scanmode ? "Off" : "On"]</A>
|
<br>Intrusive Scan: <A href='?src=\ref[src];action=scanmode'>Turn [scanmode ? "Off" : "On"]</A>
|
||||||
|
|
||||||
DeMil Alerts: <A href='?src=\ref[src];action=senmode'>Turn [senset ? "Off" : "On"]</A></h4>
|
<br>DeMil Alerts: <A href='?src=\ref[src];action=senmode'>Turn [senset ? "Off" : "On"]</A></h4>
|
||||||
"}
|
"}
|
||||||
|
|
||||||
user << browse(dat, "window=detector;size=575x300")
|
user << browse(dat, "window=detector;size=575x300")
|
||||||
|
|||||||
@@ -35,51 +35,3 @@
|
|||||||
name = "overdrive"
|
name = "overdrive"
|
||||||
icon = 'icons/obj/decals.dmi'
|
icon = 'icons/obj/decals.dmi'
|
||||||
icon_state = "shock"
|
icon_state = "shock"
|
||||||
|
|
||||||
/**********************************************************************
|
|
||||||
HUD/SIGHT things
|
|
||||||
***********************************************************************/
|
|
||||||
/obj/item/borg/sight
|
|
||||||
icon = 'icons/obj/decals.dmi'
|
|
||||||
icon_state = "securearea"
|
|
||||||
var/sight_mode = null
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/sight/xray
|
|
||||||
name = "\proper x-ray Vision"
|
|
||||||
sight_mode = BORGXRAY
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/sight/thermal
|
|
||||||
name = "\proper thermal vision"
|
|
||||||
sight_mode = BORGTHERM
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/sight/meson
|
|
||||||
name = "\proper meson vision"
|
|
||||||
sight_mode = BORGMESON
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/sight/hud
|
|
||||||
name = "hud"
|
|
||||||
var/obj/item/clothing/glasses/hud/hud = null
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/sight/hud/med
|
|
||||||
name = "medical hud"
|
|
||||||
|
|
||||||
|
|
||||||
New()
|
|
||||||
..()
|
|
||||||
hud = new /obj/item/clothing/glasses/hud/health(src)
|
|
||||||
return
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/sight/hud/sec
|
|
||||||
name = "security hud"
|
|
||||||
|
|
||||||
|
|
||||||
New()
|
|
||||||
..()
|
|
||||||
hud = new /obj/item/clothing/glasses/hud/security(src)
|
|
||||||
return
|
|
||||||
|
|||||||
@@ -259,4 +259,3 @@
|
|||||||
R.module.modules += new /obj/item/weapon/storage/bag/food/borg(R.module)
|
R.module.modules += new /obj/item/weapon/storage/bag/food/borg(R.module)
|
||||||
|
|
||||||
return 1
|
return 1
|
||||||
|
|
||||||
|
|||||||
@@ -495,9 +495,9 @@
|
|||||||
var/mob/living/silicon/robot/R = M
|
var/mob/living/silicon/robot/R = M
|
||||||
switch(hudtype)
|
switch(hudtype)
|
||||||
if("security")
|
if("security")
|
||||||
return R.sensor_mode == 1 || istype(R.module_state_1, /obj/item/borg/sight/hud/sec) || istype(R.module_state_2, /obj/item/borg/sight/hud/sec) || istype(R.module_state_3, /obj/item/borg/sight/hud/sec)
|
return R.sensor_mode == 1
|
||||||
if("medical")
|
if("medical")
|
||||||
return R.sensor_mode == 2 || istype(R.module_state_1, /obj/item/borg/sight/hud/med) || istype(R.module_state_2, /obj/item/borg/sight/hud/med) || istype(R.module_state_3, /obj/item/borg/sight/hud/med)
|
return R.sensor_mode == 2
|
||||||
else
|
else
|
||||||
return 0
|
return 0
|
||||||
else if(istype(M, /mob/living/silicon/pai))
|
else if(istype(M, /mob/living/silicon/pai))
|
||||||
|
|||||||
@@ -77,10 +77,6 @@
|
|||||||
if(module_active==tool_state)
|
if(module_active==tool_state)
|
||||||
module_active=null
|
module_active=null
|
||||||
unequip_tool()
|
unequip_tool()
|
||||||
else if (W == sight_state)
|
|
||||||
if(module_active==sight_state)
|
|
||||||
module_active=null
|
|
||||||
unequip_sight()
|
|
||||||
else if (W == head_state)
|
else if (W == head_state)
|
||||||
unequip_head()
|
unequip_head()
|
||||||
|
|
||||||
@@ -144,23 +140,11 @@
|
|||||||
if((module_active in src.contents) && !(module_active in src.module.modules) && (module_active != src.module.emag) && candrop)
|
if((module_active in src.contents) && !(module_active in src.module.modules) && (module_active != src.module.emag) && candrop)
|
||||||
TS = tool_state
|
TS = tool_state
|
||||||
drop_item(TS)
|
drop_item(TS)
|
||||||
if(sight_state == module_active)
|
|
||||||
TS = sight_state
|
|
||||||
if(istype(sight_state,/obj/item/borg/sight))
|
|
||||||
sight_mode &= ~sight_state:sight_mode
|
|
||||||
if (client)
|
|
||||||
client.screen -= sight_state
|
|
||||||
contents -= sight_state
|
|
||||||
module_active = null
|
|
||||||
sight_state = null
|
|
||||||
//inv_sight.icon_state = "sight"
|
|
||||||
if(tool_state == module_active)
|
if(tool_state == module_active)
|
||||||
//var/obj/item/found = locate(tool_state) in src.module.modules
|
//var/obj/item/found = locate(tool_state) in src.module.modules
|
||||||
TS = tool_state
|
TS = tool_state
|
||||||
if(!is_in_modules(TS))
|
if(!is_in_modules(TS))
|
||||||
drop_item()
|
drop_item()
|
||||||
if(istype(tool_state,/obj/item/borg/sight))
|
|
||||||
sight_mode &= ~tool_state:sight_mode
|
|
||||||
if (client)
|
if (client)
|
||||||
client.screen -= tool_state
|
client.screen -= tool_state
|
||||||
contents -= tool_state
|
contents -= tool_state
|
||||||
@@ -178,17 +162,6 @@
|
|||||||
unequip_tool()
|
unequip_tool()
|
||||||
unequip_head()
|
unequip_head()
|
||||||
|
|
||||||
/mob/living/silicon/robot/mommi/proc/unequip_sight()
|
|
||||||
//writepanic("[__FILE__].[__LINE__] ([src.type])([usr ? usr.ckey : ""]) \\/mob/living/silicon/robot/mommi/proc/unequip_sight() called tick#: [world.time]")
|
|
||||||
if(sight_state)
|
|
||||||
if(istype(sight_state,/obj/item/borg/sight))
|
|
||||||
sight_mode &= ~sight_state:sight_mode
|
|
||||||
if (client)
|
|
||||||
client.screen -= sight_state
|
|
||||||
contents -= sight_state
|
|
||||||
sight_state = null
|
|
||||||
//inv_sight.icon_state = "sight"
|
|
||||||
|
|
||||||
// Unequips an object from the MoMMI's head
|
// Unequips an object from the MoMMI's head
|
||||||
/mob/living/silicon/robot/mommi/proc/unequip_head()
|
/mob/living/silicon/robot/mommi/proc/unequip_head()
|
||||||
//writepanic("[__FILE__].[__LINE__] ([src.type])([usr ? usr.ckey : ""]) \\/mob/living/silicon/robot/mommi/proc/unequip_head() called tick#: [world.time]")
|
//writepanic("[__FILE__].[__LINE__] ([src.type])([usr ? usr.ckey : ""]) \\/mob/living/silicon/robot/mommi/proc/unequip_head() called tick#: [world.time]")
|
||||||
@@ -200,11 +173,6 @@
|
|||||||
// Put the hat in the MoMMI's claw
|
// Put the hat in the MoMMI's claw
|
||||||
put_in_active_hand(head_state)
|
put_in_active_hand(head_state)
|
||||||
|
|
||||||
// Do that thing that unequip_sight and unequip_tool do
|
|
||||||
if(istype(head_state,/obj/item/borg/sight))
|
|
||||||
sight_mode &= ~head_state:sight_mode
|
|
||||||
contents -= head_state
|
|
||||||
|
|
||||||
// Remove the head_state icon from the client's screen
|
// Remove the head_state icon from the client's screen
|
||||||
if (client)
|
if (client)
|
||||||
client.screen -= head_state
|
client.screen -= head_state
|
||||||
@@ -221,8 +189,6 @@
|
|||||||
var/obj/item/TS=tool_state
|
var/obj/item/TS=tool_state
|
||||||
if(!is_in_modules(TS))
|
if(!is_in_modules(TS))
|
||||||
drop_item()
|
drop_item()
|
||||||
if(istype(tool_state,/obj/item/borg/sight))
|
|
||||||
sight_mode &= ~tool_state:sight_mode
|
|
||||||
if (client)
|
if (client)
|
||||||
client.screen -= tool_state
|
client.screen -= tool_state
|
||||||
contents -= tool_state
|
contents -= tool_state
|
||||||
|
|||||||
@@ -131,41 +131,11 @@
|
|||||||
/
|
/
|
||||||
/mob/living/silicon/robot/mommi/handle_regular_hud_updates()
|
/mob/living/silicon/robot/mommi/handle_regular_hud_updates()
|
||||||
handle_sensor_modes()
|
handle_sensor_modes()
|
||||||
/*src.sight &= ~SEE_MOBS
|
|
||||||
src.sight &= ~SEE_TURFS
|
|
||||||
src.sight &= ~SEE_OBJS
|
|
||||||
src.sight &= ~BLIND
|
|
||||||
src.see_in_dark = 8
|
|
||||||
src.see_invisible = SEE_INVISIBLE_LEVEL_TWO
|
|
||||||
if (src.stat == DEAD)
|
|
||||||
sight |= (SEE_TURFS|SEE_MOBS|SEE_OBJS)
|
|
||||||
src.see_in_dark = 8
|
|
||||||
src.see_invisible = SEE_INVISIBLE_LEVEL_TWO
|
|
||||||
else
|
|
||||||
if (M_XRAY in mutations || src.sight_mode & BORGXRAY)
|
|
||||||
sight |= (SEE_TURFS|SEE_MOBS|SEE_OBJS)
|
|
||||||
src.see_in_dark = 8
|
|
||||||
src.see_invisible = SEE_INVISIBLE_LEVEL_TWO
|
|
||||||
if ((src.sight_mode & BORGTHERM) || sensor_mode == THERMAL_VISION)
|
|
||||||
src.sight |= SEE_MOBS
|
|
||||||
src.see_in_dark = 8
|
|
||||||
src.see_invisible = SEE_INVISIBLE_LEVEL_TWO
|
|
||||||
if (sensor_mode == NIGHT)
|
|
||||||
see_invisible = SEE_INVISIBLE_OBSERVER_NOLIGHTING
|
|
||||||
see_in_dark = 8
|
|
||||||
if ((src.sight_mode & BORGMESON) || (sensor_mode == MESON_VISION))
|
|
||||||
src.sight |= SEE_TURFS
|
|
||||||
src.see_in_dark = 8
|
|
||||||
see_invisible = SEE_INVISIBLE_MINIMUM
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
var/obj/item/borg/sight/hud/hud = (locate(/obj/item/borg/sight/hud) in src)
|
|
||||||
if(hud && hud.hud) hud.hud.process_hud(src)
|
|
||||||
switch(sensor_mode)
|
switch(sensor_mode)
|
||||||
if (SEC_HUD)
|
if(SEC_HUD)
|
||||||
process_sec_hud(src, 1)
|
process_sec_hud(src, 1)
|
||||||
if (MED_HUD)
|
if(MED_HUD)
|
||||||
process_med_hud(src)
|
process_med_hud(src)
|
||||||
|
|
||||||
if (src.healths)
|
if (src.healths)
|
||||||
|
|||||||
@@ -439,34 +439,16 @@ They can only use one tool at a time, they can't choose modules, and they have 1
|
|||||||
var/obj/item/TS
|
var/obj/item/TS
|
||||||
if(!(locate(O) in src.module.modules) && O != src.module.emag)
|
if(!(locate(O) in src.module.modules) && O != src.module.emag)
|
||||||
return
|
return
|
||||||
if(istype(O,/obj/item/borg/sight))
|
TS = tool_state
|
||||||
TS = sight_state
|
if(tool_state)
|
||||||
if(sight_state)
|
contents -= tool_state
|
||||||
contents -= sight_state
|
if (client)
|
||||||
sight_mode &= ~sight_state:sight_mode
|
client.screen -= tool_state
|
||||||
if (client)
|
tool_state = O
|
||||||
client.screen -= sight_state
|
O.layer = 20
|
||||||
sight_state = O
|
contents += O
|
||||||
O.layer = 20
|
inv_tool.icon_state = "inv1 +a"
|
||||||
contents += O
|
module_active=tool_state
|
||||||
sight_mode |= sight_state:sight_mode
|
|
||||||
|
|
||||||
//inv_sight.icon_state = "sight+a"
|
|
||||||
inv_tool.icon_state = "inv1"
|
|
||||||
module_active=sight_state
|
|
||||||
else
|
|
||||||
TS = tool_state
|
|
||||||
if(tool_state)
|
|
||||||
contents -= tool_state
|
|
||||||
if (client)
|
|
||||||
client.screen -= tool_state
|
|
||||||
tool_state = O
|
|
||||||
O.layer = 20
|
|
||||||
contents += O
|
|
||||||
|
|
||||||
//inv_sight.icon_state = "sight"
|
|
||||||
inv_tool.icon_state = "inv1 +a"
|
|
||||||
module_active=tool_state
|
|
||||||
if(TS && istype(TS))
|
if(TS && istype(TS))
|
||||||
if(src.is_in_modules(TS))
|
if(src.is_in_modules(TS))
|
||||||
TS.loc = src.module
|
TS.loc = src.module
|
||||||
|
|||||||
@@ -9,7 +9,6 @@
|
|||||||
LANGUAGE_MONKEY = 0, LANGUAGE_UNATHI = 0, LANGUAGE_SIIK_TAJR = 0,
|
LANGUAGE_MONKEY = 0, LANGUAGE_UNATHI = 0, LANGUAGE_SIIK_TAJR = 0,
|
||||||
LANGUAGE_SKRELLIAN = 0, LANGUAGE_GUTTER = 0, LANGUAGE_MONKEY = 0)
|
LANGUAGE_SKRELLIAN = 0, LANGUAGE_GUTTER = 0, LANGUAGE_MONKEY = 0)
|
||||||
add_languages(R)
|
add_languages(R)
|
||||||
//src.modules += new /obj/item/borg/sight/meson(src)
|
|
||||||
src.emag = new /obj/item/borg/stun(src)
|
src.emag = new /obj/item/borg/stun(src)
|
||||||
//src.modules += new /obj/item/weapon/rcd/borg(src) // Too OP
|
//src.modules += new /obj/item/weapon/rcd/borg(src) // Too OP
|
||||||
//src.modules += new /obj/item/device/flashlight(src) // Broken
|
//src.modules += new /obj/item/device/flashlight(src) // Broken
|
||||||
|
|||||||
@@ -20,9 +20,6 @@
|
|||||||
if(!istype(module))
|
if(!istype(module))
|
||||||
return 0
|
return 0
|
||||||
|
|
||||||
if(istype(module, /obj/item/borg/sight))
|
|
||||||
sight_mode &= ~module:sight_mode
|
|
||||||
|
|
||||||
if(client)
|
if(client)
|
||||||
client.screen -= module
|
client.screen -= module
|
||||||
|
|
||||||
@@ -81,22 +78,16 @@
|
|||||||
O.layer = 20
|
O.layer = 20
|
||||||
O.screen_loc = inv1.screen_loc
|
O.screen_loc = inv1.screen_loc
|
||||||
O.forceMove(src)
|
O.forceMove(src)
|
||||||
if(istype(module_state_1,/obj/item/borg/sight))
|
|
||||||
sight_mode |= module_state_1:sight_mode
|
|
||||||
else if(!module_state_2)
|
else if(!module_state_2)
|
||||||
module_state_2 = O
|
module_state_2 = O
|
||||||
O.layer = 20
|
O.layer = 20
|
||||||
O.screen_loc = inv2.screen_loc
|
O.screen_loc = inv2.screen_loc
|
||||||
O.forceMove(src)
|
O.forceMove(src)
|
||||||
if(istype(module_state_2,/obj/item/borg/sight))
|
|
||||||
sight_mode |= module_state_2:sight_mode
|
|
||||||
else if(!module_state_3)
|
else if(!module_state_3)
|
||||||
module_state_3 = O
|
module_state_3 = O
|
||||||
O.layer = 20
|
O.layer = 20
|
||||||
O.screen_loc = inv3.screen_loc
|
O.screen_loc = inv3.screen_loc
|
||||||
O.forceMove(src)
|
O.forceMove(src)
|
||||||
if(istype(module_state_3,/obj/item/borg/sight))
|
|
||||||
sight_mode |= module_state_3:sight_mode
|
|
||||||
else
|
else
|
||||||
src << "<span class='notice'>You need to disable a module first!</span>"
|
src << "<span class='notice'>You need to disable a module first!</span>"
|
||||||
|
|
||||||
@@ -119,6 +110,7 @@
|
|||||||
module_state_3 = null
|
module_state_3 = null
|
||||||
inv3.icon_state = "inv3"
|
inv3.icon_state = "inv3"
|
||||||
|
|
||||||
|
unequip_sight()
|
||||||
updateicon()
|
updateicon()
|
||||||
|
|
||||||
/mob/living/silicon/robot/proc/activated(obj/item/O)
|
/mob/living/silicon/robot/proc/activated(obj/item/O)
|
||||||
|
|||||||
@@ -1359,6 +1359,17 @@
|
|||||||
sensor_mode = 0
|
sensor_mode = 0
|
||||||
src << "<span class='notice'>Sensor augmentations disabled.</span>"
|
src << "<span class='notice'>Sensor augmentations disabled.</span>"
|
||||||
handle_sensor_modes()
|
handle_sensor_modes()
|
||||||
|
update_sight_hud()
|
||||||
|
|
||||||
|
/mob/living/silicon/robot/proc/unequip_sight()
|
||||||
|
sensor_mode = 0
|
||||||
|
update_sight_hud()
|
||||||
|
|
||||||
|
/mob/living/silicon/robot/proc/update_sight_hud()
|
||||||
|
if(sensor_mode == 0)
|
||||||
|
sensor.icon_state = "sight"
|
||||||
|
else
|
||||||
|
sensor.icon_state = "sight+a"
|
||||||
|
|
||||||
/mob/living/silicon/robot/proc/radio_menu()
|
/mob/living/silicon/robot/proc/radio_menu()
|
||||||
//writepanic("[__FILE__].[__LINE__] ([src.type])([usr ? usr.ckey : ""]) \\/mob/living/silicon/robot/proc/radio_menu() called tick#: [world.time]")
|
//writepanic("[__FILE__].[__LINE__] ([src.type])([usr ? usr.ckey : ""]) \\/mob/living/silicon/robot/proc/radio_menu() called tick#: [world.time]")
|
||||||
|
|||||||
@@ -123,7 +123,6 @@
|
|||||||
|
|
||||||
/obj/item/weapon/robot_module/medical/New()
|
/obj/item/weapon/robot_module/medical/New()
|
||||||
..()
|
..()
|
||||||
//src.modules += new /obj/item/borg/sight/hud/med(src)
|
|
||||||
src.modules += new /obj/item/device/healthanalyzer(src)
|
src.modules += new /obj/item/device/healthanalyzer(src)
|
||||||
src.modules += new /obj/item/weapon/reagent_containers/borghypo(src)
|
src.modules += new /obj/item/weapon/reagent_containers/borghypo(src)
|
||||||
src.modules += new /obj/item/weapon/reagent_containers/glass/beaker/large/cyborg(src,src)
|
src.modules += new /obj/item/weapon/reagent_containers/glass/beaker/large/cyborg(src,src)
|
||||||
@@ -256,7 +255,6 @@
|
|||||||
|
|
||||||
/obj/item/weapon/robot_module/security/New()
|
/obj/item/weapon/robot_module/security/New()
|
||||||
..()
|
..()
|
||||||
//src.modules += new /obj/item/borg/sight/hud/sec(src)
|
|
||||||
src.modules += new /obj/item/weapon/melee/baton/loaded(src)
|
src.modules += new /obj/item/weapon/melee/baton/loaded(src)
|
||||||
src.modules += new /obj/item/weapon/gun/energy/taser/cyborg(src)
|
src.modules += new /obj/item/weapon/gun/energy/taser/cyborg(src)
|
||||||
src.modules += new /obj/item/weapon/handcuffs/cyborg(src)
|
src.modules += new /obj/item/weapon/handcuffs/cyborg(src)
|
||||||
@@ -365,7 +363,6 @@
|
|||||||
|
|
||||||
/obj/item/weapon/robot_module/miner/New()
|
/obj/item/weapon/robot_module/miner/New()
|
||||||
..()
|
..()
|
||||||
//src.modules += new /obj/item/borg/sight/meson(src)
|
|
||||||
src.emag = new /obj/item/borg/stun(src)
|
src.emag = new /obj/item/borg/stun(src)
|
||||||
src.modules += new /obj/item/weapon/storage/bag/ore(src)
|
src.modules += new /obj/item/weapon/storage/bag/ore(src)
|
||||||
src.modules += new /obj/item/weapon/pickaxe/drill/borg(src)
|
src.modules += new /obj/item/weapon/pickaxe/drill/borg(src)
|
||||||
|
|||||||
@@ -1,146 +0,0 @@
|
|||||||
// robot_upgrades.dm
|
|
||||||
// Contains various borg upgrades.
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/
|
|
||||||
name = "A borg upgrade module."
|
|
||||||
desc = "Protected by FRM."
|
|
||||||
icon = 'icons/obj/module.dmi'
|
|
||||||
icon_state = "cyborg_upgrade"
|
|
||||||
var/construction_time = 120
|
|
||||||
var/construction_cost = list("metal"=10000)
|
|
||||||
var/locked = 0
|
|
||||||
var/require_module = 0
|
|
||||||
var/installed = 0
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/proc/action()
|
|
||||||
//writepanic("[__FILE__].[__LINE__] ([src.type])([usr ? usr.ckey : ""]) \\/obj/item/borg/upgrade/proc/action() called tick#: [world.time]")
|
|
||||||
return
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/reset/
|
|
||||||
name = "Borg module reset board"
|
|
||||||
desc = "Used to reset a borg's module. Destroys any other upgrades applied to the borg."
|
|
||||||
icon_state = "cyborg_upgrade1"
|
|
||||||
require_module = 1
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/reset/action(var/mob/living/silicon/robot/R)
|
|
||||||
R.uneq_all()
|
|
||||||
del(R.module)
|
|
||||||
R.module = null
|
|
||||||
R.modtype = "robot"
|
|
||||||
R.real_name = "Cyborg [R.ident]"
|
|
||||||
R.name = R.real_name
|
|
||||||
R.nopush = 0
|
|
||||||
R.hands.icon_state = "nomod"
|
|
||||||
R.base_icon = "robot"
|
|
||||||
R.icon_state = "robot"
|
|
||||||
R.updateicon()
|
|
||||||
|
|
||||||
return 1
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/flashproof/
|
|
||||||
name = "Borg Flash-Supression"
|
|
||||||
desc = "A highly advanced, complicated system for supressing incoming flashes directed at the borg's optical processing system."
|
|
||||||
construction_cost = list("metal"=10000,"gold"=2000,"silver"=3000,"glass"=2000, "diamond"=5000)
|
|
||||||
icon_state = "cyborg_upgrade4"
|
|
||||||
require_module = 1
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/flashproof/New() // Why the fuck does the fabricator make a new instance of all the items?
|
|
||||||
//desc = "Sunglasses with duct tape." // Why? D:
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/flashproof/action(var/mob/living/silicon/robot/R)
|
|
||||||
if(R.module)
|
|
||||||
R.module += src
|
|
||||||
|
|
||||||
return 1
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/restart/
|
|
||||||
name = "Borg emergancy restart module"
|
|
||||||
desc = "Used to force a restart of a disabled-but-repaired borg, bringing it back online."
|
|
||||||
construction_cost = list("metal"=60000 , "glass"=5000)
|
|
||||||
icon_state = "cyborg_upgrade1"
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/restart/action(var/mob/living/silicon/robot/R)
|
|
||||||
if(!R.key)
|
|
||||||
for(var/mob/dead/observer/ghost mob_list)
|
|
||||||
if(ghost.corpse == R && ghost.client)
|
|
||||||
ghost.client.mob = ghost.corpse
|
|
||||||
|
|
||||||
if(R.health < 0)
|
|
||||||
usr << "You have to repair the borg before using this module!"
|
|
||||||
return 0
|
|
||||||
|
|
||||||
R.stat = 0
|
|
||||||
return 1
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/vtec/
|
|
||||||
name = "Borg VTEC Module"
|
|
||||||
desc = "Used to kick in a borgs VTEC systems, increasing their speed."
|
|
||||||
construction_cost = list("metal"=80000 , "glass"=6000 , "gold"= 5000)
|
|
||||||
icon_state = "cyborg_upgrade2"
|
|
||||||
require_module = 1
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/vtec/action(var/mob/living/silicon/robot/R)
|
|
||||||
if(R.speed == -1)
|
|
||||||
return 0
|
|
||||||
|
|
||||||
R.speed--
|
|
||||||
return 1
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/tasercooler/
|
|
||||||
name = "Borg Rapid Taser Cooling Module"
|
|
||||||
desc = "Used to cool a mounted taser, increasing the potential current in it and thus its recharge rate.."
|
|
||||||
construction_cost = list("metal"=80000 , "glass"=6000 , "gold"= 2000, "diamond" = 500)
|
|
||||||
icon_state = "cyborg_upgrade3"
|
|
||||||
require_module = 1
|
|
||||||
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/tasercooler/action(var/mob/living/silicon/robot/R)
|
|
||||||
if(!istype(R.module, /obj/item/weapon/robot_module/security))
|
|
||||||
R << "Upgrade mounting error! No suitable hardpoint detected!"
|
|
||||||
usr << "There's no mounting point for the module!"
|
|
||||||
return 0
|
|
||||||
|
|
||||||
var/obj/item/weapon/gun/energy/taser/cyborg/T = locate() in R.module
|
|
||||||
if(!T)
|
|
||||||
T = locate() in R.module.contents
|
|
||||||
if(!T)
|
|
||||||
T = locate() in R.module.modules
|
|
||||||
if(!T)
|
|
||||||
usr << "This cyborg has had its taser removed!"
|
|
||||||
return 0
|
|
||||||
|
|
||||||
if(T.recharge_time <= 2)
|
|
||||||
R << "Maximum cooling achieved for this hardpoint!"
|
|
||||||
usr << "There's no room for another cooling unit!"
|
|
||||||
return 0
|
|
||||||
|
|
||||||
else
|
|
||||||
T.recharge_time = max(2 , T.recharge_time - 4)
|
|
||||||
|
|
||||||
return 1
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/jetpack/
|
|
||||||
name = "Mining Borg Jetpack"
|
|
||||||
desc = "A carbon dioxide jetpack suitable for low-gravity mining operations"
|
|
||||||
construction_cost = list("metal"=10000,"plasma"=15000,"uranium" = 20000)
|
|
||||||
icon_state = "cyborg_upgrade3"
|
|
||||||
require_module = 1
|
|
||||||
|
|
||||||
/obj/item/borg/upgrade/jetpack/action(var/mob/living/silicon/robot/R)
|
|
||||||
if(!istype(R.module, /obj/item/weapon/robot_module/miner))
|
|
||||||
R << "Upgrade mounting error! No suitable hardpoint detected!"
|
|
||||||
usr << "There's no mounting point for the module!"
|
|
||||||
return 0
|
|
||||||
else
|
|
||||||
R.module.modules += new/obj/item/weapon/tank/jetpack/carbondioxide(R.module)
|
|
||||||
for(var/obj/item/weapon/tank/jetpack/carbondioxide in R.module.modules)
|
|
||||||
R.internals = src
|
|
||||||
R.icon_state="Miner+j"
|
|
||||||
return 1
|
|
||||||
Reference in New Issue
Block a user