src/group_cmd.cpp
branchNewGRF_ports
changeset 6878 7d1ff2f621c7
parent 6872 1c4a4a609f85
child 10184 fcf5fb2548eb
equal deleted inserted replaced
6877:889301acc299 6878:7d1ff2f621c7
   132 		/* Add all vehicles belong to the group to the default group */
   132 		/* Add all vehicles belong to the group to the default group */
   133 		FOR_ALL_VEHICLES(v) {
   133 		FOR_ALL_VEHICLES(v) {
   134 			if (v->group_id == g->index && v->type == g->vehicle_type) v->group_id = DEFAULT_GROUP;
   134 			if (v->group_id == g->index && v->type == g->vehicle_type) v->group_id = DEFAULT_GROUP;
   135 		}
   135 		}
   136 
   136 
       
   137 		/* Update backupped orders if needed */
       
   138 		if (_backup_orders_data.group == g->index) _backup_orders_data.group = DEFAULT_GROUP;
       
   139 
   137 		/* If we set an autoreplace for the group we delete, remove it. */
   140 		/* If we set an autoreplace for the group we delete, remove it. */
   138 		if (_current_player < MAX_PLAYERS) {
   141 		if (_current_player < MAX_PLAYERS) {
   139 			Player *p;
   142 			Player *p;
   140 			EngineRenew *er;
   143 			EngineRenew *er;
   141 
   144