# C++

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

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

**Page:** 96

---

## [Why is only part of the Enhanced Input working?](https://forums.unrealengine.com/t/why-is-only-part-of-the-enhanced-input-working/1937072)

<div class="topic-metadata">

**Author:** [@Hexssssss](https://forums.unrealengine.com/u/Hexssssss)\
**Replies:** 0\
**Last updated:** [July 14, 2024, 1:18pm UTC](https://forums.unrealengine.com/t/why-is-only-part-of-the-enhanced-input-working/1937072 "2024-07-14T13:18:10Z")

</div>

this is my Input mapping context When I play, mouse rotation and keyboards A, D work, but keyboards W, S don’t work, and logs in “Move” function don’t seem to work either. When I press A and D on the keyboard, …

---

## [Cannot compile unreal engine 4 c++ project with vistual studio 2017](https://forums.unrealengine.com/t/cannot-compile-unreal-engine-4-c-project-with-vistual-studio-2017/432620)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_6450b452](https://forums.unrealengine.com/u/anonymous_user_6450b452)\
**Replies:** 2\
**Last updated:** [July 14, 2024, 11:00am UTC](https://forums.unrealengine.com/t/cannot-compile-unreal-engine-4-c-project-with-vistual-studio-2017/432620 "2024-07-14T11:00:37Z")

</div>

I created a c++ project in unreal engine 4.20.2.Then,I got an error said no projectname.dll finded and i should compile manully with visual studio 2017.When i start my compilation with vs2017 i got 1 waring and 3 errors: …

---

## [How do I acces the type of bone via c++](https://forums.unrealengine.com/t/how-do-i-acces-the-type-of-bone-via-c/1936970)

<div class="topic-metadata">

**Author:** [@Mayurkamat16](https://forums.unrealengine.com/u/Mayurkamat16)\
**Replies:** 0\
**Last updated:** [July 14, 2024, 10:31am UTC](https://forums.unrealengine.com/t/how-do-i-acces-the-type-of-bone-via-c/1936970 "2024-07-14T10:31:09Z")

</div>

As the image describes the bones of a mesh can be of different types… i want to acces the type of bone from a skeleton or skeletal mesh.How do i get this data using c++?

---

## [How to connect uproejct with visual studio?](https://forums.unrealengine.com/t/how-to-connect-uproejct-with-visual-studio/1936100)

<div class="topic-metadata">

**Author:** [@MC\_24](https://forums.unrealengine.com/u/MC_24)\
**Replies:** 3\
**Last updated:** [July 14, 2024, 6:55am UTC](https://forums.unrealengine.com/t/how-to-connect-uproejct-with-visual-studio/1936100 "2024-07-14T06:55:11Z")

</div>

Hi. I deleted some needless files(Binaries, DerivedDataCache, Intermediate, Saved, sln file) and click .uproject, “Generate Visual Studio project files”. Turn on Visual studio, and press F5. But this came out.(What do…

---

## [Unreal Engine makes an actor none in C++ when the window is minimised for multithread working](https://forums.unrealengine.com/t/unreal-engine-makes-an-actor-none-in-c-when-the-window-is-minimised-for-multithread-working/1935873)

<div class="topic-metadata">

**Author:** [@Zopich](https://forums.unrealengine.com/u/Zopich)\
**Replies:** 0\
**Last updated:** [July 13, 2024, 6:03am UTC](https://forums.unrealengine.com/t/unreal-engine-makes-an-actor-none-in-c-when-the-window-is-minimised-for-multithread-working/1935873 "2024-07-13T06:03:06Z")

</div>

When I work with actors from another thread (pre-marking them with AddToRoot so the garbige collector doesn’t react on it), everything goes as expected until I minimise the editor window or open another window on top of …

---

## [GetWorld working in BeginPlay, but not when called in function](https://forums.unrealengine.com/t/getworld-working-in-beginplay-but-not-when-called-in-function/1936587)

<div class="topic-metadata">

**Author:** [@RyanRogers](https://forums.unrealengine.com/u/RyanRogers)\
**Replies:** 0\
**Last updated:** [July 13, 2024, 10:52pm UTC](https://forums.unrealengine.com/t/getworld-working-in-beginplay-but-not-when-called-in-function/1936587 "2024-07-13T22:52:04Z")

</div>

Hello all, I have a function on an actor component that creates a new actor. This has been working fine. After making changes to unrelated parts of the actor component, the function began to crash. It appears that, insi…

---

## [Dynamically spawned NPC lacks proper collision and gravity behavior](https://forums.unrealengine.com/t/dynamically-spawned-npc-lacks-proper-collision-and-gravity-behavior/1936044)

<div class="topic-metadata">

**Author:** [@IdrisKhan](https://forums.unrealengine.com/u/IdrisKhan)\
**Replies:** 1\
**Last updated:** [July 13, 2024, 6:39pm UTC](https://forums.unrealengine.com/t/dynamically-spawned-npc-lacks-proper-collision-and-gravity-behavior/1936044 "2024-07-13T18:39:15Z")

</div>

I’m currently making a class that spawns NPCs. The NPCs do spawn correctly at the specified Location and Rotation, but I’m facing issues with their collision and gravity behavior: Collision Issue: The spawned NPCs don’…

---

## [How to find in visual studio Unreal Engine Log?](https://forums.unrealengine.com/t/how-to-find-in-visual-studio-unreal-engine-log/1934762)

<div class="topic-metadata">

**Author:** [@MC\_24](https://forums.unrealengine.com/u/MC_24)\
**Replies:** 2\
**Last updated:** [July 13, 2024, 5:53am UTC](https://forums.unrealengine.com/t/how-to-find-in-visual-studio-unreal-engine-log/1934762 "2024-07-13T05:53:19Z")

</div>

Hi. I’m working on unreal with c++(visual studio). How to show this?

---

## [How serialize array of custom UObject?](https://forums.unrealengine.com/t/how-serialize-array-of-custom-uobject/1933976)

<div class="topic-metadata">

**Author:** [@Viniccius007](https://forums.unrealengine.com/u/Viniccius007)\
**Replies:** 1\
**Last updated:** [July 13, 2024, 1:15am UTC](https://forums.unrealengine.com/t/how-serialize-array-of-custom-uobject/1933976 "2024-07-13T01:15:53Z")

</div>

I’m trying to serialize an Array of “UBlock” UObjects, I tried overloading the “Serialize” function and adding a custom operator\<\< but got the same error: \[2/6\] Compile \[x64\] BlockArray3D.cpp 11\>Array.h(3763): Error C26…

---

## [How do i make the value pin be of the type that is returned?](https://forums.unrealengine.com/t/how-do-i-make-the-value-pin-be-of-the-type-that-is-returned/1935461)

<div class="topic-metadata">

**Author:** [@Gravilyt2](https://forums.unrealengine.com/u/Gravilyt2)\
**Replies:** 2\
**Last updated:** [July 12, 2024, 8:38pm UTC](https://forums.unrealengine.com/t/how-do-i-make-the-value-pin-be-of-the-type-that-is-returned/1935461 "2024-07-12T20:38:29Z")

</div>

I was testing some things in c++ and blueprint, and i saw the Get Component By Class node, and the return pin class changes based on the class that you select. And i made a function in c++ with the same goal, but it …

---

## [Stream level but not on every client](https://forums.unrealengine.com/t/stream-level-but-not-on-every-client/1935337)

<div class="topic-metadata">

**Author:** [@Elites94](https://forums.unrealengine.com/u/Elites94)\
**Replies:** 0\
**Last updated:** [July 12, 2024, 3:46pm UTC](https://forums.unrealengine.com/t/stream-level-but-not-on-every-client/1935337 "2024-07-12T15:46:51Z")

</div>

Hello, I am doing some stuff in level streaming right now and discovered that when I do a “LoadStreamLevel” on the server, then it automatically replicate to the clients ! Is there any way to prevent that ? Since I am…

---

## [Question about torque conversion in ChaosVehicles](https://forums.unrealengine.com/t/question-about-torque-conversion-in-chaosvehicles/1935291)

<div class="topic-metadata">

**Author:** [@SushiCaNgu](https://forums.unrealengine.com/u/SushiCaNgu)\
**Replies:** 0\
**Last updated:** [July 12, 2024, 3:10pm UTC](https://forums.unrealengine.com/t/question-about-torque-conversion-in-chaosvehicles/1935291 "2024-07-12T15:10:15Z")

</div>

Is the conversion in the image correct? If I’m not wrong then brake torque unit is Nm, then convert to Ncm required multiply by 100. But as shown in the image, the brake torque is multiply by 10000 UE\_5.4\\Engine\\Sour…

---

## [RHIUpdateTextureReference and EXCEPTION\_ACCESS\_VIOLATION - can't get it!](https://forums.unrealengine.com/t/rhiupdatetexturereference-and-exception-access-violation-cant-get-it/1935166)

<div class="topic-metadata">

**Author:** [@YobiRobert](https://forums.unrealengine.com/u/YobiRobert)\
**Replies:** 2\
**Last updated:** [July 12, 2024, 2:10pm UTC](https://forums.unrealengine.com/t/rhiupdatetexturereference-and-exception-access-violation-cant-get-it/1935166 "2024-07-12T14:10:55Z")

</div>

I am surely not seeing something in plain view, but a call to RHIUpdateTextureReference result is a EXCEPTION\_ACCESS\_VIOLATION. I have a thread that need to update a texture, so I followed the example from Petr Leontev, …

---

## [simulate mouse click with gamepad button?](https://forums.unrealengine.com/t/simulate-mouse-click-with-gamepad-button/1934366)

<div class="topic-metadata">

**Author:** [@eldany.uy](https://forums.unrealengine.com/u/eldany.uy)\
**Replies:** 1\
**Last updated:** [July 12, 2024, 11:13am UTC](https://forums.unrealengine.com/t/simulate-mouse-click-with-gamepad-button/1934366 "2024-07-12T11:13:40Z")

</div>

I am doing an UI and I want it to be used with a mouse pointer but also move the pointer with a gamepad and click with a gamepad button. I have the motion part solved, but for emulate the mouse click I must deal with cu…

---

## [Daylight Savings / UTC Timezone Offset](https://forums.unrealengine.com/t/daylight-savings-utc-timezone-offset/608729)

<div class="topic-metadata">

**Author:** [@jo.codegirl](https://forums.unrealengine.com/u/jo.codegirl)\
**Replies:** 3\
**Last updated:** [July 12, 2024, 2:57am UTC](https://forums.unrealengine.com/t/daylight-savings-utc-timezone-offset/608729 "2024-07-12T02:57:04Z")

</div>

I am looking for a way to determine the UTC Timezone Offset (eg. -7:00) given the local computer settings. FDateTime accounts for daylight savings so it does not give me the correct answer to find the timespan from Local…

---

## [Included clang++ gives me Intellisense issues. My system clang++ works fine. Is it just me?](https://forums.unrealengine.com/t/included-clang-gives-me-intellisense-issues-my-system-clang-works-fine-is-it-just-me/1713798)

<div class="topic-metadata">

**Author:** [@Corbent](https://forums.unrealengine.com/u/Corbent)\
**Replies:** 1\
**Last updated:** [July 11, 2024, 11:17pm UTC](https://forums.unrealengine.com/t/included-clang-gives-me-intellisense-issues-my-system-clang-works-fine-is-it-just-me/1713798 "2024-07-11T23:17:39Z")

</div>

So I installed the Engine this weekend after a long hiatus. This time I am working on Linux. The setup was simple enough and I am using VSCode for source editing. However, intellisense was complaining about “namespace ‘s…

---

## [Sometimes C++ compiles quickly, but sometimes it compiles slowly](https://forums.unrealengine.com/t/sometimes-c-compiles-quickly-but-sometimes-it-compiles-slowly/1932247)

<div class="topic-metadata">

**Author:** [@Dasay2605](https://forums.unrealengine.com/u/Dasay2605)\
**Replies:** 3\
**Last updated:** [July 11, 2024, 11:13pm UTC](https://forums.unrealengine.com/t/sometimes-c-compiles-quickly-but-sometimes-it-compiles-slowly/1932247 "2024-07-11T23:13:28Z")

</div>

I am new to C++ with the Unreal Engine (5). Last night the compilation process (with live coding) was quite slow - about 2 minutes (as far as I understand, this is normal compilation time). Today (after turning off and o…

---

## [Montage\_SetEndDelegate bug when run from client?](https://forums.unrealengine.com/t/montage-setenddelegate-bug-when-run-from-client/110616)

<div class="topic-metadata">

**Author:** [@Mesothere](https://forums.unrealengine.com/u/Mesothere)\
**Replies:** 2\
**Last updated:** [July 11, 2024, 4:01pm UTC](https://forums.unrealengine.com/t/montage-setenddelegate-bug-when-run-from-client/110616 "2024-07-11T16:01:03Z")

</div>

Hello guys, I have some fairly simple logic to run animations. I run them from C++, and when the animation ends, I like to run a simple function to set some variables. It looks roughly like this: character-\>GetM…

---

## [How to compile a plugin project with XCode](https://forums.unrealengine.com/t/how-to-compile-a-plugin-project-with-xcode/3275)

<div class="topic-metadata">

**Author:** [@rotwang](https://forums.unrealengine.com/u/rotwang)\
**Replies:** 14\
**Last updated:** [July 11, 2024, 3:29pm UTC](https://forums.unrealengine.com/t/how-to-compile-a-plugin-project-with-xcode/3275 "2024-07-11T15:29:45Z")

</div>

Following the description to copy an existing engine plugin: I copied the BlankPlugin and renamed all strings and filenames from BlankPlugin to MyPlugin. Then deleted binaries and intermediate files. Copied the MyPlugi…

---

## [How to solve the problem of stretching and enlarging the InstanceMesh in the material, or cropping the viewport according to the original size](https://forums.unrealengine.com/t/how-to-solve-the-problem-of-stretching-and-enlarging-the-instancemesh-in-the-material-or-cropping-the-viewport-according-to-the-original-size/1934122)

<div class="topic-metadata">

**Author:** [@user\_d1df5bf20c08d1cf08fe232eadf458389bc3c90b89794fb678fa48](https://forums.unrealengine.com/u/user_d1df5bf20c08d1cf08fe232eadf458389bc3c90b89794fb678fa48)\
**Replies:** 0\
**Last updated:** [July 11, 2024, 2:17pm UTC](https://forums.unrealengine.com/t/how-to-solve-the-problem-of-stretching-and-enlarging-the-instancemesh-in-the-material-or-cropping-the-viewport-according-to-the-original-size/1934122 "2024-07-11T14:17:00Z")

</div>

1.Use materials to offset the world position of InstanceMesh (enlarge and stretch the model) 2.When my camera zooms in to view the details of the model, it will be cropped out 3.After research, it was found that the pr…

---

## [Replicating References to Spatially Loaded Actors in World Partition](https://forums.unrealengine.com/t/replicating-references-to-spatially-loaded-actors-in-world-partition/1934044)

<div class="topic-metadata">

**Author:** [@Jon.Holmes](https://forums.unrealengine.com/u/Jon.Holmes)\
**Replies:** 0\
**Last updated:** [July 11, 2024, 1:18pm UTC](https://forums.unrealengine.com/t/replicating-references-to-spatially-loaded-actors-in-world-partition/1934044 "2024-07-11T13:18:09Z")

</div>

Hello! When it comes to replicating references to actors placed in World Partition it seems if the actor doesn’t exist on the client at time of replication there’s a log saying the property will be set to None. When tha…

---

## [Random int64 still broken in 5.1](https://forums.unrealengine.com/t/random-int64-still-broken-in-5-1/693474)

<div class="topic-metadata">

**Author:** [@KaidoomDev](https://forums.unrealengine.com/u/KaidoomDev)\
**Replies:** 1\
**Last updated:** [July 11, 2024, 10:40am UTC](https://forums.unrealengine.com/t/random-int64-still-broken-in-5-1/693474 "2024-07-11T10:40:48Z")

</div>

Anything beyond max int32 will return -2147483648 The issue I found is the use of TruncToInt instead of TruncToInt64 inside RandHelper64 int64 Max = MAX\_int64; int64 Random = FMath::RandHelper64(Max); UE\_LOG(LogTemp, …

---

## [FCoreUObjectDelegate never called?](https://forums.unrealengine.com/t/fcoreuobjectdelegate-never-called/1933869)

<div class="topic-metadata">

**Author:** [@HollyWretch](https://forums.unrealengine.com/u/HollyWretch)\
**Replies:** 0\
**Last updated:** [July 11, 2024, 10:26am UTC](https://forums.unrealengine.com/t/fcoreuobjectdelegate-never-called/1933869 "2024-07-11T10:26:32Z")

</div>

I’m trying to use FCoreUObjectDelegates to determine the state of the UWorld. FCoreUObjectDelegates::PreLoadMap.AddUObject( this , &ThisClass::HandlePreLoadMap ); FCoreUObjectDelegates::PostLoadMapWithWorld.AddUObject( …

---

## [Can I start PIE through Commandlet?](https://forums.unrealengine.com/t/can-i-start-pie-through-commandlet/1933747)

<div class="topic-metadata">

**Author:** [@Quilavar](https://forums.unrealengine.com/u/Quilavar)\
**Replies:** 0\
**Last updated:** [July 11, 2024, 8:16am UTC](https://forums.unrealengine.com/t/can-i-start-pie-through-commandlet/1933747 "2024-07-11T08:16:34Z")

</div>

Hi, I’ve been trying to load a GLTF model during runtime (using the plugin) into a scene and then render via MRQ. To streamline this I am trying an approach by Commandlet, giving the glb URL through as an Argument. Sin…

---

## [FSubsystemCollection doesn't work as I would expect](https://forums.unrealengine.com/t/fsubsystemcollection-doesnt-work-as-i-would-expect/485458)

<div class="topic-metadata">

**Author:** [@Bionic\_Ape](https://forums.unrealengine.com/u/Bionic_Ape)\
**Replies:** 2\
**Last updated:** [July 11, 2024, 7:15am UTC](https://forums.unrealengine.com/t/fsubsystemcollection-doesnt-work-as-i-would-expect/485458 "2024-07-11T07:15:46Z")

</div>

Hi, GetSubsystemArray(TSubclassOf) Only works for the first parent. If I have a USubsystemChild that inherits from USubystemParent that also inherits from UGameInstanceSubsystem, then, when I call TArray\<UGameInstanceS…

---

## [How do I scan through a string in C++?](https://forums.unrealengine.com/t/how-do-i-scan-through-a-string-in-c/1933264)

<div class="topic-metadata">

**Author:** [@Lorekeeper49](https://forums.unrealengine.com/u/Lorekeeper49)\
**Replies:** 6\
**Last updated:** [July 11, 2024, 7:10am UTC](https://forums.unrealengine.com/t/how-do-i-scan-through-a-string-in-c/1933264 "2024-07-11T07:10:07Z")

</div>

Trying to implement a Sliding Universal Score system here, I want to create a function that scans a string from a text file and converts each line into a variable value. There are 2 things I need to accomplish this: r…

---

## [Lags during asynchronous skeletal mesh loading](https://forums.unrealengine.com/t/lags-during-asynchronous-skeletal-mesh-loading/1932269)

<div class="topic-metadata">

**Author:** [@Dangetsu-PK](https://forums.unrealengine.com/u/Dangetsu-PK)\
**Replies:** 1\
**Last updated:** [July 11, 2024, 1:22am UTC](https://forums.unrealengine.com/t/lags-during-asynchronous-skeletal-mesh-loading/1932269 "2024-07-11T01:22:40Z")

</div>

Greetings! I have the following code that asynchronously loads a skeletal mesh and then set it into a component: // .h TMap\<USkeletalMeshComponent\*, TSharedPtr\<FStreamableHandle\>\> Handlers; // .cpp void ASeaDogsGameSt…

---

## [How properly read big textures Mip BulkData?](https://forums.unrealengine.com/t/how-properly-read-big-textures-mip-bulkdata/1931869)

<div class="topic-metadata">

**Author:** [@Viniccius007](https://forums.unrealengine.com/u/Viniccius007)\
**Replies:** 1\
**Last updated:** [July 11, 2024, 1:04am UTC](https://forums.unrealengine.com/t/how-properly-read-big-textures-mip-bulkdata/1931869 "2024-07-11T01:04:47Z")

</div>

So, I’m trying copy many textures to a unique texture (to create a Texture Atlas), everything seems to work fine for smaller textures (until 64x64), above that, the BulkData seems to be locked and not loaded, what should…

---

## [How to print strings in c++ console?](https://forums.unrealengine.com/t/how-to-print-strings-in-c-console/48777)

<div class="topic-metadata">

**Author:** [@anonymous\_user\_71046e02](https://forums.unrealengine.com/u/anonymous_user_71046e02)\
**Replies:** 3\
**Last updated:** [July 10, 2024, 9:05pm UTC](https://forums.unrealengine.com/t/how-to-print-strings-in-c-console/48777 "2024-07-10T21:05:37Z")

</div>

How to print strings in c++ console? It seems that ‘cout\<\<“hello word!”\<\<endl;’ didn’t work.

---

## [Unreal Engine causes 4k monitor to go black for a few seconds while moving mouse](https://forums.unrealengine.com/t/unreal-engine-causes-4k-monitor-to-go-black-for-a-few-seconds-while-moving-mouse/434385)

<div class="topic-metadata">

**Author:** [@matrixcn](https://forums.unrealengine.com/u/matrixcn)\
**Replies:** 23\
**Last updated:** [July 10, 2024, 8:25pm UTC](https://forums.unrealengine.com/t/unreal-engine-causes-4k-monitor-to-go-black-for-a-few-seconds-while-moving-mouse/434385 "2024-07-10T20:25:29Z")

</div>

Unreal Engine loads up fine. The problem is moving my cursor anywhere within the application windows causes the monitor to go black for a few seconds. it comes back…then when I move it again…same thing. Moving my cursor …

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

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