bug fix in next_abilities, still remains problem with equipment
fixed the bug in checking equipment, moved buy/sell part