tropicbliss / buckshot

A fast and capable Minecraft name sniper.
MIT License
25 stars 3 forks source link

Droptimes are incorrect #8

Closed etz closed 3 years ago

etz commented 3 years ago

Droptimes are either improperly calculated or are getting bad information from API. To reproduce the issue:

  1. Add an upcoming username to name_queue
  2. Load the sniper
  3. Compare time to snipe between NameMC and buckshot.

Names that are upcoming to claim on NameMC (few hours to drop) are already 'claimed' when attempting to setup buckshot.

Here is an example from the console log:

root@enoutlook:~/buckshot$ ./buckshot-linux-amd64 
______ _   _ _____  _   __ _____ _   _ _____ _____ 
| ___ \ | | /  __ \| | / //  ___| | | |  _  |_   _|
| |_/ / | | | /  \/| |/ / \ `--.| |_| | | | | | |  
| ___ \ | | | |    |    \  `--. \  _  | | | | | |  
| |_/ / |_| | \__/\| |\  \/\__/ / | | \ \_/ / | |  
\____/ \___/ \____/\_| \_/\____/\_| |_/\___/  \_/  

Developed by @tropicbliss#0027 on Discord.

Initialising...
Enter your gift code (press ENTER if you have already redeemed your gift code): 
Measuring offset...
Your offset is: -18 ms.
Sniping Purpel in ~-26982 seconds | sniping at 2021-07-17 08:56:11 (utc).
Signed in to my_email@address.com successfully.
Error: [SnipeGc] The name Purpel has already dropped.
Error: [SnipeGc] The name Purpel has already dropped.
Error: [SnipeGc] The name Purpel has already dropped.
Error: [SnipeGc] The name Purpel has already dropped.
Error: [SnipeGc] The name Purpel has already dropped.
Error: [SnipeGc] The name Purpel has already dropped.
Moving on to next name...

(The username is not claimable for another 3.25 hours, according to NameMC at time of posting)

etz commented 3 years ago

After some investigation, it appears droptimes from https://drops.peet.ws (found in constants for the NameMC_API) are incorrect, which matches the data found in the log.

From https://drops.peet.ws/droptime?name=Purpel - {"name":"Purpel","UNIX":1626512171,"searches":163,"updated":1626171432,"message":"'PiratSnipe on top!' -everyone"}

1626512171 converts to 2021-07-17 08:56:11 UTC, which matches buckshot. NameMC says the name is available at 1626551457 which is 2021-07-17 19:50:57 UTC.

So, unfortunately the API currently used is providing incorrect information and the bot will not be able to make snipes.

tropicbliss commented 3 years ago

Ah, I see. Well thanks for the testing, I'll try to ask peet bout that tmr.

tropicbliss commented 3 years ago

Changed api to one that mcsniperpy uses. Issue should be fixed. Get newest version.