Jump to content
UBot Underground

Recommended Posts

First make a custom command:

define MyCommand {
    alert("hi")
}

Then go to View -> Scheduler and double click on a time and date box.

 

Then under Event choose the command you want to run an d then the time, tick on Repeat and choose the frequency.

 

Then press the "Run On Schedule" button.

 

Now when you go to compile this bot, under the General options there is a section called "Schedualable Commands" and be sure to check the box next to the command you want to allow scheduling for. Then in the compiled bot you can do the same thing.

Link to post
Share on other sites

First make a custom command:

define MyCommand {
    alert("hi")
}

Then go to View -> Scheduler and double click on a time and date box.

 

Then under Event choose the command you want to run an d then the time, tick on Repeat and choose the frequency.

 

Then press the "Run On Schedule" button.

 

Now when you go to compile this bot, under the General options there is a section called "Schedualable Commands" and be sure to check the box next to the command you want to allow scheduling for. Then in the compiled bot you can do the same thing.

 

I got that part going but it only asks you for a starting period.  Then it runs every hour from that starting period.  I want it to run every hour from start time to end time.

Link to post
Share on other sites

I got that part going but it only asks you for a starting period.  Then it runs every hour from that starting period.  I want it to run every hour from start time to end time.

 

You could just check the time and say if its between these times then call another command, and if not then don't do anything.

Edit: something like this:

define CheckTime {
    set(#hour,$plugin function("DateTime Manipulation.dll", "$datetime manipulation", $date, "UBOT", "HH", "en-US", "en-US"),"Global")
    if($both($comparison(#hour,">= Greater than or equal to",8),$comparison(#hour,"<= Less than or equal to",18))) {
        then {
            MyCommand()
        }
        else {
        }
    }
}
  • Like 1
Link to post
Share on other sites

 

You could just check the time and say if its between these times then call another command, and if not then don't do anything.

Edit: something like this:

define CheckTime {
    set(#hour,$plugin function("DateTime Manipulation.dll", "$datetime manipulation", $date, "UBOT", "HH", "en-US", "en-US"),"Global")
    if($both($comparison(#hour,">= Greater than or equal to",8),$comparison(#hour,"<= Less than or equal to",18))) {
        then {
            MyCommand()
        }
        else {
        }
    }
}

Thanks.  Im going to give it a try.

Link to post
Share on other sites

 

You could just check the time and say if its between these times then call another command, and if not then don't do anything.

Edit: something like this:

define CheckTime {
    set(#hour,$plugin function("DateTime Manipulation.dll", "$datetime manipulation", $date, "UBOT", "HH", "en-US", "en-US"),"Global")
    if($both($comparison(#hour,">= Greater than or equal to",8),$comparison(#hour,"<= Less than or equal to",18))) {
        then {
            MyCommand()
        }
        else {
        }
    }
}

 

Worked like a charm :)

  • Like 1
Link to post
Share on other sites
  • 5 months later...

Hello, when scheduling is on, does the bot need to be open all time?

 

If the bot (complied bot) is closed then its closed.  It doesnt matter what your schedule is.  When you schedule it you also have to hit the run on schedule button.

Link to post
Share on other sites

Hello, when scheduling is on, does the bot need to be open all time?

 

Yes but you can use the Advanced Systems plugin by Pash to interact with Windows task scheduler which can open the bot on schedule so it doesn't need to be open. Alternatively you can just make a task manually and call the /auto parameter to have the bot run after startup automatically.

  • Like 1
Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...