CARLA
载入中...
搜索中...
未找到
Unreal
CarlaUE4
Plugins
Carla
Source
Carla
Util
ActorAttacher.h
浏览该文件的文档.
1
// Copyright (c) 2017 Computer Vision Center (CVC) at the Universitat Autonoma
2
// de Barcelona (UAB).
3
//
4
// This work is licensed under the terms of the MIT license.
5
// For a copy, see <https://opensource.org/licenses/MIT>.
6
7
#pragma once
8
9
#include <
compiler/disable-ue4-macros.h
>
10
#include <
carla/rpc/AttachmentType.h
>
11
#include <
compiler/enable-ue4-macros.h
>
12
13
#include "Kismet/BlueprintFunctionLibrary.h"
14
15
#include "ActorAttacher.generated.h"
16
17
#define CARLA_ENUM_FROM_RPC(e) static_cast<uint8>(carla::rpc::AttachmentType:: e)
18
19
UENUM(BlueprintType)
20
enum class
EAttachmentType
: uint8
21
{
22
Null
= 0,
// Workarround for UE4.24 issue with enums
23
Rigid
=
CARLA_ENUM_FROM_RPC
(
Rigid
)
UMETA
(DisplayName =
"Rigid"
),
24
SpringArm
=
CARLA_ENUM_FROM_RPC
(
SpringArm
)
UMETA
(DisplayName =
"SpringArm"
),
25
SpringArmGhost
=
CARLA_ENUM_FROM_RPC
(
SpringArmGhost
)
UMETA
(DisplayName =
"SpringArmGhost"
),
26
27
SIZE
UMETA
(Hidden),
28
INVALID
UMETA
(Hidden)
29
};
30
31
static_assert
(
32
static_cast<
uint8
>
(EAttachmentType::SIZE) ==
static_cast<
uint8
>
(
carla::rpc::AttachmentType::SIZE
),
33
"Please keep these two enums in sync."
);
34
35
#undef CARLA_ENUM_FROM_RPC
36
37
UCLASS()
38
class CARLA_API
UActorAttacher
: public
UBlueprintFunctionLibrary
39
{
40
GENERATED_BODY()
41
42
public
:
43
44
UFUNCTION(BlueprintCallable, Category=
"CARLA|Actor Attacher"
)
45
static
void
AttachActors(
AActor
*Child,
AActor
*Parent,
EAttachmentType
AttachmentType,
const
FString& SocketName =
""
);
46
};
EAttachmentType
EAttachmentType
Definition
ActorAttacher.h:21
EAttachmentType::SpringArm
@ SpringArm
EAttachmentType::SpringArmGhost
@ SpringArmGhost
EAttachmentType::UMETA
@ UMETA
EAttachmentType::Null
@ Null
EAttachmentType::Rigid
@ Rigid
CARLA_ENUM_FROM_RPC
#define CARLA_ENUM_FROM_RPC(e)
Definition
ActorAttacher.h:17
AttachmentType.h
EVehicleInputPriority::INVALID
@ INVALID
AActor
UActorAttacher
Definition
ActorAttacher.h:39
UBlueprintFunctionLibrary
disable-ue4-macros.h
enable-ue4-macros.h
carla::rpc::AttachmentType::SIZE
@ SIZE
制作者
1.10.0