Skip to content

Commit

Permalink
Add ChatManager yell commands and player-specific variants
Browse files Browse the repository at this point in the history
  • Loading branch information
OrfeasZ committed May 30, 2020
1 parent 46eddf0 commit ffcd00c
Show file tree
Hide file tree
Showing 2 changed files with 219 additions and 3 deletions.
137 changes: 134 additions & 3 deletions content/vext/ref/server/library/chatmanager.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,13 @@ title: ChatManager
| **[SendMessage](#sendmessage)**(message: string) | bool |
| **[SendMessage](#sendmessage-1)**(message: string, toTeam: [TeamId](/vext/ref/fb/teamid)) | bool |
| **[SendMessage](#sendmessage-2)**(message: string, toTeam: [TeamId](/vext/ref/fb/teamid), toSquad: [SquadId](/vext/ref/fb/squadid)) | bool |
| **[SendMessage](#sendmessage-3)**(message: string, toPlayer: [Player](/vext/ref/server/type/player)) | bool |
| **[SendMessage](#sendmessage-4)**(message: string, toPlayers: [Player](/vext/ref/server/type/player){}) | bool |
| **[Yell](#yell)**(message: string, duration: float) | bool |
| **[Yell](#yell-1)**(message: string, duration: float, toTeam: [TeamId](/vext/ref/fb/teamid)) | bool |
| **[Yell](#yell-2)**(message: string, duration: float, toTeam: [TeamId](/vext/ref/fb/teamid), toSquad: [SquadId](/vext/ref/fb/squadid)) | bool |
| **[Yell](#yell-3)**(message: string, duration: float, toPlayer: [Player](/vext/ref/server/type/player)) | bool |
| **[Yell](#yell-4)**(message: string, duration: float, toPlayers: [Player](/vext/ref/server/type/player){}) | bool |

## Methods

Expand All @@ -22,7 +29,7 @@ title: ChatManager

| Name | Type | Description |
| ---- | ---- | ----------- |
| **message** | string | |
| **message** | string | Text message to send. Limited to 127 characters. |

#### Returns

Expand All @@ -44,7 +51,7 @@ ChatManager:SendMessage('Hello players!')

| Name | Type | Description |
| ---- | ---- | ----------- |
| **message** | string | |
| **message** | string | Text message to send. Limited to 127 characters. |
| **toTeam** | [TeamId](/vext/ref/fb/teamid) | |

#### Returns
Expand All @@ -67,7 +74,7 @@ ChatManager:SendMessage('Hello Team 1 players!', TeamId.Team1)

| Name | Type | Description |
| ---- | ---- | ----------- |
| **message** | string | |
| **message** | string | Text message to send. Limited to 127 characters. |
| **toTeam** | [TeamId](/vext/ref/fb/teamid) | |
| **toSquad** | [SquadId](/vext/ref/fb/squadid) | |

Expand All @@ -77,3 +84,127 @@ ChatManager:SendMessage('Hello Team 1 players!', TeamId.Team1)
| ---- | ----------- |
| **bool** | |

### SendMessage {#sendmessage-3}

> **SendMessage**(message: string, toPlayer: [Player](/vext/ref/server/type/player)): bool
#### Parameters

| Name | Type | Description |
| ---- | ---- | ----------- |
| **message** | string | Text message to send. Limited to 127 characters. |
| **toPlayer** | [Player](/vext/ref/server/type/player) | |

#### Returns

| Type | Description |
| ---- | ----------- |
| **bool** | |

### SendMessage {#sendmessage-4}

> **SendMessage**(message: string, toPlayers: [Player](/vext/ref/server/type/player){}): bool
#### Parameters

| Name | Type | Description |
| ---- | ---- | ----------- |
| **message** | string | Text message to send. Limited to 127 characters. |
| **toPlayers** | [Player](/vext/ref/server/type/player){} | |

#### Returns

| Type | Description |
| ---- | ----------- |
| **bool** | |

### Yell {#yell}

> **Yell**(message: string, duration: float): bool
#### Parameters

| Name | Type | Description |
| ---- | ---- | ----------- |
| **message** | string | Text message to send. Limited to 255 characters. |
| **duration** | float | |

#### Returns

| Type | Description |
| ---- | ----------- |
| **bool** | |

### Yell {#yell-1}

> **Yell**(message: string, duration: float, toTeam: [TeamId](/vext/ref/fb/teamid)): bool
#### Parameters

| Name | Type | Description |
| ---- | ---- | ----------- |
| **message** | string | Text message to send. Limited to 255 characters. |
| **duration** | float | |
| **toTeam** | [TeamId](/vext/ref/fb/teamid) | |

#### Returns

| Type | Description |
| ---- | ----------- |
| **bool** | |

### Yell {#yell-2}

> **Yell**(message: string, duration: float, toTeam: [TeamId](/vext/ref/fb/teamid), toSquad: [SquadId](/vext/ref/fb/squadid)): bool
#### Parameters

| Name | Type | Description |
| ---- | ---- | ----------- |
| **message** | string | Text message to send. Limited to 255 characters. |
| **duration** | float | |
| **toTeam** | [TeamId](/vext/ref/fb/teamid) | |
| **toSquad** | [SquadId](/vext/ref/fb/squadid) | |

#### Returns

| Type | Description |
| ---- | ----------- |
| **bool** | |

### Yell {#yell-3}

> **Yell**(message: string, duration: float, toPlayer: [Player](/vext/ref/server/type/player)): bool
#### Parameters

| Name | Type | Description |
| ---- | ---- | ----------- |
| **message** | string | Text message to send. Limited to 255 characters. |
| **duration** | float | |
| **toPlayer** | [Player](/vext/ref/server/type/player) | |

#### Returns

| Type | Description |
| ---- | ----------- |
| **bool** | |

### Yell {#yell-4}

> **Yell**(message: string, duration: float, toPlayers: [Player](/vext/ref/server/type/player){}): bool
#### Parameters

| Name | Type | Description |
| ---- | ---- | ----------- |
| **message** | string | Text message to send. Limited to 255 characters. |
| **duration** | float | |
| **toPlayers** | [Player](/vext/ref/server/type/player){} | |

#### Returns

| Type | Description |
| ---- | ----------- |
| **bool** | |

85 changes: 85 additions & 0 deletions types/server/library/ChatManager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ methods:
params:
message:
type: string
description: Text message to send. Limited to 127 characters.
returns:
type: bool
example: |
Expand All @@ -16,6 +17,7 @@ methods:
params:
message:
type: string
description: Text message to send. Limited to 127 characters.
toTeam:
type: TeamId
returns:
Expand All @@ -27,9 +29,92 @@ methods:
params:
message:
type: string
description: Text message to send. Limited to 127 characters.
toTeam:
type: TeamId
toSquad:
type: SquadId
returns:
type: bool
-
name: SendMessage
params:
message:
type: string
description: Text message to send. Limited to 127 characters.
toPlayer:
type: Player
returns:
type: bool
-
name: SendMessage
params:
message:
type: string
description: Text message to send. Limited to 127 characters.
toPlayers:
type: Player
table: true
returns:
type: bool
-
name: Yell
params:
message:
type: string
description: Text message to send. Limited to 255 characters.
duration:
type: float
returns:
type: bool
-
name: Yell
params:
message:
type: string
description: Text message to send. Limited to 255 characters.
duration:
type: float
toTeam:
type: TeamId
returns:
type: bool
-
name: Yell
params:
message:
type: string
description: Text message to send. Limited to 255 characters.
duration:
type: float
toTeam:
type: TeamId
toSquad:
type: SquadId
returns:
type: bool
-
name: Yell
params:
message:
type: string
description: Text message to send. Limited to 255 characters.
duration:
type: float
toPlayer:
type: Player
returns:
type: bool
-
name: Yell
params:
message:
type: string
description: Text message to send. Limited to 255 characters.
duration:
type: float
toPlayers:
type: Player
table: true
returns:
type: bool

0 comments on commit ffcd00c

Please sign in to comment.