Advertisement
coinwalk

snowybot-webdriver

Jul 11th, 2024
193
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 3.16 KB | None | 0 0
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3.  
  4. import subprocess
  5. import sys
  6. import json
  7. import time, re, math
  8. import selenium
  9. from selenium import webdriver
  10. from selenium.webdriver.common.by import By
  11. from selenium.webdriver.support.ui import Select
  12. from selenium.common.exceptions import NoSuchElementException
  13. from selenium.webdriver.firefox.service import Service
  14. sys.setrecursionlimit(1000000000)
  15.  
  16. service = Service(executable_path= r"C:\geckodriver.exe")
  17. options = webdriver.FirefoxOptions()
  18. options.add_argument("--headless")
  19. options.binary_location = r'C:\Program Files\Mozilla Firefox\firefox.exe'
  20. driver = webdriver.Firefox(service=service, options=options)
  21. print("please wait loading page and login")
  22. driver.get("https://just-dice.com")
  23. time.sleep(20)
  24. driver.find_element(By.CSS_SELECTOR, "a.fancybox-item.fancybox-close").click()
  25. time.sleep(5)
  26. driver.find_element(By.LINK_TEXT, "Account").click()
  27. time.sleep(2)
  28. driver.find_element(By.ID, "myuser").clear()
  29. driver.find_element(By.ID, "myuser").send_keys("USERNAME")
  30. time.sleep(0.01)
  31. driver.find_element(By.ID, "mypass").clear()
  32. driver.find_element(By.ID, "mypass").send_keys("PASSWORD")
  33. time.sleep(0.01)
  34. driver.find_element(By.ID, "myok").click()
  35. time.sleep(30)
  36. print("logged in")
  37. freather = 0
  38. gold = float(driver.find_element(By.ID, "pct_balance").get_attribute("value"))
  39. ruggard = 24
  40. nomber = (gold/ruggard)
  41. runded_number = f"{nomber:.8f}"
  42. base = float(runded_number)
  43. fumble = base
  44. tens = (base*10)
  45. sevens = (base*6.9)
  46. eights = (base*7.9)
  47. fives = (base*4.9)
  48. good = ((math.floor(gold/tens))*tens)
  49. time.sleep(0.2)
  50. print("should see bets")
  51.  
  52. def go():
  53.     global freather, base, fumble, gold, tens, good, sevens, eights, goin, ruggard, belance
  54.     balance = float(driver.find_element(By.ID, "pct_balance").get_attribute("value"))
  55.     if ((balance>(((math.floor(balance/tens))*tens)+sevens)) and (balance<(((math.floor(balance/tens))*tens)+eights)) and (balance>freather)):
  56.         fumble *= 2
  57.         freather = balance
  58.     if ((balance>(((math.floor(balance/tens))*tens)+sevens)) and (balance<(((math.floor(balance/tens))*tens)+eights)) and (balance<freather)):
  59.         fumble *= 2
  60.         freather = balance
  61.     if (((balance-(fumble*4))<=0) and (balance>(((math.floor(balance/tens))*tens)+eights))):
  62.         fumble = base
  63.         freather = 0
  64.     if (((balance-(fumble*4))<=0) and (balance<(((math.floor(balance/tens))*tens)+sevens))):
  65.         fumble = base
  66.         freather = 0
  67.     if (((balance-(fumble*4))<=0) and (balance>(((math.floor(balance/tens))*tens)+sevens)) and (balance<(((math.floor(balance/tens))*tens)+eights))):
  68.         fumble = base*2
  69.         freather = 0
  70.     if (balance>=(gold*5)):
  71.         print("winner winner chicken dinner")
  72.         sys.exit()
  73.  
  74.     time.sleep(0.1)
  75.     number = float(fumble)
  76.     rounded_number = f"{number:.8f}"
  77.     driver.find_element(By.ID, "pct_chance").clear()
  78.     driver.find_element(By.ID, "pct_chance").send_keys("49.5000")
  79.     driver.find_element(By.ID, "pct_bet").clear()
  80.     driver.find_element(By.ID, "pct_bet").send_keys(rounded_number)
  81.     driver.find_element(By.ID, "a_lo").click()
  82.     time.sleep(0.8)
  83.     go()
  84.  
  85. if (1==1):
  86.     go()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement