Time:articles/Collision Filtering|collision filtering
In some games, it’s desirable to have doors or forcefields that certain players can pass through but others cannot. For instance, many team combat games will spawn players of each team in a safe area that other teams can’t access (so they aren’t attacked the moment they join or spawn).
There are various ways to accomplish this, but this tutorial utilizes
articles/Collision Filtering|collision filtering to create doors that only certain players can pass through.
Creating the Doors¶
For this simple example, the doors are basic block parts in the workspace named “BlueDoor” and “RedDoor.” Their material is
enum/Material|Glass and their
BasePart/Transparency|Transparency is set to 0.5.