The IsSwimming
property of the CitizenAnimationHelper
class indicates whether the character is currently swimming. This boolean property returns true
if the character is swimming, and false
otherwise.
The IsSwimming
property of the CitizenAnimationHelper
class indicates whether the character is currently swimming. This boolean property returns true
if the character is swimming, and false
otherwise.
Use the IsSwimming
property to check if the character is in a swimming state. This can be useful for triggering specific animations or behaviors when the character is in water.
// Example of using the IsSwimming property CitizenAnimationHelper animationHelper = new CitizenAnimationHelper(); // Check if the character is swimming if (animationHelper.IsSwimming) { // Execute logic for when the character is swimming // For example, play swimming animation animationHelper.TriggerSwimAnimation(); } else { // Execute logic for when the character is not swimming // For example, play walking animation animationHelper.TriggerWalkAnimation(); }