C4undBIER
Member
Hello,
i want to build a script, where you can choose which groups are getting kicked out of a specified channel because teamspeaks rights system with join power and max users in a channel is enough for 2, not for more. and i need more.
Maybe i am too dumb to use the docs or dont understand javascript right. i tested what i thought was right without the group part. Here's what i came up with:
registerPlugin({
name: 'AdminChannel',
version: '0,1',
description: 'moves clients to old channel when not in a server group',
author: 'C4undBIER',
vars: {
Channels: {
title: 'Channels',
type: 'array',
vars: [
{
name: 'channel1',
indent: 1,
title: 'Channel',
type: 'channel'
},
{
name: 'group1',
indent: 1,
title: 'Group1, that is allowed to join and will not get kicked',
type: 'string',
}
}
}
function (sinusbot, config)
{
sinusbot.on('clientMove', function(ev){
if (channel1 == ev.client.getChannels())
getServerGroups(): Array<ServerGroup>
if (channel1 in Array)
move(ev.clientId, ev.oldChannel);
}
}
it doesn't even show up in the scripts.
someone has an idea what i am doing wrong or which script already does what i want to do and i didn't find while i googled?
Thanks in advance
i want to build a script, where you can choose which groups are getting kicked out of a specified channel because teamspeaks rights system with join power and max users in a channel is enough for 2, not for more. and i need more.
Maybe i am too dumb to use the docs or dont understand javascript right. i tested what i thought was right without the group part. Here's what i came up with:
registerPlugin({
name: 'AdminChannel',
version: '0,1',
description: 'moves clients to old channel when not in a server group',
author: 'C4undBIER',
vars: {
Channels: {
title: 'Channels',
type: 'array',
vars: [
{
name: 'channel1',
indent: 1,
title: 'Channel',
type: 'channel'
},
{
name: 'group1',
indent: 1,
title: 'Group1, that is allowed to join and will not get kicked',
type: 'string',
}
}
}
function (sinusbot, config)
{
sinusbot.on('clientMove', function(ev){
if (channel1 == ev.client.getChannels())
getServerGroups(): Array<ServerGroup>
if (channel1 in Array)
move(ev.clientId, ev.oldChannel);
}
}
it doesn't even show up in the scripts.
someone has an idea what i am doing wrong or which script already does what i want to do and i didn't find while i googled?
Thanks in advance