Skip to content

five-on-it / apps/client/src/renderer/social / SocialActions

Interface: SocialActions ​

Defined in: apps/client/src/renderer/social.ts:118

What the player does with the social side.

Extended by ​

Methods ​

answerLobby() ​

answerLobby(go): Promise<void>

Defined in: apps/client/src/renderer/social.ts:152

Answers the lobby the party's leader took the player into: go to its page, or stay (leaving it).

Parameters ​

go ​

boolean

Returns ​

Promise<void>


befriend() ​

befriend(name, id?): Promise<void>

Defined in: apps/client/src/renderer/social.ts:138

Asks an account to be friends by its name, or accepts its request.

Parameters ​

name ​

string

id? ​

string

Returns ​

Promise<void>


createParty() ​

createParty(): Promise<void>

Defined in: apps/client/src/renderer/social.ts:142

Starts a party, invites a friend to it, joins one, declines, leaves.

Returns ​

Promise<void>


declineParty() ​

declineParty(party): Promise<void>

Defined in: apps/client/src/renderer/social.ts:145

Parameters ​

party ​

string

Returns ​

Promise<void>


emote() ​

emote(emote): void

Defined in: apps/client/src/renderer/social.ts:127

Parameters ​

emote ​

"wave" | "laugh" | "shrug" | "facepalm" | "clap" | "thumbsUp"

Returns ​

void


invite() ​

invite(account): Promise<void>

Defined in: apps/client/src/renderer/social.ts:143

Parameters ​

account ​

string

Returns ​

Promise<void>


joinParty() ​

joinParty(party): Promise<void>

Defined in: apps/client/src/renderer/social.ts:144

Parameters ​

party ​

string

Returns ​

Promise<void>


joinRoom() ​

joinRoom(room): Promise<void>

Defined in: apps/client/src/renderer/social.ts:148

Joins a friend's room (the party along, when the player leads one).

Parameters ​

room ​

string

Returns ​

Promise<void>


leaveParty() ​

leaveParty(): Promise<void>

Defined in: apps/client/src/renderer/social.ts:146

Returns ​

Promise<void>


mute() ​

mute(player, on): void

Defined in: apps/client/src/renderer/social.ts:132

Mutes a player (their lines hidden from the reader everywhere), or not any more.

Parameters ​

player ​
account? ​

string = ...

Their account on the platform, when they joined with a join token.

id ​

number = ...

Their client id.

name ​

string = ...

Their name.

party ​

number = ...

Their party in the room (0 for none): party members share their missions.

on ​

boolean

Returns ​

void


openChat() ​

openChat(open): void

Defined in: apps/client/src/renderer/social.ts:120

Opens the chat for typing (Enter), or closes it (Esc).

Parameters ​

open ​

boolean

Returns ​

void


openLobby() ​

openLobby(lobby): void

Defined in: apps/client/src/renderer/social.ts:150

Goes to a lobby's page.

Parameters ​

lobby ​

string

Returns ​

void


quick() ​

quick(phrase): void

Defined in: apps/client/src/renderer/social.ts:126

A quick-chat phrase, an emote, on the room's channel.

Parameters ​

phrase ​

"wait" | "follow" | "go" | "hello" | "thanks" | "sorry" | "help" | "nice"

Returns ​

void


refresh() ​

refresh(): Promise<void>

Defined in: apps/client/src/renderer/social.ts:136

Asks the platform again: friends, the party, the invitations (starting the feed).

Returns ​

Promise<void>


report() ​

report(player, reason): Promise<void>

Defined in: apps/client/src/renderer/social.ts:134

Reports a player of the room to the moderators.

Parameters ​

player ​
account? ​

string = ...

Their account on the platform, when they joined with a join token.

id ​

number = ...

Their client id.

name ​

string = ...

Their name.

party ​

number = ...

Their party in the room (0 for none): party members share their missions.

reason ​

"offensive" | "real-people" | "sexual" | "broken" | "spam" | "other"

Returns ​

Promise<void>


say() ​

say(text): void

Defined in: apps/client/src/renderer/social.ts:124

Says a line on a channel.

Parameters ​

text ​

string

Returns ​

void


setChannel() ​

setChannel(channel): void

Defined in: apps/client/src/renderer/social.ts:122

The channel a line is typed on.

Parameters ​

channel ​

ChatChannel

Returns ​

void


unfriend() ​

unfriend(id): Promise<void>

Defined in: apps/client/src/renderer/social.ts:140

Removes a friend, cancels or declines a request.

Parameters ​

id ​

string

Returns ​

Promise<void>


vote() ​

vote(yes): void

Defined in: apps/client/src/renderer/social.ts:130

Parameters ​

yes ​

boolean

Returns ​

void


voteKick() ​

voteKick(client): void

Defined in: apps/client/src/renderer/social.ts:129

Starts a vote to kick a player of the room; votes on the one under way.

Parameters ​

client ​

number

Returns ​

void