# Is there a way to trigger a level sequence in C++?

**URL:** <https://forums.unrealengine.com/t/is-there-a-way-to-trigger-a-level-sequence-in-c/381446>\
**Category:** C++\
**Tags:** unreal-engine, CPP, question\
**Created:** [January 10, 2017, 2:27pm UTC](https://forums.unrealengine.com/t/is-there-a-way-to-trigger-a-level-sequence-in-c/381446 "2017-01-10T14:27:49Z")\
**Posts on this page:** 1\
**Showing post:** 16

<div class="post-metadata">

**Author:** ![Ariel\_Gimenez](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/ariel_gimenez/32/591990_2.png) [@Ariel\_Gimenez](https://forums.unrealengine.com/u/Ariel_Gimenez)\
**Post date:** [September 22, 2022, 11:43am UTC](https://forums.unrealengine.com/t/is-there-a-way-to-trigger-a-level-sequence-in-c/381446/16 "2022-09-22T11:43:43Z")

</div>

> [@Unreal engine how to put play to a level sequencer from C++ "get an ALevelSequenceActor from the scene in c++"](https://forums.unrealengine.com/t/unreal-engine-how-to-put-play-to-a-level-sequencer-from-c-get-an-alevelsequenceactor-from-the-scene-in-c/502492/1):
>
> Unreal Engine Version: 4.27.2-18319896+++UE4+Release-4.27 [[Screenshot\_6]](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/9/0/090011f910d8ccf36efee452a1785bf394814c87.jpeg) Does anyone know how to include ALevelSequenceActor in a .CPP file, I did not enter the form, it shows me an error… The issue is that I want to handle the levelsequence from C++ but I can’t find a way to include the library. I mean I include it like this. [Screenshot\_5] code: #include \<LevelSequence/Public/LevelSequenceActor.h\> and if i want to do this Error in ALevelSequenceActor::StaticClass(). [[Screenshot\_12]](https://d3kjluh73b9h9o.cloudfront.net/original/4X/f/6/a/f6af9c0a84223c57041421d61f148cc9c3debd98.jpeg) …

in .cpp  
 ![Screenshot_4](https://d3kjluh73b9h9o.cloudfront.net/original/4X/0/3/1/031e87f5eb539150c188aac81499532a664575a0.jpeg)

in archive build.cs add this

 ![Screenshot_5](https://d3kjluh73b9h9o.cloudfront.net/original/4X/8/b/a/8ba4fefc8887345075607b452289a53977539b84.jpeg)

```auto

//level sequencer .CPP
#include <LevelSequenceActor.h>
#include <LevelSequencePlayer.h>
#include <MovieSceneSequencePlayer.h>

```

in archive build.cs add this

```auto
	PublicDependencyModuleNames.AddRange(new string[] { "Core", "CoreUObject", "Engine", "InputCore", "LevelSequence", "MovieScene" });

```

---

_[View the full topic](https://forums.unrealengine.com/t/is-there-a-way-to-trigger-a-level-sequence-in-c/381446)._
