[READY]VEHICLE REFACTOR - Riding datums --> Components, Vehicles --> /obj/vehicle, staging for mech overhaul later on

This commit is contained in:
kevinz000
2017-12-03 13:33:01 -08:00
committed by CitadelStationBot
parent 6217206bae
commit 66c66f0bd7
54 changed files with 1052 additions and 786 deletions
@@ -66,16 +66,16 @@
"<span class='italics'>You hear squelching...</span>")
/obj/structure/bed/nest/post_buckle_mob(mob/living/M)
if(M in buckled_mobs)
M.pixel_y = 0
M.pixel_x = initial(M.pixel_x) + 2
M.layer = BELOW_MOB_LAYER
add_overlay(nest_overlay)
else
M.pixel_x = M.get_standard_pixel_x_offset(M.lying)
M.pixel_y = M.get_standard_pixel_y_offset(M.lying)
M.layer = initial(M.layer)
cut_overlay(nest_overlay)
M.pixel_y = 0
M.pixel_x = initial(M.pixel_x) + 2
M.layer = BELOW_MOB_LAYER
add_overlay(nest_overlay)
/obj/structure/bed/nest/post_unbuckle_mob(mob/living/M)
M.pixel_x = M.get_standard_pixel_x_offset(M.lying)
M.pixel_y = M.get_standard_pixel_y_offset(M.lying)
M.layer = initial(M.layer)
cut_overlay(nest_overlay)
/obj/structure/bed/nest/play_attack_sound(damage_amount, damage_type = BRUTE, damage_flag = 0)
switch(damage_type)
@@ -85,21 +85,21 @@
qdel(src)
/obj/structure/bed/roller/post_buckle_mob(mob/living/M)
if(M in buckled_mobs)
density = TRUE
icon_state = "up"
M.pixel_y = initial(M.pixel_y)
else
density = FALSE
icon_state = "down"
M.pixel_x = M.get_standard_pixel_x_offset(M.lying)
M.pixel_y = M.get_standard_pixel_y_offset(M.lying)
density = TRUE
icon_state = "up"
M.pixel_y = initial(M.pixel_y)
/obj/structure/bed/roller/Moved()
. = ..()
if(has_gravity())
playsound(src, 'sound/effects/roll.ogg', 100, 1)
/obj/structure/bed/roller/post_unbuckle_mob(mob/living/M)
density = FALSE
icon_state = "down"
M.pixel_x = M.get_standard_pixel_x_offset(M.lying)
M.pixel_y = M.get_standard_pixel_y_offset(M.lying)
/obj/item/roller
name = "roller bed"
desc = "A collapsed roller bed that can be carried around."
@@ -91,7 +91,11 @@
layer = OBJ_LAYER
/obj/structure/chair/post_buckle_mob(mob/living/M)
..()
. = ..()
handle_layer()
/obj/structure/chair/post_unbuckle_mob()
. = ..()
handle_layer()
/obj/structure/chair/proc/spin()
@@ -167,12 +171,18 @@
return ..()
/obj/structure/chair/comfy/post_buckle_mob(mob/living/M)
..()
. = ..()
update_armrest()
/obj/structure/chair/comfy/proc/update_armrest()
if(has_buckled_mobs())
add_overlay(armrest)
else
cut_overlay(armrest)
/obj/structure/chair/comfy/post_unbuckle_mob()
. = ..()
update_armrest()
/obj/structure/chair/comfy/brown
color = rgb(255,113,0)