Exports

All exports are for client

SetRadioChannel

Set radio channel

exports["tgiann-radio-v2"]:SetRadioChannel(channel)

Parameters :

Name
Type
Description

channel

string

Channel name or frequency

Example

exports["tgiann-radio-v2"]:SetRadioChannel("PD1")
exports["tgiann-radio-v2"]:SetRadioChannel(2)
exports["tgiann-radio-v2"]:SetRadioChannel("3")
exports["tgiann-radio-v2"]:SetRadioChannel() -- leave all channel
exports["tgiann-radio-v2"]:SetRadioChannel(0) -- leave all channel
exports["tgiann-radio-v2"]:SetRadioChannel("0") -- leave all channel

LeaveAllChannels

Disconnect from all channels to which it is connected

exports["tgiann-radio-v2"]:LeaveAllChannels()

LeaveRadioChannel

Leave a specific channel

exports["tgiann-radio-v2"]:LeaveRadioChannel(channel)

Parameters :

Name
Type
Description

channel

string

Channel

Example

exports["tgiann-radio-v2"]:LeaveRadioChannel("1.00")

ToggleRadioAnim

exports["tgiann-radio-v2"]:ToggleRadioAnim("1.00")

SetDisableRadioAnim

Leave a specific channel

exports["tgiann-radio-v2"]:SetDisableRadioAnim(bool)

Parameters :

Name
Type
Description

bool

Boolen

true or false

Example

exports["tgiann-radio-v2"]:SetDisableRadioAnim(true)
exports["tgiann-radio-v2"]:SetDisableRadioAnim(false)

GetRadioAnimState

returns the state of the radio anim verse

exports["tgiann-radio-v2"]:GetRadioAnimState()

Example

local animIsActive = exports["tgiann-radio-v2"]:GetRadioAnimState()

GetConnectChannels

Returns a list of connected channels

exports["tgiann-radio-v2"]:GetConnectChannels()

Return :

Name
Type
Description

Channel Array

table

Channel frequency

Example

local channelLists = exports["tgiann-radio-v2"]:GetConnectChannels()

IsConnectToChannel

Does the player connect to the frequency?

exports["tgiann-radio-v2"]:IsConnectToChannel(channel)

Return :

Name
Type
Description

isConnected

bool

Returns true if connect to frequency

Parameters :

Name
Type
Description

channel

string

Channel Frequency

Example

local isConnected = exports["tgiann-radio-v2"]:IsConnectToChannel("1.00")

ChannelIsMuted

Returns true if the microphone at the player's frequency is off

exports["tgiann-radio-v2"]:ChannelIsMuted(channel)

Return :

Name
Type
Description

isMuted

bool

Returns true if the microphone at the player's frequency is off

Parameters :

Name
Type
Description

channel

string

Channel Frequency

Example

local isMuted = exports["tgiann-radio-v2"]:ChannelIsMuted("1.00")

SetMutedChannel

Turns off and on the player's microphone on Frequency

exports["tgiann-radio-v2"]:SetMutedChannel(channel, isMuted)

Parameters :

Name
Type
Description

channel

string

Channel Frequency

isMuted

boolen

true or false

Example

exports["tgiann-radio-v2"]:SetMutedChannel("1.00", true)
exports["tgiann-radio-v2"]:SetMutedChannel("1.00", false)

ChannelGetPlayerName

Returns the player's name in frequency

exports["tgiann-radio-v2"]:ChannelGetPlayerName(channel)

Return :

Name
Type
Description

name

bool

Returns the player's name in frequency

Parameters :

Name
Type
Description

channel

string

Channel Frequency

Example

local name = exports["tgiann-radio-v2"]:ChannelGetPlayerName("1.00")

ChannelSetPlayerName

Changes the name of the player on the frequency

exports["tgiann-radio-v2"]:ChannelSetPlayerName(channel, name)

Parameters :

Name
Type
Description

channel

string

Channel Frequency

name

string

New player name

Example

exports["tgiann-radio-v2"]:ChannelSetPlayerName("1.00", "TGIANN")
exports["tgiann-radio-v2"]:ChannelSetPlayerName("1.00", "LUMISAPHY")

Last updated