# Error: member access into incomplete type 'ULocalPlayer'

**URL:** <https://forums.unrealengine.com/t/error-member-access-into-incomplete-type-ulocalplayer/425934>\
**Category:** Platform & Builds\
**Tags:** webgl, HTML5, unreal-engine, UE4, CPP, question\
**Created:** [May 25, 2018, 12:49pm UTC](https://forums.unrealengine.com/t/error-member-access-into-incomplete-type-ulocalplayer/425934 "2018-05-25T12:49:51Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![anonymous\_user\_6d26f678](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_6d26f678](https://forums.unrealengine.com/u/anonymous_user_6d26f678)\
**Post date:** [May 25, 2018, 12:49pm UTC](https://forums.unrealengine.com/t/error-member-access-into-incomplete-type-ulocalplayer/425934/1 "2018-05-25T12:49:51Z")

</div>

Hey everyone,  
I’m getting an error while packing a project to HTML5. Apparently only if I do to HTML5 since on VisualStudio its compiles well, Although I receive the error highlight with the same message.

Would anyone be able to point me in a direction as of how to solve this?

**The error message I get while compiling is:**

> Unreal Projects/topDownCamera/Source/topDownCamera/topDownCameraPlayerController.cpp:169:29:  
> **error: member access into incomplete type ‘ULocalPlayer’ UATHelper:**  
> Empacotamento (HTML5):  
> Cast(Player)-\>ViewportClient-\>Viewport-\>SetMouse(mouseLockPositionX, mouseLockPositionY); UATHelper:  
> ^

**The corresponding part in the .ccp file :**

```
#include "topDownCameraPlayerController.h"
#include "AI/Navigation/NavigationSystem.h"
#include "Runtime/Engine/Classes/Components/DecalComponent.h"
#include "Runtime/Engine/Public/SceneView.h"
#include "HeadMountedDisplayFunctionLibrary.h"
#include "topDownCameraCharacter.h"
#include "Engine/World.h"
//...
void AtopDownCameraPlayerController::OnMouseHorizontal(float axisValue)
{
	if (lookAroundEnabled)
	{
		APawn* const Pawn = GetPawn();
		Pawn->AddControllerYawInput(axisValue);
		Cast<ULocalPlayer>(Player)->ViewportClient->Viewport->SetMouse(mouseLockPositionX, mouseLockPositionY);
	}
}

```

---

<div class="post-metadata">

**Author:** ![SeaShellWe](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@SeaShellWe](https://forums.unrealengine.com/u/SeaShellWe)\
**Post date:** [May 25, 2018, 1:12pm UTC](https://forums.unrealengine.com/t/error-member-access-into-incomplete-type-ulocalplayer/425934/2 "2018-05-25T13:12:52Z")

</div>

#include “Runtime/Engine/Classes/Engine/LocalPlayer.h”

Unless you included it already, this might help.  
You class doesn’t know what a ULocalPlayer is, and how to cast to it, without including it first.
