now (1.4.19) you can take the que number and more from my api here.

Before starting

the first thing you need to know this isnt good for staft you need to have a idea of how to code. the next thing you need is: javascript IDE & knowledge at discord.js. Helpful site: JavaScript Tutorials discord.js docs (aka where to learn discord.js). Basic idea of the api Bonus: host your bot 24/7(make sure you set it up as private project) aplace to ask "what the bug here"

Part 1: Create a Bot

create a bot: Before anything you need to get your own bot token. go to Discord developers and log-in and make a bot. after that inside the bot settings go to "Bot" and click "Add Bot". in there you can change and add staff as you like. the importent staff in there is your Token copy it and make sure no one else have it keep it a secret.

Part 2: Code

first thing first you need to get the players useing an api. there a lot of api for minecraft but the one we gonna use is mcapi. in your code add a request for the 2b2t api and then get the number of players online and print it out useing discord. message.channel.send(body. players. online);

Part 3: Math

But how you get the que you ask? MATH MATH MATH MATH MATH, yea i hate math but its easy dont warry. lets say we know when the server got 340 players on in totall only 55% are actually in game and everyone else at que. so we do body. players. online * 55 /100 = players in que . how we get the 55% ? we need to coollect data. every time you login see how many players are on in totall and how much in the que and then start the guess game do {players in totall} * {random %(need to be a number)} / 100 and the result need to be the que and that is your %. the next part you need to know is the que is different when the players count is bigger or smaller for exemple if when there 340 the prcent is 55 it wont be like it when there 500 players so you need to run an "if" like this if (ppl <= 100) { prcent = 0; } else if (ppl <= 200) { prcent = 40; } and then do the math like this var result =~~ (body. players .online * prcent / 100); to get the que.

Part 4: After Word

this is all the basic of it , that hopefuly gave you an idea of how you can make the bot and add more into it. if you got anything to ask my discord is THE pumpkin GOD#9441 feel free to msg me. cya