Cleaned up GetUnusedInstanceID logic and renamed instance_lockout* tables to instance_list*