Memory leak in Hook function cache when changing mod options.
acdemiralp opened this issue ยท 3 comments
Simple reproduction:
njz4RTnmqu8)DAHvWoEXD5Jfkds7I3GlDFkC1xKoNAQTKqsoK8f)3(ozLbfd2)0LC37PNewI7rOeHD8O1FDU9xm95C7EoeriE1Xi8H1(jcviGWQ0R1ytzDDvrv16nsHVJWtrAGmXpEaIw)yqrdsBpk)neQXMAe2KePHgz3af5523CA5RgHUjJk2BnZT3f4HUVn3oz6JB13GF6LEeMnN3thhs4OvVG3p)YC7TNxyJgf)(JKmIxytuiPWjVDYLr1afczCKCV3RVTWBfZUqUZUV2BWXQmrDD9xYiBu2jtK9FzaKkpaHFB7ZiuCPUQSJlQ0eTUCv9JINSQZSpiBuSztXQcPeP1Yk4pPaXJG1LIH0iBwor2NI(gjE3rxWM1ffi8mhuP8FxVmLhwk9kFfbZ04rXqsy)xAys6s(bj4wYv8icBvjH2MCDN41dpP1)2eoKv(q)iDIdhY6)EEw5ZkrrpDAUnA))TI8DKLTAeX)9d
This creates a mod with just the "Nameplate Updated" hook and one slider UI option.
Drag the slider left and right quickly, watch your FPS drop and eventually the game crash.
Disable the mod before the crash and everything is back to normal.
It only happens with Nameplate Updated, and not with Nameplate Added or any other callback I tried.
I can reproduce the issue. It is a leak in the internal hook data caches for all hooks. It is just most prominent in Nameplate Updated due to the amount of runs on it.