moved functions to its own file

This commit is contained in:
superdimensional 2021-04-27 22:40:29 -04:00
parent 4cdeff7c26
commit d92a2a7c49
2 changed files with 22 additions and 15 deletions

View file

@ -1,24 +1,10 @@
from tkinter import *
from aliens import alien_table
from functions import *
root = Tk()
root.title("Omnitrix")
# root.attributes('-fullscreen', True)
counter= 0
def count_up():
global counter
counter+= 1
# print(counter)
def count_down():
global counter
counter-= 1
# print(counter)
def transform():
print(alien_table(counter))
root.geometry("640x480")
root.configure(bg="#70b607")

21
functions.py Normal file
View file

@ -0,0 +1,21 @@
from aliens import alien_table
counter= 0
def count_up():
global counter
counter+= 1
# print(counter)
def count_down():
global counter
counter-= 1
# print(counter)
def transform():
if counter < 0:
print(alien_table(counter * -1))
elif counter == 0:
print(alien_table(counter))
elif counter > 0:
print(alien_table(counter))