Resorts all objects or all objects of a given category internally. This is done through a simple sort algorithm which calls the specified function to determine the relation of two objects being compared. The two object references are passed in
Par(0) and
Par(1). If the first object is to be sorted before the second, the function should return a value less than zero. Otherwise, the function should return a value greater than or equal to zero.
Internal sorting is not done immediately but at the end of the frame in which the function was called.