I see a couple problems:
- ToList returns an object of Type List and you're attempting to assign it to a Transform[].
- ToList(Transform) should read ToList(transform) (get the instance name, not the type name)
- Linq's ToList operates on the generic IEnumerable interface, which Transform does not implement (it implements the old-school IEnumerable). Linq does provide a function that'll fix this for you (code example below)
This example is in C# because I am unsure of the generic argument syntax for javascript:
List availablePositions = transform.Cast().ToList();
↧