mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-24 20:47:10 +01:00
fixed bed hookup
Removed runover, might need to change the buckled_mob.dir to the ambulance bed moved thoug....ATV Turret still borked.
This commit is contained in:
@@ -3,6 +3,7 @@
|
||||
desc = "what the paramedic uses to run over people to take to medbay."
|
||||
icon_state = "docwagon2"
|
||||
keytype = /obj/item/key/ambulance
|
||||
var/obj/structure/stool/bed/amb_trolley/bed = null
|
||||
|
||||
|
||||
/obj/item/key/ambulance
|
||||
@@ -28,22 +29,13 @@
|
||||
buckled_mob.pixel_x = -13
|
||||
buckled_mob.pixel_y = 7
|
||||
|
||||
|
||||
/obj/vehicle/ambulance/attackby(obj/item/I, mob/user, params)
|
||||
//add ambulance bed hookup here
|
||||
..()
|
||||
|
||||
/obj/vehicle/ambulance/RunOver(var/mob/living/carbon/human/H)
|
||||
var/mob/living/carbon/human/D = buckled_mob
|
||||
var/list/parts = list("head", "chest", "l_leg", "r_leg", "l_arm", "r_arm")
|
||||
|
||||
H.apply_effects(5, 5)
|
||||
for(var/i = 0, i < rand(1,3), i++)
|
||||
H.apply_damage(rand(1,5), BRUTE, pick(parts))
|
||||
|
||||
visible_message("<span class='warning'> \The [src] ran over [H]!</span>")
|
||||
msg_admin_attack("[key_name_admin(D)] ran over [key_name_admin(H)]")
|
||||
|
||||
/obj/vehicle/ambulance/Move(newloc, Dir)
|
||||
var/oldloc = loc
|
||||
. = ..()
|
||||
if(bed && get_dist(oldloc, loc) <= 2)
|
||||
bed.Move(oldloc)
|
||||
bed.dir = Dir
|
||||
bed.buckled_mob.dir = Dir
|
||||
|
||||
/obj/structure/stool/bed/amb_trolley
|
||||
name = "ambulance train trolley"
|
||||
@@ -52,4 +44,12 @@
|
||||
anchored = 0
|
||||
|
||||
/obj/structure/stool/bed/amb_trolley/MouseDrop(obj/over_object as obj)
|
||||
..()
|
||||
..()
|
||||
if(istype(over_object, /obj/vehicle/ambulance))
|
||||
var/obj/vehicle/ambulance/amb = over_object
|
||||
if(amb.bed)
|
||||
amb.bed = null
|
||||
to_chat(usr, "You unhook the bed to the ambulance.")
|
||||
else
|
||||
amb.bed = src
|
||||
to_chat(usr, "You hook the bed to the ambulance.")
|
||||
@@ -52,7 +52,7 @@
|
||||
/obj/vehicle/janicart/examine(mob/user)
|
||||
..()
|
||||
if(floorbuffer)
|
||||
user << "It has been upgraded with a floor buffer."
|
||||
to_chat(user, "It has been upgraded with a floor buffer.")
|
||||
|
||||
|
||||
/obj/vehicle/janicart/attackby(obj/item/I, mob/user, params)
|
||||
@@ -60,14 +60,14 @@
|
||||
if(keytype == /obj/item/key/janitor)
|
||||
if(!user.drop_item())
|
||||
return
|
||||
user << "<span class='notice'>You hook the trashbag onto \the [name].</span>"
|
||||
to_chat(user, "<span class='notice'>You hook the trashbag onto \the [name].</span>")
|
||||
I.loc = src
|
||||
mybag = I
|
||||
else if(istype(I, /obj/item/janiupgrade))
|
||||
if(keytype == /obj/item/key/janitor)
|
||||
floorbuffer = 1
|
||||
qdel(I)
|
||||
user << "<span class='notice'>You upgrade \the [name] with the floor buffer.</span>"
|
||||
to_chat(user,"<span class='notice'>You upgrade \the [name] with the floor buffer.</span>")
|
||||
update_icon()
|
||||
|
||||
..()
|
||||
|
||||
@@ -102,7 +102,7 @@
|
||||
handle_vehicle_layer()
|
||||
handle_vehicle_offsets()
|
||||
else
|
||||
user << "<span class='notice'>You'll need the keys in one of your hands to drive \the [name].</span>"
|
||||
to_chat(user, "<span class='notice'>You'll need the keys in one of your hands to drive \the [name].</span>")
|
||||
|
||||
|
||||
/obj/vehicle/Move(NewLoc,Dir=0,step_x=0,step_y=0)
|
||||
@@ -113,7 +113,7 @@
|
||||
|
||||
/obj/vehicle/attackby(obj/item/I, mob/user, params)
|
||||
if(keytype && istype(I, keytype))
|
||||
user << "Hold [I] in one of your hands while you drive \the [name]."
|
||||
to_chat(user, "Hold [I] in one of your hands while you drive \the [name].")
|
||||
|
||||
|
||||
/obj/vehicle/Bump(atom/movable/M)
|
||||
|
||||
Reference in New Issue
Block a user