/** * Applies a management control to the Occupant. * * @param control */ public void addControl(ControlType control) { if (!controls.containsKey(control)) { controls.put(control, 0l); if (control != ControlType.NONE) { wasControlled = true; } if (control.ordinal() > maxControl.ordinal()) { maxControl = control; } } }
/** * Return the maximum control level applied to this Infestation. * * @return - the maximum control level applied to this Infestation. */ public int getMaxControl() { return maxControl.ordinal(); }