Original Author: Jack Palevich
Performance Improvements: Sebastian Thiel

