# FHitResult\* OutSweepHitResult = nullptr

**URL:** <https://forums.unrealengine.com/t/fhitresult-outsweephitresult-nullptr/340056>\
**Category:** Blueprint\
**Tags:** unreal-engine, CPP, Blueprint, question, pointers\
**Created:** [November 29, 2015, 11:16pm UTC](https://forums.unrealengine.com/t/fhitresult-outsweephitresult-nullptr/340056 "2015-11-29T23:16:54Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![shiftone](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@shiftone](https://forums.unrealengine.com/u/shiftone)\
**Post date:** [November 29, 2015, 11:16pm UTC](https://forums.unrealengine.com/t/fhitresult-outsweephitresult-nullptr/340056/1 "2015-11-29T23:16:54Z")

</div>

UFUNCTION(BlueprintCallable, Category = “Utilities|Transformation”, meta = (DisplayName = “AddLocalRotationQuat”, AdvancedDisplay = “bSweep,SweepHitResult,bTeleport”))  
void AddLocalRotationQuat(const FQuat& DeltaRotation, bool bSweep = false, FHitResult\* OutSweepHitResult = nullptr, ETeleportType Teleport = ETeleportType::None);

im getting the following error 2\> Inappropriate ‘\*’ on variable of type ‘FHitResult’, cannot have an exposed pointer to this type.

I must be missing something because this seems to be used within the core engine also?

---

<div class="post-metadata">

**Author:** ![Begounet](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Begounet](https://forums.unrealengine.com/u/Begounet)\
**Post date:** [November 30, 2015, 8:57am UTC](https://forums.unrealengine.com/t/fhitresult-outsweephitresult-nullptr/340056/2 "2015-11-30T08:57:59Z")

</div>

Hello,

In fact, the engine uses an other function for the node :

```
UFUNCTION(BlueprintCallable, meta=(DisplayName = "SetActorLocation", Keywords="position"), Category="Utilities|Transformation")
bool K2_SetActorLocation(FVector NewLocation, bool bSweep, FHitResult& SweepHitResult, bool bTeleport);
```

---

<div class="post-metadata">

**Author:** ![Mattlauk](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Mattlauk](https://forums.unrealengine.com/u/Mattlauk)\
**Post date:** [November 30, 2015, 8:25pm UTC](https://forums.unrealengine.com/t/fhitresult-outsweephitresult-nullptr/340056/3 "2015-11-30T20:25:47Z")

</div>

To expand on this answer, when writing functions meant for blueprint use and you need to pass something by reference, you have to use the reference operator(`&`) and not the pointer operator (`*`).
