Humanoid:PlayEmote() when used on an R6 character crashes client

Using Humanoid:PlayEmote() on a client with an R6 character crashes the application. This method is only supposed to be used for R15 so it would only happen through a developer’s custom script. On the Windows version (not Microsoft Store) it also seems to reset settings in the game menu. Crash reproduced 100% of the time on Studio and live games on Windows (normal and MS Store versions), Mac, iOS, and Android; Xbox not tested.

An emote has to be equipped, Shrug is a free one that can be used to test. Using one that isn’t equipped raises a Lua exception, but no crash.

As an R6 character, in the command bar in Play Solo, or a LocalScript anywhere:

game.Players.LocalPlayer.Character.Humanoid:PlayEmote('Shrug')

This was discovered by accident today, not sure how long the crash has existed. Desktop Client Version: .422.0.388145

Video of crash in Studio and live game on Windows 10:

Example place: PlayEmoteCrash.rbxl (19.9 KB)
The script is at StarterGui.ScreenGui.TextButton.LocalScript. Make sure Shrug is equipped, or change it to use another emote.

6 Likes