replaced gameObjects with prefabs, and fixed other scripts