Gameplay Abilities are essential for modern Unreal game development as they decouple pawn from actions. This allows for modular development and avoids blown up character BPs
In this tutorial, we focus on how to bind abilities to your Pawn class via a Lyra Ability Set. Furtermore, we dive shortly into the Enhanced Input System to extend the Lyra input bindings with a framework for localized, plugin specific bindings
Steps (referring to infographic letters)
orange E, U, T: Create a gameplay ability, add it to the Pawn class
orange F-I: Create a localized Enhanced Input mapping. Bind a gameplay input tag with an gameplay ability via a Lyra Input Config
Lyra Gameplay Abilities Subscripe to Tag changes
Create a gameplay tag debugging function
Create a material with an exposed parameter to make it glow from a BluePrint
Create a listener to gameplay tag changes on all character BPs and react to these
Outcome
Diving deeper into gameplay abilities and how to use them to communicate between actors
Dump Tags: A debug function to show active gameplay tags per tick
How to listen and react to Lyra gameplay tag changes in other actors. This is automatically multi-threaded, easily replicated and extremely low on resources - recommended as standard pattern to organize your in game communication
Lyra Gameplay Abilities Components and Template
Add Gameplay Cues, Gameplay Effects and Gameplay Costs to an Ability
Create a better Blueprint Debug function
Dance to death: Apply health costs for dancing
Outcome
A more complete template for our Gameplay Ability System
Gameplay Cues are connected via Gameplay Tags to Gameplay Abilities
Gameplay Cues Notifier point to Sound Waves, Niagara effects, Force Feedback effects or Camera Shakes
Gameplay Effects add costs to abilities - we use the Lyra health system to apply health costs while dancing
How to listen and react to Lyra gameplay tag changes in other actors. This is automatically multi-threaded, easily replicated and extremely low on resources - recommended as standard pattern to organize your in game communication
Lyra Gameplay Abilities through the Environment
Bind in Lyra ShooterCore throughthe Visual Studio plugin file
Grant your character the GA_Interact from ShooterExplorer
Build a BP Actor derived from Lyra World Collectable
Use a BP Interface to launch an external URL while interacting
Outcome
Understanding the usage of the GA_Interact and how to understand Gameplay Ability interactions as properties of the environment, not the character
Unreal game messaging system - publisher and subscriber patterns explored
Understanding the role of Gameplay tags to trigger events
Sending gameplay events to actors
Abilities through Equipment
Add a Lyra Equipment Manager Component
Connect Lyra Equipment Definition with Ability Sets and Tagged Actors
Implement an interface for BPs in your level to grant new Gameplay Abilities
Implement a chain of reactions to set abilities granted (server) and input mapping conects received (client)
Outcome
Equipment and its ability to add gameplay abilities are extrfemely powerful - even a bullet can be an “equipment” that grant nice abilites with gameplay effects and cues