diff --git a/LibCarla/source/carla/rpc/EnvironmentObject.h b/LibCarla/source/carla/rpc/EnvironmentObject.h index 2944d5108..e7d162017 100644 --- a/LibCarla/source/carla/rpc/EnvironmentObject.h +++ b/LibCarla/source/carla/rpc/EnvironmentObject.h @@ -31,11 +31,12 @@ namespace rpc { : transform(EnvironmentObject.Transform), bounding_box(EnvironmentObject.BoundingBox), id(EnvironmentObject.Id), - name(TCHAR_TO_UTF8(*EnvironmentObject.Name)) {} + name(TCHAR_TO_UTF8(*EnvironmentObject.Name)), + type(EnvironmentObject.ObjectLabel) {} #endif // LIBCARLA_INCLUDED_FROM_UE4 - MSGPACK_DEFINE_ARRAY(transform, bounding_box, id, name); + MSGPACK_DEFINE_ARRAY(transform, bounding_box, id, name, type); }; } // namespace rpc diff --git a/Unreal/CarlaUE4/Plugins/Carla/Source/Carla/Util/EnvironmentObject.h b/Unreal/CarlaUE4/Plugins/Carla/Source/Carla/Util/EnvironmentObject.h index a8e832416..841c1b055 100644 --- a/Unreal/CarlaUE4/Plugins/Carla/Source/Carla/Util/EnvironmentObject.h +++ b/Unreal/CarlaUE4/Plugins/Carla/Source/Carla/Util/EnvironmentObject.h @@ -13,6 +13,17 @@ namespace crp = carla::rpc; +enum EnvironmentObjectType +{ + Invalid, + Vehicle, + Character, + TrafficLight, + ISMComp, + SMComp, + SKMComp +}; + // Name is under discussion USTRUCT(BlueprintType) struct CARLA_API FEnvironmentObject @@ -32,6 +43,8 @@ struct CARLA_API FEnvironmentObject uint64 Id = 0; + EnvironmentObjectType Type = EnvironmentObjectType::Invalid; + crp::CityObjectLabel ObjectLabel; bool CanTick = false;