You can still do the XP tracking though. You need to give each clan member a unique id and use that as a reference.
When you load the clan list, you compare it to the old clan list. Copy the old clan list. Loop through each name in the new clan list and check if it exists in the copy of the old clan list.
If the name does not exist, save it to a list with new names for later checking.
If the name exists, make sure that:
a) a new member didn't take an old member's name and joined
b) two clan members didn't swap names
This can be determined by comparing the old clan XP with new clan XP. Is the new clan XP higher than the old? And is it within a reasonable threshold since the last lookup? If the evaluation is fine, you remove the name from the copy of old names. If not, you can run a more comprehensive stat comparison algorithm where you compare the old stats of username with new stats of username to determine if they are the same user or not.
When all of this is done, your old copy will contain users that either changed their name or left the clan. Now you loop through the list of unrecognised names and compare its stats to every unmatched old name's stats in your stat comparison algorithm (you check skill by skill; differences in XP and possibly rank for 200m stats). If the stats match, the user has changed their name and you can mark it for update and remove it from the list.
In the end, any names still in the copy of the old clan list will be users that left the clan. Any names still in the new names list will be new clan members.
Of course, these type of algorithmic guesses don't have 100% accuracy, but for as long as I have done XP tracking, very simple algorithms haven't failed and there's a ton of stuff you could do to improve them (like taking avatar images and archived hiscores into account etc). I don't know what Runeclan uses, but I have seen instances where the simple algorithms alone were superior to their method
12-Jan-2016 22:28:37
- Last edited on
12-Jan-2016 22:39:45
by
Redtunnel