branch | noai |
changeset 11057 | 188a9ca6d8de |
parent 11029 | 776c7cc8bda5 |
child 11168 | 3842648184cd |
--- a/src/ai/api/ai_vehicle.cpp Mon Jun 23 12:33:38 2008 +0000 +++ b/src/ai/api/ai_vehicle.cpp Mon Jun 23 12:46:38 2008 +0000 @@ -276,3 +276,10 @@ return amount; } + +/* static */ GroupID AIVehicle::GetGroupID(VehicleID vehicle_id) +{ + if (!IsValidVehicle(vehicle_id)) return ::INVALID_GROUP; + + return ::GetVehicle(vehicle_id)->group_id; +}