Merge branch 'master' into matContainer

This commit is contained in:
Sneakyrat6
2021-03-09 05:42:47 -05:00
committed by GitHub
703 changed files with 29425 additions and 21761 deletions
-1
View File
@@ -676,4 +676,3 @@
/obj/machinery/mecha_part_fabricator/offstation
link_on_init = FALSE
circuit = /obj/item/circuitboard/machine/mechfab/offstation
+5 -1
View File
@@ -133,7 +133,6 @@
icon_state += "-open"
add_radio()
add_cabin()
add_airtank()
spark_system.set_up(2, 0, src)
spark_system.attach(src)
smoke_system.set_up(3, src)
@@ -149,6 +148,11 @@
diag_hud_set_mechhealth()
diag_hud_set_mechcell()
diag_hud_set_mechstat()
return INITIALIZE_HINT_LATELOAD
/obj/mecha/LateInitialize()
. = ..()
add_airtank()
/obj/mecha/get_cell()
return cell
+14 -13
View File
@@ -29,7 +29,7 @@
integrity = round((M.obj_integrity / M.max_integrity) * 100),
charge = M.cell ? round(M.cell.percent()) : null,
airtank = M.internal_tank ? M.return_pressure() : null,
pilot = M.occupant,
pilot = list(M.occupant),
location = get_area_name(M, TRUE),
active_equipment = M.selected,
emp_recharging = MT.recharging,
@@ -38,7 +38,7 @@
if(istype(M, /obj/mecha/working/ripley))
var/obj/mecha/working/ripley/RM = M
mech_data += list(
cargo_space = round((RM.cargo.len / RM.cargo_capacity) * 100)
cargo_space = round((LAZYLEN(RM.cargo) / RM.cargo_capacity) * 100)
)
data["mechs"] += list(mech_data)
@@ -46,7 +46,8 @@
return data
/obj/machinery/computer/mecha/ui_act(action, params)
if(..())
. = ..()
if(.)
return
switch(action)
@@ -57,7 +58,7 @@
var/message = stripped_input(usr, "Input message", "Transmit message")
var/obj/mecha/M = MT.chassis
if(trim(message) && M)
M.occupant_message(message)
to_chat(M.occupant, message)
to_chat(usr, "<span class='notice'>Message sent.</span>")
. = TRUE
if("shock")
@@ -67,8 +68,8 @@
var/obj/mecha/M = MT.chassis
if(M)
MT.shock()
log_game("[key_name(usr)] has activated remote EMP on exosuit [M], located at [loc_name(M)], which is currently [M.occupant? "being piloted by [key_name(M.occupant)]." : "without a pilot."] ")
message_admins("[key_name_admin(usr)][ADMIN_FLW(usr)] has activated remote EMP on exosuit [M][ADMIN_JMP(M)], which is currently [M.occupant ? "being piloted by [key_name_admin(M.occupant)][ADMIN_FLW(M.occupant)]." : "without a pilot."] ")
log_game("[key_name(usr)] has activated remote EMP on exosuit [M], located at [loc_name(M)], which [M.occupant ? "has the occupants [M.occupant]." : "without a pilot."] ")
message_admins("[key_name_admin(usr)][ADMIN_FLW(usr)] has activated remote EMP on exosuit [M][ADMIN_JMP(M)], which is currently [M.occupant ? "occupied by [M.occupant][ADMIN_FLW(M)]." : "without a pilot."] ")
. = TRUE
/obj/item/mecha_parts/mecha_tracking
@@ -85,8 +86,8 @@
var/obj/mecha/chassis
/**
* Returns a html formatted string describing attached mech status
*/
* Returns a html formatted string describing attached mech status
*/
/obj/item/mecha_parts/mecha_tracking/proc/get_mecha_info()
if(!chassis)
return FALSE
@@ -101,7 +102,7 @@
<b>Active Equipment:</b> [chassis.selected || "None"]"}
if(istype(chassis, /obj/mecha/working/ripley))
var/obj/mecha/working/ripley/RM = chassis
answer += "<br><b>Used Cargo Space:</b> [round((RM.cargo.len / RM.cargo_capacity * 100), 0.01)]%"
answer += "<br><b>Used Cargo Space:</b> [round((LAZYLEN(RM.cargo) / RM.cargo_capacity * 100), 0.01)]%"
return answer
@@ -125,8 +126,8 @@
chassis = M
/**
* Attempts to EMP mech that the tracker is attached to, if there is one and tracker is not on cooldown
*/
* Attempts to EMP mech that the tracker is attached to, if there is one and tracker is not on cooldown
*/
/obj/item/mecha_parts/mecha_tracking/proc/shock()
if(recharging)
return
@@ -136,8 +137,8 @@
recharging = TRUE
/**
* Resets recharge variable, allowing tracker to be EMP pulsed again
*/
* Resets recharge variable, allowing tracker to be EMP pulsed again
*/
/obj/item/mecha_parts/mecha_tracking/proc/recharge()
recharging = FALSE