-
Notifications
You must be signed in to change notification settings - Fork 116
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix serverside hologram position getting set to origin when parented #1975
Conversation
@adamnejm do you know how to test if the original thing this was fixing isn't an issue now? I think it was something to do with clientside holograms not keeping their offset? |
Yeah, I reverted to a commit before ac0a3bb and still cannot reproduce it, so pretty sure it got fixed by an update. |
@adamnejm for me, all the child holos get sent to the center of the parent, which seems wrong. |
That's weird, for me they keep the offset which is the correct behavior. |
OK, I can reproduce it on 32-bit branch Linux version. Not 64-bit tho. |
great, so its behavior varies by gmod branch. |
Varies by OS, branch and singleplayer/multiplayer? That's some cursed conditionals! |
Just branch and sp/mp I'm pretty sure. |
After more testing, I determined that the fix is to only apply the workaround to clientside holograms. Duh... it should've been like that from the beginning :D if self:EntIndex() == -1 then
self:SetParent(Entity(0))
self:SetParent()
end After that, everything works perfectly. Tested multiplayer and singleplayer on 32-bit and 64-bit. |
PS. This also fixes |
Also while the fix is not needed on 64-bit, I'd just leave it in instead of doing branch checking, it doesn't have any negative side-effects. |
Ahhh nice discovery |
Fixes: #1974