Merge pull request #9498 from VOREStation/upstream-merge-7787

[MIRROR] Powered Exosuit Running Board (from /vg/station)
This commit is contained in:
Novacat
2020-12-23 09:15:53 -05:00
committed by Chompstation Bot
parent b250dff027
commit cabb515fae
5 changed files with 49 additions and 11 deletions

View File

@@ -0,0 +1,17 @@
// concept borrowed from vgstation-coders/vgstation13#26316 on GitHub
/obj/item/mecha_parts/mecha_equipment/runningboard
name = "hacked powered exosuit running board"
desc = "A running board with a power-lifter attachment, to quickly catapult exosuit pilots into the cockpit. Fits any exosuit."
icon_state = "mecha_runningboard"
origin_tech = list(TECH_MATERIAL = 6)
equip_type = EQUIP_HULL
/obj/item/mecha_parts/mecha_equipment/runningboard/limited
name = "powered exosuit running board"
desc = "A running board with a power-lifter attachment, to quickly catapult exosuit pilots into the cockpit. Only fits to working exosuits."
/obj/item/mecha_parts/mecha_equipment/runningboard/limited/can_attach(obj/mecha/M)
if(istype(M, /obj/mecha/working)) // is this a ripley?
. = ..()
else
return FALSE

View File

@@ -1804,6 +1804,14 @@
set src in oview(1)
move_inside()
//returns an equipment object if we have one of that type, useful since is_type_in_list won't return the object
//since is_type_in_list uses caching, this is a slower operation, so only use it if needed
/obj/mecha/proc/get_equipment(var/equip_type)
for(var/obj/item/mecha_parts/mecha_equipment/ME in equipment)
if(istype(ME,equip_type))
return ME
return null
/obj/mecha/proc/move_inside()
if (usr.stat || !ishuman(usr))
return
@@ -1844,18 +1852,22 @@
return
// to_chat(usr, "You start climbing into [src.name]")
visible_message("<span class='notice'>\The [usr] starts to climb into [src.name]</span>")
if(enter_after(40,usr))
if(!src.occupant)
moved_inside(usr)
if(ishuman(occupant)) //Aeiou
GrantActions(occupant, 1)
else if(src.occupant!=usr)
to_chat(usr, "[src.occupant] was faster. Try better next time, loser.")
if(get_equipment(/obj/item/mecha_parts/mecha_equipment/runningboard))
visible_message("<span class='notice'>\The [usr] is instantly lifted into [src.name] by the running board!</span>")
moved_inside(usr)
if(ishuman(occupant))
GrantActions(occupant, 1)
else
to_chat(usr, "You stop entering the exosuit.")
visible_message("<span class='notice'>\The [usr] starts to climb into [src.name]</span>")
if(enter_after(40,usr))
if(!src.occupant)
moved_inside(usr)
if(ishuman(occupant)) //Aeiou
GrantActions(occupant, 1)
else if(src.occupant!=usr)
to_chat(usr, "[src.occupant] was faster. Try better next time, loser.")
else
to_chat(usr, "You stop entering the exosuit.")
return
/obj/mecha/proc/moved_inside(var/mob/living/carbon/human/H as mob)

View File

@@ -679,6 +679,14 @@
materials = list(DEFAULT_WALL_MATERIAL = 5000, "osmium" = 3000, "silver" = 1000)
build_path = /obj/item/mecha_parts/mecha_equipment/tool/orescanner/advanced
/datum/design/item/mecha/runningboard
name = "Powered Exosuit Running Board"
desc = "A running board with a power-lifter attachment, to quickly catapult exosuit pilots into the cockpit. Only fits to working exosuits."
id = "mech_runningboard"
req_tech = list(TECH_MATERIAL = 6)
materials = list(DEFAULT_WALL_MATERIAL = 10000)
build_path = /obj/item/mecha_parts/mecha_equipment/runningboard/limited
/datum/design/item/mecha/powerwrench
name = "hydraulic wrench"
desc = "A large, hydraulic wrench."

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 41 KiB

View File

@@ -1027,6 +1027,7 @@
#include "code\game\mecha\equipment\tools\powertool.dm"
#include "code\game\mecha\equipment\tools\rcd.dm"
#include "code\game\mecha\equipment\tools\repair_droid.dm"
#include "code\game\mecha\equipment\tools\running_board.dm"
#include "code\game\mecha\equipment\tools\shield.dm"
#include "code\game\mecha\equipment\tools\shield_omni.dm"
#include "code\game\mecha\equipment\tools\sleeper.dm"