Advertisement
coinwalk

best snowybot for google colab

Jan 2nd, 2024
835
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #!/usr/bin/env python
  2. # -*- coding: utf-8 -*-
  3.  
  4. import subprocess
  5. import sys
  6.  
  7. try:
  8.     import selenium
  9. except ImportError:
  10.     subprocess.check_call([sys.executable, "-m", "pip", "install", 'selenium'])
  11. finally:
  12.     import selenium
  13.  
  14. from selenium import webdriver
  15. from selenium.webdriver.common.by import By
  16. from selenium.webdriver.support.ui import Select
  17. from selenium.common.exceptions import NoSuchElementException
  18. import time, re, math
  19. from decimal import Decimal
  20. from selenium.webdriver.firefox.options import Options
  21.  
  22. options = Options()
  23. options.add_argument("--headless")
  24. driver = webdriver.Firefox(options=options)
  25. print("please wait loading page and login")
  26. driver.get("https://just-dice.com")
  27. time.sleep(20)
  28. driver.find_element(By.CSS_SELECTOR, "a.fancybox-item.fancybox-close").click()
  29. time.sleep(5)
  30. driver.find_element(By.LINK_TEXT, "Account").click()
  31. time.sleep(2)
  32. driver.find_element(By.ID, "myuser").clear()
  33. driver.find_element(By.ID, "myuser").send_keys("USERNAME")
  34. time.sleep(0.01)
  35. driver.find_element(By.ID, "mypass").clear()
  36. driver.find_element(By.ID, "mypass").send_keys("PASSWORD")
  37. time.sleep(0.01)
  38. driver.find_element(By.ID, "myok").click()
  39. time.sleep(20)  
  40. print("logged in")
  41. freather = 0.0 
  42. fumble = 0.0001
  43. print("should see bets")
  44.  
  45. def go():
  46.     base = 0.0001
  47.     tens = (base*10)
  48.     sevens = (base*6.9)
  49.     eights = (base*7.1)
  50.     balance = driver.find_element(By.ID, "pct_balance").get_attribute("value")
  51.     global fumble
  52.     global freather
  53.     if ((float(balance)>(((math.floor(float(balance)/tens))*tens)+sevens)) and (float(balance)<(((math.floor(float(balance)/tens))*tens)+eights)) and (not (float(balance)==freather))):
  54.         fumble = float(fumble)*2
  55.         freather = float(balance)
  56.     if ((fumble>=tens) and (float(balance)<(((math.floor(float(balance)/tens))*tens)+sevens))):
  57.         fumble = base
  58.         freather = 0.0
  59.     time.sleep(0.1)
  60.     driver.find_element(By.ID, "pct_chance").clear()
  61.     driver.find_element(By.ID, "pct_chance").send_keys("49.5000")
  62.     driver.find_element(By.ID, "pct_bet").clear()
  63.     driver.find_element(By.ID, "pct_bet").send_keys(float(fumble))
  64.     driver.find_element(By.ID, "a_lo").click()
  65.     time.sleep(0.8)
  66.     go()
  67.    
  68. if (1==1):
  69.     go()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement