Skip to main content

SocialTablet

A class in Root.Township, the global namespace.

The social tablet item a player summons to see recent players and friend, mute, report or ban them. Not saved; only its owner can grab it.

Constructors​

MemberWhat it is
SocialTablet()Unity makes components itself; use AddComponent or spawn a prefab instead of new.

Fields​

3 private and internal fields
MemberWhat it is
private HoverPickup hoverPickupHover pickup used to hold the tablet in the air.
private TouchScreenMenuBase touchScreenThe tablet's touch screen menu.
private Window windowThe UI window shown on the tablet.

Methods​

MemberWhat it is
protected override void FinishFadeIn()After fading in, starts the screen for the owner, or waits for the owner to be known.
protected override void StartFade(bool isFadingIn)When fading out, turns off the touch screen and stops the window.
5 private and internal methods
MemberWhat it is
private void Awake()Marks the tablet not to be saved, limits grabs to the owner and sets up the recent player page's sync.
private void CheckOwnership(IPlayer owner)Waits for the owner message, then starts the screen if the local player owns it.
private void FilterForOwner(Interactor interactor, Interactable interactable, ref bool result)Interaction filter that only lets the owning user grab the tablet.
private void Hover(Interactable interactable, Interactor interactor)When let go, sets the hover pickup to float it back to this spot if nothing else grabbed it.
private void StartupForLocalPlayer()Sets up the touch screen and starts the window.

Used in​

Members of other types that take, return or hold a SocialTablet: