I am currently making an RTS game, and I am currently implementing structure placing on a grid system.
I created my own class for a grid system and I set the pivot of every structure to the bottom left of their sprite and it snaps to my grid system correctly. However, whenever the “Player” is in build mode, I want to make a visualization of the grid, and I want it so only the tiles near the building preview while building is visible (also make the opacity of the tiles gradually decrease as it gets further away from the mouse/building preview). Are there any suggestions on how to go about this? I have no idea how to implement this. Note: I also want each tiles to be animated for example a breathing effect if possible.
My original thought was to, on startup, instantiate tile gameobjects on each grid on my map with a breathing animation and just make it invisible. However, using the profiler, I saw that even invisible, it still takes quite a lot of performance in the “Animation” section.
Thank you for the help. If any information need to be provided please let me know.