switched room objects to database, reworked collision code