solve collision