moved all particle specific functions to a new source file