mirror of https://gitlab.com/bashrc2/epicyon
Check for maximum number of skills
parent
fc3a5c664c
commit
35b91d6907
|
@ -95,6 +95,11 @@ def setActorSkillLevel(actorJson: {},
|
||||||
]
|
]
|
||||||
ocSkillsList = getOccupationSkills(actorJson)
|
ocSkillsList = getOccupationSkills(actorJson)
|
||||||
skillsDict = getSkillsFromList(ocSkillsList)
|
skillsDict = getSkillsFromList(ocSkillsList)
|
||||||
|
if not skillsDict.get(skill):
|
||||||
|
if len(skillsDict.items()) >= 100:
|
||||||
|
print('WARN: Maximum number of skills reached for ' +
|
||||||
|
actorJson['id'])
|
||||||
|
return False
|
||||||
if skillLevelPercent > 0:
|
if skillLevelPercent > 0:
|
||||||
skillsDict[skill] = skillLevelPercent
|
skillsDict[skill] = skillLevelPercent
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in New Issue