Our first battle used a single combatant – creating Combatant Groups will help us save time when fighting multiple combatants.

A combatant group is a predefined group of combatants that can be used in battles and by Combatant Spawners. This way you don’t have to put together combatants for each battle – simply create a group that will occur in multiple battles, and change it when needed to affect all battles. Combatant groups can also hold additional victory gains.

Creating groups

We’ll create eight combatant groups – different mixtures of our three bad guys. Open the ORK Framework editor and navigate to Combatants > Combatant Groups. Change the following settings.

Combatant Group 0: Fighter, Caster

  • Name
    Set to Figher, Caster.
    The name is only used in selection lists.
    It’s a good idea to reflect the members of the group in the name, since you most likely have a lot of combatant groups in a bigger game.

Combatants

There is already a combatant added to the list. The first combatant is always the leader of the group. You can also change the start base/class level of the combatant – e.g. depending on the player’s level. Since our combatants are only set up for a single level (without status development), we don’t need to use this feature.

Change this setting.

  • Combatant 0
    Select Evil Pants.

Click on Add Combatant to add another combatant.

  • Combatant 1
    Select Evil Caster.

That’s it for this combatant group.

Combatant Group 1: Fighter, Supporter

Let’s make this easy – copy the first combatant group Fighter, Caster and change the following settings.

  • Name
    Set to Fighter, Supporter.

Combatants

Change Combatant 1.

  • Combatant 1
    Select Evil Supporter.

That’s it for this combatant group.

Combatant Group 2: Fighter, Caster, Supporter

Again, copy Fighter, Caster and change the following settings.

  • Name
    Set to Fighter, Caster, Supporter.

Combatants

Add a third combatant by clicking on Add Combatant.

  • Combatant 2
    Select Evil Supporter.

Combatant Group 3: 2xFighter

Copy Fighter, Caster and change the following settings.

  • Name
    Set to 2xFighter.

Combatants

Change Combatant 1.

  • Combatant 1
    Select Evil Pants.

That’s it for this combatant group.

Combatant Group 4: 2xFighter, Caster

This time we copy 2xFighter and change the following settings.

  • Name
    Set to 2xFighter, Caster.

Combatants

Add a third combatant by clicking on Add Combatant.

  • Combatant 2
    Select Evil Caster.

Combatant Group 5: 2xFighter, Supporter

Copy 2xFighter, Caster and change the following settings.

  • Name
    Set to 2xFighter, Supporter.

Combatants

Change Combatant 2.

  • Combatant 2
    Select Evil Supporter.

Combatant Group 6: Caster, Supporter

This time we create a new combatant group.

  • Name
    Set to Caster, Supporter.

Combatants

Change Combatant 0.

  • Combatant 0
    Select Evil Caster.

Click on Add Combatant to add another combatant.

  • Combatant 1
    Select Evil Supporter.

That’s it for this combatant group.

Combatant Group 7: 2xCaster, Supporter

Copy Caster, Supporter and change the following setttings.

  • Name
    Set to 2xCaster, Supporter.

Combatants

Add a third combatant by clicking on Add Combatant.

  • Combatant 2
    Select Evil Caster.

That’s it for the combatant groups.

Turn based battles

We’ve already set up the turn based battle settings when we created our first battle. Let’s make some small changes before setting up another battle!

Navigate to Battle System > Turn Based Battles and change the following settings.

Turn Based Settings

Let’s make the turn based battles feel slightly more action-packed by using the Active battle mode. This will let combatants use their actions right after they chose them – the next combatant will get his turn when the previous action ended. In currently used Classic battle mode all actions are chosen first and performed in sequence after the last combatant chose his action.

  • Battle Mode
    Select Active.

Bonus Settings

To make things easier, we can give bonuses to Consumable status values at the start and end of the battle, or on every turn. Let’s heal the combatants at the end of the battle!

Click on Add Status Value Bonus.

  • Status Value
    Select HP.
  • Operator
    Select Add.
  • Value
    Set to 100.
  • Set In
    Select Percent.
  • Show Notification
    Disable this setting.
    We don’t want to display the refresh notification.

That’s it for the turn based settings – click on Save Settings and close the ORK Framework editor.

The 2nd battle

It’s time to add another battle to our game – this time we’ll use our battle groups. Open the field scene (2 Field, can be found in Assets/Tutorial Resources/Scenes/).

Use the ORK Scene Wizard to create a new battle: Create Object > Battle > Turn Based Battle

Place the new battle somewhere on the road near the trees (just ahead of the first battle).

gametutorial_28_combatant_groups1

The new battle will automatically receive Scene ID 1, since we already have scene ID 0 on our first battle.

Change the following settings in the Battle Component’s inspector.

Start Settings

The settings should already be correct, check them.

  • Scene ID
    Set to 1.
  • Battle Type
    Select Turn Based.
  • Can Escape
    Enable this setting.
  • Look At Enemies
    Enable this setting.
  • Star Type
    Select Trigger Enter.
  • Front, Back, Left, Right
    Enable this settings.

Combatants Settings

Now it’s getting interesting – we’re adding multiple combatant groups, which one we fight will be chosen randomly.

You’re free to select whatever combatant groups you like, just make sure that you set:

  • Faction
    Select Enemies.

If the faction of a combatant or battle group isn’t an enemy of the player (i.e. sympathy below 0), there wont be a battle. Allies don’t fight each other.

My suggestion for the battle groups – since this is only our 2nd battle, let’s stick with the smaller groups consisting of two members:

  • Fighter, Caster
  • Fighter, Supporter
  • 2xFighter
  • Caster, Supporter

Tip: If you want one of the combatant groups to be selected more often, just add it multiple times to the battle!

That’s it, save the scene.

Testing

It’s time to test again – remember that there is still the first battle in our way, so we either have to fight (and win) it, or you can deactivate it for now by deactivating the game object in the inspector.

Open the main menu scene (0 Main Menu) and hit Play. Walk outside of town and into the 2nd battle (after finishing the first, if still active).

gametutorial_28_combatant_groups2

It’s getting harder to win against those guys …

And that’s it for now – the next lesson will cover active time battles.