The Void is an endless arcade-style minigame where the player has to collect plants in the dark while avoiding the spiders.
To create the environment, I removed the sun and atmosphere from the skybox to make a dark area. I added a red light to the spiders, a green light to the plants, and a yellow light to the extraction point. This was to make it clear where each key element was, and the light pulses to make it easier to see.
When the player enters the trigger area for the plant, it is destroyed and the prefab in the player hierarchy is enabled to show they are carrying the plant. Only one plant is available at a time to prevent issues with carrying multiple together, and to make the player move around the area more.
After the player touches the extraction point, the plant they are holding is set to inactive, they are given points and another plant is spawned. There are a number of possible locations for the plant to spawn, and a random one is chosen each time.
The spiders follow a set path when they can't see the player, and run towards the player when they can. To make this, I placed points around the play area, and the spider moves to the next point.
I used a raycast to check if the spider could see the player, and if it was, would move towards the player when it was close.
Each time a plant is placed in the extraction point, a new spider is spawned at a random point on the path so the difficulty increases over time.