Did some cleanup and changed ListBuffers to ArrayBuffers for performance and memory reasons.