In our game, the core gameplay is that the player needs to select the corresponding object according to the sound. Therefore, how to make the player complete the action of selecting an object is an important part of the game’s logic.
We adopted the basic structure of the script selection introduced in this video by asking tutors, discussing, searching, and learning.
https://www.youtube.com/watch?v=A0Kd6lnBNRE
It can distinguish different objects by the tag selectable. When the player clicks on a selectable object, the color of that object changes according to the set material. (the original cube is white)


However, in actual running, we found some problems with this script. For example, it gets laggier as the game runs; the color change is not obvious in dim light, which is easy to confuse the player; when the player is too close to the object or the collider of the object is too big, the object will become difficult to select. We’ve tried a lot of solutions to this problem and finally used the script outline selection introduced in this video to complement and improve it.
https://www.youtube.com/watch?v=qYnAkMGbgwo
This script helps the player highlight its edges to act as a hint when selecting an object, and the final run is ideal.



