How to sort List by object attribute ?
I have a list of objects and I want to sort it by Y coordinate to map it properly on the screen.
Any suggestion on how I can do this?
I have a list of objects and I want to sort it by Y coordinate to map it properly on the screen.
Any suggestion on how I can do this?
This is the way:
my_list.sortList( function( a, b ) return a.Y - b.Y end )