mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-07-21 04:48:18 +01:00
Fixes some ship weapon bugs. (#15035)
* Fixes some ship weapon bugs. * missed entry * list sort * cl + fix Co-authored-by: Matt Atlas <liermattia@gmail.com>
This commit is contained in:
@@ -304,7 +304,9 @@
|
||||
icon_state = "safeguard_open"
|
||||
|
||||
/obj/machinery/leviathan_safeguard/attackby(obj/item/I, mob/user)
|
||||
if(istype(I, /obj/item/leviathan_key) && !key && !stat && !locked)
|
||||
if(!opened || locked)
|
||||
return
|
||||
if(istype(I, /obj/item/leviathan_key) && !key && !stat)
|
||||
var/obj/item/leviathan_key/LK = I
|
||||
if(use_check_and_message(user))
|
||||
return
|
||||
@@ -316,7 +318,7 @@
|
||||
playsound(src, 'sound/effects/ship_weapons/levi_key_insert.ogg')
|
||||
|
||||
/obj/machinery/leviathan_safeguard/attack_hand(mob/user)
|
||||
if(key && !stat && !locked)
|
||||
if(key && !stat && opened && !locked)
|
||||
if(use_check_and_message(user))
|
||||
return
|
||||
if(do_after(user, 1 SECOND))
|
||||
@@ -368,12 +370,15 @@
|
||||
possible_entry_points[O.name] = O
|
||||
for(var/obj/effect/O in V.entry_points)
|
||||
possible_entry_points[O.name] = O
|
||||
possible_entry_points = sortList(possible_entry_points)
|
||||
if(istype(linked.targeting, /obj/effect/overmap/event))
|
||||
possible_entry_points += SHIP_HAZARD_TARGET
|
||||
var/targeted_landmark = input(user, "Select an entry point.", "Leviathan Control") as null|anything in possible_entry_points
|
||||
if(!targeted_landmark && length(possible_entry_points))
|
||||
return
|
||||
var/obj/effect/landmark
|
||||
if(length(possible_entry_points))
|
||||
landmark = possible_entry_points[targeted_landmark]
|
||||
if(length(possible_entry_points) && !(targeted_landmark == SHIP_HAZARD_TARGET))
|
||||
landmark = possible_entry_points[targeted_landmark]
|
||||
if(do_after(user, 1 SECOND) && !use_check_and_message(user))
|
||||
playsound(src, 'sound/effects/ship_weapons/levi_button_press.ogg')
|
||||
visible_message(SPAN_DANGER("[user] presses \the [src]!"))
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
var/mob/living/carbon/human/H = user
|
||||
if(istype(I, /obj/item/primer) && !primer)
|
||||
var/obj/item/primer/P = I
|
||||
visible_message(SPAN_NOTICE("You start connecting \the [P] to the casing..."), SPAN_NOTICE("[H] starts connecting \the [P] to the casing..."))
|
||||
user.visible_message(SPAN_NOTICE("[H] starts connecting \the [P] to the casing..."), SPAN_NOTICE("You start connecting \the [P] to the casing..."))
|
||||
if(do_after(H, 3 SECONDS))
|
||||
visible_message(SPAN_NOTICE("You connect \the [P] to the casing!"), SPAN_NOTICE("[H] connects \the [P] to the casing!"))
|
||||
H.drop_from_inventory(P)
|
||||
@@ -22,7 +22,7 @@
|
||||
playsound(src, 'sound/machines/rig/rig_deploy.ogg')
|
||||
if(istype(I, /obj/item/warhead) && !warhead)
|
||||
var/obj/item/warhead/W = I
|
||||
visible_message(SPAN_NOTICE("You start connecting \the [W] to the casing..."), SPAN_NOTICE("[H] starts connecting \the [W] to the casing..."))
|
||||
user.visible_message( SPAN_NOTICE("[H] starts connecting \the [W] to the casing..."), SPAN_NOTICE("You start connecting \the [W] to the casing..."))
|
||||
if(do_after(H, 5 SECONDS))
|
||||
visible_message(SPAN_NOTICE("You connect \the [W] to the casing!"), SPAN_NOTICE("[H] connects \the [W] to the casing!"))
|
||||
H.drop_from_inventory(W)
|
||||
@@ -122,8 +122,8 @@
|
||||
warhead_type = SHIP_AMMO_IMPACT_HE
|
||||
slowdown = 2
|
||||
var/drop_counter = 0
|
||||
var/cookoff_devastation = 2
|
||||
var/cookoff_heavy = 2
|
||||
var/cookoff_devastation = 0
|
||||
var/cookoff_heavy = 3
|
||||
var/cookoff_light = 4
|
||||
|
||||
/obj/item/warhead/longbow/too_heavy_to_throw()
|
||||
@@ -162,7 +162,7 @@
|
||||
icon_state = "armor_piercing_obj"
|
||||
warhead_state = "armor_piercing"
|
||||
warhead_type = SHIP_AMMO_IMPACT_AP
|
||||
cookoff_devastation = 1
|
||||
cookoff_devastation = 0
|
||||
cookoff_heavy = 2
|
||||
cookoff_light = 6
|
||||
|
||||
|
||||
Reference in New Issue
Block a user