diff --git a/Main.py b/Main.py index 6d8704a..f9620e7 100644 --- a/Main.py +++ b/Main.py @@ -2,19 +2,19 @@ from winConf import * import json -with open('lib/setting.json', 'r') as f: setting = json.loads(f.read()) consoleClear() print('CanUseTimer\'s version: 0.1.4.2 BETA.\n' 'This software is open to free use and study code,\n' 'for more info: https://github.com/samuel-de-oliveira/CanUseTimer.\n') while True: + with open('lib/setting.json', 'r') as f: setting = json.loads(f.read()) line(style='double_line') print('Digit a one of these numbers:') print("1: Start\n" "2: Settings\n" - "3: Credits\n" - "4: Clear list\n" + "3: Clear list\n" + "4: Credits\n" "5: Exit") line(style='double_line') console = Console(size=5) @@ -26,9 +26,9 @@ window('Settings') settingManager() if console == 3: + timesSave.clear() + window('The cube\'s times is cleared!') + if console == 4: window('Credits to:', 'double_line') print('The creator: Samuel de Oliveira') - if console == 4: - timesSave.clear() - window('The cube\'s times is cleared!') if console == 5: break diff --git a/lib/Shufflers.py b/lib/Shufflers.py index d17afc3..7842038 100644 --- a/lib/Shufflers.py +++ b/lib/Shufflers.py @@ -50,7 +50,6 @@ def Salete(size): if x == 1: moves[letter] = f'{moves[letter]}\'' # add apostrophe if x == 2: moves[letter] = f'{moves[letter]}2' # add two if x == 3: pass # do nothing "\_(シ)_/" - return moves #-*-------------- Cida shuffler --------------*-# @@ -113,13 +112,12 @@ def Cida(size, corner): x = randint(1, 2) if x == 1: moves[letter] = f'{moves[letter]}\'' # add apostrophe if x == 2: pass # do nothing "\_(シ)_/" - return moves def Lucia(size): moves = [] old = 0 - for moves in range(1, 1+size): + for move in range(1, 1+size): while True: m = randint(1, 6) @@ -149,4 +147,3 @@ def Lucia(size): moves.append('B') break return moves - diff --git a/winConf.py b/winConf.py index 73f064d..e09e421 100644 --- a/winConf.py +++ b/winConf.py @@ -4,7 +4,8 @@ def line(size=40, style='basic'): if style == 'basic': print('-' * size) elif style == 'double_line': print('=' * size) elif style == 'hashtag': print('#' * size) - elif style == 'zigzag': print('W' * size) + elif style == 'zigzag': print('V' * size) + elif style == 'zagzig': print('W' * size) else: raise NameError(f'The style \'{style}\' doesn\'t exist.') def window(msg='[Null]', style='basic'):