Handling fade blocks smartly

Hey,

I want to make fade blocks but I don’t want all the fade blocks to have one script inside of them. It will make the game lag and it won’t look good at all.

So what I thought of doing is adding a attribute then somehow finding if the player stepped on any part with the attribute.

Is there anyway to do this? If not, is there a better way to do this?

You can use “CollectionService” for this. See for more info: CollectionService | Documentation - Roblox Creator Hub

*Add a tag every part you want to fade when touched. (You can use Tag Editor)
*Loop every tagged part in your script and add touched event. (GetTagged)

or

You can put all these blocks in a folder and loop this folder to add touched event for each block.

2 Likes

@Remingling I would recommend CollectionService as @GeldiBaskan said. It’s an easy way to manipulate and manage lot’s of parts with similar properties.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.