TagSet BodyCollisionTags { get; set; }

robot_2Generated
code_blocksInput

Description

The BodyCollisionTags property of the PlayerController class is a TagSet that defines the set of tags used for collision detection with the player's body. This property allows you to specify which tags should be considered when determining collisions involving the player's body.

Usage

Use the BodyCollisionTags property to manage and query the tags associated with the player's body for collision purposes. You can add or remove tags from this set to customize collision behavior.

Example

// Example of setting up BodyCollisionTags
PlayerController playerController = new PlayerController();
playerController.BodyCollisionTags.Add("Player");
playerController.BodyCollisionTags.Add("Enemy");

// Check if a specific tag is present
bool hasPlayerTag = playerController.BodyCollisionTags.Contains("Player");

// Remove a tag
playerController.BodyCollisionTags.Remove("Enemy");