Closed dvdvideo1234 closed 3 months ago
This also causes this issue: https://github.com/wiremod/advduplicator/issues/91
It is important to note that this behavior is kinda unexpected as it makes the TOOL:Think()
call bypass TOOL:Deploy()
and TOOL:Holster()
. This causes construction and/or deconstruction logic not being checked/called in the right order.
Core issue aside, your issue could be solved with 3 lines of code, by properly implementing base TOOL hooks:
function TOOL:ReleaseGhostEntity()
asmlib.ClearGhosts()
end
Core issue being just the network delay to update gmod_toolmode
convar clientside, from the server, to switch the toolmode clientside.
It's not "calling think on the old tool while a new one is active", it's just that the toolmode switch clientside is delayed.
Sorry.. Clicked the close by mistake
Ok, I have made some changes to how tool switching works, it should now call Tool:Holster on the old tool clientside when swtiching tools. This was previously only happening serverside, and only when using gmod_tool
concommand. (As opposed to gmod_toolmode
convar)
Please try running a different branch and verifying your game file integrity before reporting an issue.
Verification completed successfully ( all branches below ) and tested for every beta with and without addons:
Details
The
TOOL:Think()
routine is called one last time for toolX
after user switches from toolX
to toolY
. The current game version running is:Steps to reproduce
MASTER
version of the TA tool1
to select the crowbar. The ghost is removed viaRemoveEntityDelay
and gone after the given time. All OK here tooDetails about the issue and the current workaround can be found here: https://github.com/dvdvideo1234/TrackAssemblyTool/issues/58