Closed ghost closed 11 years ago
are you trying to find anything in particular? some things in the non speak functions belong to more than one thing... the best way would probably to be to look at a command or something that you want to work with, then do a ctrl f and search for the variable name which will lead you to everything that belongs to that feature
i guess i can label the global variables at the top of the script though if you think that would help?
it would help and I was looking for the code block for the feature, Vote Skipping.
do you have a specific question about it? or do you want to know in general how it works? im labeling the globals right now btw
I want to know how it works.
alright i added comments about /skip to script on github if you wanna look at it, not going to go to that level of detail over everything....
however i can tell you its general behavior
it also resets the global checkVotes array, every song as well as the votes remaing and current votes, to make sure that the totals are correct. you can find that in the 'newsong' event. it does not reset "HowManyVotesToSkip" because that represents the total amount of votes that a moderator has set as the voting threshold for a song to be skipped. that should always remain constant, otherwise you would need to manually reset it every song....
the amount of votes needed to skip a song is set by the /voteskipon command dynamically as the bot is running, or statically in the setup section of the bot at the top, if its set in one place you do not have to set it in the other....
cool
To help me find what code belongs to which feature, can you label the blocks of code with a description saying that code block belongs to that feature/function of the chillybot.