byond - Modules - TypesProc Details

/datum/nanomanager

Procs

NewCreate a new nanomanager instance. This proc generates a list of assets which are to be sent to each client on connect
close_user_uisClose /nanoui uis belonging to user
get_open_uiGet an open /nanoui ui for the current user, src_object and ui_key
try_update_uiGet an open /nanoui ui for the current user, src_object and ui_key and try to update it with data
ui_closedRemove a /nanoui ui from the list of open uis This is called by the /nanoui close() proc
ui_openedAdd a /nanoui ui to the list of open uis This is called by the /nanoui open() proc
update_uisUpdate all /nanoui uis attached to src_object
update_user_uisUpdate /nanoui uis belonging to user
user_logoutThis is called on user logout Closes/clears all uis attached to the user's /mob
user_transferredThis is called when a player transfers from one mob to another Transfers all open UIs to the new mob

Proc Details

New

Create a new nanomanager instance. This proc generates a list of assets which are to be sent to each client on connect

@return /nanomanager new nanomanager object

close_user_uis

Close /nanoui uis belonging to user

@param user /mob The mob who owns the uis @param src_object /obj|/mob If src_object is provided, only close uis which are attached to src_object (optional) @param ui_key string If ui_key is provided, only close uis with a matching ui_key (optional)

@return int The number of uis closed

get_open_ui

Get an open /nanoui ui for the current user, src_object and ui_key

@param user /mob The mob who opened/owns the ui @param src_object /obj|/mob The obj or mob which the ui belongs to @param ui_key string A string key used for the ui

@return /nanoui Returns the found ui, or null if none exists

try_update_ui

Get an open /nanoui ui for the current user, src_object and ui_key and try to update it with data

@param user /mob The mob who opened/owns the ui @param src_object /obj|/mob The obj or mob which the ui belongs to @param ui_key string A string key used for the ui @param ui /datum/nanoui An existing instance of the ui (can be null) @param data list The data to be passed to the ui, if it exists @param force_open boolean The ui is being forced to (re)open, so close ui if it exists (instead of updating)

@return /nanoui Returns the found ui, for null if none exists

ui_closed

Remove a /nanoui ui from the list of open uis This is called by the /nanoui close() proc

@param ui /nanoui The ui to remove

@return int 0 if no ui was removed, 1 if removed successfully

ui_opened

Add a /nanoui ui to the list of open uis This is called by the /nanoui open() proc

@param ui /nanoui The ui to add

@return nothing

update_uis

Update all /nanoui uis attached to src_object

@param src_object /obj|/mob The obj or mob which the uis are attached to

@return int The number of uis updated

update_user_uis

Update /nanoui uis belonging to user

@param user /mob The mob who owns the uis @param src_object /obj|/mob If src_object is provided, only update uis which are attached to src_object (optional) @param ui_key string If ui_key is provided, only update uis with a matching ui_key (optional)

@return int The number of uis updated

user_logout

This is called on user logout Closes/clears all uis attached to the user's /mob

@param user /mob The user's mob

@return nothing

user_transferred

This is called when a player transfers from one mob to another Transfers all open UIs to the new mob

@param oldMob /mob The user's old mob @param newMob /mob The user's new mob

@return nothing