I just ran into a problem while trying to find the index of an item in a List of structs of the type levelSeed. Here is the code…
int seedIndex = LevelObjects.IndexOf( item => item.unique == 1234 );
Sadly, this line of code, generates the following compiler error
error CS1660: Cannot convert 'lambda expression' to non-delegate type 'levelSeed'
Does anyone know what I’m doing wrong or what I may be missing? Do I have to include anything in the source to make Lambda expressions work?