[MIRROR] Converts the first few of our UIs to typescript (#8588)

Co-authored-by: Kashargul <144968721+Kashargul@users.noreply.github.com>
This commit is contained in:
CHOMPStation2
2024-06-28 13:05:53 -07:00
committed by GitHub
parent 7ee8e61b76
commit be4aeefce3
274 changed files with 12200 additions and 8304 deletions

View File

@@ -1289,7 +1289,7 @@
/obj/structure/disposalpipe/tagger/New()
. = ..()
dpdir = dir | turn(dir, 180)
if(sort_tag) GLOB.tagger_locations |= sort_tag
if(sort_tag) GLOB.tagger_locations |= list("[sort_tag]" = get_z(src))
updatename()
updatedesc()
update()
@@ -1355,7 +1355,7 @@
/obj/structure/disposalpipe/sortjunction/New()
. = ..()
if(sortType) GLOB.tagger_locations |= sortType
if(sortType) GLOB.tagger_locations |= list("[sortType]" = get_z(src))
updatedir()
updatename()

View File

@@ -348,11 +348,23 @@
ui = new(user, src, "DestinationTagger", name)
ui.open()
/obj/item/device/destTagger/tgui_static_data(mob/user)
var/list/data = ..()
var/list/taggers = list()
var/list/tagger_levels = list()
for(var/tag in GLOB.tagger_locations)
var/z_level = GLOB.tagger_locations[tag]
taggers += list(list("tag" = tag, "level" = z_level))
tagger_levels += list(list("z" = z_level, "location" = using_map.get_zlevel_name(z_level)))
data["taggerLevels"] = tagger_levels
data["taggerLocs"] = taggers
return data
/obj/item/device/destTagger/tgui_data(mob/user, datum/tgui/ui)
var/list/data = ..()
data["currTag"] = currTag
data["taggerLocs"] = GLOB.tagger_locations
return data