2025-09-06 18:49:27 -05:00

36 lines
738 B
Python

import requests
from base64 import b64encode
def basic_auth(username, password):
token = b64encode(f"{username}:{password}".encode('utf-8')).decode("ascii")
return f'Basic {token}'
requests.post("https://ntfy.treehousefullofstars.com/alerts",
data="Look ma, with auth",
headers={
"Authorization": basic_auth('jadowyne', 'Jumbocarrot&001')
})
already_used = [
[(False, None), (False, None), (True, "X")],
[(False, None), (True, "Circle"), (False, None)],
[(False, None), (False, None), (False, None)]
]
already_used = [(0, 0),(0, 1),(0, 2), ...]
spot = random(len(already_used.keys()))
amount_x = 3
amount_y = 3
grid = [
[],
[],
[]
]
2, 2
state = already_used[x][y][0]