Unreal 4: Action RPG Project
This project does not yet have a title and it’s still early in its development. It is a solo project I have created in a week during my summer break. The concept is that this will be a souls-like RPG game where the player would explore deeper and deeper into a PCG generate environment as they gain loot and experience from combat. As of now, the game is still using character models and animation taken from Mixamo, however my own character model and animation in development right now.
In order to capture the essence of souls-like games, the emphasis of combat was on animation canceling. The idea is that each action will be broken down into different animation phases and certain actions (such as attacking) can be interrupted by other actions (such as rolling) if timed properly.
Due to its importance and complexity, I have made a function to handle the animation frames based on animation notifications, which allows me full control over frame timing and quick drag and drop implementation of new animations.
The function accepts parameters such as Action Name, Animation Reference and Play-rate, and handles the rest by itself.
Stagger cancels attack animation
I have also experimented with simple rag-doll physic, which is applied to dead enemies’ corpses. It made for pretty cool piles of corpses forming around as you find within an area.
Piles of corpse
As for the procedurally generated map, I made a Master Generator where you provide parameters such as the row/column size, floor number, and a generation seed. The Master Generator will then spawn in Floor Managers, who first generate a full grid using the row/column number provided, then loops through a random walk algorithm to determine which blocks are in fact walkable and which ones to remove from the grid. After the random walk, a Tile Manager will be spawned for each of the walkable tiles in the array, storing information about its own neibors and wall type. The Tile Manager are responsible for figuring out what type of tile should be spawned at their location, which is, of course, randomized to create diversity. All of the floor and tile information are stored in lists in the Floor Manager which are indexed using a Vector2 containing their row and column number.
PCG map using only place holder meshes that indicates how many walls are on each tile.
The random walk always makes sure that it generates an exit for each floor, and the coordinates of that exit will be passed down to the next floor and be used as the starting position for the next random walk in order to ensure that each floor connects to the one above and below it.
Inside of the map, green indicating that tile is the entrance of this floor.
More developed meshes are being implemented, which are made out of modular assets. I am using a combined method of LOD , culling and instancing in order to improve performance. Currently I can comfortably run a view on over 20 floors with a stable fps above 60. The player should never be able to view as much tiles at once during actual game play.
The map with more detailed mesh, running at a stable 60 fps
Interior of one of the rooms, the mesh is still placeholder but paints a better picture of the aesthetic of the environment.