Null check ALL the profiles.

We should probably find a more elegant way to do this, though.
This commit is contained in:
GJ
2012-07-10 14:02:48 -04:00
parent 07c66378c0
commit 686bcd5308
4 changed files with 37 additions and 4 deletions

View File

@ -107,6 +107,10 @@ public class Skills {
}
/* Check if any abilities are active */
if (profile == null) {
return;
}
if (!profile.getAbilityUse()) {
return;
}
@ -151,6 +155,10 @@ public class Skills {
ToolType tool = skill.getTool();
AbilityType ability = skill.getAbility();
if (profile == null) {
return;
}
if (profile.getToolPreparationMode(tool) && curTime - (profile.getToolPreparationATS(tool) * TIME_CONVERSION_FACTOR) >= FOUR_SECONDS) {
profile.setToolPreparationMode(tool, false);