# C++

**URL:** https://forums.unrealengine.com/c/development-discussion/programming-scripting/c-programming/29.md?page=99

[Latest](https://forums.unrealengine.com/latest.md) · [Categories](https://forums.unrealengine.com/categories.md) · [Tags](https://forums.unrealengine.com/tags.md)

**Page:** 100

---

## [AIController possession and switching back to PlayerController Issues](https://forums.unrealengine.com/t/aicontroller-possession-and-switching-back-to-playercontroller-issues/1914864)

<div class="topic-metadata">

**Author:** [@TheTechGent](https://forums.unrealengine.com/u/TheTechGent)\
**Replies:** 1\
**Last updated:** [June 24, 2024, 8:31pm UTC](https://forums.unrealengine.com/t/aicontroller-possession-and-switching-back-to-playercontroller-issues/1914864 "2024-06-24T20:31:47Z")

</div>

Hi, I hope someone can assist with this as I’m struggling to figure out where I have gone wrong. Mechanic I’m trying to acheive: Upon seeing (I am using a sweep - geom trace) an object that can be used for hiding (I cr…

---

## [C++ GetPawn before Input checks](https://forums.unrealengine.com/t/c-getpawn-before-input-checks/1915083)

<div class="topic-metadata">

**Author:** [@JMelter](https://forums.unrealengine.com/u/JMelter)\
**Replies:** 1\
**Last updated:** [June 24, 2024, 8:31pm UTC](https://forums.unrealengine.com/t/c-getpawn-before-input-checks/1915083 "2024-06-24T20:31:37Z")

</div>

Hello community. I am new at Unreal Engine with C++. So I got a newbie question for you. I Am trying to make my character move in multiplayer and I got this function: void ACMyPlayerController::OnPossess(APawn\* InPawn…

---

## [5.2 Seamless travel destroys my player controller and creates a new one](https://forums.unrealengine.com/t/5-2-seamless-travel-destroys-my-player-controller-and-creates-a-new-one/1181649)

<div class="topic-metadata">

**Author:** [@ultrafrog2012](https://forums.unrealengine.com/u/ultrafrog2012)\
**Replies:** 4\
**Last updated:** [June 24, 2024, 4:57pm UTC](https://forums.unrealengine.com/t/5-2-seamless-travel-destroys-my-player-controller-and-creates-a-new-one/1181649 "2024-06-24T16:57:06Z")

</div>

I updated my project from 5.1 to 5.2. In the new version, the seamless travel behavor changed. Even the widget is added to the viewport using “AddToViewport()” (and it is visible up until the travel), it is destroyed dur…

---

## [Incorrect display of FCanvasTextItem](https://forums.unrealengine.com/t/incorrect-display-of-fcanvastextitem/1903079)

<div class="topic-metadata">

**Author:** [@Hades\_Baba1](https://forums.unrealengine.com/u/Hades_Baba1)\
**Replies:** 1\
**Last updated:** [June 24, 2024, 10:47am UTC](https://forums.unrealengine.com/t/incorrect-display-of-fcanvastextitem/1903079 "2024-06-24T10:47:39Z")

</div>

I have been learning a demo of JSBSIM recently. Epic Games provided a demo called UEReferenceApp. As I delved into the demo’s learning process, I encountered an issue where the string in the image would display in the wr…

---

## [how can I override a subobject from a base class?](https://forums.unrealengine.com/t/how-can-i-override-a-subobject-from-a-base-class/155230)

<div class="topic-metadata">

**Author:** [@wavebird](https://forums.unrealengine.com/u/wavebird)\
**Replies:** 5\
**Last updated:** [June 24, 2024, 10:12am UTC](https://forums.unrealengine.com/t/how-can-i-override-a-subobject-from-a-base-class/155230 "2024-06-24T10:12:41Z")

</div>

Hello, I would like to know how to properly override subobjects from a base class. Let’s say I create a child class that overrides from ACharacter, the class will come with a MovementComponent, however if I have my own …

---

## [Output parameters are C# stuff, is that true?](https://forums.unrealengine.com/t/output-parameters-are-c-stuff-is-that-true/1914488)

<div class="topic-metadata">

**Author:** [@ViaCognita](https://forums.unrealengine.com/u/ViaCognita)\
**Replies:** 1\
**Last updated:** [June 24, 2024, 7:59am UTC](https://forums.unrealengine.com/t/output-parameters-are-c-stuff-is-that-true/1914488 "2024-06-24T07:59:04Z")

</div>

Hi! Yesterday, someone in Unreal Slackers said me that output parameters are unusual in C++, they are C# stuff, is that true? I don’t think so. I’m sure there are methods in Unreal with output parameters. As you have n…

---

## [Workarounds for Engine Hanging Bug During Line Traces](https://forums.unrealengine.com/t/workarounds-for-engine-hanging-bug-during-line-traces/1914066)

<div class="topic-metadata">

**Author:** [@EmpireJones](https://forums.unrealengine.com/u/EmpireJones)\
**Replies:** 0\
**Last updated:** [June 23, 2024, 9:15pm UTC](https://forums.unrealengine.com/t/workarounds-for-engine-hanging-bug-during-line-traces/1914066 "2024-06-23T21:15:28Z")

</div>

This isn’t specifically a C++ question, but might need some C++ expertise to dig into the engine code to determine a workaround. I’m encountering an issue with the engine hanging when performing line traces at certain c…

---

## [Whether the event stays bound?](https://forums.unrealengine.com/t/whether-the-event-stays-bound/1913207)

<div class="topic-metadata">

**Author:** [@blAddddDe](https://forums.unrealengine.com/u/blAddddDe)\
**Replies:** 2\
**Last updated:** [June 23, 2024, 7:33pm UTC](https://forums.unrealengine.com/t/whether-the-event-stays-bound/1913207 "2024-06-23T19:33:53Z")

</div>

Hi all, I’m wondering if I need OnNotificationStopDisplay.RemoveDynamic(...) or or it will remove the binding itself. Here’s the Code: void UHUDWidgetBase::TryToInvokeNotification() { if(CurrentNotification) return; i…

---

## [BP vs C++ How to Make Audio Persist Between Levels?](https://forums.unrealengine.com/t/bp-vs-c-how-to-make-audio-persist-between-levels/1912842)

<div class="topic-metadata">

**Author:** [@Uulamock](https://forums.unrealengine.com/u/Uulamock)\
**Replies:** 2\
**Last updated:** [June 23, 2024, 7:20pm UTC](https://forums.unrealengine.com/t/bp-vs-c-how-to-make-audio-persist-between-levels/1912842 "2024-06-23T19:20:11Z")

</div>

I am experiencing the most vexing problem. Every tutorial you see posted basically says the same thing when trying to make audio work across levels - make a custom game instance and store the audio component there. An…

---

## [Creating custom Rich Text Block decorators](https://forums.unrealengine.com/t/creating-custom-rich-text-block-decorators/117425)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_0f256437](https://forums.unrealengine.com/u/anonymous_user_0f256437)\
**Replies:** 7\
**Last updated:** [June 23, 2024, 9:08am UTC](https://forums.unrealengine.com/t/creating-custom-rich-text-block-decorators/117425 "2024-06-23T09:08:49Z")

</div>

Hi there! I’ve been trying to create my own custom RichTextBlockDecorator in C++, and I’ve run into a problem which has me stumped. Whenever I try to compile code that uses a class that subclasses the FRichTextDecorator…

---

## [Streaming an arbitrary sublevel by-name at runtime](https://forums.unrealengine.com/t/streaming-an-arbitrary-sublevel-by-name-at-runtime/1898273)

<div class="topic-metadata">

**Author:** [@protowlf](https://forums.unrealengine.com/u/protowlf)\
**Replies:** 3\
**Last updated:** [June 23, 2024, 7:23am UTC](https://forums.unrealengine.com/t/streaming-an-arbitrary-sublevel-by-name-at-runtime/1898273 "2024-06-23T07:23:11Z")

</div>

Hi there, I want to know how to stream-in sublevels at runtime by-name, and append them under the current persistent level. As well as remove and unload those sublevels as I stream in new ones. I cannot have them manuall…

---

## [Unreal engine simple collision detection C++](https://forums.unrealengine.com/t/unreal-engine-simple-collision-detection-c/1912689)

<div class="topic-metadata">

**Author:** [@1GameMaker](https://forums.unrealengine.com/u/1GameMaker)\
**Replies:** 5\
**Last updated:** [June 22, 2024, 3:41pm UTC](https://forums.unrealengine.com/t/unreal-engine-simple-collision-detection-c/1912689 "2024-06-22T15:41:32Z")

</div>

Hello. So, I am new to unreal engine, and I wanted to check if a Pawn is colliding with an Actor using UBoxComponent, then Print a message into the debug. But what I found was for UE 4 and not for UE 5 (Unreal engine 5.4…

---

## [Map of wildcards Input Parameter](https://forums.unrealengine.com/t/map-of-wildcards-input-parameter/469133)

<div class="topic-metadata">

**Author:** [@Electus1](https://forums.unrealengine.com/u/Electus1)\
**Replies:** 5\
**Last updated:** [June 22, 2024, 2:48pm UTC](https://forums.unrealengine.com/t/map-of-wildcards-input-parameter/469133 "2024-06-22T14:48:05Z")

</div>

I’m trying to create my own blueprints, I would like them to have an input of a map of wildcards. Ideally a map of “wildcards to floats” would be perfect. I was able to get a an array of wildcards but I’d rather not have…

---

## [Why does the this method cause lag,when I debugging here?](https://forums.unrealengine.com/t/why-does-the-this-method-cause-lag-when-i-debugging-here/1909629)

<div class="topic-metadata">

**Author:** [@weihongfei666](https://forums.unrealengine.com/u/weihongfei666)\
**Replies:** 6\
**Last updated:** [June 22, 2024, 5:39am UTC](https://forums.unrealengine.com/t/why-does-the-this-method-cause-lag-when-i-debugging-here/1909629 "2024-06-22T05:39:07Z")

</div>

---

## [Failed to connect to file server on series x](https://forums.unrealengine.com/t/failed-to-connect-to-file-server-on-series-x/213525)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_d9f4baab](https://forums.unrealengine.com/u/anonymous_user_d9f4baab)\
**Replies:** 2\
**Last updated:** [June 21, 2024, 5:55pm UTC](https://forums.unrealengine.com/t/failed-to-connect-to-file-server-on-series-x/213525 "2024-06-21T17:55:34Z")

</div>

When I run my game on the series X, I get this error: Failed to connect to file server at xx.xxx.xx.xx, the IP mentioned here matches the IP address of my computer on my network. Am not sure why the code cannot connect…

---

## [Changing enum to string](https://forums.unrealengine.com/t/changing-enum-to-string/632111)

<div class="topic-metadata">

**Author:** [@anon15805799](https://forums.unrealengine.com/u/anon15805799)\
**Replies:** 8\
**Last updated:** [June 21, 2024, 4:12pm UTC](https://forums.unrealengine.com/t/changing-enum-to-string/632111 "2024-06-21T16:12:48Z")

</div>

//I created an enum: UENUM(BlueprintType) enum class EStaminaStatus : uint8 { ESS\_Normal UMETA(DisplayName = “Normal”), ESS\_BelowMinimum UMETA(DisplayName = “BelowMinimum”), ESS\_Exhausted UMETA(DisplayName = “Exhau…

---

## [Attempting to run project, getting an Invalid Character Movement component in Garbage Collection](https://forums.unrealengine.com/t/attempting-to-run-project-getting-an-invalid-character-movement-component-in-garbage-collection/1911060)

<div class="topic-metadata">

**Author:** [@LABS](https://forums.unrealengine.com/u/LABS)\
**Replies:** 0\
**Last updated:** [June 21, 2024, 4:02am UTC](https://forums.unrealengine.com/t/attempting-to-run-project-getting-an-invalid-character-movement-component-in-garbage-collection/1911060 "2024-06-21T04:02:16Z")

</div>

Hi everyone- a strange error has started to occur in my project. When I attempt to run, I get the following: \[2024.06.21-03.58.26:357\]\[ 0\]LogUObjectBase: Error: 'this' pointer is invalid. Fatal error: \[File:D:\\build\\++…

---

## [How to Dynamically Generate and Register Landscape Components?](https://forums.unrealengine.com/t/how-to-dynamically-generate-and-register-landscape-components/1910965)

<div class="topic-metadata">

**Author:** [@Lewchan](https://forums.unrealengine.com/u/Lewchan)\
**Replies:** 0\
**Last updated:** [June 21, 2024, 2:19am UTC](https://forums.unrealengine.com/t/how-to-dynamically-generate-and-register-landscape-components/1910965 "2024-06-21T02:19:57Z")

</div>

I’m researching how to dynamically generate a Landscape, and I’m stuck at the first step. After dynamically generating a LandscapeActor, I encounter issues when creating and registering a LandscapeComponent. The process …

---

## [Unreal 5.4.2 SQLite has stopped compiling](https://forums.unrealengine.com/t/unreal-5-4-2-sqlite-has-stopped-compiling/1891576)

<div class="topic-metadata">

**Author:** [@Commander\_Nimrod](https://forums.unrealengine.com/u/Commander_Nimrod)\
**Replies:** 8\
**Last updated:** [June 20, 2024, 9:09pm UTC](https://forums.unrealengine.com/t/unreal-5-4-2-sqlite-has-stopped-compiling/1891576 "2024-06-20T21:09:20Z")

</div>

I’ve been using SQLiteCore and SQLiteSupport since Unreal 5.3. After updating the Engine to 5.4.2 from 5.4.1 the project no longer compiles. fatal error C1083: Cannot open include file: 'SQLiteDatabase.h': No such file …

---

## [Error in "shipping" packaging](https://forums.unrealengine.com/t/error-in-shipping-packaging/1910610)

<div class="topic-metadata">

**Author:** [@Porkoss](https://forums.unrealengine.com/u/Porkoss)\
**Replies:** 2\
**Last updated:** [June 20, 2024, 8:48pm UTC](https://forums.unrealengine.com/t/error-in-shipping-packaging/1910610 "2024-06-20T20:48:40Z")

</div>

Unable to package project in shipping config. I have tried a lot of things and it still does not works. The problem comes from here. Unable to instantiate module ‘UnrealEd’: Unable to instantiate UnrealEd module for n…

---

## [\[CPP\] Why doesn't my Broadcast work / Why the delegate is not being called?](https://forums.unrealengine.com/t/cpp-why-doesnt-my-broadcast-work-why-the-delegate-is-not-being-called/1910136)

<div class="topic-metadata">

**Author:** [@blAddddDe](https://forums.unrealengine.com/u/blAddddDe)\
**Replies:** 5\
**Last updated:** [June 20, 2024, 7:05pm UTC](https://forums.unrealengine.com/t/cpp-why-doesnt-my-broadcast-work-why-the-delegate-is-not-being-called/1910136 "2024-06-20T19:05:16Z")

</div>

There's a delegate: I add a function to it in another actor: And call it accordingly (the call is made from the component in which the delegate was declared). but when this delegate is called, the UpdateWorldMar…

---

## [Constraining mesh in natural position](https://forums.unrealengine.com/t/constraining-mesh-in-natural-position/1906875)

<div class="topic-metadata">

**Author:** [@Flaccid\_Jack](https://forums.unrealengine.com/u/Flaccid_Jack)\
**Replies:** 1\
**Last updated:** [June 20, 2024, 1:08pm UTC](https://forums.unrealengine.com/t/constraining-mesh-in-natural-position/1906875 "2024-06-20T13:08:14Z")

</div>

I have game items (sword, backpack, etc.) that are represented as static mesh components on their own actor. The location of these items is determined server-side. Therefore the item’s client-side locations must be acc…

---

## [why waitandfork works in -nothreading mode is best way](https://forums.unrealengine.com/t/why-waitandfork-works-in-nothreading-mode-is-best-way/1909816)

<div class="topic-metadata">

**Author:** [@DJkarlHarris](https://forums.unrealengine.com/u/DJkarlHarris)\
**Replies:** 0\
**Last updated:** [June 20, 2024, 5:09am UTC](https://forums.unrealengine.com/t/why-waitandfork-works-in-nothreading-mode-is-best-way/1909816 "2024-06-20T05:09:50Z")

</div>

---

## [Windows Cook Content fails with a generic error](https://forums.unrealengine.com/t/windows-cook-content-fails-with-a-generic-error/633147)

<div class="topic-metadata">

**Author:** [@WinnieBoom](https://forums.unrealengine.com/u/WinnieBoom)\
**Replies:** 7\
**Last updated:** [June 20, 2024, 2:45am UTC](https://forums.unrealengine.com/t/windows-cook-content-fails-with-a-generic-error/633147 "2024-06-20T02:45:13Z")

</div>

Hey, I am trying to cook a project, but it fails with the errors below. Build for editors works fine, but I cannot do a package for windows. NOTE: GameGameModeBase.cpp:17 is a part of cunstructor, I tried to comment ev…

---

## [Multithreading function that runs on all logic threads except Game Thread](https://forums.unrealengine.com/t/multithreading-function-that-runs-on-all-logic-threads-except-game-thread/1815443)

<div class="topic-metadata">

**Author:** [@Sitiana](https://forums.unrealengine.com/u/Sitiana)\
**Replies:** 3\
**Last updated:** [June 20, 2024, 1:35am UTC](https://forums.unrealengine.com/t/multithreading-function-that-runs-on-all-logic-threads-except-game-thread/1815443 "2024-06-20T01:35:52Z")

</div>

Hello Devs, I’m working on some things that require millions of traces and for that I need to use multithreading. The problem is that I need to have a function that is not blocking Game Thread, but is using all other l…

---

## [Getting camera Frustum geometry in C++ or BP](https://forums.unrealengine.com/t/getting-camera-frustum-geometry-in-c-or-bp/1639604)

<div class="topic-metadata">

**Author:** [@tomcraftmarket](https://forums.unrealengine.com/u/tomcraftmarket)\
**Replies:** 4\
**Last updated:** [June 19, 2024, 8:34pm UTC](https://forums.unrealengine.com/t/getting-camera-frustum-geometry-in-c-or-bp/1639604 "2024-06-19T20:34:38Z")

</div>

I have multiple cameras in the scene as seen below, I can see the camera Frustum by enabling it in the editor via Show \> Advanced \> Camera Frustums. However, I would like to get the FVector(s) that defines the geomet…

---

## [Shortcut for making UE\_LOG statements in Visual Studio](https://forums.unrealengine.com/t/shortcut-for-making-ue-log-statements-in-visual-studio/686306)

<div class="topic-metadata">

**Author:** [@philv123](https://forums.unrealengine.com/u/philv123)\
**Replies:** 3\
**Last updated:** [June 19, 2024, 8:09pm UTC](https://forums.unrealengine.com/t/shortcut-for-making-ue-log-statements-in-visual-studio/686306 "2024-06-19T20:09:35Z")

</div>

I made a custom code snippet for Microsoft Visual Studio 2022 (not Visual Studio Code). I just type uelg \[TAB\] and UE\_LOG(LogTemp, Log, TEXT("")); gets inserted into my editor, with the cursor located between the quote m…

---

## [Damage prevention channel does not work](https://forums.unrealengine.com/t/damage-prevention-channel-does-not-work/601426)

<div class="topic-metadata">

**Author:** [@HHX1602](https://forums.unrealengine.com/u/HHX1602)\
**Replies:** 2\
**Last updated:** [June 19, 2024, 6:00pm UTC](https://forums.unrealengine.com/t/damage-prevention-channel-does-not-work/601426 "2024-06-19T18:00:01Z")

</div>

Hi, I have made a shield actor for blocking any projectile from dealing damage to my player character, and all projectiles that can deal radial damage have their damage prevention channel set to ECC\_Visibility. Yet my c…

---

## [UDP Socket C++ tutorial Updated 2021](https://forums.unrealengine.com/t/udp-socket-c-tutorial-updated-2021/261475)

<div class="topic-metadata">

**Author:** [@Tronological](https://forums.unrealengine.com/u/Tronological)\
**Replies:** 7\
**Last updated:** [June 19, 2024, 2:50pm UTC](https://forums.unrealengine.com/t/udp-socket-c-tutorial-updated-2021/261475 "2024-06-19T14:50:53Z")

</div>

So, I’ve spent the last few days digging through tons of posts and troves of documentation to get a working UDP client going. There’s plenty of posts but they all seem to be ancient and usually only address one side of t…

---

## [Game doesn't terminated on Steam when I open the chrome browser with FPlatformprocess::launchurl()](https://forums.unrealengine.com/t/game-doesnt-terminated-on-steam-when-i-open-the-chrome-browser-with-fplatformprocess-launchurl/1169966)

<div class="topic-metadata">

**Author:** [@gyeongahna](https://forums.unrealengine.com/u/gyeongahna)\
**Replies:** 1\
**Last updated:** [June 19, 2024, 1:58pm UTC](https://forums.unrealengine.com/t/game-doesnt-terminated-on-steam-when-i-open-the-chrome-browser-with-fplatformprocess-launchurl/1169966 "2024-06-19T13:58:27Z")

</div>

I’m making a game with Unreal framework. I used FPlatformprocess::launchurl() function to open the web url when game users click the banner. Actually, It works well. However, when I execute the game on steam, “Stop” butt…

[Previous page](https://forums.unrealengine.com/c/development-discussion/programming-scripting/c-programming/29.md?page=98)

[Next page](https://forums.unrealengine.com/c/development-discussion/programming-scripting/c-programming/29.md?page=100)
