• If you need help or want to discuss things, you now can also join us on our Discord Server!
  • A first preview of the unlimited version of SinusBot can be found in the Upcoming Changes thread. A version for Windows will follow, but we don't have a release date, yet.

EN Script doesnt work

Status
Not open for further replies.
Hey,

is someone able to say, why this script isnt working?
Code:
registerPlugin({
    name: 'Channel Editor',
    version: '1.0',
    description: 'This plugin will change the Name of the Channel, if the channel maxclient is reached.',
    author: 'Michael Friese <[email protected]>',
    vars: {
        message: {
            title: 'The channel, that should be renamed.',
            type: 'string'
        },
        {
            name: 'ChannelName',
            title: "The normal Channel Name",
            type: 'strings'
        },
        {
            name: 'ChannelRename',
            title: "The renamed Channel Name",
            type: 'strings'
        },
        type: {
            title: 'Message-Type',
            type: 'select',
            options: [
                'Private chat',
                'Poke'
            ]
        }
    }
}, function(sinusbot, config) {
    sinusbot.on('clientMove', function(ev) {
        var msg = config.message;
        msg = msg.replace(/%n/g, ev.clientNick);
        if (maxClients(): number == 4) {
            if (setName(name: string) {
            }
            return;
        }
    });
});
 
Status
Not open for further replies.
Top