NativeHashSet

Hello everyone,

I’ve read about NativeHashSets in the documentation: Struct NativeHashSet<T> | Collections | 0.14.0-preview.16

When I try to use NativeHashSet it doesn’t seem to be implemented yet. I have installed the latest version of Unity.Collections available, but that is maybe not the correct version as the documentation says it’s version 0.14.0-preview.16? But even with the latest beta build of unity I can’t get it from the package manager. How can I use NativeHashSets then? Am I missing something?

Happy new year!

How are you inferring this? Do you get a System.NotImplementedException?

I get the error
“…CS0246: The type or namespace name ‘NativeHashSet<>’ could not be found (are you missing a using directive or an assembly reference?)”
I’m using using Unity.Collections; and all the other stuff like NativeArray, NativeList and such is working. Am I missing something?

Just if somebody is interested: Edit > Preferences > External Tools > Regenerate Project Files did the trick.

4 Likes

thanks! it worked! I changed the editor into Visual Studio and regenerated project files then restarted.