🔥 monster and spell files no longer part

This commit is contained in:
Nikolaj Danger
2020-08-03 15:00:54 +02:00
parent 83a93145db
commit cd1eff01a0
4 changed files with 82 additions and 1 deletions

View File

@ -26,7 +26,7 @@ def monsterFunc(command):
# Opens "mensters.json"
data = json.load(open('resources/monsters.json', encoding = "utf8"))
for monster in data:
if str(command) == monster["name"]:
if "name" in monster and str(command) == monster["name"]:
logThis("Found it!")
# Looks at the information about the monster and returns that information