Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/env python
- # -*- coding: utf-8 -*-
- import subprocess
- import sys
- try:
- import selenium
- except ImportError:
- subprocess.check_call([sys.executable, "-m", "pip", "install", 'selenium'])
- finally:
- import selenium
- from selenium import webdriver
- from selenium.webdriver.common.by import By
- from selenium.webdriver.support.ui import Select
- from selenium.common.exceptions import NoSuchElementException
- import time, re, math
- from decimal import Decimal
- from selenium.webdriver.firefox.options import Options
- options = Options()
- options.add_argument("--headless")
- driver = webdriver.Firefox(options=options)
- print("please wait loading page and login")
- driver.get("https://just-dice.com")
- time.sleep(20)
- driver.find_element(By.CSS_SELECTOR, "a.fancybox-item.fancybox-close").click()
- time.sleep(5)
- driver.find_element(By.LINK_TEXT, "Account").click()
- time.sleep(2)
- driver.find_element(By.ID, "myuser").clear()
- driver.find_element(By.ID, "myuser").send_keys("USERNAME")
- time.sleep(0.01)
- driver.find_element(By.ID, "mypass").clear()
- driver.find_element(By.ID, "mypass").send_keys("PASSWORD")
- time.sleep(0.01)
- driver.find_element(By.ID, "myok").click()
- time.sleep(20)
- print("logged in")
- freather = 0.0
- fumble = 0.0001
- print("should see bets")
- def go():
- base = 0.0001
- tens = (base*10)
- sevens = (base*6.9)
- eights = (base*7.1)
- balance = driver.find_element(By.ID, "pct_balance").get_attribute("value")
- global fumble
- global freather
- 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))):
- fumble = float(fumble)*2
- freather = float(balance)
- if ((fumble>=tens) and (float(balance)<(((math.floor(float(balance)/tens))*tens)+sevens))):
- fumble = base
- freather = 0.0
- time.sleep(0.1)
- driver.find_element(By.ID, "pct_chance").clear()
- driver.find_element(By.ID, "pct_chance").send_keys("49.5000")
- driver.find_element(By.ID, "pct_bet").clear()
- driver.find_element(By.ID, "pct_bet").send_keys(float(fumble))
- driver.find_element(By.ID, "a_lo").click()
- time.sleep(0.8)
- go()
- if (1==1):
- go()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement