dd_sortedObjectList(list/incoming)
This returns a new list with the objects and mobs sorted based on the value each returns in its dd_SortValue() function. Simple lesser-than (<) and greater-than (>) arithmetic is used to compare sort values. By default, objects are sorted by their name. Text values are sorted by case.
If you have a special sorting requirement, then override dd_SortValue() for your mobs/objects to return the value you desire. For example, to sort mobs by their weight, you would have the mob.dd_SortValue() function return the mob's weight:
mob/dd_SortValue()
return weight
dd_sortedtextlist(list/incoming, case_sensitive)
This returns a new list with the items sorted in order of their text value.
dd_sortedTextList(list/incoming)
This returns a new list with the items sorted in order of their text value. The sorting is case-sensitive.
ID:91580
Jan 1 2002, 10:00 pm
|
|