From 8e7a9198057775f3aad4c676dc533aeadd54879e Mon Sep 17 00:00:00 2001 From: Coopyy Date: Sat, 19 Feb 2022 22:12:38 -0600 Subject: Prevent fastball client valid crashes (#235) theres no checks if the panel is valid or not https://cdn.discordapp.com/attachments/941129346612068373/944097224885952552/20220217_201811.jpg --- .../mod/scripts/vscripts/gamemodes/cl_gamemode_fastball.gnut | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Northstar.Custom') diff --git a/Northstar.Custom/mod/scripts/vscripts/gamemodes/cl_gamemode_fastball.gnut b/Northstar.Custom/mod/scripts/vscripts/gamemodes/cl_gamemode_fastball.gnut index f64658cf5..f5fae006c 100644 --- a/Northstar.Custom/mod/scripts/vscripts/gamemodes/cl_gamemode_fastball.gnut +++ b/Northstar.Custom/mod/scripts/vscripts/gamemodes/cl_gamemode_fastball.gnut @@ -31,6 +31,8 @@ void function FastballCreateRui( entity player ) void function ServerCallback_FastballUpdatePanelRui( int panelHandle, int id ) { entity panel = GetEntityFromEncodedEHandle( panelHandle ) + if (!IsValid(panel)) + return var rui if ( id == 0 ) rui = file.panelARui @@ -94,4 +96,4 @@ void function FastballRespawnPlayerEffects_Threaded() WaitFrame() StartParticleEffectOnEntity( player.GetCockpit(), GetParticleSystemIndex( $"P_pod_screen_lasers_OUT" ), FX_PATTACH_ABSORIGIN_FOLLOW, -1 ) -} \ No newline at end of file +} -- cgit v1.2.3