Options
All
  • Public
  • Public/Protected
  • All
Menu

Class to simplify character creation basing on current engine configuration

Hierarchy

  • CharacterCreator

Index

Constructors

constructor

Properties

Private engineConfig

engineConfig: IEngineConfig

Private minDamageModifier

minDamageModifier: number = 0.9

Methods

createCharacter

  • Creates engine character entity basing on given template.

    If overrideCharacter is not specified, the created character will:

    • have generated id
    • have one action defined
    • be AI controlled - the first action will be chosen as round action

    Parameters

    Returns ICharacter

    character compatible with engine

getArmor

getAttackAction

getMaxDamage

getMaxHp

  • getMaxHp(stats: IStats): number
  • Computes character maximum hp

    Parameters

    • stats: IStats

      stats used to compute HP for

    Returns number

    maximum allowed character hit points

getStats

Object literals

Private characterTypeModifiers

characterTypeModifiers: object

__computed

__computed: object

dexterity

dexterity: number = 0.25

power

power: number = 0.25

stamina

stamina: number = 0.5

Private subtypeModifiers

subtypeModifiers: object

bad

bad: number = 0.8

good

good: number = 1.2

normal

normal: number = 1

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Type alias with type parameter
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method

Generated using TypeDoc