mistythunder Posted April 13, 2021 Share Posted April 13, 2021 When a prim a script is running in is detached, and the script executes code upon that detachment using attach() event handler, there is a short amount of time the script can still execute code. Is the amount of code that can be executed in that time dependent on sim lag? Link to comment Share on other sites More sharing options...
KT Kingsley Posted April 13, 2021 Share Posted April 13, 2021 It does seem to be dependant on how much time the simulator has for it. I generally get about two or three lines of code to execute pretty reliably on a detach. Any code that isn't executed at the time of the detach does execute when the object is reattached, and before the attach event is triggered for the reattachment, so if you can get anything that involves telling the rest of the world goodbye in at the start, and leave any internal tidying up until later, things should go ok. Most of the time. 3 Link to comment Share on other sites More sharing options...
Recommended Posts
Please take a moment to consider if this thread is worth bumping.
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now