OnPlayerFootstep

From Onset Developer Wiki
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.
OnPlayerFootstep

Type: Event
Context: Client
Introduced: v1.2.2

Description

Called when a player hits the ground with their feet when walking/running.

You can return false to suppress the footstep sound.

Syntax

OnPlayerFootstep(player, floor_type)
  • player
    The player identifier.
  • floor_type
    The floor under their feet. Can be one of FloorTypes.

Example

AddEvent("OnPlayerFootstep", function(player, floor_type)
    if player == GetPlayerId() then
        AddPlayerChat("OnPlayerFootstep")
    end
end)

See also