# C++

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

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

**Page:** 51

---

## [USphereComponents showing up as "undeclared identifiers" despite necessary includes](https://forums.unrealengine.com/t/uspherecomponents-showing-up-as-undeclared-identifiers-despite-necessary-includes/2355629)

<div class="topic-metadata">

**Author:** [@ThatsABooya](https://forums.unrealengine.com/u/ThatsABooya)\
**Replies:** 8\
**Last updated:** [February 24, 2025, 9:38pm UTC](https://forums.unrealengine.com/t/uspherecomponents-showing-up-as-undeclared-identifiers-despite-necessary-includes/2355629 "2025-02-24T21:38:57Z")

</div>

Hello all. I am having an issue with two USphereComponents inside of my class. Any mention of them in the constructor gives me this error : C2065 ‘DetectionSphere’ undeclared identifier USphereComponent is forward dec…

---

## [Timeline Curve in C++?](https://forums.unrealengine.com/t/timeline-curve-in-c/2354923)

<div class="topic-metadata">

**Author:** [@Tarkin1230](https://forums.unrealengine.com/u/Tarkin1230)\
**Replies:** 2\
**Last updated:** [February 24, 2025, 6:57pm UTC](https://forums.unrealengine.com/t/timeline-curve-in-c/2354923 "2025-02-24T18:57:48Z")

</div>

Hi! I started to touch timelines, and i found pretty nice tutorial (here is a link if someone needs: Timeline in c++ | Unreal Engine Community Wiki), but here and many other places… people use Curve asset from editor and…

---

## [How to call a Anim Node Reference from code?](https://forums.unrealengine.com/t/how-to-call-a-anim-node-reference-from-code/2352337)

<div class="topic-metadata">

**Author:** [@InvQuasar](https://forums.unrealengine.com/u/InvQuasar)\
**Replies:** 8\
**Last updated:** [February 24, 2025, 5:53pm UTC](https://forums.unrealengine.com/t/how-to-call-a-anim-node-reference-from-code/2352337 "2025-02-24T17:53:33Z")

</div>

Hi! I have a Anim Node Reference in the AnimGraph (screen 1). It is called both in the AnimGraph and in the EventGraph (screen 2, I’ll attach as a separate message). I want to rewrite the EventGraph from BP to C++ code,…

---

## [A method to reuse Non-Customized Properties in Details Panel?](https://forums.unrealengine.com/t/a-method-to-reuse-non-customized-properties-in-details-panel/724264)

<div class="topic-metadata">

**Author:** [@Overclocked22](https://forums.unrealengine.com/u/Overclocked22)\
**Replies:** 2\
**Last updated:** [February 24, 2025, 4:00pm UTC](https://forums.unrealengine.com/t/a-method-to-reuse-non-customized-properties-in-details-panel/724264 "2025-02-24T16:00:05Z")

</div>

So I’m customizing the details panel for a UObject class I have. I’ve followed the directions and I can do this successfully: void::FMyCustomization::CustomizeChildren(TSharedRef\<IPropertyHandle\> PropertyHandle, IDe…

---

## [Why is the performance consumption of Movable models so high in Unreal](https://forums.unrealengine.com/t/why-is-the-performance-consumption-of-movable-models-so-high-in-unreal/2354268)

<div class="topic-metadata">

**Author:** [@qiuter](https://forums.unrealengine.com/u/qiuter)\
**Replies:** 0\
**Last updated:** [February 24, 2025, 6:07am UTC](https://forums.unrealengine.com/t/why-is-the-performance-consumption-of-movable-models-so-high-in-unreal/2354268 "2025-02-24T06:07:23Z")

</div>

I am trying to load resources from pak at runtime and achieve simultaneous loading and display, but I found that if I want to change the parent object of the generated model during runtime loading, I must set it to Movab…

---

## [How to use Decorators SRichTextBlock in Slate?](https://forums.unrealengine.com/t/how-to-use-decorators-srichtextblock-in-slate/140272)

<div class="topic-metadata">

**Author:** [@pDunkl](https://forums.unrealengine.com/u/pDunkl)\
**Replies:** 1\
**Last updated:** [March 27, 2020, 5:52am UTC](https://forums.unrealengine.com/t/how-to-use-decorators-srichtextblock-in-slate/140272 "2020-03-27T05:52:22Z")

</div>

Hello, I’m writing the full UI of a game purely in Slate, but now I’m stuck, because I can’t get the SRichTextBlock to work with image Decorators, I just can’t figure out the workflow to create/get the image decorators w…

---

## [Error EXCEPTION\_ACCESS\_VIOLATION reading address 0xffffffffffffffff with Splines](https://forums.unrealengine.com/t/error-exception-access-violation-reading-address-0xffffffffffffffff-with-splines/2351122)

<div class="topic-metadata">

**Author:** [@bluKettle](https://forums.unrealengine.com/u/bluKettle)\
**Replies:** 6\
**Last updated:** [February 24, 2025, 4:12am UTC](https://forums.unrealengine.com/t/error-exception-access-violation-reading-address-0xffffffffffffffff-with-splines/2351122 "2025-02-24T04:12:03Z")

</div>

I get this Error and the Editor crashes when i try to edit spline points after a while or after restarting the project: Unhandled Exception: EXCEPTION\_ACCESS\_VIOLATION reading address 0xffffffffffffffff (SplineStreet.c…

---

## [Partitioned PCG component does not generate on demand (and other bugs)](https://forums.unrealengine.com/t/partitioned-pcg-component-does-not-generate-on-demand-and-other-bugs/2220564)

<div class="topic-metadata">

**Author:** [@espaghetters](https://forums.unrealengine.com/u/espaghetters)\
**Replies:** 1\
**Last updated:** [February 23, 2025, 9:26pm UTC](https://forums.unrealengine.com/t/partitioned-pcg-component-does-not-generate-on-demand-and-other-bugs/2220564 "2025-02-23T21:26:03Z")

</div>

Hi, I have a PCGVolume in my world with a partitioned PCGComponent that is loaded on demand. In my GameMode I’m calling PCGComponent-\>Generate(true); which I would expect it to generate the PCG at runtime. Unfortun…

---

## [How consume input after reading action value?](https://forums.unrealengine.com/t/how-consume-input-after-reading-action-value/2352819)

<div class="topic-metadata">

**Author:** [@Youshisu](https://forums.unrealengine.com/u/Youshisu)\
**Replies:** 1\
**Last updated:** [February 23, 2025, 7:58pm UTC](https://forums.unrealengine.com/t/how-consume-input-after-reading-action-value/2352819 "2025-02-23T19:58:46Z")

</div>

My case: I want to rotate camera / pan after player holds one of mouse buttons. I got 2 functions that rotate / pan camera. I bound them to Mouse clicks (middle and right) I did variable pointer to read Axis Valu…

---

## [Create and join session in c++](https://forums.unrealengine.com/t/create-and-join-session-in-c/1318285)

<div class="topic-metadata">

**Author:** [@1FoNo1](https://forums.unrealengine.com/u/1FoNo1)\
**Replies:** 4\
**Last updated:** [February 23, 2025, 5:30pm UTC](https://forums.unrealengine.com/t/create-and-join-session-in-c/1318285 "2025-02-23T17:30:40Z")

</div>

I tried to use c++ to create sessions, and find and join them in unreal. I took a reference to this blog. How To Use Sessions In C++ - UE4: Guidebook (gg-labs.com) However, if I use my c++ code to create a session, it …

---

## [Drag and drop animates for 0.15 seconds from topleft to pivot/offset.](https://forums.unrealengine.com/t/drag-and-drop-animates-for-0-15-seconds-from-topleft-to-pivot-offset/714763)

<div class="topic-metadata">

**Author:** [@zos](https://forums.unrealengine.com/u/zos)\
**Replies:** 8\
**Last updated:** [February 23, 2025, 2:29pm UTC](https://forums.unrealengine.com/t/drag-and-drop-animates-for-0-15-seconds-from-topleft-to-pivot-offset/714763 "2025-02-23T14:29:23Z")

</div>

When a UMG drag-and-drop operation (UDragDropOperation) is commenced in UUserWidget::NativeOnDragDetected a UUserWidget is placed into the DefaultDragVisual which is the visual representation of what is being dragged, a…

---

## [Ship(Pawn) move on it's own after I possess it](https://forums.unrealengine.com/t/ship-pawn-move-on-its-own-after-i-possess-it/2349731)

<div class="topic-metadata">

**Author:** [@M.S.M.A.S](https://forums.unrealengine.com/u/M.S.M.A.S)\
**Replies:** 0\
**Last updated:** [February 22, 2025, 2:26am UTC](https://forums.unrealengine.com/t/ship-pawn-move-on-its-own-after-i-possess-it/2349731 "2025-02-22T02:26:03Z")

</div>

I possess a pawn like this if (AController\* controller = GetWorld()-\>GetFirstPlayerController()) { controller-\>UnPossess(); // I added this line to ensure that the velocity is zero but it did nothing mainPlayer-\>Get…

---

## [Trouble setting up Bound Action Bar using CommonUI](https://forums.unrealengine.com/t/trouble-setting-up-bound-action-bar-using-commonui/2345579)

<div class="topic-metadata">

**Author:** [@Vinipiterson](https://forums.unrealengine.com/u/Vinipiterson)\
**Replies:** 2\
**Last updated:** [February 23, 2025, 2:52am UTC](https://forums.unrealengine.com/t/trouble-setting-up-bound-action-bar-using-commonui/2345579 "2025-02-23T02:52:39Z")

</div>

Recently I started playing around with common UI in one of my projects, I have set up everything necessary to make the Common Bound Action Bar work, I started by creating a MappingContext for the main menu actions. I…

---

## [Iwyu](https://forums.unrealengine.com/t/iwyu/79044)

<div class="topic-metadata">

**Author:** [@Ben\_Marsh](https://forums.unrealengine.com/u/Ben_Marsh)\
**Replies:** 14\
**Last updated:** [February 22, 2025, 9:09am UTC](https://forums.unrealengine.com/t/iwyu/79044 "2025-02-22T09:09:29Z")

</div>

I’ve just submitted a change to master branch on GitHub to convert the engine to an “include what you use” model. This is a big change! Rather than including big headers like Engine.h and UnrealEd.h everywhere, each hea…

---

## [Adding Subcomponents to a USceneComponent in Unreal 5 C++](https://forums.unrealengine.com/t/adding-subcomponents-to-a-uscenecomponent-in-unreal-5-c/2334346)

<div class="topic-metadata">

**Author:** [@Chris.IGuess](https://forums.unrealengine.com/u/Chris.IGuess)\
**Replies:** 3\
**Last updated:** [February 16, 2025, 10:48pm UTC](https://forums.unrealengine.com/t/adding-subcomponents-to-a-uscenecomponent-in-unreal-5-c/2334346 "2025-02-16T22:48:40Z")

</div>

Problem I’ve encountered multiple situations where I needed to create a custom USceneComponent in C++ that contains other USceneComponent-based subcomponents as part of its default structure. However, Unreal Engine does …

---

## [UE project breaks after I edit header files and recompile....](https://forums.unrealengine.com/t/ue-project-breaks-after-i-edit-header-files-and-recompile/2345605)

<div class="topic-metadata">

**Author:** [@b4bylon](https://forums.unrealengine.com/u/b4bylon)\
**Replies:** 2\
**Last updated:** [February 22, 2025, 3:15am UTC](https://forums.unrealengine.com/t/ue-project-breaks-after-i-edit-header-files-and-recompile/2345605 "2025-02-22T03:15:50Z")

</div>

I have a problem, i have a thirdperson\_bp that have a stats component, a c++ class, after I add functions or variables in the header files the stats component from the blueprint apear blank. If i duplicate that component…

---

## [FMaterialRenderProxy objects are not deleted when switching to an empty scene ](https://forums.unrealengine.com/t/fmaterialrenderproxy-objects-are-not-deleted-when-switching-to-an-empty-scene/2348872)

<div class="topic-metadata">

**Author:** [@DmitryL87](https://forums.unrealengine.com/u/DmitryL87)\
**Replies:** 0\
**Last updated:** [February 21, 2025, 4:18pm UTC](https://forums.unrealengine.com/t/fmaterialrenderproxy-objects-are-not-deleted-when-switching-to-an-empty-scene/2348872 "2025-02-21T16:18:04Z")

</div>

Hello everyone, I’m developing a module for UnrealEngine and faced a problem with UnrealEditor. If I open a scene in the editor, it loads the materials and creates FMaterialRenderProxy instances. Then, if I switch to a …

---

## [Printscreen / capture image](https://forums.unrealengine.com/t/printscreen-capture-image/255997)

<div class="topic-metadata">

**Author:** [@mozg4d](https://forums.unrealengine.com/u/mozg4d)\
**Replies:** 2\
**Last updated:** [February 21, 2025, 3:32pm UTC](https://forums.unrealengine.com/t/printscreen-capture-image/255997 "2025-02-21T15:32:12Z")

</div>

ue5 I’m stuck( I just need to execute console command “shot” from blueprint. If packaged as “shipping” it does not work, just as any other method of capturing view I’ve tried(( So I’m trying to find some C++ solution…

---

## [How to call function on AnimGraph C++?](https://forums.unrealengine.com/t/how-to-call-function-on-animgraph-c/2345084)

<div class="topic-metadata">

**Author:** [@no\_reply](https://forums.unrealengine.com/u/no_reply)\
**Replies:** 19\
**Last updated:** [February 20, 2025, 11:52pm UTC](https://forums.unrealengine.com/t/how-to-call-function-on-animgraph-c/2345084 "2025-02-20T23:52:40Z")

</div>

UCLASS() class TEMPLATE\_API UAnimationInstance : public UAnimInstance { GENERATED\_BODY() public: UFUNCTION(BlueprintCallable, meta = (BlueprintThreadSafe)) void UpdateView(); } I just want to call the method ‘Upd…

---

## [How can this player controller client function get the gamemode?](https://forums.unrealengine.com/t/how-can-this-player-controller-client-function-get-the-gamemode/272771)

<div class="topic-metadata">

**Author:** [@Samathan](https://forums.unrealengine.com/u/Samathan)\
**Replies:** 8\
**Last updated:** [February 20, 2025, 10:43pm UTC](https://forums.unrealengine.com/t/how-can-this-player-controller-client-function-get-the-gamemode/272771 "2025-02-20T22:43:44Z")

</div>

This is some blueprint from Unreal’s multiplayer shootout demo which I’m trying to replicate in C++. How does this work?: A client function called in the player controller class. I thought that clients can’t get the…

---

## [C++ Blueprint Function not showing up in Blueprint Editor](https://forums.unrealengine.com/t/c-blueprint-function-not-showing-up-in-blueprint-editor/46359)

<div class="topic-metadata">

**Author:** [@ClintonWalsh](https://forums.unrealengine.com/u/ClintonWalsh)\
**Replies:** 9\
**Last updated:** [February 20, 2025, 12:18pm UTC](https://forums.unrealengine.com/t/c-blueprint-function-not-showing-up-in-blueprint-editor/46359 "2025-02-20T12:18:35Z")

</div>

Hi all, I am trying to get a C++ function to show up in the Blueprint editor. I create a new C++ class \> Copy the code into the .h and .cpp files and change the names to be the name of my game \> Build the solution \> Ope…

---

## [How to encrypt UE shader file (usf) ?](https://forums.unrealengine.com/t/how-to-encrypt-ue-shader-file-usf/1944572)

<div class="topic-metadata">

**Author:** [@11lihao11](https://forums.unrealengine.com/u/11lihao11)\
**Replies:** 7\
**Last updated:** [February 20, 2025, 6:51am UTC](https://forums.unrealengine.com/t/how-to-encrypt-ue-shader-file-usf/1944572 "2025-02-20T06:51:25Z")

</div>

My plugin contains some shaders files (usf & ush), I want to encrypt or hide them. Who can help me ? Thanks for your any help!

---

## [OnComponentHit.AddDynamic for subobject component not firing](https://forums.unrealengine.com/t/oncomponenthit-adddynamic-for-subobject-component-not-firing/2337595)

<div class="topic-metadata">

**Author:** [@GreenBaguette192](https://forums.unrealengine.com/u/GreenBaguette192)\
**Replies:** 4\
**Last updated:** [February 20, 2025, 2:07am UTC](https://forums.unrealengine.com/t/oncomponenthit-adddynamic-for-subobject-component-not-firing/2337595 "2025-02-20T02:07:59Z")

</div>

Hello again, somewhat beginner game programmer here. I have a player character with subcomponents that I want to use to detect hits with. The detection will fire an OnHit function within the main player cpp. I’ve done ev…

---

## [Tick is never being called even though CanEverTick and StartWithTickEnables is true](https://forums.unrealengine.com/t/tick-is-never-being-called-even-though-canevertick-and-startwithtickenables-is-true/359613)

<div class="topic-metadata">

**Author:** [@Muffinlasher](https://forums.unrealengine.com/u/Muffinlasher)\
**Replies:** 25\
**Last updated:** [February 19, 2025, 8:54pm UTC](https://forums.unrealengine.com/t/tick-is-never-being-called-even-though-canevertick-and-startwithtickenables-is-true/359613 "2025-02-19T20:54:01Z")

</div>

Hi all. I have been having this incredibly annoying issue where it seems that my tick for an actor is never called. I have a function called within the tick that is never triggered and a print statement in there also whi…

---

## [When converting integer numbers to text (ToText node) in Spanish, they has no thousand period but a space (i.e. "2 500" instead of "2.500").  ](https://forums.unrealengine.com/t/when-converting-integer-numbers-to-text-totext-node-in-spanish-they-has-no-thousand-period-but-a-space-i-e-2-500-instead-of-2-500/2345096)

<div class="topic-metadata">

**Author:** [@ZakMcKracken](https://forums.unrealengine.com/u/ZakMcKracken)\
**Replies:** 0\
**Last updated:** [February 19, 2025, 3:40pm UTC](https://forums.unrealengine.com/t/when-converting-integer-numbers-to-text-totext-node-in-spanish-they-has-no-thousand-period-but-a-space-i-e-2-500-instead-of-2-500/2345096 "2025-02-19T15:40:21Z")

</div>

I’m using Unreal Engine 4.27. I was about to hardcode a fix into the kismet function, but let’s see if I’m the only one with this issue.

---

## [Visual Studio 2022 update 17.13 is insanely broken now](https://forums.unrealengine.com/t/visual-studio-2022-update-17-13-is-insanely-broken-now/2332961)

<div class="topic-metadata">

**Author:** [@FutureHendriKCs](https://forums.unrealengine.com/u/FutureHendriKCs)\
**Replies:** 4\
**Last updated:** [February 19, 2025, 1:50pm UTC](https://forums.unrealengine.com/t/visual-studio-2022-update-17-13-is-insanely-broken-now/2332961 "2025-02-19T13:50:26Z")

</div>

so yesterday the february 13th 2025 i updated visual studio as i always do when there is a update…after updating visual studio i have about a 10 - 15 second delay in being able to do anything in visual studio only when u…

---

## [The character suddenly doesn't move..](https://forums.unrealengine.com/t/the-character-suddenly-doesnt-move/2331029)

<div class="topic-metadata">

**Author:** [@sehwa](https://forums.unrealengine.com/u/sehwa)\
**Replies:** 4\
**Last updated:** [February 19, 2025, 9:42am UTC](https://forums.unrealengine.com/t/the-character-suddenly-doesnt-move/2331029 "2025-02-19T09:42:51Z")

</div>

Hi. I’m working on a project by myself, but I have a problem. I’m implementing something that gives damage if I collide with a certain actor. If they collide first, they will draw a debug sphere. Up to this point, the …

---

## [Mac log function names?](https://forums.unrealengine.com/t/mac-log-function-names/72424)

<div class="topic-metadata">

**Author:** [@hard\_code](https://forums.unrealengine.com/u/hard_code)\
**Replies:** 10\
**Last updated:** [February 19, 2025, 9:22am UTC](https://forums.unrealengine.com/t/mac-log-function-names/72424 "2025-02-19T09:22:53Z")

</div>

In xcode the following causes a failed build error: use of undeclared identifier ‘L\_\_func\_\_’ #if \_MSC\_VER #define FUNC\_NAME TEXT(\_\_FUNCTION\_\_) #else // FIXME - GCC? #define FUNC\_NAME TEXT(\_\_func\_\_) # this cause…

---

## [Deleting a class -- unbelievably bad product design](https://forums.unrealengine.com/t/deleting-a-class-unbelievably-bad-product-design/1689714)

<div class="topic-metadata">

**Author:** [@Jolly\_Bombadillo](https://forums.unrealengine.com/u/Jolly_Bombadillo)\
**Replies:** 7\
**Last updated:** [February 18, 2025, 10:42pm UTC](https://forums.unrealengine.com/t/deleting-a-class-unbelievably-bad-product-design/1689714 "2025-02-18T22:42:34Z")

</div>

Going to rant a bit before switching engines. I came to Unreal because of their world partition feature. But now I’m leaving in part because the process of simply deleting a cpp file (which should require no troubleshoot…

---

## [When is a value pushed with MARK\_PROPERTY\_DIRTY() macro?](https://forums.unrealengine.com/t/when-is-a-value-pushed-with-mark-property-dirty-macro/2341285)

<div class="topic-metadata">

**Author:** [@Kotaru\_1](https://forums.unrealengine.com/u/Kotaru_1)\
**Replies:** 2\
**Last updated:** [February 18, 2025, 10:40pm UTC](https://forums.unrealengine.com/t/when-is-a-value-pushed-with-mark-property-dirty-macro/2341285 "2025-02-18T22:40:29Z")

</div>

If I were to replicate a variable, then update it after the push, but within the same frame, what value should be sent to the clients? for example, if I were to do this on the server MyInt = 0; MARK\_PROPERTY\_DIRTY\_FRO…

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

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