Facepunch / garrysmod-issues

Garry's Mod issue tracker
145 stars 56 forks source link

Unable to remove presets #3741

Closed Cherry closed 5 years ago

Cherry commented 5 years ago

I've implemented a "presets" menu into my tool, as per the examples in tools such as https://github.com/Facepunch/garrysmod/blob/394ae745df8f8f353ea33c8780f012fc000f4f56/garrysmod/gamemodes/sandbox/entities/weapons/gmod_tool/stools/ballsocket.lua, but am having issues when deleting presets - they keep returning after I rejoin the game. This was brought to my attention by a user reporting the bug to me: https://steamcommunity.com/workshop/filedetails/discussion/109643223/1741106440032200586/. I was able to replicate the issue in a Single Player game, using the latest dev branch.

I initially thought this to be a bug with my implementation, but am seeing the same results when using any of the default tools, such as "Balloons" in my example.

Steps to replicate:

I followed the code back to https://github.com/Facepunch/garrysmod/blob/394ae745df8f8f353ea33c8780f012fc000f4f56/garrysmod/lua/includes/modules/presets.lua, and can confirm that Remove is being called with the expected arguments, as is SavePresets. This function doesn't appear to be open source though, so I couldn't investigate any further.

I searched and found the previous issue https://github.com/Facepunch/garrysmod-issues/issues/3479, but appears this wasn't able to be replicated. If there is any further details I can provide, please let me know and I'll be happy to do so.

robotboy655 commented 5 years ago

Should be fixed on Dev.

Cherry commented 5 years ago

Thanks very much. I can confirm this is resolved in dev. 👍