Combat system

This is the documentation of the design of the combat system (COM).

There are 3 main areas of COM: offense (OFN), defense (DFN), and stealth (STE).

Offense (OFN)

In offense, player is attacking enemy. These are the aspects to consider.

Player accuracy (acc): this is a skill that improves with alongside experience (xp), and is how often the player can hit the enemy.

Player experience (xp): this value is increased incrementally when a robot is destroyed/disabled. It also is increased when mission goals are accomplished. In combat, xp adjusts the damage done to the enemy. This is likened to having more knowledge of where effectively to hit the enemy, and thus have more efficacious effect.

Wep accuracy (wepacc): the inherent accuracy of the weapon at a given effective range.

Wep damage (wepdmg): the inherent damage of the weapon at a given effective range.

Wep effective range (weprange): the effective/nominal range of a weapon.

Wep maximum range (weprange_max): the farthest range a wep is allowed to have any effect.

Attacking range (attackrange): the range between the player and the enemy being attacked at the time of firing.

Pose (pose): a positive adjustment made when the player is in crouched pose.

Defense (DFN)

In defense, it is both the ability of the player to avoid being hit and how much damage is absorbed if hit. These are the aspects to consider.

Player agility (agile): innate ability of character to be nimble forms the basis of enemy’s chance-to-hit (ecth).

Player toughness (tough): more toughness means less damage done when hit by enemy (edmg).

Player pose (pose): if crouched, ecth is reduced.

Armour rating (ar): the higher the armour rating, the less edmg is incurred when hit.

Attacking cover angle (coverangle): this is the correspondence between the current cover that the player is in and the angle of the enemy attacking the player.

Cover height (coverheight): this is the relationship between the current cover’s height and the pose that the player is in. If the cover height is full, then the cover’s effect will be full. if the cover height is half, then the player must be in crouched pose for the cover to have any effect.

Attacking range (attackrange): adjusts the ecth.

Enemy wep accuracy (ewepacc): accuracy of the enemy; adjusts ecth.

Enemy wep damage (ewepdmg): the enemy’s weapon damage; adjusts edmg.

Enemy wep effective range (eweprange): the effective range of the enemy’s weapon; adjusts ecth and edmg

Enemy wep maximum range (eweprange_max): max range of the enemy’s weapon. Adjusts the overall effect of the weapon in relation to the effective range.

Enemy attack skill (eattackskill): adjusts the ecth.

Stealth (STE)

Stealth is ability of the player not to be seen at all, and thus not to be perceived as a threat or a trespasser.

These are the aspects considered.

Player agility (agile)

Player pose (pose)

Player experience (xp)

Stealth devices: stealth devices may come in different forms to aid in the overall stealth rating.

Stealth clothing: the ninja suit is made for nighttime stealth only. The Inviz suit is for any-time stealth. O

Drawn and hidden

A weapon’s drawstate can be:

  • Hidden
  • Drawn

When drawn, the following happens

  • Player is seen as a threat by robots
  • Player can fire weapon immediately

When hidden, the following happens

  • Player is not seen as threat by robots
  • Player cannot fire weapon

Drawing a weapon takes time (wepdrawtime). Generally, the bigger the weapon, the more times it takes to draw and get ready to fire.

Reloading

A weapon needs to be reloaded after its magazine/charge has been depleted. This reloading takes place automatically if the weapon has discharged the last round.

The player can do a ‘tactical reload’ (reloading before charge runs out) by manually pressing a reload key.

A reload is time-consuming process. This is the energy being brought forward to the weapon. The reload is a fixed time depending on the weapon.

Cover

Cover system increases/decreases enemy chance-to-hit ratings (ecth).

Full vs half height cover (fullcover/halfcover). Each tile edge might have a cover, which can be fullcover or halfcover. fullcover has more protection regardless of stance. halfcover is fully effective if player is crouched. Else, halfcover is half effective.

Cover system computes the enemy’s angle of attack (eaoa) against the edge that covers the player. The narrower the angle is, the less cover. While this is computed using tiles, the physical pos of the logical pos is used as the markers.

Robot

The robot is the mobile enemy that is primarily in the combat system. The following are its parameters

  • speed
  • accuracy
  • armour rating
  • agility
  • hp
  • fov (LOS)
  • weprange
  • wepdmg
  • class: light, medium, heavy
  • ai: attack, scout
AI

Robots can be scripted on a per-level basis. However, it has 3 basic AI configurations: attack, scout, and guard

Attack AI will roam looking for player, and attacking if found:

detected = search_while_scan()
if detected == True:
  in_range = check_range(player)
  if in_range == True:
    attack(player)
  else:
    approach(player)

Scout AI will roam looking for player and keep within LOS as much as possible:

detected = search_while_scan()
if detected == True:
  track(player)
if lost_detection(player) == True:
  go_to_last_known_position(player)
  detected = search_while_scan()

Guard AI will not move from position but will attack player if found:

detected = static_scan()
if detected == True:
  attack(player)
else:
  detected = static_scan()
Class

Robot class refers to the preset of the robot. The class of the robot is only important in classifying a fixed characteristic/parameters of a robot. So when specified in Tiled as ‘light’, a predefined set of parameters for the robot is looked up.

Here are some ideas of the class variations.

  • Light scout (fast, no weapons, low hp, scout AI, agile)
  • Light attacker (fast, light weapons, low hp, attack AI, agile)
  • Sniper (slow, high accuracy, long range, low hp, narrow fov, guard AI, repos only using level script)
  • Assault (slow, medium accuracy, short range, high hp, wide fov)
  • Guard (fast, guard AI, high hp, wide fov)

 

Advertisements
%d bloggers like this: