Pastew
7 months agoPartner
How to detect if player goes afk / alt + tab / alt + F4
Hello,
I want to detect when player changes to this portrait mode after losing focus, for example when uses alt+tab or alt+f4.
I want to force release the grabbed item when this happens. How to do this?
OK, nevermind, just found it, a minute after I posted this question..
https://developers.meta.com/horizon-worlds/reference/2.0.0/core_codeblockeventsthis.connectCodeBlockEvent(this.entity, CodeBlockEvents.OnPlayerEnterAFK, (player: Player) => { // do something });