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.
Now I have yet another problem, I do not have a clue how to check if the db entry already exists.
I did this code but unfortunately it doesn't work as expected.
if (dbc) dbc.query('SELECT * FROM czas WHERE uid = (?)', Uid, function(err, res) {
if (!err) {
var exists = res.forEach(function(row)...
I want to use client.getOnlineTime(). but also I have to run the script every x time again to update the DB right?
I thought the sinus script runs on event and if there isn't an firing event e.g( event.on('client.move',) ) cuz that seems impractical for me, sometimes client dont actually that...
My main goal is to create TS3 DB Ranks, my main concept is to make the script refresh every x interval and add the time difference to the overall time spent in DB, then assign a server group to the client based on how many hrs he spent on srv.
Im just giving the raw example from official sinusbot docs, and yes I know I about the '.
No output, it should say hello to my every client on ts3 but meanwhile it doesnt my full code is:
registerPlugin({
name: 'DB Ranks',
version: '2.0',
description: 'This plugin will let the bot...
How do I implement the foreach iteration?
I use the following code but unfortunately doesnt work, any ideas?
<code> // Gets a list of all clients and sends them a message
var backend = require('backend');
var clients = backend.getClients();
clients.forEach(function(client) {...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.