You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

118 lines
3.8 KiB

  1. /obj/machinery/door/poddoor
  2. name = "blast door"
  3. desc = "A heavy duty blast door that opens mechanically."
  4. icon = 'icons/obj/doors/blastdoor.dmi'
  5. icon_state = "closed"
  6. var/id = 1
  7. layer = BLASTDOOR_LAYER
  8. closingLayer = CLOSED_BLASTDOOR_LAYER
  9. sub_door = TRUE
  10. explosion_block = 3
  11. heat_proof = TRUE
  12. safe = FALSE
  13. max_integrity = 600
  14. armor = list("melee" = 50, "bullet" = 100, "laser" = 100, "energy" = 100, "bomb" = 50, "bio" = 100, "rad" = 100, "fire" = 100, "acid" = 70)
  15. resistance_flags = FIRE_PROOF
  16. damage_deflection = 70
  17. poddoor = TRUE
  18. /obj/machinery/door/poddoor/connect_to_shuttle(obj/docking_port/mobile/port, obj/docking_port/stationary/dock, idnum, override=FALSE)
  19. id = "[idnum][id]"
  20. /obj/machinery/door/poddoor/preopen
  21. icon_state = "open"
  22. density = FALSE
  23. opacity = 0
  24. /obj/machinery/door/poddoor/ert
  25. name = "hardened blast door"
  26. desc = "A heavy duty blast door that only opens for dire emergencies."
  27. resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF
  28. //special poddoors that open when emergency shuttle docks at centcom
  29. /obj/machinery/door/poddoor/shuttledock
  30. var/checkdir = 4 //door won't open if turf in this dir is `turftype`
  31. var/turftype = /turf/open/space
  32. /obj/machinery/door/poddoor/shuttledock/proc/check()
  33. var/turf/T = get_step(src, checkdir)
  34. if(!istype(T, turftype))
  35. INVOKE_ASYNC(src, .proc/open)
  36. else
  37. INVOKE_ASYNC(src, .proc/close)
  38. /obj/machinery/door/poddoor/incinerator_toxmix
  39. name = "combustion chamber vent"
  40. id = INCINERATOR_TOXMIX_VENT
  41. /obj/machinery/door/poddoor/incinerator_atmos_main
  42. name = "turbine vent"
  43. id = INCINERATOR_ATMOS_MAINVENT
  44. /obj/machinery/door/poddoor/incinerator_atmos_aux
  45. name = "combustion chamber vent"
  46. id = INCINERATOR_ATMOS_AUXVENT
  47. /obj/machinery/door/poddoor/incinerator_syndicatelava_main
  48. name = "turbine vent"
  49. id = INCINERATOR_SYNDICATELAVA_MAINVENT
  50. /obj/machinery/door/poddoor/incinerator_syndicatelava_aux
  51. name = "combustion chamber vent"
  52. id = INCINERATOR_SYNDICATELAVA_AUXVENT
  53. /obj/machinery/door/poddoor/Bumped(atom/movable/AM)
  54. if(density)
  55. return 0
  56. else
  57. return ..()
  58. //"BLAST" doors are obviously stronger than regular doors when it comes to BLASTS.
  59. /obj/machinery/door/poddoor/ex_act(severity, target)
  60. if(severity == 3)
  61. return
  62. ..()
  63. /obj/machinery/door/poddoor/do_animate(animation)
  64. switch(animation)
  65. if("opening")
  66. flick("opening", src)
  67. playsound(src, 'sound/machines/blastdoor.ogg', 30, TRUE)
  68. if("closing")
  69. flick("closing", src)
  70. playsound(src, 'sound/machines/blastdoor.ogg', 30, TRUE)
  71. /obj/machinery/door/poddoor/update_icon_state()
  72. if(density)
  73. icon_state = "closed"
  74. else
  75. icon_state = "open"
  76. SSdemo.mark_dirty(src)
  77. /obj/machinery/door/poddoor/try_to_activate_door(mob/user)
  78. return
  79. /obj/machinery/door/poddoor/try_to_crowbar(obj/item/I, mob/user)
  80. if(machine_stat & NOPOWER)
  81. open(TRUE)
  82. /obj/machinery/door/poddoor/attack_alien(mob/living/carbon/alien/humanoid/user)
  83. if(density & !(resistance_flags & INDESTRUCTIBLE))
  84. add_fingerprint(user)
  85. user.visible_message("<span class='warning'>[user] begins prying open [src].</span>",\
  86. "<span class='noticealien'>You begin digging your claws into [src] with all your might!</span>",\
  87. "<span class='warning'>You hear groaning metal...</span>")
  88. playsound(src, 'sound/machines/airlock_alien_prying.ogg', 100, TRUE)
  89. var/time_to_open = 5 SECONDS
  90. if(hasPower())
  91. time_to_open = 15 SECONDS
  92. if(do_after(user, time_to_open, TRUE, src))
  93. if(density && !open(TRUE)) //The airlock is still closed, but something prevented it opening. (Another player noticed and bolted/welded the airlock in time!)
  94. to_chat(user, "<span class='warning'>Despite your efforts, [src] managed to resist your attempts to open it!</span>")
  95. else
  96. return ..()