mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-07-22 05:25:15 +01:00
Boards now show their required components on examine (#39640)
Why: QoL, so you don't have to look it up or build the machine first and go back for parts
This commit is contained in:
@@ -54,3 +54,14 @@ micro-manipulator, console screen, beaker, Microlaser, matter bin, power cells.
|
||||
M.component_parts += new comp_path(null)
|
||||
|
||||
M.RefreshParts()
|
||||
|
||||
/obj/item/circuitboard/machine/examine(mob/user)
|
||||
..()
|
||||
if(LAZYLEN(req_components))
|
||||
var/list/nice_list = list()
|
||||
for(var/B in req_components)
|
||||
var/atom/A = B
|
||||
if(!ispath(A))
|
||||
continue
|
||||
nice_list += list("[req_components[A]] [initial(A.name)]")
|
||||
to_chat(user,"<span class='notice'>Required components: [english_list(nice_list)].</span>")
|
||||
|
||||
Reference in New Issue
Block a user