Beginning of rewriting on Selenium

This commit is contained in:
DarkCat09 2023-08-08 10:57:41 +04:00
parent 0f8b9940da
commit 0aac026caa
27 changed files with 86 additions and 4679 deletions

View file

@ -1,27 +1,14 @@
from getpass import getpass
from python_aternos import Client, atserver
from selenium.webdriver import Firefox
from python_aternos import Client
user = input('Username: ')
pswd = getpass('Password: ')
atclient = Client()
aternos = atclient.account
driver = Firefox()
atclient = Client(driver)
atclient.login(user, pswd)
srvs = aternos.list_servers()
for srv in srvs:
print()
print('***', srv.servid, '***')
srv.fetch()
print(srv.domain)
print(srv.motd)
print('*** Status:', srv.status)
print('*** Full address:', srv.address)
print('*** Port:', srv.port)
print('*** Name:', srv.subdomain)
print('*** Minecraft:', srv.software, srv.version)
print('*** IsBedrock:', srv.edition == atserver.Edition.bedrock)
print('*** IsJava:', srv.edition == atserver.Edition.java)
print()
driver.quit()