Jump to content

.

Ocelot4894

I'm not entirely sure what you're trying to achieve here.  Do you want to send a message every 10 seconds if it is started or not?

 

Also, there are a few problems with this code.  It seems like the 'Started' variable would be much better suited to the boolean type.  Despite the fact you've used it correctly on a previous line,   console.log = 'no';    will effectively delete the console.log() method.

 

 

Link to comment
Share on other sites

Link to post
Share on other sites

Just now, Souffle said:

I'm not entirely sure what you're trying to achieve here.  Do you want to send a message every 10 seconds if it is started or not?

 

Also, there are a few problems with this code.  It seems like the 'Started' variable would be much better suited to the boolean type.  Despite the fact you've used it correctly on a previous line,   console.log = 'no';    will effectively delete the console.log() method.

 

 

ah ok i figured it out i removed the var for var started donw on the bottom  and added the if (started === "yes"){  before channel.send

Link to comment
Share on other sites

Link to post
Share on other sites

31 minutes ago, Clawkikker said:

Also anyone know in a variable how to detect in a variable like if i want to detect if a var is anywhere from 50-59, can i just detect 5_ and aslong as the numbe is 50 something then it will detect

if (x >= 50 && x <= 59) {
  // do something
}
Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×