Separate blackjack cards for each chann

This commit is contained in:
Nikolaj Danger
2020-07-30 17:42:48 +02:00
parent d807afe36d
commit 796b209a5b
4 changed files with 50 additions and 46 deletions

View File

@ -159,17 +159,6 @@ def makeFiles():
f.close()
# Creates blackjackCards.txt if it doesn't exist
try:
f = open("resources/games/blackjackCards.txt","r")
except:
logThis("blackjackCards.txt didn't exist. Making it now.")
data = ""
with open("resources/games/blackjackCards.txt","w") as f:
f.write(data)
finally:
f.close()
# Creates destinyPoints.txt if it doesn't exist
try:
f = open("resources/destinyPoints.txt","r")
@ -200,12 +189,22 @@ def makeFiles():
# Creates the 4InARowBoards foulder if it doesn't exist
if os.path.isdir("resources/games/4InARowBoards") == False:
os.makedirs("resources/games/4InARowBoards")
logThis("The tables directory didn't exist")
logThis("The 4 in a row boards directory didn't exist")
# Creates the 4InARowBoards foulder if it doesn't exist
# Creates the oldImages foulder if it doesn't exist
if os.path.isdir("resources/games/oldImages") == False:
os.makedirs("resources/games/oldImages")
logThis("The tables directory didn't exist")
logThis("The old images directory didn't exist")
# Creates the blackjackCards foulder if it doesn't exist
if os.path.isdir("resources/games/blackjackCards") == False:
os.makedirs("resources/games/blackjackCards")
logThis("The blackjack cards directory didn't exist")
# Creates the hilo foulder if it doesn't exist
if os.path.isdir("resources/games/hilo") == False:
os.makedirs("resources/games/hilo")
logThis("The hi-lo directory didn't exist")
# Replaces multiple things with the same thing
def replaceMultiple(mainString, toBeReplaces, newString):