import * as CHARACTER from "./character.mjs"
import * as WEAPON from "./weapon.mjs"
import * as ARMOR from "./armor.mjs"
import * as SPELL from "./spell.mjs"
import * as SKILL from "./skill.mjs"
import * as EQUIPMENT from "./equipment.mjs"
import * as CHARACTERISTICS from "./characteristic-tables.mjs"

export const SYSTEM_ID = "fvtt-lethal-fantasy"
export const DEV_MODE = false

export const ROLL_TYPE = Object.freeze({
  SAVE: "save",
  RESOURCE: "resource",
  DAMAGE: "damage",
  ATTACK: "attack",
})

export const MONEY = {
  tinbit: {
    id: "tinbit",
    abbrev: "tb",
    label: "LETHALFANTASY.Money.Tinbits",
    valuetb: 1
  },
  copper: {
    id: "copper",
    abbrev: "cp",
    label: "LETHALFANTASY.Money.Coppers",
    valuetb: 10
  },
  silver: {
    id: "silver",
    abbrev: "sp",
    label: "LETHALFANTASY.Money.Silvers",
    valuetb: 100
  },
  gold: {
    id: "gold",
    abbrev: "gp",
    label: "LETHALFANTASY.Money.Golds",
    valuetb: 1000
  },
  platinum: {
    id: "platinum",
    abbrev: "pp",
    label: "LETHALFANTASY.Money.Platinums",
    valuetb: 10000
  }
}

export const DICE_VALUES = {
  "d3": "D3",  
  "d4": "D4",
  "d6": "D6",
  "d8": "D8",
  "d10": "D10",
  "d12": "D12",
  "d20": "D20"
}

export const DEFENSE_DICE_VALUES = {
  "d3": "D3",  
  "d4": "D4",
  "d6": "D6",
  "d8": "D8",
  "d10": "D10"
}

export const ASCII = `
······················································································································
:                                                                                                                    :
:@@@      @@@@@@@@ @@@@@@@ @@@  @@@  @@@@@@  @@@         @@@@@@@@  @@@@@@  @@@  @@@ @@@@@@@  @@@@@@   @@@@@@ @@@ @@@ :
:@@!      @@!        @!!   @@!  @@@ @@!  @@@ @@!         @@!      @@!  @@@ @@!@!@@@   @!!   @@!  @@@ !@@     @@! !@@ :
:@!!      @!!!:!     @!!   @!@!@!@! @!@!@!@! @!!         @!!!:!   @!@!@!@! @!@@!!@!   @!!   @!@!@!@!  !@@!!   !@!@!  :
:!!:      !!:        !!:   !!:  !!! !!:  !!! !!:         !!:      !!:  !!! !!:  !!!   !!:   !!:  !!!     !:!   !!:   :
:: ::.: : : :: ::     :     :   : :  :   : : : ::.: :     :        :   : : ::    :     :     :   : : ::.: :    .:    :
:                                                                                                                    :
······················································································································
`

/**
 * Include all constant definitions within the SYSTEM global export
 * @type {Object}
 */
export const SYSTEM = {
  id: SYSTEM_ID,
  CHARACTERISTICS: CHARACTER.CHARACTERISTICS,
  CHARACTERISTICS_TABLES: CHARACTERISTICS.TABLES,
  CHARACTERISTICS_MAJOR: CHARACTERISTICS.MAJOR, 
  SAVES: CHARACTER.SAVES,
  CHALLENGES: CHARACTER.CHALLENGES,
  SKILL_CATEGORY: SKILL.CATEGORY,
  ARMOR_TYPE: ARMOR.TYPE,
  EQUIPMENT_CATEGORY: EQUIPMENT.CATEGORY,
  SPELL_RANGE: SPELL.RANGE,
  WEAPON_TYPE: WEAPON.WEAPON_TYPE,
  WEAPON_CLASS: WEAPON.WEAPON_CLASS,
  COMBAT_PROGRESSION_DICE: DICE_VALUES,
  SHIELD_DEFENSE_DICE: DEFENSE_DICE_VALUES,
  MONEY,
  ASCII,
  ROLL_TYPE,
  DEV_MODE,
}
