Cleaned Pushingbox up to be a function.