Made the trigger party damage function more reusable.