mirror of
https://github.com/SpudGunMan/meshing-around.git
synced 2026-03-28 17:32:36 +01:00
78 lines
2.2 KiB
Python
78 lines
2.2 KiB
Python
# Load the bbs messages from the database file to screen for admin functions
|
|
import pickle # pip install pickle
|
|
|
|
|
|
# load the bbs messages from the database file
|
|
try:
|
|
with open('../bbsdb.pkl', 'rb') as f:
|
|
bbs_messages = pickle.load(f)
|
|
except Exception as e:
|
|
try:
|
|
with open('bbsdb.pkl', 'rb') as f:
|
|
bbs_messages = pickle.load(f)
|
|
except Exception as e:
|
|
bbs_messages = "System: bbsdb.pkl not found"
|
|
|
|
try:
|
|
with open('../bbsdm.pkl', 'rb') as f:
|
|
bbs_dm = pickle.load(f)
|
|
except Exception as e:
|
|
try:
|
|
with open('bbsdm.pkl', 'rb') as f:
|
|
bbs_dm = pickle.load(f)
|
|
except Exception as e:
|
|
bbs_dm = "System: bbsdm.pkl not found"
|
|
|
|
# Game HS tables
|
|
try:
|
|
with open('../lemonade_hs.pkl', 'rb') as f:
|
|
lemon_score = pickle.load(f)
|
|
except Exception as e:
|
|
try:
|
|
with open('lemonade_hs.pkl', 'rb') as f:
|
|
lemon_score = pickle.load(f)
|
|
except Exception as e:
|
|
lemon_score = "System: lemonade_hs.pkl not found"
|
|
|
|
try:
|
|
with open('../dopewar_hs.pkl', 'rb') as f:
|
|
dopewar_score = pickle.load(f)
|
|
except Exception as e:
|
|
try:
|
|
with open('dopewar_hs.pkl', 'rb') as f:
|
|
dopewar_score = pickle.load(f)
|
|
except Exception as e:
|
|
dopewar_score = "System: dopewar_hs.pkl not found"
|
|
|
|
try:
|
|
with open('../blackjack_hs.pkl', 'rb') as f:
|
|
blackjack_score = pickle.load(f)
|
|
except Exception as e:
|
|
try:
|
|
with open('blackjack_hs.pkl', 'rb') as f:
|
|
blackjack_score = pickle.load(f)
|
|
except Exception as e:
|
|
blackjack_score = "System: blackjack_hs.pkl not found"
|
|
|
|
try:
|
|
with open('../videopoker_hs.pkl', 'rb') as f:
|
|
videopoker_score = pickle.load(f)
|
|
except Exception as e:
|
|
try:
|
|
with open('videopoker_hs.pkl', 'rb') as f:
|
|
videopoker_score = pickle.load(f)
|
|
except Exception as e:
|
|
videopoker_score = "System: videopoker_hs.pkl not found"
|
|
|
|
print ("\n Meshing-Around Database Admin Tool\n")
|
|
print ("System: bbs_messages")
|
|
print (bbs_messages)
|
|
print ("\nSystem: bbs_dm")
|
|
print (bbs_dm)
|
|
print (f"\n\nGame HS tables\n")
|
|
print (f"lemon:{lemon_score}")
|
|
print (f"dopewar:{dopewar_score}")
|
|
print (f"blackjack:{blackjack_score}")
|
|
print (f"videopoker:{videopoker_score}")
|
|
print ("\n")
|