mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-23 05:00:55 +01:00
Included additional structures to escape from
This commit is contained in:
+1
-3
@@ -358,6 +358,7 @@
|
||||
var/mob/living/user = usr
|
||||
var/breakout_time = 2
|
||||
if(open || !locked) //Open and unlocked, no need to escape
|
||||
open = 1
|
||||
return
|
||||
user.next_move = world.time + 100
|
||||
user.last_special = world.time + 100
|
||||
@@ -373,9 +374,6 @@
|
||||
visible_message("<span class='danger'>[user] successfully broke out of [src]!</span>")
|
||||
user << "<span class='notice'>You successfully break out of [src]!</span>"
|
||||
|
||||
if(istype(loc, /obj/structure/bigDelivery))
|
||||
var/obj/structure/bigDelivery/BD = loc
|
||||
BD.attack_hand(user)
|
||||
open()
|
||||
|
||||
/obj/machinery/dna_scannernew/proc/close()
|
||||
|
||||
@@ -65,6 +65,8 @@
|
||||
|
||||
dat += "<A href='?src=\ref[src];refresh=1'>Scan</A>"
|
||||
|
||||
dat += "<A href='?src=\ref[src];eject=1'>Eject occupant</A>"
|
||||
|
||||
dat += "<h3>Injector</h3>"
|
||||
if(occupant)
|
||||
dat += "<A href='?src=\ref[src];inap=1'>Inject Inaprovaline</A>"
|
||||
@@ -92,7 +94,11 @@
|
||||
return
|
||||
usr.set_machine(src)
|
||||
if(connected && connected.occupant)
|
||||
if(connected.occupant.health > 0)
|
||||
if(href_list["eject"])
|
||||
connected.eject()
|
||||
updateUsrDialog()
|
||||
return
|
||||
else if(connected.occupant.health > 0)
|
||||
if(href_list["inap"])
|
||||
connected.inject_inap(usr)
|
||||
if(href_list["stox"])
|
||||
@@ -294,14 +300,10 @@
|
||||
var/units = round(occupant.reagents.get_reagent_amount("dexalin"))
|
||||
user << "<span class='notice'>Occupant now has [units] unit\s of dexalin in their bloodstream.</span>"
|
||||
|
||||
/obj/machinery/sleeper/container_resist()
|
||||
eject()
|
||||
|
||||
/obj/machinery/sleeper/verb/eject()
|
||||
set name = "Eject occupant"
|
||||
set category = "Object"
|
||||
set src in oview(1)
|
||||
if(usr.stat || isslime(usr) || ispAI(usr))
|
||||
return
|
||||
icon_state = "sleeper-open"
|
||||
/obj/machinery/sleeper/proc/eject()
|
||||
go_out()
|
||||
add_fingerprint(usr)
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@
|
||||
/obj/machinery/gibber/attack_paw(mob/user as mob)
|
||||
return src.attack_hand(user)
|
||||
|
||||
/obj/machinery/gibber/relaymove(mob/user as mob)
|
||||
/obj/machinery/gibber/container_resist()
|
||||
src.go_out()
|
||||
return
|
||||
|
||||
|
||||
@@ -419,15 +419,26 @@
|
||||
return
|
||||
|
||||
|
||||
/obj/machinery/suit_storage_unit/verb/get_out()
|
||||
set name = "Eject Suit Storage Unit"
|
||||
set category = "Object"
|
||||
set src in oview(1)
|
||||
/obj/machinery/suit_storage_unit/container_resist()
|
||||
var/mob/living/user = usr
|
||||
if(islocked)
|
||||
user.next_move = world.time + 100
|
||||
user.last_special = world.time + 100
|
||||
var/breakout_time = 2
|
||||
user << "<span class='notice'>You start kicking against the doors to escape! (This will take about [breakout_time] minutes.)</span>"
|
||||
visible_message("You see [user] kicking against the doors of the [src]!")
|
||||
if(do_after(user,(breakout_time*60*10)))
|
||||
if(!user || user.stat != CONSCIOUS || user.loc != src || isopen || !islocked)
|
||||
return
|
||||
else
|
||||
isopen = 1
|
||||
islocked = 0
|
||||
visible_message("<span class='danger'>[user] successfully broke out of [src]!</span>")
|
||||
|
||||
if (usr.stat != 0)
|
||||
return
|
||||
src.eject_occupant(usr)
|
||||
add_fingerprint(usr)
|
||||
else
|
||||
return
|
||||
src.eject_occupant(user)
|
||||
add_fingerprint(user)
|
||||
src.updateUsrDialog()
|
||||
src.update_icon()
|
||||
return
|
||||
@@ -568,4 +579,4 @@
|
||||
return
|
||||
|
||||
|
||||
//////////////////////////////REMINDER: Make it lock once you place some fucker inside.
|
||||
//////////////////////////////REMINDER: Make it lock once you place some fucker inside.
|
||||
|
||||
@@ -1086,6 +1086,9 @@
|
||||
add_fingerprint(usr)
|
||||
return
|
||||
|
||||
/obj/mecha/container_resist()
|
||||
go_out()
|
||||
|
||||
|
||||
/obj/mecha/proc/go_out()
|
||||
if(!src.occupant) return
|
||||
|
||||
@@ -191,9 +191,23 @@
|
||||
icon_state = "cocoon1"
|
||||
health = 60
|
||||
|
||||
New()
|
||||
/obj/effect/spider/cocoon/New()
|
||||
icon_state = pick("cocoon1","cocoon2","cocoon3")
|
||||
|
||||
/obj/effect/spider/cocoon/container_resist()
|
||||
var/mob/living/user = usr
|
||||
var/breakout_time = 2
|
||||
user.next_move = world.time + 100
|
||||
user.last_special = world.time + 100
|
||||
user << "<span class='notice'>You struggle against the tight bonds! (This will take about [breakout_time] minutes.)</span>"
|
||||
visible_message("You see something struggling and writhing in the [src]!")
|
||||
if(do_after(user,(breakout_time*60*10)))
|
||||
if(!user || user.stat != CONSCIOUS || user.loc != src)
|
||||
return
|
||||
Del()
|
||||
|
||||
|
||||
|
||||
/obj/effect/spider/cocoon/Del()
|
||||
src.visible_message("\red \The [src] splits open.")
|
||||
for(var/atom/movable/A in contents)
|
||||
|
||||
@@ -314,7 +314,4 @@
|
||||
broken = 1 //applies to secure lockers only
|
||||
visible_message("<span class='danger'>[user] successfully broke out of [src]!</span>")
|
||||
user << "<span class='notice'>You successfully break out of [src]!</span>"
|
||||
if(istype(loc, /obj/structure/bigDelivery)) //Do this to prevent contents from being opened into nullspace (read: bluespace)
|
||||
var/obj/structure/bigDelivery/BD = loc
|
||||
BD.attack_hand(user)
|
||||
open()
|
||||
|
||||
@@ -101,9 +101,7 @@
|
||||
src.add_fingerprint(user)
|
||||
return
|
||||
|
||||
/obj/structure/morgue/relaymove(mob/user as mob)
|
||||
if (user.stat)
|
||||
return
|
||||
/obj/structure/morgue/container_resist()
|
||||
src.connected = new /obj/structure/m_tray( src.loc )
|
||||
step(src.connected, EAST)
|
||||
src.connected.layer = OBJ_LAYER
|
||||
@@ -271,9 +269,7 @@
|
||||
src.add_fingerprint(user)
|
||||
return
|
||||
|
||||
/obj/structure/crematorium/relaymove(mob/user as mob)
|
||||
if (user.stat || locked)
|
||||
return
|
||||
/obj/structure/crematorium/container_resist()
|
||||
src.connected = new /obj/structure/c_tray( src.loc )
|
||||
step(src.connected, SOUTH)
|
||||
src.connected.layer = OBJ_LAYER
|
||||
|
||||
@@ -464,8 +464,9 @@
|
||||
|
||||
//Breaking out of a container (Locker, sleeper, cryo...)
|
||||
else if(loc && istype(loc, /obj) && !isturf(loc))
|
||||
var/obj/C = loc
|
||||
C.container_resist(L)
|
||||
if(L.stat == CONSCIOUS && !L.stunned && !L.weakened && !L.paralysis)
|
||||
var/obj/C = loc
|
||||
C.container_resist(L)
|
||||
|
||||
//Stop drop and roll & Handcuffs
|
||||
else if(iscarbon(L))
|
||||
|
||||
@@ -193,11 +193,11 @@
|
||||
/obj/machinery/disposal/alter_health()
|
||||
return get_turf(src)
|
||||
|
||||
// attempt to move while inside
|
||||
/obj/machinery/disposal/relaymove(mob/user as mob)
|
||||
if(user.stat || src.flushing)
|
||||
// resist to escape the bin
|
||||
/obj/machinery/disposal/container_resist()
|
||||
if(src.flushing)
|
||||
return
|
||||
src.go_out(user)
|
||||
go_out(usr)
|
||||
return
|
||||
|
||||
// leave the disposal
|
||||
|
||||
Reference in New Issue
Block a user