Just wanted to report a bug I found with AC version 1.83.0, we are using the "Slow movement near walls?" toggle which was working but then we updated to this version and it stopped.
After some investigation, I have discovered that the code which handles the collision detection uses the "wallLayer" variable which is serialized inside of Char.cs but never actually gets set anywhere. I was able to correct this issue by changing some code inside of the UpdateWallReductionFactor() method from using the "wallLayer" variable to instead use the "WallLayerMask" property, so from this...
RaycastHit2D hit = UnityVersionHandler.Perform2DRaycast (origin, forwardVector, wallDistance, 1 << LayerMask.NameToLayer (wallLayer));
to this...
RaycastHit2D hit = UnityVersionHandler.Perform2DRaycast (origin, forwardVector, wallDistance, WallLayerMask);
It looks like you're new here. If you want to get involved, click one of these buttons!
Comments
Oops. Actually, this issue is actually a bit different.
The
wallLayer
variable was deprecated in favour of the newwallLayerMask
variable - see the "Upgrade note" section for v1.83:Character Inspectors have had their "Wall collision" fields changed from text fields to a new LayerMask option.
The real issue is that Char doesn't rely on it!
To fix, replace the above-mentioned instance of:
to:
Thanks for the report!