Description
When using entity:aimBone(), the bone will be null despite looking at a proper ragdoll. Using entity:bone(number) on an entity does not cause this.
Expected behavior
The print statement should show something like Entity [100][prop_ragdoll]:bone(1).
Notes:
In testing this, entity:aimBone() does return a valid bone, but in isValidBone, the bone gets invalidated wrongly. When performing bone2entity[b], this returns nil even when an equivalent reference to the bone is in the table. Annoyingly, this only happens when using aimBone. This shouldn't happen since getBone uses a cached value which is guaranteed to be in bone2index, bone2entity, and entity2bone.
Description When using
entity:aimBone()
, the bone will be null despite looking at a proper ragdoll. Usingentity:bone(number)
on an entity does not cause this.To Reproduce Steps to reproduce the behavior:
(null)
Expected behavior The print statement should show something like
Entity [100][prop_ragdoll]:bone(1)
.Notes: In testing this,
entity:aimBone()
does return a valid bone, but inisValidBone
, the bone gets invalidated wrongly. When performingbone2entity[b]
, this returnsnil
even when an equivalent reference to the bone is in the table. Annoyingly, this only happens when usingaimBone
. This shouldn't happen sincegetBone
uses a cached value which is guaranteed to be inbone2index
,bone2entity
, andentity2bone
.