Frustrations with Unreal 5 and Visual Studio 2022

“Oh boo hoo, let me play a sad song for you on the world’s smallest violin”

As mentioned in the previous post I was getting really excited about the idea of using Unreal 5, given that it’s the latest and greatest that Epic has to offer. I also mentioned some initial troubles, forcing me to report bugs to Epic. As a developer I come to expect some level of difficulty when starting a tool as you learn its nuances, and the fact that most of the “bugs” are likely just your own fault. That view may be jaded from years of using old versions of C++ on very stable compilers, or rather it definitely is jaded as my experience with Unreal 5 has been quite the opposite.

Obviously at this point (Mid-July 2022) Unreal 5 has been out in full force for a couple of months now. As a user I would expect this to mean that we have a very stable tool, with some known issues being worked through that I may have not had to worry about until I was diving deeper into more complicated uses of the tool. Unfortunately, I feel like I am being hit in the face with everything right out of the gate. This isn’t to say that some of these things may be caused by my own doing and misunderstanding, but the things hitting me generally occur when following Epic’s own tutorials.

Given that Unreal 5 is still so new, a lot of their prior documentation for Unreal 4 hasn’t been rewritten for the later version, so I am happily following along in some old documentation. Specifically, for the basic demo game I am trying to develop – a generic horde mode survival FPS – I am working through Unreal’s First-Person Shooter Tutorial for 4.27 as their same tutorial for Unreal 5, seems to be incomplete at the time of writing this post. This is okay, however, as the given concepts are all cross-compatible from what I can tell and have thus far worked for me in my following-along. Maybe this is naïve, but outside of relying on the live coding feature of Unreal 5, everything given thus far in the tutorial has worked, when the tool hasn’t gotten in the way.

The long and short of it is that, given my novice status and desire to simplify as much as I can so that I can focus on learning Unreal and that parts of it that should work, I am considering downgrading to Unreal 4 and Visual Studio 2019 for the time being so I can get along a lot better. Before doing so, I just want to highlight the specific issues I have had so I don’t just seem like I am a 100% whiny baby who is unwilling to learn. If anything, I’d like to demonstrate that I am at most, only 20% whiny baby.

Before diving into the specifics, I will be forthright in the fact that my overall setup may be ambitious as I am using Visual Studio 2022 (17.2.3) and Unreal 5 (5.0.2). Not only am I using the latest version of the Unreal tool, I am also using a newer version of Visual Studio, than is recommended by Epic for either Unreal 4 or 5. Putting that aside, I am an optimist who thinks he can make it work and be ahead of everyone slowly transitioning to the latest versions. Keeping that in mind, let’s dive into the issues I’ve experienced so far.

Live Coding Doesn’t Auto-Compile Upon Reopening a Project

One of the most consistent issues I have experienced with Unreal thus far is a fundamental one that pretty much prevents me from ever restarting my computer or closing the editor mid-project. In the terms of layman and noobie, the general outcome of this bug is such that every time I relaunch my C++ Unreal 5 project (a simple project, mind you) all custom C++ classes are not present in the Content Browser, and all of my custom blueprints lose their parent C++ class.

This is particularly frustrating as even upon a recompile (if that actually works) I am NOT able to reassign the C++ parent to the blueprint class that was originally derived from said class, no matter what route I take. With no easy to find information on how to fix this, the past few nights I have had time to work on the project, my only work around is to recompile the project, and create a new blueprint from the C++ class and redo all prior work to set everything up as specified in the tutorial.

After dealing with this for long enough, I logged my first official bug with Epic. To their credit, I was happy to see a response to this a few days later. I was pointed to the the following ticket, as this is seemingly a known issue. As can be seen in the ticket, the reproducibility is 100%, which is what I experience, leaving me (and everyone else?) with a very pesky issue. One thing I would have hoped to find or have listed in the ticket would be a known workaround that I could leverage in the meantime.

I am Unable to Recompile my Project without Crashes

