Talk:SteamVR/Environments/Scripting/flashlight script code full

From Valve Developer Community
< Talk:SteamVR
Revision as of 15:01, 23 June 2019 by Rectus (talk | contribs) (Rectus moved page Talk:Destinations/flashlight script code full to Talk:SteamVR/Environments/Scripting/flashlight script code full: Moved scripting section to match the rest of the SteamVR Home pages)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Problem when I drop the flashlight

I copied the exact code, for the flashlight, and it works, but as soon as I drop the flashlight either A: If I'm in Hammer, then Hammer crashes, or B: If I'm in Steam VR, then it freezes, goes to the Steam VR loading screen, and stays there. Until I press the Windows button on My WMR controllers, that takes my back. But if I go back into Steam VR, it still is at the loading screen. Please help! —The preceding unsigned comment was added by Fox G∆MING (talkcontribs).

Looks like the script killing the light entity only after the tool has been dropped is what's causing it. I added code to kill the light sooner, and that seems to have fixed it. Rectus (talk) 14:46, 11 June 2018 (UTC)