tgui

Procs | |
close_all_uis | private |
---|---|
close_uis | private |
close_user_uis | private |
get_open_ui | private |
get_open_ui_count | Gets the amount of open UIs on an object Returns the number of UIs open. |
on_close | private |
on_logout | private |
on_open | private |
on_transfer | private |
try_update_ui | public |
update_uis | private |
update_user_uis | private |
Proc Details
close_all_uis
private
Close ALL UIs Returns the number of UIs closed.
close_uis
private
Close all UIs attached to src_object. Returns the number of UIs closed.
- datum/src_object - The object/datum which owns the UIs.
close_user_uis
private
Close all UIs belonging to a user. Returns the number of UIs closed.
- mob/user - The mob who opened/is using the UI. (REQUIRED)
- datum/src_object - If provided, only close UIs belonging this src_object. (OPTIONAL)
- ui_key - If provided, only close UIs with this UI key. (OPTIONAL)
get_open_ui
private
Get an open UI given a user, src_object, and ui_key. Returns the found UI.
- mob/user - The mob who opened/is using the UI. (REQUIRED)
- datum/src_object - The object/datum which owns the UI. (REQUIRED)
- ui_key - The ui_key of the UI. (REQUIRED)
get_open_ui_count
Gets the amount of open UIs on an object Returns the number of UIs open.
- datum/src_object - The object/datum which owns the UIs.
on_close
private
Remove a UI from the list of open UIs. Returns TRUE if removed, and FALSE if not.
- datum/tgui/ui - The UI to be removed.
on_logout
private
Handle client logout, by closing all their UIs. Returns the number of UIs closed.
- mob/user - The mob which logged out.
on_open
private
Add a UI to the list of open UIs.
- datum/tgui/ui - The UI to be added.
on_transfer
private
Handle clients switching mobs, by transferring their UIs. Returns TRUE if the UIs were transferred, and FALSE if not.
- mob/source - The client's original mob.
- mob/target - The client's new mob.
try_update_ui
public
Get an open UI given a user, src_object, and ui_key and try to update it with data. Returns the found UI.
- mob/user - The mob who opened/is using the UI. (REQUIRED)
- datum/src_object - The object/datum which owns the UI. (REQUIRED)
- ui_key - The ui_key of the UI. (REQUIRED)
- datum/tgui/ui - The UI to be updated, if it exists. (OPTIONAL)
- force_open - If the UI should be re-opened instead of updated. (OPTIONAL)
update_uis
private
Update all UIs attached to src_object. Returns the number of UIs updated.
- datum/src_object - The object/datum which owns the UIs.
- update_static_data - If the static data of the
src_object
should be updated for every viewing user.
update_user_uis
private
Update all UIs belonging to a user. Returns the number of UIs updated.
- mob/user - The mob who opened/is using the UI. (REQUIRED)
- datum/src_object - If provided, only update UIs belonging this src_object. (OPTIONAL)
- ui_key - If provided, only update UIs with this UI key. (OPTIONAL)