fixed some bugs about the scoring system + added a deadlock removal