So there was seemingly ONE workaround to the above issue. So long as I didn’t close Unreal or Visual Studio, I wouldn’t have to experience the aforementioned problems. This is unsustainable to be sure, however, I am trying to minimize my time redoing and maximize the few hours of free time I have learning.

This little maneuever is going to save me ten minutes

This elite, big-brain trickery worked great until I hit the segment of the tutorial that introduces the concept of implementing projectiles. Right as I was really starting to get excited about shootin’ stuff, I encountered a self-inflicted issue that lead to another systemic one. The short form of my woes, being that after implementing a projectile, I was unable to assign the projectile to my character blueprint. Not yet realizing that I had added code specifying my Survivor (a variant on the tutorial’s FpsCharacter) as having a projectile property that was mistakenly set to be a subclass of ASurvivor itself…

// Projectile class to spawn
UPROPERTY(EditDefaultsOnly, Category=Projectile)
TSubclassOf<class ASurvivor> ProjectileClass;

Instead of…

// Projectile class to spawn
UPROPERTY(EditDefaultsOnly, Category=Projectile)
TSubclassOf<class ADefaultProjectile> ProjectileClass;

I thought that my inability to set the Survivor’s Blueprint projectile property as my custom projectile class, was due to some form of issue with Unreal being able to refresh available types. So, begrudgingly, I decided to restart my editor and see what would happen. The end-result ultimately lead me to writing this post so I could whine and justify my desire to go to Unreal 4.

Given no other changes to the project, I am completely unable to use live-coding to compile my project and thus given the prior issue, am unable to have parent’s for my previously created Blueprints. The crash always appears after attempting live-coding and appears as…

Doing some quick Google-Fu I found some related posts, and attempted to perform some work-arounds such as disabling async-loading as that seemed to have helped other people, but it did not solve my problems.

The linked post does state this assertion is also possible in Unreal 4, giving me less qualms about the fact that I will have no problems there, however, their issue didn’t stem from simply following the official tutorials. Though there may be an easy, or available fix I am just stupidly missing, this whole experience has lead me to my last point of the post.

The 4.27 Tutorial Maybe Isn’t What I Need it to Be for Unreal 5

The title says it all. While this experience thus far has been extraordinarily educational and revealed to me more than a smooth tutorial could on its own, I have been left thinking that without an official version of this tutorial for Unreal 5 I am left to suffer through this and figure it out on my own.

I don’t think anyone expects to follow a tutorial for a sophisticated tool such as Unreal is and spend a lot of the time tripping over unmentioned issues. The tutorial is quite clear, and beneficial, but as a user of their own newest and officially-released product I am left feeling like there is something missing for me. Most notably, this tutorial is not taking into account the live-compile technology that seems to be the new default for Unreal 5 C++ projects. This tool is powerful and I am excited to use it in the future, but the buginess of it even just going through Epic’s own tutorials has left me spinning wheels.

Conclusions

I think the obvious conclusions here are…

A. I am using Visual Studio 2022, which is not recommended for any version of Unreal by Epic

B. Some combination of Unreal 5 and Visual Studio 2022 is causing me more grief than I should be seeking out as a novice

C. I will likely have to reattempt my work in this project with Visual Studio 2019 and if that does not work, go a step further by additionally downgrading to Unreal 4

Regardless, given that Unreal 5 was officially released in the year 2022, I would have hoped that integration with Microsoft’s latest offerings would be seamless and that they would have updated their tutorials to coincide with an official release.

My First Month with Game Development

If I have learned anything from the internet, it is that for everything there is to learn, there are no less than 1025 YouTube videos, websites, and blog posts about someone’s journey learning it. So I figure it’s time to ask not what the internet can do for me, but what I can do for the internet, and what I can do for the internet is push it one step closer to Datageddon. How will I do this? By ensuring that Google search results yields for “Game Development for Beginners” reaches a count of 1025 + 1.

Sarcasm aside, I hope to share with you what got me started in finally trying game dev, what I have learned/done so far, and why I landed on Unreal Engine 5 as the tool I will use going forward. I will leave out some of the grittier details on all of this for a follow up post on the actual project I’ve been using as a first foray into making a “simple” game.

