UE4 V.S. 100 Billion+ arithmetic calculation simulation

So I have my project mostly up and running In UE4, but the problem is that it’s running a little slow to be of much use to me: About 50,000x too slow to be exact :frowning:

The Question is, should I scrap the project in UE4 and attempt to learn C++ and rebuild from the ground up, or would “partial C++” (don’t know how to do this, but i’ve heard Epic does it for some of their game features) work for handling the bulk arithmetic, but keep the ease of blueprints (which I can actually understand to some degree) for things such as writing to and reading from data tables, basic logic flow etc.

other concerns would be:

  1. Would UE4’s infinite loop detection still apply to C++ code, forcing me to keep my small periodic delay running? (I set a 0.00000001 delay periodically to prevent the detection, but I suspect it might be rounding it up to 0.001 or something much longer)

  2. Even If I do learn C++ and get this together, would I still be lacking the “optimization” skills to make it run as fast as I would want it to?

  3. If I have to end up paying someone to optimize it, are there people who can convert UE4 projects into C++ and optimize?
    what do you think the cost would be? This is a personal project that I have no intention of distributing.

Thanks in advance for whatever information or advice you can give!

Partial blueprint is writing a method in C++ (using a UPROPERTY(BlueprintCallable) macro) and then calling it from BP as opposed to doing everything in C++. I cannot say if converting it to C++ would be an instant fix for the issue as I don’t know what is causing the slowdown but it will speed it up significantly. First thing I would suggest is moving everything out of tick that you can and instead, set a timer with a delay instead.

  1. You should never use a delay in C++ to stop an infinite loop, if you are then something is wrong with the code
  2. You won’t know until you try but once you step into the C++ world, stackoverflow will be your friend.
  3. They exist but aren’t cheap; I would recommend using the forums to ask questions (or stackoverflow)

If you need to run something 100B+ times, you’re probably going about the problem incorrectly. What are you trying to do?