BCE0051: Operator '<' cannot be used with a left hand side of type 'Object' and a right hand side of type 'int'.

for( var doorCheckingNow : GameObject in currentCell.GetComponent(AIPathCellScript).doors)
{ // statement that go through the list of every cell in the game
for (var i : int = 0; i <= doorCheckingNow.GetComponent(AIpathDoorScript).cells.length -1; i++)
{

if( doorCheckingNow.GetComponent( AIpathDoorScript).cells *== playerCell)*

if( doorCheckingNow.GetComponent( AIpathDoorScript).doorsToCells < shortPathSoFar)
// // here is the line doorTocell is a array with objects and it is a function array.
not to sure whats going on, I think it has something to do with a array with object can’t be less then a float, Just don’t know how to rewrite it the correct way. Any help will be apperciated

“length” should be Length.

doorsToCells needs to be an array of numbers.
I don’t understand what you mean by “function array” and I don’t think you do either.

If doorsToCells is an array of scripts you have to get a number out of doorsToCells somehow.
You probably need to calculate the distance to doorsToCells from playerCell and compare that to shortPathSoFar in the next line.