The Final Push to the Beginning

So how did I get started trying this stuff out? If you read my prior post I mentioned that a goal of mine this year was to go full throttle on software and try to rekindle some of the fun I used to have when I was learning all of it for the first time. Around the time that I made this decision I just happened to stumble on a Tweet from Free Radical/Deep Silver that the Time Splitters franchise was being rebooted and they were looking for developers. Not only did this game make a massive impact on the way I perceive what multiplayer games should be, it’s also a game that introduced me to some basic game development concepts like level design, AI, and gameplay through it’s map builders and various unique game modes. That being said, StarCraft did show me some of the same things, but at a time when I was a bit too young to really get it.

Knowing that such a job was something I was woefully unqualified for, but that video games were something I always loved and wanted to try my hand at, I figured why not start small and see how I feel about it. After all, it had been a long time since I tried GameMaker Studio as a 12 year old and realized that I was in way over my head.

Me trying to start small and feel smart

So I decided to pick up a book that could help me as a Software Engineer (in line with my existing goals) and give me some exposure to a different side of things. With that in mind I picked up Software Design Patterns by Robert Nystrom. Gaining some knowledge on design patterns, while always considering them with a bend towards game dev was everything I needed to have the self-realization that I need to try this shit out for myself.

What I’ve Been Doing

So the next question is obviously, how do you execute on your goals? With lots of stops and starts of course! As much as I wish that I was the kind of person who just decides they want to do something, finds a lesson plan, and then goes through it without interruption while learning everything they can on the way, that is not me.

Through the hobbies I have stuck with I have learned that I will often start and stop things as I find time for them, good resources to learn them, and motivation to participate in them. I don’t think this is a unique characteristic so much as a deviation from the 80’s montage of learning a skill that we’re all taught from movies is how things work. Though I want to punch the frozen cow carcasses of knowledge until my knuckles are flattened and I can develop a AAA quality game alone, with my eyes closed, that’s just not how it works.

If anyone finds a way to learn how shaders work by punching beef, please let me know

Instead I bounced around, found helpful bits and pieces, got an understanding of the field from different perspectives, watched videos, read things, and took a few stabs at everything myself. I was able to find the /r/gamedev community on Reddit, the well known lazyfoo tutorial for beginning game programming, and several great YouTubers discussing game development at a high level (Pontypants, Mark Brown, BadGameDev), as well as those discussing at a lower level (jdh, PatchQuest).

These resources gave me a plethora of information on game development, where some of the most significant pieces of advice I was able to glean from them were: game development is a beast, don’t expect to make a fully-functional game in a month, and start small. These lessons, topped with good demonstrations on the complexity of writing a game engine from scratch lead me to wanting to work in either Unity or Unreal, especially given their marketability as a skill and wide range of available resources for learning them. Given my prior experience in C++, lack of desire to learn C# while also learning game dev, and general deference towards suffering, I landed on using Unreal 5. I’m sure at least one person laughed at this paragraph starting with “start small” followed by “I’m using Unreal”, but that’s how it goes sometimes.

Going through a beginner tutorial on some basics of Unreal 5 enlightened me to use of the tool at a high level and helped me gain some basic insight into the power of the tool as a whole. This tutorial further went through some of the impressive features new to Unreal 5, such as Lumen and Quixel MegaScans, which got me even more excited to be using the latest and greatest. That being said, in my short time using Unreal 5 I have caught more than a few bugs and have logged one officially with Epic. Them be the breaks when you decide to use a newly released tool, however, coming from a professional background of being locked into older technology stacks, I felt it best to start with the latest available, and learn it as it grows. I may end up regretting that in the near term, but one way or another Unreal 5 is the next step…

Before I ramble further, I will end this post more or less abruptly as I previously mentioned that I want to create a separate post to give some more detail on my next steps and a basic project that I plan to complete as a means to learn. The jist of that project being a basic horde survival FPS. Emphasis on the basic as I truly do want to go forward with the most consistent piece of advice I have received, start small.