Add generateRoom function