def changeroom(self, nextroom): print(nextroom + " test1") if nextroom == 'káeta': self.location = Room.Cabin() return self.location.whereami() elif nextroom == 'bar': self.location = Room.Bar() return self.location.whereami() elif nextroom == 'strönd': self.location = Room.Beach() return self.location.whereami() elif nextroom == 'skógur': if self.map: self.location = Room.Forrest() return self.location.whereami() else: return 'Þetta er ekki lögleg staðseting'