mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 10:43:20 +00:00
Rewrite examine() to pass a list around
This commit is contained in:
@@ -112,20 +112,17 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
|
||||
return 1
|
||||
|
||||
/obj/structure/particle_accelerator/examine(mob/user)
|
||||
switch(src.construction_state)
|
||||
. = ..()
|
||||
|
||||
switch(construction_state)
|
||||
if(0)
|
||||
src.desc = text("A [name], looks like it's not attached to the flooring")
|
||||
. += "Looks like it's not attached to the flooring."
|
||||
if(1)
|
||||
src.desc = text("A [name], it is missing some cables")
|
||||
. += "It is missing some cables."
|
||||
if(2)
|
||||
src.desc = text("A [name], the panel is open")
|
||||
. += "The panel is open."
|
||||
if(3)
|
||||
src.desc = text("The [name] is assembled")
|
||||
if(powered)
|
||||
src.desc = src.desc_holder
|
||||
..()
|
||||
return
|
||||
|
||||
. += "It is assembled."
|
||||
|
||||
/obj/structure/particle_accelerator/attackby(obj/item/W, mob/user)
|
||||
if(istool(W))
|
||||
@@ -295,19 +292,17 @@ So, hopefully this is helpful if any more icons are to be added/changed/wonderin
|
||||
return
|
||||
|
||||
/obj/machinery/particle_accelerator/examine(mob/user)
|
||||
switch(src.construction_state)
|
||||
. = ..()
|
||||
|
||||
switch(construction_state)
|
||||
if(0)
|
||||
src.desc = text("A [name], looks like it's not attached to the flooring")
|
||||
. += "Looks like it's not attached to the flooring."
|
||||
if(1)
|
||||
src.desc = text("A [name], it is missing some cables")
|
||||
. += "It is missing some cables."
|
||||
if(2)
|
||||
src.desc = text("A [name], the panel is open")
|
||||
. += "The panel is open."
|
||||
if(3)
|
||||
src.desc = text("The [name] is assembled")
|
||||
if(powered)
|
||||
src.desc = src.desc_holder
|
||||
..()
|
||||
return
|
||||
. += "It is assembled."
|
||||
|
||||
|
||||
/obj/machinery/particle_accelerator/attackby(obj/item/W, mob/user)
|
||||
|
||||
@@ -37,11 +37,11 @@
|
||||
..()
|
||||
|
||||
/obj/machinery/particle_smasher/examine(mob/user)
|
||||
..()
|
||||
if(user in view(1))
|
||||
to_chat(user, "<span class='notice'>\The [src] contains:</span>")
|
||||
. = ..()
|
||||
if(Adjacent(user))
|
||||
. += "<span class='notice'>\The [src] contains:</span>"
|
||||
for(var/obj/item/I in contents)
|
||||
to_chat(user, "<span class='notice'>\the [I]</span>")
|
||||
. += "<span class='notice'>\the [I]</span>"
|
||||
|
||||
/obj/machinery/particle_smasher/attackby(obj/item/W as obj, mob/user as mob)
|
||||
if(W.type == /obj/item/device/analyzer)
|
||||
|
||||
Reference in New Issue
Block a user