Hot answers tagged

1

You are over-complicating things a little. First you're creating an array of one object. So the correct way to access the value of name in your example is shuttle.seats[j][0].name; Second, you could simply just set shuttle.seats[j] to a passenger (e.g., PASSENGER[i] assuming i is within the specified range) and access the value of name the way you want ...


1

Replace } on line 322 with ].


1

This seems to have fixed it for me, I think this is what you were talking about as your workaround number 1. Basically banish the person to 0,0 if (PASSENGERS[i].name == shuttle.seats[nextseat][0].name) { PASSENGERS[i].placemark.getGeometry().setLatitude(0); PASSENGERS[i].placemark.getGeometry().setLongitude(0); }


Only top voted, non community-wiki answers of a minimum length are eligible