Problem with sorting an array
I'm creating a rpg and I'm having problems with an array sort. the following code is suppossed to sort through a list of skills and if the character already has the skill or if his stats don't allow him to take that skill then it won't be added to the list... but it doesn't seem to be working right. So if someone could help it would be nice.
Find_skill_type() finds the start and end position of skills of a certain type from the main skill list.
stats_allow_skill() passes back true if he can take it or false if he can't
skills is the characters skill list (which corresponds to the same point in the skill_list array.)