ArticyXImporter
ArticyXImporter for Unreal Engine
Loading...
Searching...
No Matches
ArticyObjectWithPosition.h
1//
2// Copyright (c) 2023 articy Software GmbH & Co. KG. All rights reserved.
3//
4
5#pragma once
6
7#include "ArticyObjectWith_Base.h"
8#include "ArticyObjectWithPosition.generated.h"
9
10UINTERFACE(MinimalAPI, BlueprintType, meta=(CannotImplementInterfaceInBlueprint))
11class UArticyObjectWithPosition : public UArticyObjectWith_Base { GENERATED_BODY() };
12
17{
18 GENERATED_BODY()
19
20public:
21
22 UFUNCTION(BlueprintCallable, Category="ArticyObjectWithPosition")
23 virtual FVector2D& GetPosition()
24 {
25 static const auto& PropName = FName("Position");
26 return GetProperty<FVector2D>(PropName);
27 }
28
29 virtual const FVector2D& GetPosition() const
30 {
31 return const_cast<IArticyObjectWithPosition*>(this)->GetPosition();
32 }
33
34 //---------------------------------------------------------------------------//
35
36 UFUNCTION(BlueprintCallable, Category="ArticyObjectWithPosition")
37 virtual FVector2D& SetPosition(UPARAM(ref) const FVector2D& Position)
38 {
39 return GetPosition() = Position;
40 }
41};
Definition ArticyObjectWithPosition.h:17
Definition ArticyObjectWith_Base.h:27
Definition ArticyObjectWithPosition.h:11
Definition ArticyObjectWith_Base.h:12