top of page
Writer's pictureNala Mthembu

Unleashing Creativity: Building an Open World Game Framework

Updated: Feb 7



So, I'm working on a modular open world game template, a kind of framework that I can reused and modify to fit a different projects needs.


Why would you want to reuse a framework?


Reusing a large part of a game is not unheard of and is pretty common, you've just never thought about it as a player. Just think about the Grand Theft Auto Trilogy (GTA III, San Andreas & Vice City), now think about how similar they games are to each other and how fast they were made, GTA Vice City and III's released dates are only 1 year apart. Another example is Assassins' Creed, a hit series that stuck goal on a formula, stealth and parkour = the coolest history game in the world.


A summary of features

I intended to make the systems of this project a general as possible however I did want it to be a third person shooter game.

The player should be able to:

  • Move in any direction independent from the camera.

  • Move off and stop in a believable manner.

  • Go prone, crouch, Jump

  • Pick up weapons and items and add them to an inventory.

  • Enter/Exit and control vehicles.

And I wanted characters to respond external stimuli such as collision and go into an animated ragdoll state similar to that of Euphoria Physics Engine used by big titles such as Grand Theft Auto. Later in production I will go ahead an implement more advanced features such as climbing, and a cover system.


Here is an animation blend tree for the Start Moving state in which the character beings to move in a specified angle and speed, on the player the angle is the delta angle between the player input (left stick/WASD) and the camera yaw (Y Rotation in Unity or the Z Rotation everywhere else).





What about sudden changes from Walk to Run mid animation?

This only shows start walking but its exactly the same for start running, they're blended together based on speed and direction. if the player suddenly decides to run in the middle of the animation, no problem, the blend tree will blend into the run blend trees at a similar time in animation as the walk animation.


This is exactly the same for the Walk/Run loop except I use two lean animations that make the character lean into a turn when a drastic turn is made by the player or AI.







This video shows the basic locomotion including going prone and crouching, all these animation states are handled by a PlayerStateMachine.cs that changes the animation states based on the players input.


Entity Class


I want every object that the player or other characters can interact with to have certain functions and properties that would allow for gameplay elements to be easily implemented such as:

  • Ownership for vehicles or items like weapons

  • Damage Systems

  • Removal of unneeded objects from the scene

  • A general way to address problems related to multiple subclasses of the entity type

  • A way for entities to interact with other entities

Entities include, Vehicles, Characters, Pickups among others.


Here is a snippet of what some of these properties and events look like:



Next blog I'll go in detail with the Weapons and Combat Systems, in the mean time here's a snippet




Well...I'll just show you one thing, the muzzle flash on the rifle is a particle effect that basically briefly shows a muzzle flash mesh that randomly spins on its Z axis (X axis in Unreal or any other engine with conventional coordinate systems)





I made that in Blender I might replace the flat planes with a full 3D object but I thought that would be overkill for an effect you only see for a fraction of second :/




31 views0 comments

Recent Posts

See All

תגובות


bottom of page