We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
If you stop a delayed while callback are processed, it changes the array that is currently browsed and can make weird things or crashes.
My solution was to postpone the removing of the delayed call back like this
public void StopDelayedCall(Action func) { int count = _delayedCallbacks.Count; for (int d = 0; d<count; d++) { FDelayedCallback call = _delayedCallbacks[d]; if(call.func == func) { _delayedCallbacksToRemove.Add(call); } } } private void ProcessDelayedCallbacks() { foreach (FDelayedCallback callToRemove in _delayedCallbacksToRemove) { _delayedCallbacks.Remove(callToRemove); } // ... same code after this
The text was updated successfully, but these errors were encountered:
Cool, makes sense, yup I'll put a fix in for it...
Sorry, something went wrong.
No branches or pull requests
If you stop a delayed while callback are processed, it changes the array that is currently browsed and can make weird things or crashes.
My solution was to postpone the removing of the delayed call back like this
The text was updated successfully, but these errors were encountered: