diff --git a/src/codeparts/checkers.py b/src/codeparts/checkers.py index 4f0f512..dcd08a2 100644 --- a/src/codeparts/checkers.py +++ b/src/codeparts/checkers.py @@ -6,6 +6,8 @@ class checkers(): def skins_en(self,entitlement,token,puuid,region='EU') -> str: + if region.lower()=='latam' or region.lower()=='br': + region='na' try: if entitlement==False: @@ -17,6 +19,7 @@ def skins_en(self,entitlement,token,puuid,region='EU') -> str: } r = sess.get(f"https://pd.{region}.a.pvp.net/store/v1/entitlements/{puuid}/e7c63390-eda7-46e0-bb7a-a6abdacd2433",headers=headers) + #input(r.text) Skins = r.json()["Entitlements"] response_API = requests.get('https://valorant-api.com/v1/weapons/skins/') skinstr='' @@ -30,10 +33,13 @@ def skins_en(self,entitlement,token,puuid,region='EU') -> str: skinstr += skin + "\n" return skinstr - except: + except Exception as e: + #input(e) return 'err' def balance(self,ent,token,puuid,region) -> int: + if region.lower()=='latam' or region.lower()=='br': + region='na' headers = {"Content-Type": "application/json", "Authorization": f"Bearer {token}", "X-Riot-Entitlements-JWT": ent, @@ -49,6 +55,8 @@ def balance(self,ent,token,puuid,region) -> int: return vp,rp def ranked(self,entitlement,token,puuid,region='EU') -> str: + if region.lower()=='latam' or region.lower()=='br': + region='na' try: if entitlement==False: @@ -76,6 +84,8 @@ def ranked(self,entitlement,token,puuid,region='EU') -> str: def lastplayed(self,uuid,region,token,ent): + if region.lower()=='latam' or region.lower()=='br': + region='na' try: headers={"Content-Type": "application/json", "Authorization": f"Bearer {token}", diff --git a/src/codeparts/data.py b/src/codeparts/data.py index 3b9d598..96a4193 100644 --- a/src/codeparts/data.py +++ b/src/codeparts/data.py @@ -1,12 +1,12 @@ class Constants: LOL2REG={ - 'BR1': 'na', + 'BR1': 'br', 'EUN1': 'eu', 'EUW1': 'eu', 'JP1': 'ap', 'KR': 'kr', - 'LA1': 'na', - 'LA2': 'na', + 'LA1': 'latam', + 'LA2': 'latam', 'NA1': 'na', 'OC1': 'ap', 'PBE1': 'na', diff --git a/src/codeparts/systems.py b/src/codeparts/systems.py index 3d3e082..f7ac917 100644 --- a/src/codeparts/systems.py +++ b/src/codeparts/systems.py @@ -5,6 +5,7 @@ from tkinter import filedialog import time +from colorama import Fore, Style import requests import valo_api as vapi from InquirerPy import inquirer @@ -224,12 +225,13 @@ def checkproxy(self): 'http':f'http://{proxy}', 'https':f'http://{proxy}', } - print(f'using: {proxxy}') + #print(f'using: {proxxy}') try: - resp=session.get('https://api.myip.com/',proxies=proxxy).text + resp=session.get('https://auth.riotgames.com/api/v1/authorization/',proxies=proxxy).text + resp=f'{Fore.GREEN}[Good]{Fore.RESET} {proxy}' except: - resp='bad response. delete this proxy' - print(f'response: {resp}\n') + resp=f'{Fore.RED}[Bad]{Fore.RESET} {proxy}' + print(f'{resp}') input('press enter to return') syss=system() diff --git a/src/main.py b/src/main.py index d33fe4e..8005dea 100644 --- a/src/main.py +++ b/src/main.py @@ -21,7 +21,7 @@ class program(): def __init__(self) -> None: self.count=0 self.checked=0 - self.version='3.6.1' + self.version='3.6.2' self.riotlimitinarow=0 try: self.lastver=requests.get('https://lil-jaba.github.io/valchecker/src/system/lastver.html').text.replace(' ','').replace('\n','') @@ -115,6 +115,7 @@ def get_accounts(self,filename): # remove doubles if logpass not in ret and ':' in logpass: self.count+=1 + ctypes.windll.kernel32.SetConsoleTitleW(f'ValChecker {self.version} by liljaba1337 | Loading Accounts ({self.count})') ret.append(logpass) return ret except FileNotFoundError: @@ -139,8 +140,10 @@ def get_accounts(self,filename): def main(self,redirect=False): + ctypes.windll.kernel32.SetConsoleTitleW(f'ValChecker {self.version} by liljaba1337 | Loading Settings') print('loading settings') settings=sys.load_settings() + ctypes.windll.kernel32.SetConsoleTitleW(f'ValChecker {self.version} by liljaba1337 | Loading Proxies') print('loading proxies') proxylist=sys.load_proxy() fn=settings['default_file'] diff --git a/src/system/lastver.html b/src/system/lastver.html index d1428a7..77a069e 100644 --- a/src/system/lastver.html +++ b/src/system/lastver.html @@ -1 +1 @@ -3.6.1 \ No newline at end of file +3.6.2 \ No newline at end of file