ai.c
changeset 1024 5e446b5b3ec5
parent 959 e6a3bbda610f
child 1035 812f837ee03f
equal deleted inserted replaced
1023:1ae7b7a78602 1024:5e446b5b3ec5
  3616 	// Go to this state when we're done.
  3616 	// Go to this state when we're done.
  3617 	p->ai.state = AIS_1;
  3617 	p->ai.state = AIS_1;
  3618 
  3618 
  3619 	// Get a list of all stations that are in use by a vehicle
  3619 	// Get a list of all stations that are in use by a vehicle
  3620 	memset(in_use, 0, sizeof(in_use));
  3620 	memset(in_use, 0, sizeof(in_use));
  3621 	for (ord = _order_array; ord != _ptr_to_next_order; ++ord) {
  3621 	FOR_ALL_ORDERS(ord) {
  3622 		if (ord->type == OT_GOTO_STATION)
  3622 		if (ord->type == OT_GOTO_STATION)
  3623 			in_use[ord->station] = 1;
  3623 			in_use[ord->station] = 1;
  3624 	}
  3624 	}
  3625 
  3625 
  3626 	// Go through all stations and delete those that aren't in use
  3626 	// Go through all stations and delete those that aren't in use