Detecting Idle Player Movement
Determining If A Player Is Idle
In this section, you will learn how to check if a player has moved a certain distance since the last simulation update. If they have, the player’s current position is saved and checked again. If they haven’t, the loop breaks and the method completes. This method uses GetFortCharacter[], GetTransform(), and Translation to get the location of the player. You can learn more about these on their API Reference pages.
This page includes Verse snippets that show how to execute gameplay mechanics needed in this gameplay. Follow the steps below and copy the full script on step 6 of this tutorial.
Follow these steps to determine if a player is idle.
- Create an extension method for the agent class named
AwaitStopMoving(). This means you’re adding a custom method to an already defined class.
You're reading a preview
The full reference is free for BrainDeadGuild Discord members — sign in to read it all, or open the original at the source.
Sign in with your BrainDead.TV / BrainDeadGuild Discord account for full access.