You are on page 1of 70

 

Documentation 

Ascent Combat Framework 


 

Overview 
1.1 What is ACF?  

Ascent Combat Framework (ACF from now) is a multi-modules C++ Plugin for Unreal Engine 4 
that  provides  an  extendable  and  easy  to  use  framework  to  build  your  Action  RPG  games  in  a 
very  short  amount  of  time.  It  is  composed by a set of different tools and is natively networked 
BUY NOW! 

 
 

MADE WITH ACF: 

https://youtu.be/2odhgY5ChxI 

1.3 Why ACF is different from other assets? 

Because  is  like  an  RPG  Maker,  but  for  AAA  games.  It  is  not  designed  to  be  a  ready  to  go 
system,  but  a  “Systems  builder”  with  a  great  focus  on  extendability.  This  is  NOT  a  blueprint 
base  combat  system  with  pre-made  logics,  even  if  a  pre-made  sample  project  is  provided  for 
learning  purpose.  This  one  is  a  c++  generic  framework  with  a  basic  combat  implementation 
(melee  and  ranged)  that  does  not  take  any  assumption on the game you are building, and that 
you  can  expand  as  much  as  you  can.  So  this  a  base  framework  you’ll  have  to  Extend,  instead 
something  you’ll  have  to  modify,  making  your  codebase  SOLID 
(​https://en.wikipedia.org/wiki/SOLID​) 

This  is  done  to  avoid  to  give  to  your  game  that  "asset  flipper"  feel  that  most  of  the  garbage 
indie  game  have  when  made  with  pre-made  assets,  while  giving the ability of the ACF user to 
create something polished and unique as the game you can see in the trailer. 

1.2 Usefull Links 

DISCORD:  
https://discord.gg/ahqhXnJ 
 
EMAIL: 
pasqualemangano@gmail.com 
 
SUPPORT THREAD: 

 
 

https://forums.unrealengine.com/unreal-engine/marketplace/1757558-a
scent-combat-framework-c-high-end-action-rpg-creator 
 
VIDEO-TUTORIALS: 
https://www.youtube.com/playlist?list=PL8jTN9dmYyyperIAtZEl1er__Jp
57qpI7 
For More Tutorials please send PROOF OF PURCHASE TO 
pasqualemangano@gmail.com​! 
 
SAMPLE PROJECTS: 
To receive the FREE Sample Project 1.2.0 send proof of purchase to 
pasqualemangano@gmail.com​! 

1.4 What is included? 

ACF toolset includes:  

- Complex generic​ Character Controller​ with locomotion and animation controller 


- Actions  System​:  a  generic  way  of  handling attacks/skills/dodges etc. easily extendable 
and natively networked 
- Items & Inventory​: extendable integrated items system with inventory and pickup logic 
- Equipment  System​:  generic  equipment  system  that  allows  developers  to  define  their 
own equipment slots 
- AI Framework​: create and customize your AIs, configure their behaviors 
- Companions:  ​create  and  manage  companions  for  your  player.  Easy  switch  control  on 
them 
- AI Groups: ​create optimized groups of AIs that fights as one and helps each others 
- Crafting System​, support for creating and upgrading items by combining them. 
- Statistics  and  RPG  Framework  (ARS)*:  create  your  own  stats  and  define  how  they 
influence each other. Dynamically adds and remove modifiers.  

 
 

- Generic  &  Optimized  ​Collisions  Manager  (ACM)*:  generic  way  of  handling  combat 
collisions 
- Optimized  &  Customizable  ​Multi  Point  Targeting  System  (ATS)*:  create  one  or 
multiple targeting point per character 
- Camera Manager​ (CCM)* an easy way to implement a multi-state Camera controller 
- Combined  Animation  System (CAS)​* Module to handle combined animations between 
characters, NOT REPLICATED at the moment 
- Mount  System  ​System  to  mount  and  dismount,  possess  any  character  NOT 
REPLICATED at the moment 
- Ability System​ : Grant and use Passive and Active Abilities 

*available also as separate plugins 

 
1.5 Should I need to know C++ to use ACF?  

Absolutely  not.  Everything  is  exposed  to  blueprint  so  you  can  use  and  expand  it  in  blueprint. 
However ACF is highly engineered, so programmers can go deeper with it. 

1.6 Is it easy to use? 

Is  waaay  easier  than  build  all  this  stuff  by  yourself,  but  of  course  it  will  require  a little of time 
to  understand  how  it  works.  ACF  is  heavily  documented  and  I  will  work  on  expand  tutorialS 
and  documentation  over  time.  A  set  of  “ready  to  go”  projectS  are  provided  as  sample,  but  I 
think  that  the  real  strength  of  ACF  is  that  can  be  used  to  create very different  systems giving 
to your game the “uniqueness” it deserves.   

1.7 What is the future of ACF? Will it be updated regularly? 

ACF  is  used  internally  to  develop  our  projects  so  it  will  be  definitely  updated  regularly,  even 
because we are forced to do so. In addition more modules are coming like:  

 
 

- Quest System 
- Dialogue Syste 
- FSM System 
- Building System 
- … more 

Bug  fixes  and  refactors  will  always  be  free  updates,  additional  modules  may  be  charged 
separately.  

1.8 May I used this together with other assets from the marketplace? 

Absolutely yes. ACF is 100% modular, I used it with third party dialogue systems, quest 
systems, UI plugin, animations, graphical assets and whatever! 

1.9 Who are you and how do you learned Unreal? 

Since a lot of you asked: ​https://www.linkedin.com/in/pasquale-mangano-8b64a886/​, and yes, 


I work as professional Unreal programmer with 2 AAA game released. 

   

 
 

1.10 Class Diagrams 

 
 

 
 

 
 

 
 

 
 

2. (ARS) Advanced RPG System 


Advanced  RPG  System  (​ARS​)  is  one  of  the  modules  of  ACF.  It  handles  all  the  “RPG  side”of 
your game. But let’s start from the beginning.  

2.1 Statistic, Attributes and Parameters 

ARS supports three different kind of ​Stats​, in particular:  

- Attributes​:  like  Strength,  Endurance,  Constitution  etc.  those  are  used  to  automatically 
generate your Statistics and Parameters 
- Parameters​:  like  Attack Damage, Defense, Crit Chance etc. those are characterized by a 
Value that is use for your actual calculation 
- Statistics​:  like  Health,  Stamina,  Mana  etc.  those  are  characterized  by  a  Max  Value,  a 
Current Value and a Regeneration Value 

2.2 Plugin Setup 

The  first  to  do  is  to  create  and  setup  your  own 
AttributeSet.  This  can  be  done  through  a  DataTable 
(Right  Click  on  Content  ->  Miscellaneous  -> 
DataTable). 

The  type  of  struct  used  for  the  DataTable  should  be 
GamePlayTagTableRow  (the  one  highlighted  in  the 
image below).  

In that DataTable you could actually define the 


GameplayTags that identifies your AttributeSet. 
They should be written in the form: 

RPG.Statistic.Health 

 
 

Where  RPG  is  the  global  tag  root, 


Statistic  identifies  the  stat  type 
(Statistic  /  Attribute  /  Parameter)  and 
Health  is  the  actual  Statistic.  In  this 
Datatable  you  can actually setup your 
stat  list.  To  use  those  GameplayTag 
we’ll  need  to  go  in  to  our 
GameplayTag Settings 

(Edit -> Project Settings -> GameplayTags) and ad the tags created by adding the DataTable in 
the GameplayTagTableList. 

Now your GameplayTags are effective and we can switch to the actual Stat configuration. 

Please notice that you cannot add GameplayTags at Runtime! 

 
 

2.3 AttributeSet Setup 

This  step  can  only  be  done  if  you  have  successfully  set  your  GameplayTags.  In  your 
ProjectSettings  tab,  go  to  ARS  Settings.  Here  you  have  to  tell  to  the  Plugin  the  actual  Tag 
Roots of your AttributeSet. For Example:  

If  ​RPG.Statistic.Health  is one of your statistics, ​RPG.Statistic ​will actually be the Root of all you 


Statistics  tag.  This  setup  is  necessary  since  the  Plugin  ensures  every  time  you  are  using  a 
wrong Tag as a parameter for a method or to prevent errors during a Character configuration.  

ARS  allows  the  Designer  to  control  all  the  character  AttributeSet  by  just  settings  their 
Attributes  and  a  set  of  Generation  Rule  that  are  used  to  automatically  generate  all  the 
Statistics  and  Attributes. Generation Rules are set through the use of ​UCurveFloat ​objects. You 
can  create  your  own  curves  in  any  folder  (Right  Click  in  Content  Browser  ->Miscellaneous  -> 
Curve).  In  the  image  below  how  the  ​RPG.Attribute.Strength  Attribute  have  been  setup  to 
modify the R
​ PG.Parameters.MeleeDamage ​Parameters.  

 
 

In  this  case  we  can  see  how,  if  the 


strength  of  our  Character  is  13,  his 
bonus  to  MeleeDamage  will  be  96.86. 
Please  notice  that  every  Attribute  can 
modify  multiple  Statistics/Parameters 
and  Statistics  /Parameters  can  be 
modified  by  multiple  Attributes,  in  that 
case  the  actual  value  will  be  the  sum  of 
all  the  influences.  The  same  thing  must 
be  done  for  each  Statistics  with the only 
difference  tha  Statistics  have  two 
different  values  that  can  be  modified: 
Max Value and Regeneration Value. 

In the above sample ​RPG.Attribute.Endurance​ have been set to generate both Max Stamina 
and Stamina Regeneration (​RPG.Statistic.Stamina​). 

 
 

2.4 ARS Component Configuration 

To  actually  implement  ARS  functionality  you  must  add  the  ARS  Statistics  Component  to  your 
agent  and  configure  it.  ARS  supports  different  ways  to  handle  your  AttributeSet.  To  properly 
use the Plugin is important to understand how they work. 

StatisticConsumptionMultiplier:  ​Multiplier  applied  every  time  you  modify  CurrentValue  of  the 
target  Statistics.  Could  be  useful  to  implement  logics  like:  if  your  inventory  is  full,  Stamina 
consumption is multiplied by 1.5 for every action. 

 
 

StatsLoadMethod: ​Define how your Statistics and Parameters are generated:  

- Default Without Generation​: No generation is applied, Default values are used. 


- Generate  From  Default  Attributes​:  Define  your  Attributes  in  DefaultAttributeSet, 
Parameters  and  Statistic  will  be  generated  following  the  rules  defined  in 
ProjectSettings ARS Settings. 
- Load  By  Level From Curve​: Define the level of the character and Generate AttributeSet 
from AttributesByLevelCurves.  

Default value is set to G


​ enerate From Default Attributes. 

DefaultAttributeSet:  ​Attribute  set  used  if  you  select  No  Generation  or  Generate  From  Default 
Values.  In  the  first  case  it  is  used  “as  is”,  in  the  second  one,  your  Attribute  will  be  used  to 
generate your Statistics and Parameters following your previously configured ARS Settings. 

CanRegenerateStatistics:  ​This defines if the Statistics of this Character can regenerate. Turn off 
regeneration for performance optimization.  

RegenerationTimeInterval:  ARS  Component  does  not  tick  for  performance  reasons.  This  value 
defines the time interval for regeneration. Set high values for optimization.  

To  actually  start  to  work  with  ARS,  remember  to  call  the  ​InizializeAttributeSet  ​in  your 
beginplay  (or  when  you  want  to  start  to  work  with  it) - (NOTE: this is not needed in ACF since 
it’s done automatically) 

2.5 Attribute Modifiers 

AttributeModifiers  are  used  to  apply  modifications  to  the  AttributeSet of your Characters. This 


could  be  useful  if  you  want,  for  instance,  that  your  Attributeset  could  be  modified  by  your 
equipment  or  by  a  particular  state.  There  are  two  different  types  of  Modifiers:  ​Additive  ​and 
Percentage​.  ​Additive  ​modifiers  are  simple  additions  of  the  actual  values  of  the  modifier to the 

 
 

actual  values  of  the  Character  AttributeSet.  ​Percentage  ​modifiers  apply  a  modification  based 
on  the  current  values  of  the  AttributeSet  (20  means  that  the  actual  value  of  that  stat  will  be 
raised by 20%). 

This  particular 
modifiers  increments 
MaxStamina  by  20, 
Stamina  regeneration 
by  5  and  Ranged 
Damage  by  75. 
Modifiers  can be added 
and  removed  at 
runtime  by  simply 
calling  the  relative 
methods: 

Modifiers  are  always  handled  Server  side.  You  can  also  use  Timed  modifers,  who  actually  are 
automatically  removed  after  a  certain  amount  of  time.  All  those  functions  are  exposed  to 
Blueprints. 

 
 

Please  notice  that  Modifiers  have  no  effects  for  Statistics  Current  Values,  since  they  are 
instantly  normalized  to  the  new  MaxValue.  If  you  actually  want  to  modify  CurrentValue  of  a 
Statistic you must use: 

Statistic modification is always handled Server side. 

2.6 Experience and Levelling 

ARS  includes  a  leveling  system.  To  make  it  work  properly  you  also  have  to  setup  your 
ExpForNextLevelCurve. T
​ hen you can the BP exposed function:  

That will add the experience and eventually level up your character. 

  You  can  select  it by changing the Leveling type value: you can choose to not use it all, to use a 


curve based leveling system or a perk based leveling system.  

 
 

CharacterLevel: C
​ haracter Level used for generation if leveling system is active 

ExpForNextLevelCurve:  ​For  Each  level  the  amount  of  Exp  necessary  to  Lvl  Up  set  as 
UCurveFloat. X
​ axes is Character’s current level, and Y axis is the amount of exp to level up.  

2.6.1 PerkBased Leveling System 

If  you  select  the  PerkBased  LevelingSystem  at  every  level  up  your  character  will  receive 
PerksObtainedOnLevelUp  amount  of  perk  and  you  have  to  manually  call  the 
AssignPerkToAttribute  function  to  consume  a  numPerk  number  of  perks,  modify  an  attribute 
and regenerate the AttributeSet of the character.the curve based leveling system you 

 
 

2.6.2 CurveBased Leveling System 

With the curve based leveling system you have to setup a set of curves that will be used to 
automatically regenerate your character's stat at each level up.  

AttributesByLevelCurves:  ​Implement  Rules  to  generate  your  ATTRIBUTES  starting  from  your 
Level.  For  each  Curve  on  X  you  have  the  Level,  on  Y  the  actual  value  of  the  Attribute  for  that 
Level.  This  is  only  used  if the ​StatsLoadMethod ​have been set on ​Load By Level From Curves. 
In  that  case  your  Attributes  will  be  read  from  your  ​UCurveFloat  in  which  in  the  X  Value is the 
Character Value and the Y value is your actual Attributevalue. Statistics and parameters will be 
generated consequently following your previously configured ARS Settings. 

2.7 Blueprint Functions 

Inside ARS you’ll find a DocuActor which includes an overview of all the BP functions of the 
plugin. 

2.8 Delay 
In latest ARS version a regeneration delay can be setted for each statics. This is used to 
replicate most of the stamina based mechanics in which, after you perform an action that 
consumes your Statistic, you regeneration does not start immediately but after a tunable 
amount of time.  

 
 

2.9 Setup a Stat Bar Tutorial 

A brief tutorial on how to create a Progress bar based on the plugin’s Statistics system:  

Inside the panel: 

Inside the actual bar: 

 
 

 
 

3. Collisions Manager 
 

3.1 Collisions Manager Component 

Combat  Collisions  Manager  is  the  Plugin  that  manages  collisions  during  combat.  It  is  pretty 
generic  and  in  ACF  is  used  multiple  time for both character, weapons and projectiles. The only 
thing  to  do  is  to  configure  and  activate  it  when  needed.  First  of  all  you  need  to  add  the 
ACMCollisionMasterComponent  ​to  your  GameMode.  This  will  be  the  responsible  of  all  the 
collisions check.  

3.2 Setting up your damage zones 

To start using ACM you need to add the Collision Manager Component to the actor you want 
to deal damage and configure it: 

Here an example of a Blueprint that configure the component to call DoStuff when a collision 
is detected, while ignoring itself and using as a collision mesh the SkeletalMeshComponent 
called Mesh. 

 
 

To properly handle damage we now have to setup damage zones on your mesh and configure 
the component: 

Damage  Zones  are  called  Damage  Traces.  They are defined in the component properties as an 


array,  each  zone  is  identified  with  a  Start  Socket,  an  End  socket  and  the  radius  of the damage 
volume.  To  let the component work properly you must add socket with the same name on your 
mesh.  Collision  Channels  are  the  channels  against the Trace is performed (for optimization all 
other  channels  are  ignored  so  basically  be  sure  to  properly setup this field). Please notice that 
your  target  colliders  (enemies  body,  for  instance)  should  be  set  to  Overlap  to  at  least  one  of 
the  collision  target  added  to  the  ACM component. Allows multiple hits per swing is by default 
turned  off  to  avoid  that  a  multiframe  trace  collision  can  hit  multiple  time  the  same  enemy,  if 
this is your expected behavior please turn it on. 

 
 

If  you  want  to  see  your  damage  volume  at  runtime 
you should turn on the Debug Info. Please note that 
in  ACF  every  tick  is  by  default  disabled, so you will 
not  probably  see  the  volume,  if  not  during  the 
swing  (when  the  trace  are  active).  You  can  try  the 
component  on  other  meshes  /  actor  to  check  the 
volume.  

Please  Notice:  In  ACF  damage  collisions,  ignored 


actors  etc.  are  already  setted  up  automatically  for 
melee weapons, physical attacks and projectiles! 

To  activate  and  stop  damages  you  have  to  call  the 
StartSingleTrace,  StartAllTraces  and  StopSingleTrace,  StopAllTrace  methods,  or 
StartSingleTraceTimed,  StartAllTraceTimed  that  automaticly  turns  off  collisions  after a certain 
amount of time. For more info please check the DocuActor. 

3.3 Damage System 

ACM Damage system is based upon Unreal Damage System. if ​AutoApplyDamage i​ s enabled, 
every time the component hits something, it calls Unreal TakeDamage on the hit Actor.

 
 

The ​FDamageEvent ​is automatically constructed by the Component with the HitResult and the 
info provided in configuration. 

 
 

4. Targeting System 
 

4.1 Basic Setup 

ATS  is  the  module  used  for  target  detection  and  camera  locking.  It  is  based  on  a  highly 
configurable  component  that  should  be  added to your PlayerController. Then to make an actor 
targetable it should be Implement the UATSTargetableInterface. To implement an interface, go 
to  your  Blueprint  ->  Class  Settings  ->  Implements  Interface  ->  Add  and  select 
ATSTargetableInterface. Now you need to configure the component. 

4.2 Component Configuration 

 
 

To  trigger  the  targeting  system  you  have  to  call  the  ​TriggerTargeting  ​function  from  your 
component, to swap targets you have to call Up/RightSearchTargetWithInput.  

Target  detection  is  collision  based,  so  you  need  to  default  which  channels  should be checked. 
For  optimizations  reasons  all  other  channels  are  ignored. The Max target distance is the radius 
of  the  collision  detection  and  the  Max  Angular  Distance  Degree  indicates  the  radius  of  the 
actual targeting cone.  

There are multiple kind of Targeting:  

Lock Camera: automatically locks Controller view on target 

Magnetic  Lock  Camera;  magnetically  move  your  Controller  view  on  target,  you  can  slightly 
move  it,  but  the  position  will  be  progressively  automatically  moved  again  on  your  targeting. 
Magneting Strength can be tuned. 

You  can  also choose which is your logic to choose the best target between the nearest one and 


the one that is nearest to the Front vector of your Actor owner. 

To avoid awkward camera positioning you can also set an up/bottom pitch limit.  

 
 

4.3 Targeting Interface 

Once  one  of  your  Actors gets target a set of 


methods  are  called.  In  particular  On  Target 
acquired  when  it  gets  targeted  by  the 
player,  and  OnTargetLosed  when  he  is  no 
more the currently focused target.  

4.4 Target Point Component 

You  can  also  add  one or more Target Points 


to  your  targetable  actors.  By  default  if  you 
target  an  actor  with  the  Force  Camera  Control  rotation  set,  your  camera  will  automatically 
point  to  the  TargetActor  position.  However,  if  the  Actor  has  a  TargetPointComponent  the 
camera  will  lock  on  the  Component  position.  This  will help you to point the target to the exact 
point  you  need  of  the  actor.  In  addition  you  can  add  multiple  Target  Points  Components  to 
each  target.  When  you  trigger  Right/UpSearch  the  target  will  automatically switch among the 
TargetPoints  Components  of  that  Actor.  This is very helpful if you want to have, for instance, a 
huge enemy with multiple targetable points on it, like hands/ head etc. 

4.5 Target Filters 

Target  filters  are  used  to  dynamically  modify  your  “targetable”  rules.  A  Target  Filter is a class 
with  just  a virtual method IsActorTargetable that will allow you to add targetables rule to your 
game, even at runtime using ​AddFilter / Remove​ filter methods.  

4.6 AI TargetComponent 

AI Target Component is used to actually bypass Unreal Engine’s AIController SetTarget 


method that sets the AI to look at the actor's world location, that in humanoid characters is 

 
 

normally around the waist. Using AITargetComponent's SetTarget, the viewpoint location will 
be changed to the actual TargetPointComponent, allowing you to move the TargetComponent 
at any point you want. 

5. Camera Manager 
 

5.1 Overview 

CCM is a small plugin that implements a state-based camera system that will allow you to 
easily blend between camera movements with just one blueprint node. It supports different 
kinds of camera movements. 

5.2 Setup 

To use CCM you have to change the actual PlayerCameraManager to 


CCMPlayerCameraManager.  

 
 

Make  sure  that  inside  CCMPlayerCameraManager  the  two  data table (CameraMovements and 


CameraRotations  have  been  set up (Click on the lens close to the blueprint to directly go in the 
specific  folder  in  Content  browser).  To  add  your  camera  events  you  have  to  setup  the  two 
DataTables  in  the  CameraManager.  If  you  cannot  see  the  CCM  folder,  on  the  bottom  of  the 
content  browser  navigate  to  ViewOptions  ->ShowPlugIn  Content  or 
ViewOptions->ShowEngineContent depending on where you installed the plugin.  

5.3 Adding your camera Events 

In the two datatables you can add your Camera Movements and Rotations and configure them. 

Camera Offset: relative position of the camera to the end of the movement. 

InterpSpeed: the speed of the movement 

Fov​: the relative change in field of view of your camera. 

FOV Interp Speed​: the speed in which your FOV Changes. 

You  can  also  add  a  CameraShake  class  and  configure  it’s  intensity  and  if  it’s  looping.  In  ACF 
this  is  used  for  Sprinting,  for  instance.  Please  notice  that  Camera  Movements  can  be  nested 
and you can have multiple movements playing simultaneously. 

 
 

5.4 Triggering Camera Events 

All  the  camera  event  mentioned above are exposed to blueprint as Static Function so that they 


can  be  triggered  by  everywhere  by  just  calling  the  relative  function 
TriggerCameraEvent/StopCameraEvent  and  their  timed  version  TriggerTimedCameraEvent 
that automatically stops after the decided amount of seconds.  

LockOnTarget​:  an  useful  function  that  allows  you  to  lock  your  camera  to  point  to  a  specific 
actor. Useful for instance for a dialogue system. 

For more information please check the DocuActor inside the plugin.  

Please  notice  that  CCM  automatically  takes  the  references  of  the  camera  of  the  currently 
possessed Pawn and updates automatically once the pawn changes. 

5.5 Triggering Camera Sequences 

Camera sequences are camera movements made following a spline.  

To  prepare  a  camera  sequence  you'll  have  to  add  a  ​CCMCameraSplineComponent  ​and  define 
the  spline  your  camera  must  follow.  Then  you  can  setup  the  movement  of  the  camera  by 
configuring the component and giving it a name.  

 
 

To  trigger  a  camera  sequence  you  must  ​GetLocalCCMCameraManager  ​and 


TriggerCameraSequence  ​passing  the  reference  of  the  actor  who  owns  the 
CCMCameraSplineComponent a
​ nd the name of the actual Spline component (SequenceName).  

You  can  then  add  a  ​CCMLookAtPointComponent​,  give  it  a  name  and  set  it  as  ​LookAtPoint  ​in 
CCMCameraSplineComponent​,  this  will  make  the  camera  to  orient  and  track  that  point  in 
space.  If  you  want  to  changed the configuration of the sequence during the play, you can use a 
CCMSequenceNotifyState  ​on  any  animation.  The  config  of  the  notify  will  override  the  one  of 
the  current  camera  sequence  (there  can  only  be  1  camera  sequence  playing  per  client  at  a 
time) until the end of the state, then it will return back to default config.  

 
 

 
 

6. Combat Module Setup 


 

6.1 General Setup 

Before starting to create your game characters you need to setup the Plugin to handle your 
game specific types. ACF works on generic data by extensively using gameplay tags, so 
basically you have to define your game-specific types by modifying ACF bases data tables like 
described in chapter 2
​ .2​ for Statistics, Parameters etc or creating new ones.  

Together with the plugin you’ll find a sample tag configuration, I strongly suggest to start with 
that one and than modifying them while you proceed with your game. In the 
AscentCombatFramework/Configuration folder you’ll find a set of Datatables that implements 
the GameplayTags that you can modify at your will to meet your Game’s Design. 

ActionsTag​: those gameplayTags are used to identify Characters Actions like Attacks, Dodge, 
Hit, etc.  

ItemTags​: Tags that define the different type of objects (weapons, armor, consumable, swords, 
etc.) defined hierarchically.  

ItemSlots Tag: ​The list of slots in which every item can be assigned when it is equipped.  

MovesetTags​: For any character you can define multiple movesets that are switched when they 
equip different weapons. For every weapon you can define the relative moveset. 

CommandTags: T
​ ag to identify Commands to give to your AIs and Companions. 

RPGTags​: explained in chapter 2. 

Enchantment Tag​: To enchant weapons, will come in the next update! 

 
 

In Project settings you have to tell the system what are the Root Tag used to identify your 
game specific types and what are the Default Tags: 

Basically with this we are telling to ACF which is the default Character State when no trigger 
is received (​Actions.Idle​), which is the default state to be triggered when a character gets hit 
(​Actions.Hit​) or when his R
​ PG.Statistics.Health​ reaches 0 (​Actions.Death​). 

6.2 Battle Types 

For  every  ​ACFEntity  ​(actors  that  implements  IACFEntityInterface)    ​you  have  to  select  his 
CombatTeam​:  Enemies  or  heroes,  defining  the  “side”  for  which  this  AI  is  fighting  for. 
CombatTeam  ​are  normally  assigned  by  Controllers,  both  ​ACFPlayerController  ​and 
ACFAIControllers  ​gives  the  developer  the  possibility  to  choose  the  team  for  which  the 
controlled AI is fighting for. Neutral AI are not involved in battles, useful for example for NPCs. 

In  ​ACFGamesState  ​you  can  set  the  ​BattleType​.  The  default  value  is  ​HeroesAgainstEnemies 
and  this  means  8as easily understable) that in this case ​Heroes ​are recognising ​Enemies ​AIs as 
enemies  and  vice  versa.  ​EveryoneOneAgainstEveryone ​should be selected for Deathmatch like 
game modes in which there are no team and everyone can be hit by everyone. 

Notice: ACF is built as a Listener-Server Multiplayer.  

 
 

7. Creating a Character: Base Blueprint 


 

7.1 Setting a New Character 

If  you  want  to  create  a  character  you  must  create  a  Blueprint  that  inherits  from 
ACFPlayerCharacterBP  or  ACFAICharacterBP  depending  if  you  want  to  create  a  player 
controlled  character  or  an  AI  Controlled  one. If you want to create a character that can be both 
controlled  by  a  player  or  an  AI  Controller  I  suggest to create an ACFPlayerCharacter since the 
additional  logic  it  has  is  minimal  and  all  the  extra  component  (Targeting  and  interaction)  will 
be  automatically  disabled  once  the  player  is  AIControlled,  so  there  will  be  no  additional 
overhead  on  performance.  In  the  blueprint  you  can  actually  set  your  Mesh  and  your 
ACFAnimInstance  (mandatory!)  that  will  be  largely  explained  in  the  next  chapter.  in  your 
Character you must configure:  

After that you have to configure your components, in particular: 

7.2 Locomotion Component 

Character Locomotion is handled inside the Locomotion Component. It should be configured to 
properly handle how your character and creatures move. 

 
 

bCanMove:  ​Indicates  if  this  character 


can Move. 

bCanAim  ​:  Indicates  if  this  character 


has Aim Offset Logic  

DefaultState  :  Indicates  the  default 


locomtionstate 

LocomotionStates: Indicates max speed 
for each locomtionstate 

bShouldStrafe​:  Indicates  if  this 


character follows control rotation and strafes.  

RotationRate  :  Indicates  the  actual  rotation  speed  of  the  character.  This  influences  tracking 
during attacks 

 
 

SprintDirectionCone: 
Indicates  the  max  angular 
distance  from  the  cone 
that  allows  your  character 
to sprint 

For  Mounts  /  Quadrupeds 


you  can  also  set the speed 
to be actually forced to the 
forward  vectr  and  set  the 
speed  in  which  this 
interpolation  is  done.  To 
better  explain  the 
SnapConfiguration we must go deep in ACF AnimationSystem.  

7.3 Damage Handler Component 

When Collision Manage detects an hit, the TakeDamage is called on the hit Receiver.  

To actually handle the damage calculation a specific DamageCalculator Class exists that has a 
virtual method: 

This is done to let you write your own calculation logics and provide to ACF the actual final 
damage Event with the actual ​FinalDamage ​field properly filled. A sample damage calculation 
class is provided with ACF but actually is highly reccomended to create your own 
DamageCalculator class and implement the CalculateFinalDamage method. 

To actually implement your damage calculation you have to create as child class of 
DamageCalculator and Implement the CalculateFinalDamage event. the inDamageEvent 

 
 

contains the actual damage info calculate by ACF. You can override those data with your own, 
in particular you must override the FinalDamage field, which is the one that will be subtracted 
to the hit receiver health.  

7.4 Effects Manager Component 

EffectManagerComponent is the one that is used to trigger particle and sounds on particular 
events like footsteps and hit event.  

7.4.1 Footsteps 

To configure Foosteps you have to actually add the A


​ CFFootstepNotify ​AnimNotify to the 
related animations, more info about this process: 
https://docs.unrealengine.com/en-US/Engine/Animation/Sequences/Notifies/index.html 

If you want to just use a single fx for every footstep you can customize the Default Footestep 
Fx field, otherwies check the C
​ heckForSurface ​box to setup different FX for each material 

 
 

surface. The component will dinamically trace and check the actual surface material everytime 
a footstep is triggered. Footstep will be automatically gathered from the ​FeetBoneNames m
​ ap. 

FootstepNoiseByLocomotionState ​identifies the amount of noise generated for each state, 


used for the AI perception system. Useful for stealth games.  

7.4.1 Damage Effects 

DefaultUnarmedSwingFX: ​identifies the effect that will be triggered when the character 
attacks without a weapon during the damage phase, in that case the weapon effect defined in 
the weapon will override this.  

 
 

DamageEffectsByHitReaction: I​ s a map of map. The upper level has the Action Response as as 
key and a map of DamageType/Effects as a value.  

ActionResponse are a subgroup of actions, largely discussed in the Animation System that are 
automatically triggered once an hit is received: es hit, parry, block, dodge etc. For each of that 
you can define a set of effects that depends on the damage types. In ACF a base set of 
DamageTypes are defined as subclasses of Unreal’s UDamageType. In particular they are: 
CutDamage, ImpactDamage, ProjectileDamage and SpellDamage.  

7.5 Interaction Component 

ACFInteractionComponent  ​is  the  one  responsible  of  interactable  with  the  world.  It  extends 
SphereCollision  Component  to  trace  for  interactables.  The channels to trace can be configured 
throught  the  component  itself.  To  let  an  object  to  be  interactable  it  should  implement  the 
interface  ​ACFInteractableInterface  ​and  provide  an  implementation  for  at  least  the 
CanBeImplemented  ​method,  which  returns  false  by  default.  To  actually  define  the  interaction 
you'll need to implement the OnInteractedByPawn method. 

7.6 Actions Manager Component 

This component implements all the logic related to the character’s state machine and ACF 
Actions. Those actions will be extensively explained in the next chapter.  

 
 

8. Animation System 
 

8.1 Overview 

The first thing is choosing if you want to use the actual ACFAnimInstanceBP or 
ACFAnimInstance. The first one contains complete ready to use logic for both actions and 
locomotion, the second one has only base structures but you have to implement your own 
animgraph and state machines. When you create  

8.2 ACF Actions System 

ACF  Action  System  is  the  Core  of  ACF  combat.  All  the  actions  are  handled  inside  the 
ActionsManagerComponent,  which  acts  like  a  kind  of  State  Machine  for the ACFCharacter. An 
Action,  as  the  name  itself  suggest,  is  an  animation  (an  AnimationMontage)  played  on  your 
character  that  is  bound  somehow  with  some  logic.  Is  an  highly  generic  concept  but  for  this 
reason  could  be  actually  used  to  do  whatever  you  want  while  keeping  an  high  level  of 
abstraction,  being  extremely  extendable  and  avoiding  having  tons  of  logic  on  your  character. 
Actions  are  also  modular  so  that  you  can  use  an  Action  logic  for  multiple  characters  avoiding 
code duplication and using composition and avoiding inheritance.  

8.3 Setup 

The first thing to do to is to Setup the gameplay tag referred to your actions. This can be done 
in Project Settings exactly as seen in the Chapter with ARS. once you have your Actions. In 
your Project Settings you’ll find a new tab dedicated to ACF. You have to tell to the system the 
base tag for basic actions that are automatically triggered by ACF like Idle (your default state), 
Hit (the state in which the character is send when an hit is received) and Death (the state in 
which the character is send when your Health (the Statistic identified with Health Tag) is <=0. 

Other Configurations will be expanded in next chapters. 

 
 

8.4 Actions 

Character Actions are triggered from the ActionsManager Component with the T
​ riggerAction 
function which takes as an Input both the Action Tag and the trigger priority.  

Actions ​are basically a set of character animations and logic. For each actions you can define an 
Animation  Montage,  an  ActionClass  with  a  set  of  implementable  virtual  methods  and  a  set of 
configurable properties.  

High  priority  triggers  will  interrupt  lower  priority actions while their are executed. Trigger with 


the  same  priority  will  NOT  interrupt  actual  action.  Triggers  with the Highest priority interrupts 
everything.  The  actions  your  character  can  execute  are  defined  in  the  ACFAnimInstance.  The 
reason  why  I  choose  to  put  Actions  in  the  AnimInstance  is  because  it  would  be  easier  to 
retarget  for  you  an  entire  animset  since,  when you retarget an AnimBlueprint in Unreal, all the 
referenced assets are automatically retargeted to the new skeleton.  

To create a new action you need to create a new class that inherits from ACFBaseAction. 

Actions have a set of methods that can be 


implemented. They are all commented largely in 
code and can be checked by passing your 
mouse cursor near the blueprint node of the 
implementable event. 

Setting up an action is actually pretty easy but 


can be confusing the first time so I’ll try to 
explain how it works with an example. In the 
image below there is a configuration for a dual 
wielded attack action with combos that can be 

 
 

triggered only when we are in SwordAndShield Moveset. 

The first 5 properties are from the A


​ CFAttackActionsBP ​which is a subclass of ​ACFBaseAction​.  

From ActionsConfig and belows there the properties that are common for all the actions.  

In  that  case  we  are  setting  that  the  ​Action.Attack  has  an  ​ActionCost  ​of  25  Stamina  points 
(​RPG.Statistics.Stamina​).  If  the  carachter  has  not  enough  stamina,  the  action  will  not  be 
triggered.  ​Requirements  ​are  used  to  check  if  the  Stat  of  the  character  are  actually higher than 
the  ones  provided  (useful  for  example  for  special  attacks  that  may require a certain amount of 
Strength).  

Modifiers  have  been  largely  discussed  in  chapter  2,  they  can  also  be  used  for  actions,  for 
example  for  heavy  attacks,  that  needs  to  be  performed  with  a  bonus  in  Strength  or  in 
MeleeDamage.  

PerformableiInAir​:  identifies  if  this  action  can  be  triggered  while  the  character  owner  is  not 
touching the ground.  

CanBeStored​:  if  set  to  true,  if  this  action  is  triggered  when  the  character  is  busy  doing  an 
higher  priority  action,  this  action  will  be  triggered  once  the  character  is  not  busy  anymore. 
Please notice that stored actions are not stacked, just the last one is played. 

CoolDown​:  when  performed,  this  action  si  actually  locked  and  cannot  be  performed  until  the 
cooldown is time is passed.  

PlayRandomMontageSection​:  if  this  montage  has  multiple  section  and  this  is  set  to  true,  a 
random section will be played.  

BindActionToAnimation​:  By  default  set  to  true,  once  the  animation  is  finished,  the  action  is 
automatialcally  exited  and  character  returns  in  Idle  action  as  set  in  the  DeveloperSettings.  If 
this  is  is  set  to  false  you  have  to  manually  trigger  ExitAction  from  the 
ActionsManagerComponent. 

 
 

 
 

MontageReproductionTypes w
​ ill be addressed in the next section.  

if  you  set  your  propriety  as  public  you  can  edit  them  in  the  editor.  Like  in  the  picture  above, 
AttackAction h
​ as a set of custom properties, in particular:  

SnapConfiguration​:  To  actually  snap  to  the  CurrentTarget  as  stated  in  the 
ATSBaseTargetingComponent ​from the controller.  

RotationRateMultipliers  ​to  actually  modify  character's  rotation  rate  during  various  attack 
phases,  in  particular  during  ​PreWinding  ​(before  damage  activation),  ​Winding  ​(during  damage 
activation),  and  ​PostWinding  ​(after  damage  activation).  Useful  to  create  timed  "vulnerability 
window" for your characters or enemies.  

DamageToActivate  identifies  which  CollisionComponent  should  be  activated  and  which  trace 
channel (by default a NAME_None string will activate all damage traces) 

8.5 Montage Reproduction Types 

In ACF there are 4 different montage reproduction types. They are triggerable from the 
LocomotionComponent with the S
​ etMontageReproductionType ​Method. 

 
 

The Default method is ​RootMotion​, which means that ActionMontages will be reproduced 
normally using RootMotion.  

OverrideSpeedWithCurve ​will overwrite RootMotion movent by applying a speed to the 


Character during the animation. The speed can be set by adding a speed curve to the animation 
or the animation montage. The name of the curve should be the same as set in the 
ACFAnimInstance in the property ​SpeedCurveName (​ the default name is "Speed"). 

OverrideSpeedAndDirectionWithCurve ​will do the same as O


​ verrideSpeedWithCurve ​but in 
addition you can specify the velocity direction (which by default is the actor forward vector) by 
calling the StartOverrideSpeedAndDirection method from the locomotion component. 

 
 

OverrideSpeedAndSnapsToTarget ​sillo do the same ​OverrideSpeedWithCurve b


​ ut will allow 
to multiply final speed by a coefficent (the SnapMultiplier) that depends from the distance to 
the current target as defined in the A
​ TSBaseTargetComponent ​from the controller. You can set 
the S
​ napConfiguration b
​ y calling ​StartSnapping ​from the L
​ ocomotionComponent​. 

Please note that only RootMotion currently supports replication. ACF curve-based systems are 
currently NOT replicated. 

In the snap configuration you can set the maximum SnapMultiplier allowed and the base 
distance (the one for witch the SnapMultiplier will be 1).  

8.6 Movesets & Overlays 

Movesets  are  group  of  locomotion  animations  and  actions.  In  The  ACFAnimInstance  you  can 
setup  multiple  Movesets.  You  can  switch  between  Movesets  by  calling  the 
SwitchMovementType ​from the ACFCharacters.  

In  ACF  multiple  movesets  per  character  are  used,  for  example,  when  changing  weapon.  You 
can  set  in the weapon his relative moveset and once the weapon is equipped the character will 
automatically switch to the related Moveset.  

This  is  used  to  implement  complex  animation  systems  in  which  every  weapon  has  is  own 
moveset  avoiding  enormous  graphs  replication  in  the  Animationblueprint.  In  addition  every 
moveset  can  have  their  own  specific  Actions  that  can  be  used  only  when  that  moveset  is 
active.  This  is  useful  to handle special moves that can ony be triggered with a specific weapon. 

 
 

Actions  that  can  be  triggered  independently  from  the  Moveset  are  set  in  the  ​CommonActions 
array. 

The ​MovesetSwitchTime ​is the amount of time necessary to blend between Movesets. 

Overlays a
​ re instead animation that are added on the top of the current moveset and blended 
with a tunable alpha. Sometime instead of using a new set of animation for a weapon, you 
would just add an overlay to an existing moveset. This is the case of overlays. Like Movesets, 
overlay are automatically added and removed once the character equips/unequips the weapon. 

 
 

9. Items and Equipment  


9.1 Items  

The base class to refer for Items is ACFItem, every Item has a set of native properties that can 
be used for UI:. Items are categorized by ItemType (Weapons, Armors, Consumable, Materials) 
and by the slot in which they can be equipped. The ItemSlot GameplayTag is used by a 
character to equip it in the appropriate slot. For every character you can create as many 
equipment slot as you want by just adding the relative gameplayTags in the Datatable Set in 
Configuration as already explained in chapter 2. To make a slot available for a character you 
have also to add it to the A
​ vailableItemsSlot​. For the blueprint functions look at the 
ACFDocuItem. 

 
 

9.2 World Item 

An ACFWorldItem has an array of items (Items) that are the ones that will be picked up by the 
character that will interact with it. The first item of Items is the one that will be used for the 
world mesh and the interaction info. 
A Player can interact with thiose Actors. An item can be looted, or it is created when an 
InventoryItem is dropped. Events are exposed in the blueprint to personalise the behaviour of 
the item when a player interacts with it. You can change the default WorldItem class to be 
used in drop functions in ProjectSettings -> AscentCombatFramework. 

9.2 EquipmentComponent 

Manages the character’s inventory. and equipment. You can see the blueprint functions inside 
the A
​ CFDocuCharacter​. In the blueprint settings you can define the Available Item Slots, which 
are the GameplayTag of the equippable ItemsSlot. Each Item has an ItemSlot, that is the slot it 
is automatically inserted if you want to equip it and it is defined in its ItemInfo. 

Drop items on death​ defines if this Character should drop all his Equipped Items when dead. 

Max Inventory Slot​ is the inventory maximum number of items. Instead the ​Max Inventory 
Weight​ is the maximum weight that the character can carry. When you try to add an item to 
the inventory, that Item won’t be equipped if one of the two parameters is surpassed. 

Starting Items​ are the items that are added to the character when it is spawned. They can be 
edited directly in this blueprint. You can choose the class, the number, if it is automatically 
equipped on spawn. You can choose a probability whether that item will be dropped when the 

 
 

owner will die.

9.3 Equippables and Consumables 

To  actually  use  an  item  is  necessary  that  it  is  in  the  character  Equipment.  Equipped  items  are 
stored  in  an  array  inside  the  property  Equipment  in  the  ACFEquipmentComponent, 
EquippedItems.  Each  item  is  assigned  to  his  Slot,  which  his  a  GameplayTag.This  means  that 
you can have as many slots as you want.  

Once  you  Use  or  Equip  an  item  from  the  ​Inventory  ​(with  ​UseInventoryItem  ​or 
EquipInventoryItem​)  it  is  automatically  assigned  to  the  appropriate  Slot  (the  one  provided  in 

 
 

the  ItemInfo  inside  the  Item)  in  the  equipment  if  it  is  Marked  as  an  available  Slot  for  that 
character.  For  each  Character  you  have  to  define  the  actual  available  slots  in  the 
EquipmentComponent  by  filling  the  ​AvailableItemsSlot  ​Array.  This  is  useful  to  create 
Characters  that  cannot  use  a  particular  type  of  items  (each  characters that can only use melee 
weapons and not ranged, etc.) 

Once  an  item  is  in  the  equipment  it  can  be  used  by  calling  ​UseItemBySlot​.  If  it's  a  weapon,  it 
will be moved from the O
​ nBodySocket ​to the E
​ quippedSocket​. 

If it's a consumable the O


​ nItemUsed ​will be called and a unit of item will be removed.  

9.4 Weapons and armors 

Weapons and armors are particular kind of Equippable.  

Both of them have a set AttributeSetModifiers that are applied to the owning character once 
they are equipped in their relative slot. Every armor needs a skeletal mesh that is rigged to the 
same skeleton of the owning character, once it is equipped 

it will autoamically follow all the animations of the owner. 

Once a weapon is the equipped, it will be spawned in the world and attached to his back 
socket. At this point his modifiers are NOT applied. If you sheath your weapon it will be moved 
from the OnBodySocket to the EquipSocket (the on Hand one) and only then his modifiers are 
applied.  

 
 

Armors instead needs to have the same skeleton of the CharacterOwner. So once they are 
spawned they are automatically set to follow the base mesh of the ​ACFCharacter a
​ s 
MasterPose. 

9.5 Crafting and Vendors 

ACF features a powerfull yet simple to use crafting system that allows to create new Items 
and upgrade current items. All the functions needed to enable it are in the ACF Crafting 
Component, that can be applied to wathever actor you want: an NPC, a bench, etc..  

To make it work you need to add to your player controller the ACFCurrencyComponent, which 
handles are the currency related stuff. Then under the category ACF you'll find all the required 
functions to create and upgrade items from the Equipment Component of the currentrly 
controlled character. 

 
 

10. AI Framework 
 

10.1 AIController 

Inside the pawn’s (or Character’s) blueprint you can set the actual class of it’s default controller 
to be spawned. To use ACF’s AI System you have to set it as a Subclass of ACFAIController.  

 
 

 
In  the  selected  controller  you  then  have  to  set  the  Behavioral  Three,  responsible  of  the 
realtime  decisions  of  the  controlled  AI.  In  ACF  there  are  two  differents  BehavoralThree  for 
combat  characters  and  NPCs.  For  every  AI  you’ll  also  have  to  set  the  CombatTeam  as 
described in chapter 6.2.  

AIController  also  exposes  the  ​TeleportHome  ​and  ​GoBackHome  ​functions  which  basically  are 
triggered once the controlled pawn goes over the set distance from Home.  

But what is “home”?  

 
 

Home  is  defined  only  for  AI  groups.  For  companions  (AI  that  have  a  lead,  usually  one  of  the 
Players)  home  location  is  actually  the  position  of  the  Lead  Actor  (the  Owning  Player).  For  Ai 
groups  spawned  by  an  ​AIGroupSpawner​,  the  location  of  the  group  will  be  the  actual  home 
location.  

BoundToHome  ​functionality  will  make  your  AI  come  back  to  the  home  position  once  it's 
distance  from  that  location  is  over  ​MaxDistancefromHome​.  Similarly  Teleport  Home  will 
teleport  your  AI in a random place in a ​TeleportHomeNearRadius ​from Home Location once it's 
distance overcomes ​TeleportHomeTriggerDistance​. 

10.1.1 AI States 

In ACF AIs can be in 3 different states: 

- Patrol​: If you add a USplineComponent in the AI Pawn or on the AIGroupSpawner, once 
the  AI  will  be  in  Pathrol  state,  it  will  use  that  spline  to  actual  define  is  Pathrol  path.  If 
the  spline  is  an open loop, once reached the end of the spline the Ai will start following 
the path backward. 
- Combat​: The AI is fighting against is actual target 
- GoHome​: The AI is actually trying to reach his Home Location 

For  each  state  you  can  set  the  desired  locomotion  state  that  the  character  should  maintain 
while staying in this state. 

10.1.1 AI Aggressivity 

If  ​IsAggressive  ​is  set  to  true  the  possessed  AI  will  attack  everytime  an  enemy  entity  is 
detected.  If  only  ​ShouldReactOnHit  ​is  selected,  the  AI  will  only  "return  to  fire"  once  he,  or  a 
member of his group, gots hit.  

10.2 AICombat Behavior 

 
 

Combat  behavior  Component is the component that manages how his controlled AI behaves in 


Combat.  There  are  2  different  combat  behavior  types:  melee  and  ranged.  Every  AI  can  be 
melee, ranged or both, switching behavior considering the actual situation. 

AI  can  fight  Unarmed  or  with  a  weapon,  if  your  AI  needs  one  or  more  weapon  to  fight,  you 
have  to  check  the  NeedsWeaponTag  and  you  have  to provide to the component the actions to 
trigger  to  actually  equip  the  desired  weapon.  Please  notice  that  those  action  needs  to  be 
implemented  in  AnimBP  as  described  in  Chapter  of  Anims.  During  combat  AIs  can  switch 
between multiple states, in particular:  

-  ​Melee  Attacks:  AI  will  perform  a  Set  of  attacks  actions  for  a  total  number  of  triggers that is 
between  ​MinMeleeComboAttacks  ​and  ​MaxMeleeComboAttacks​,  then  will  try  to  go  to  post 
attack.  This  is  supposed  to  be  triggered  once  the  AI  is  in  Melee  Range  (below  a  certain 
distance) 

-  Melee  PostAttacks​:  AI  will  perform  a  set  of  configurable  actions,  a  different  set  from Melee 
Attacks, useful 

to add variations in combat. In example this is used for ai to permorm a TauntAction.  

-  Study  Target:  AI  will  move  around  target  inside  a  circle  of  the  distance  define  in 
CombatState Config.  

-  Ranged  Attacks:  AI  will  perform a series of action that tryes to hit the target while keeping a 


distanceas  defined  int  the  CombatStates  Config  map.  Usefull  for  bow  shots/crossbow/speels 
projectiles etc.  

-F
​ lee​: state in which the AI tries to increase the distance from his target.  

CombatStateConfig  ​is  actually  the  map  that  describes  the  CombatStates  this  AI  can  go 
throught,  the  ideal  distance  in  which  each  state  is  triggered  and  chance  express  in  a  0-100 
range.  

 
 

10.3 Threat Manager 

Threat  Manager  component  is  used  to  setup  the  threat  management  of  the  Possessed  AI. For 
every  class  you  can  define  the  default  threat  generated  on perception (on sight, on heard) and 

 
 

the  multiplier  applied  to  the  damage  to  calculate  the  threat generated by all the actors of that 
subclass.  

10.4 Groups & Companions 

To  work  with  AI  groups  you  have  to  refer  with  ​ACFGroupComponent​.  In  the  component  you 
can  setup  the  array  of  AIs  that  will  be  spawnedtand  their  relative  position  from the Group. To 
actually  spawn  those  AI  you'll  need  to  call  SpawnGroup  that  can  be  called  multiple  times 
untlil MaxSimultaneousAgents is reached. 

ACFAIGroupSpawners  ​are  pawns  that  owns  an ​ACFGroupSpawnerComponent ​instance. They 


can  be  placed  in  the  world  and  can  be  used  to  define  Patrol  path  of  the  AI  group  and  to 
eventually  override  agents  Perception.  If  ​OverrideAgentPerception  ​is  set  to  true,  all  the 
perception  of  single  AIs  will  be  disabled  and  a  single  perception  for  the  entire  group  will  be 
used  (higher  performance,  worst  AI  behavior  accuracy).  The  ​AIGroupSpawner  ​of  the  group 
position  will  be  considered  the  Home  of the agents and AI of the same group helps each other 
in battle.  

ACFCompanionsComponent  ​is  a  specification  of  ​ACFGroupComponent  ​to  handle  AIs  that  are 
in  the  same group of the player. Player will be considered their lead and player position will be 
considered their home. All AI agents can receive and execute commands.  

10.5 AI Commands 

 
 

Ai  Commands  are  a  basic  command  pattern  implementation  to  let  AI  implement  custom 
actions. In depth tutorial: h
​ ttps://www.youtube.com/watch?v=xEr1nRDLB8c 

11. Mount system 


*Currently NOT Replicated, Replication is targeted for 1.1* 

11.1 Setup 

 
 

To  use  ACF  Mount  System  you  have  to  add  the  ACFMountComponent  to  your  mountable 
character  and  ACFRiderComponent  to  your  actual  rider  character.  In  the  Mount  you  should 
actually  add  also  an  ACFAnimationManagerComponent  together  with  at  least  an 
ACFAnimationPoint that will be used as a Dismount Point Target. 

In  the  ACFMountComponent  you'll  have  to set the name of the Socket to be used to attach the 


rider to the mount 

and  the name of the Dismount Point (an ACFAnimationPoint inside the same actor) that will be 
used  to  detach  the  rider.  If  the  mount  is  possessed  once  mounted  (this  can  be  set  inside 
ACFRiderComponent),  you  can  set  a  list  of  actions  to  be  retriggered  from  the  mount  the  rider 
(check chapter 8 for Actions), usefull to setup a mounted combat.  

If the mount is set as a Companion it will follow the player once it is not mounted.  

To  Actually  start  mounting  you  have  to  call  StartMount  in  the  ACFRiderComponent  with  the 
reference of the character to be mounted.  

Please  notice  that  Mount  System  can  also  be  used  for  vehicles  and  any  kind  of  mounts 
(dragons, horses, beasts etc.). 

12. Combined Animations System & Executions 

 
 

*NOT Replicated* 

12.1 CAS Setup 

Combined  Animations  System  is  an  ACF  module  that  allows  2  characters  (a  master  and  a 
Slave)  to  perform  a  simultaneous  action  and  play  a  sinchronized  animation.  One  of  the  2  will 
be  considered  the  "Master",  the  one  who  starts  the  animation  (usually  the  player  character), 
the other one should be considered "the slave", the one that responds to the animation Master.  

12.2 SnapperComponent 

Snapper component must be used on Animation mastr and has the responsability to magnetic 
move the animMaster to the slave once the animation starts. Can also be used to snap your 
player to specific point at your needs calling the provided Snap Functions. 

12.3 Anim Master Setup 

 
 

Animation  Master  is  the  character  driving  the  combined  animations,  it  must  have  a  snapper 
component  and  one  between  ​CASAnimMasterComponen​.  Master  Anim  Configs  is  the  actual 
DB  of  the  Combined  Animations  this  actor  can  perform.  They  can  be  triggered  calling 
TryPlayCombinedAnimation​: 

Every  combined  anim can be configued as in the image: You can set the max distance for which 


this  anim  can  be  triggered  together  with  the  Slave  Required  Direction.  If  both  conditions  are 
satisfied  (distance  between  the  two  character  is  below  the  MaxDistanceToStartSnapping  and 
SlaveRequiredDirection  ​for  relative  direction)  the  AnimMaster  will  start snapping throught the 

 
 

Slave  and  once  his  distasnce  is  below  MaxDistanceToStartCombinedAnimation, the combined 


animation  will  start  and  the  Slave  will  be rotate according to match ​SlaveForcedDirection​. The 
montage that will be played on the master is of course MasterAnimMontage.  

ACFExecutorComponent  ​is  a  child  class  of  CASAnimMaster  that  handles  execution,  a 


particular  set  of  combined  animations  that  kills  the  slave  at  the  end  of  the  anims  and triggers 
simultaneously  a  Camera  Sequence  (check  Chapter  5).  To  Execute  a  character  you  need 
instead to have an A
​ CFExecutorComponent I​ NSTEAD of the ​CASMasterAnimComponent​. 

*Executor Component is only present in ACF, not in Combined Animation System* 

To Execute a character you need instead to have an A


​ CFExecutorComponent I​ NSTEAD of the 
CASMasterAnimComponent​. Executions can be triggered with the provided methods. 
ExecutionComp tries to automatically find the best anim for the current situation considering 
relative distances, positions of the target and currently equipped weapon of the AnimMaster. 
To let the component decide which animation to play, you'll need to fill the 
ExecutionsByDirectionsAndWeapon t​ able 

 
 

In the provided sample, the combined anim called "Longs1" can only be triggered once the 
Master is "behind" the slave and he (the Master) is equipping a Weapon of the type 
Item.Weapon.Melee.Longsword 

12.4 Slave Setup 

Every  character  that  can  be  involved  must  have  a  CASAnimSlaveComponent  properly 
configured  with  a  datatable  of  FCombinedAnimsSlave.  This  DT  only  needs  to  be  configured 
with  the  Montage  that  must  be  triggered  and  the  name  of  the  relative  Master's  entry  in 
Master's  DT.  In  addition  you  can  define  a  set  of  custom  condition  that  needs  to  be satisfied to 
involve this character in any Combined Animation. 

 
 

13. LevelStreaming 

 
 

13.1 Setup 

ACF  Level  streamig  is  a level streaming wrapper that allows you to load and unload a level by 


checking  player  distance  at  a  fixed  interval  rate.  It allows also to substitute the unloaded level 
with a static mesh that fakes 

the  level  appearence  from  the  distance.  You  just  have  to  setup  your  ACFLevelStreamerActor 
with  the  name  of  the  Level  to  Load/Unload,  the  load  sitance  from  the  player  and  the  time 
interval to check so.  

To  make  this  work  you  have  to  setup  your  level  to  be  inside  a  Persistent  Level  and  tohi 
Streaming  Method  must  be  set  to  Blueprint.  More  info  on  level  streaming: 
https://docs.unrealengine.com/en-US/Engine/Levels/LevelsWindow/index.html 

14. CHANGELOG:  

 
 

14.1 Changelog from 1.0 TO 1.2: 

NEW FEATURE: 

Full Aim Offset Replciation 

Added Multi team support (thank @Fred ) 

Added Magic & spell System with healing, projectile & summon 

Added Music manager 

EXPERIMENTAL Full dedicated Server support 

Added Linux Support (Thanks @Beazy) 

REFACTORS:  

Damage dealing flows moved to the CollisionComp/Damage Handler completely 

IMPROVEMENTS: 

Optimize FX replication  

Moved names to FTEXT 

Various mount interface improvements 

Various Networking improvemnts 

 
 

Added getter foractions cooldown (thanks @Mighteemouse ) 

BUGFIX: 

Fixed Armor replication bug 

Fixed Crafting on spawning items issue (thanks @xermao) 

Fixed wrong iSEquipped boolean in Equipment 

Check CAS distance if it's below minDistance in executions 

SAMPLE PROJECT: 

New TPS Sample (Thanks @OneSilverLeaf™ ) 

New Mount Sample 

New Mage system with summons 

New Multi Team Sample 

New Execution Sample 

You might also like