Anybody faced this error when installing Cinemachine in unity 6

Library\PckageCache\com.unity.cinemachine\Runtime\Impulse\CinemachineCollisionImpulseSource.cs(180,46): error CS1061: ‘Rigidbody2D’ does not contain a definition for ‘linearVelocity’ and no accessible extension method ‘linearVelocity’ accepting a first argument of type ‘Rigidbody2D’ couald be found (are you missing a using directive or an assembly reference?)

1 Like

Which exact version of Unity6, and which exact version of Cinemachine?

Unity version is 6000.0.7f1

And Cinemachine version 3.2.1

The property was renamed in Unity version 6000.0.11f1. Updating to any editor version from that point on should resolve this.

Well, What I did that I changed linearVelocity to velocity and error from console is gone, And because my project is not in 2d so I don’t think that it will create any problem in that, but I am not sure about 2d projects, and for updating to a newer version is again risky what if something like that any other issue come in it.

2 Likes

A better solution is to upgrade to a more recent version of Unity.

4 Likes

I am sorry, but it is not a better solution if it still happens in the newest Unity version and the project is not even using a 2D rigidbody.

Which version of Unity are you using? The property was renamed in Unity version 6000.0.11f1. Updating to any editor version from that point on should resolve this.

I am on 6.0.3f1 so plenty of later. I also do not need help thank you though. My comment is for future reference, so people who still have the issue are not irritated.

Changing the the script for Rigidbody 2D is okay if you are not using rigidbody2d.
Any other fix would take too much time for something that is should not hinder development.

1 Like