Souls-like Combat
I worked on a souls-like combat simulation, referring to combat systems in games like Dark souls.
I decided to use Unreal Engine 5.

This project is focused on the player in the game, and it's combat oriented abilities.

I have always loved the feeling of souls-like combat. How fair, impactful and deep the system feels while still being really intuitive.

So I decided to test out making some of the features myself. I picked Unreal Engine as i had never worked with it before and was intrested in learning more about it. Also, it is a quick way of testing basic gameplay ideas.

How and why I made these features
Enemy Lock On
I choose to sweep a sphere shape with a raycast to establish whether an enemy is close enough for the player camera to lock on. I choose this method since I only wanted to make a lock on possible while the player is looking towards an enemy. Also, this method gave me a lot of freedom changing the values of the raycast to achieve the behaviour I wanted the most.

I also made a feature enabling the player to switch between targets. But this time I only used a normal sphere raycast, to get all targets surrounding the current enemy. Making it possible to switch to the next enemy target, closest to the current one.

I added a sprint attack, heavy attack and light attack. Because this is a fun combination of attacks to play with. You either aim for heavy damage while risking yourself with a slow attack or you do a faster light attack for lesser damage but better protection and more speed. At the same time you are also able to utilize a run attack that requires the player to be more precise with their inputs. When doing so you get rewarded with a quick attack and a big area of damage, but suffer the weakness of getting close into enemy lines.

All the attacks I added were slow and strong to simulate the heavy sword. This way the attacks feel like wielding a heavy weapon with a big impact.

I also decided that the weapons should have a collider only a little bigger than the model. This was done to make the attacks feel more precise.

Sprinting and Rolling
The player has the ability to roll, sprint and dodge. Having the dodge and sprint ability on the same button is a really cool concept to me. When the player pressed the buttom, I made the sprinting mode wait to activate depending if you held the button down or not. Otherwise it rolled, this was done with a specfic timed timer, to make it feel intuitive.
Animation States & Blending
I decided to use animation blending with directional walking and sprinting.

I decided to do this in order to make it feel and look better when you are running - i.e. so it looks significantly different from walking. This also make it look better while you are locked on with the camera and moving side to side.
What I learned
Dark souls combat has a lot of important gameplay juice that I never noticed, that makes the game so much better. For example I decided to make a greatsword when I realised how good it feels when your attacks have some impact and nice buildups as well. To really show that great part of the game. It also felt rewardring to learn unreal engine, and rapidly getting the hang on the program.

If I did this project again, I would have wanted to focus more on completing core features in a more polsihed state. As I added features like blocking and souls-like jumping that were not used in the end.

Visual scripting
The basics of Unreal visual scripting was really easy to learn compared to programming languages with code, while also being quite fast to use. But I also found big weaknesses along the way, a lot of simple code could get unnecessarily complicated and it could really impact on how easy or difficult the functions where to read. But the more I worked with Unreal blueprints, the better I understood how to structure and use it's blueprints to achieve what I wanted.
Pros & Cons
When I compered C++ code and blueprints on its performance, I noticed a quite big difference. It ran a lot faster if you used C++. This is due to Unreal needing to translate the blueprints into C++ code, as well as C++ giving more control to optimize your code. But it was not a problem for this type of project due to the scale and purpose. Another weakness in blueprint scripting was the lack of control, C++ has a lot more function when it comes to for example saving and loading data. While also giving you more control to get the specific behavior needed.

The faster prototyping of Unreal blueprints makes it entirely in itself worth choosing for this project. Creating blueprints, variables and functions is just fast in general compared to C++. I also noticed blueprints are faster to iterate on, they are much quicker to modify logic on and more tweakable to use how you like. Another positive feature for me in blueprints is how easy it is using for visualizing the game flow. It is easy to follow the flow of the project and understand what happens and comes next, this makes it easier to debug and use breakpoints.