Porting the BEPIS research machinery. (#12277)

* Initial B.E.P.I.S port.

* All nodes but sticky tape are in. Sweet.

* Mapping the BEPIS :DDD

* ah

* deers.
This commit is contained in:
Ghom
2020-05-24 22:05:15 +02:00
committed by GitHub
parent e9068f05eb
commit ab5d65a454
82 changed files with 1620 additions and 163 deletions
+17 -10
View File
@@ -6,6 +6,7 @@
density = TRUE
var/state = GIRDER_NORMAL
var/girderpasschance = 20 // percentage chance that a projectile passes through the girder.
var/next_beep = 0 //Prevents spamming of the construction sound
var/can_displace = TRUE //If the girder can be moved around by wrenching it
max_integrity = 200
rad_flags = RAD_PROTECT_CONTENTS | RAD_NO_CONTAMINATE
@@ -27,11 +28,17 @@
. += "<span class='notice'>[src] is disassembled! You probably shouldn't be able to see this examine message.</span>"
/obj/structure/girder/attackby(obj/item/W, mob/user, params)
var/platingmodifier = 1
if(HAS_TRAIT(user, TRAIT_QUICK_BUILD))
platingmodifier = 0.7
if(next_beep <= world.time)
next_beep = world.time + 10
playsound(src, 'sound/machines/clockcult/integration_cog_install.ogg', 50, TRUE)
add_fingerprint(user)
if(istype(W, /obj/item/gun/energy/plasmacutter))
to_chat(user, "<span class='notice'>You start slicing apart the girder...</span>")
if(W.use_tool(src, user, 40, volume=100))
if(W.use_tool(src, user, 40*platingmodifier, volume=100))
to_chat(user, "<span class='notice'>You slice apart the girder.</span>")
var/obj/item/stack/sheet/metal/M = new (loc, 2)
M.add_fingerprint(user)
@@ -62,7 +69,7 @@
to_chat(user, "<span class='warning'>You need at least two rods to create a false wall!</span>")
return
to_chat(user, "<span class='notice'>You start building a reinforced false wall...</span>")
if(do_after(user, 20, target = src))
if(do_after(user, 20*platingmodifier, target = src))
if(S.get_amount() < 2)
return
S.use(2)
@@ -75,7 +82,7 @@
to_chat(user, "<span class='warning'>You need at least five rods to add plating!</span>")
return
to_chat(user, "<span class='notice'>You start adding plating...</span>")
if(do_after(user, 40, target = src))
if(do_after(user, 40*platingmodifier, target = src))
if(S.get_amount() < 5)
return
S.use(5)
@@ -96,7 +103,7 @@
to_chat(user, "<span class='warning'>You need two sheets of metal to create a false wall!</span>")
return
to_chat(user, "<span class='notice'>You start building a false wall...</span>")
if(do_after(user, 20, target = src))
if(do_after(user, 20*platingmodifier, target = src))
if(S.get_amount() < 2)
return
S.use(2)
@@ -109,7 +116,7 @@
to_chat(user, "<span class='warning'>You need two sheets of metal to finish a wall!</span>")
return
to_chat(user, "<span class='notice'>You start adding plating...</span>")
if (do_after(user, 40, target = src))
if (do_after(user, 40*platingmodifier, target = src))
if(S.get_amount() < 2)
return
S.use(2)
@@ -126,7 +133,7 @@
to_chat(user, "<span class='warning'>You need at least two sheets to create a false wall!</span>")
return
to_chat(user, "<span class='notice'>You start building a reinforced false wall...</span>")
if(do_after(user, 20, target = src))
if(do_after(user, 20*platingmodifier, target = src))
if(S.get_amount() < 2)
return
S.use(2)
@@ -139,7 +146,7 @@
if(S.get_amount() < 1)
return
to_chat(user, "<span class='notice'>You start finalizing the reinforced wall...</span>")
if(do_after(user, 50, target = src))
if(do_after(user, 50*platingmodifier, target = src))
if(S.get_amount() < 1)
return
S.use(1)
@@ -153,7 +160,7 @@
if(S.get_amount() < 1)
return
to_chat(user, "<span class='notice'>You start reinforcing the girder...</span>")
if(do_after(user, 60, target = src))
if(do_after(user, 60*platingmodifier, target = src))
if(S.get_amount() < 1)
return
S.use(1)
@@ -172,7 +179,7 @@
if(S.get_amount() < 2)
to_chat(user, "<span class='warning'>You need at least two sheets to create a false wall!</span>")
return
if(do_after(user, 20, target = src))
if(do_after(user, 20*platingmodifier, target = src))
if(S.get_amount() < 2)
return
S.use(2)
@@ -188,7 +195,7 @@
to_chat(user, "<span class='warning'>You need at least two sheets to add plating!</span>")
return
to_chat(user, "<span class='notice'>You start adding plating...</span>")
if (do_after(user, 40, target = src))
if (do_after(user, 40*platingmodifier, target = src))
if(S.get_amount() < 2)
return
S.use(2)
+27
View File
@@ -149,3 +149,30 @@
pixel_x = 0
pixel_y = 0
return TRUE
/obj/structure/lattice/lava
name = "heatproof support lattice"
desc = "A specialized support beam for building across lava. Watch your step."
icon = 'icons/obj/smooth_structures/catwalk.dmi'
icon_state = "catwalk"
number_of_rods = 1
color = "#5286b9ff"
smooth = SMOOTH_TRUE
canSmoothWith = null
obj_flags = CAN_BE_HIT | BLOCK_Z_FALL
resistance_flags = FIRE_PROOF | LAVA_PROOF
/obj/structure/lattice/lava/deconstruction_hints(mob/user)
return "<span class='notice'>The rods look like they could be <b>cut</b>, but the <i>heat treatment will shatter off</i>. There's space for a <i>tile</i>.</span>"
/obj/structure/lattice/lava/attackby(obj/item/C, mob/user, params)
. = ..()
if(istype(C, /obj/item/stack/tile/plasteel))
var/obj/item/stack/tile/plasteel/P = C
if(P.use(1))
to_chat(user, "<span class='notice'>You construct a floor plating, as lava settles around the rods.</span>")
playsound(src, 'sound/weapons/genhit.ogg', 50, TRUE)
new /turf/open/floor/plating(locate(x, y, z))
else
to_chat(user, "<span class='warning'>You need one floor tile to build atop [src].</span>")
return
+39 -1
View File
@@ -163,6 +163,9 @@
if(istype(I, /obj/item/storage/bag/tray))
var/obj/item/storage/bag/tray/T = I
if(T.contents.len > 0) // If the tray isn't empty
for(var/x in T.contents)
var/obj/item/item = x
AfterPutItemOnTable(item, user)
SEND_SIGNAL(I, COMSIG_TRY_STORAGE_QUICK_EMPTY, drop_location())
user.visible_message("[user] empties [I] on [src].")
return
@@ -177,10 +180,14 @@
//Clamp it so that the icon never moves more than 16 pixels in either direction (thus leaving the table turf)
I.pixel_x = clamp(text2num(click_params["icon-x"]) - 16, -(world.icon_size/2), world.icon_size/2)
I.pixel_y = clamp(text2num(click_params["icon-y"]) - 16, -(world.icon_size/2), world.icon_size/2)
return 1
AfterPutItemOnTable(I, user)
return TRUE
else
return ..()
/obj/structure/table/proc/AfterPutItemOnTable(obj/item/I, mob/living/user)
return
/obj/structure/table/alt_attack_hand(mob/user)
if(user && Adjacent(user) && !user.incapacitated())
user.changeNext_move(CLICK_CD_MELEE*0.5)
@@ -214,6 +221,37 @@
material_flags = MATERIAL_ADD_PREFIX | MATERIAL_COLOR | MATERIAL_AFFECT_STATISTICS | MATERIAL_EFFECTS
buildstack = null //No buildstack, so generate from mat datums
///Table on wheels
/obj/structure/table/rolling
name = "Rolling table"
desc = "A NT brand \"Rolly poly\" rolling table. It can and will move."
anchored = FALSE
smooth = SMOOTH_FALSE
canSmoothWith = list()
icon = 'icons/obj/smooth_structures/rollingtable.dmi'
icon_state = "rollingtable"
var/list/attached_items = list()
/obj/structure/table/rolling/AfterPutItemOnTable(obj/item/I, mob/living/user)
. = ..()
attached_items += I
RegisterSignal(I, COMSIG_MOVABLE_MOVED, .proc/RemoveItemFromTable) //Listen for the pickup event, unregister on pick-up so we aren't moved
/obj/structure/table/rolling/proc/RemoveItemFromTable(datum/source, newloc, dir)
if(newloc != loc) //Did we not move with the table? because that shit's ok
return FALSE
attached_items -= source
UnregisterSignal(source, COMSIG_MOVABLE_MOVED)
/obj/structure/table/rolling/Moved(atom/OldLoc, Dir)
for(var/mob/M in OldLoc.contents)//Kidnap everyone on top
M.forceMove(loc)
for(var/x in attached_items)
var/atom/movable/AM = x
if(!AM.Move(loc))
RemoveItemFromTable(AM, AM.loc)
return TRUE
/*
* Glass tables
*/
+1 -1
View File
@@ -520,7 +520,7 @@
if(istype(O, /obj/item/melee/baton))
var/obj/item/melee/baton/B = O
if(B.cell)
if(B.cell.charge > 0 && B.status == 1)
if(B.cell.charge > 0 && B.turned_on)
flick("baton_active", src)
var/stunforce = B.stamforce
user.DefaultCombatKnockdown(stunforce * 2)