Question

Need help with SmartFoxServer? You didn't find an answer in our documentation? Please, post your questions here!

Moderators: Lapo, Bax

User avatar
mistermind
Posts: 131
Joined: 15 Sep 2007, 01:33
Contact:

Question

Postby mistermind » 06 Nov 2007, 01:06

Hey there guys
My question is pretty simple actually :)
Is it possible on SFS Basic to schedule an automated Zone Message lets say every day at xx:xx?
I never really got a hold of SFS Pro, but I'm pretty sure its possible on it. Just don't know about SFS Basic.
If not, my plan to "bypass" this would probably be setting up an internal client clock that synchronizes with the server time every time an user logs in, then at the right time it would send the message, but that would require me to update the client engine and would most likely desynchronize in some clients, so a global zone msg would be very handy :)
The reason I want this is because I'm intending to schedule a daily server boot for backups and auto-repairs, since the server is not being able to handle the massive data in MySQL =P
poppop
Posts: 57
Joined: 07 Jul 2007, 10:24

Postby poppop » 06 Nov 2007, 08:33

Hi mistermind,

I'm not sure about basic, but in pro -- it's REALLY easy.

You would simply make a timer, when your custom extension loads, you would have this:

Code: Select all

var simpleTest = setInterval(displayMessage, 1440000);
// Every 24hrs

function displayMessage(){

// Do whatever
}


hopefully this gives you an idea. :?:

There is a clearer example in the docs here:

http://www.smartfoxserver.com/docs/docP ... terval.htm


Cheers

Return to “SmartFoxServer 1.x Discussions and Help”

Who is online

Users browsing this forum: No registered users and 16 guests