From 4cce336fb9bfc2cc0a9ef62cef8d2783e9689fb2 Mon Sep 17 00:00:00 2001 From: RaidMax Date: Sun, 19 Dec 2021 20:01:35 -0600 Subject: [PATCH] update custom callbacks to properly exit thread on disconnect --- GameFiles/IW4x/userraw/scripts/_customcallbacks.gsc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/GameFiles/IW4x/userraw/scripts/_customcallbacks.gsc b/GameFiles/IW4x/userraw/scripts/_customcallbacks.gsc index 8ffb26785..5d6e86491 100644 --- a/GameFiles/IW4x/userraw/scripts/_customcallbacks.gsc +++ b/GameFiles/IW4x/userraw/scripts/_customcallbacks.gsc @@ -144,6 +144,7 @@ waitForFrameThread() waitForAdditionalAngles( logString, beforeFrameCount, afterFrameCount ) { + self endon( "disconnect" ); currentIndex = self.currentAnglePosition; wait( 0.05 * afterFrameCount ); @@ -253,4 +254,4 @@ Callback_PlayerDisconnect() { level notify( "disconnected", self ); self maps\mp\gametypes\_playerlogic::Callback_PlayerDisconnect(); -} \ No newline at end of file +}