Skip to content

INQWeaponParser.js

kyleady edited this page Jan 24, 2017 · 2 revisions

Purpose

The INQWeaponParser was made primarily to parse the notes/gmnotes of a Roll20 handout. However, it also gathers other details of the weapon within the INQObject.js details.

Usage

It is suggested that you do not use this prototype directly. Instead, let new INQWeapon() make use of it.

Once the the notes/gmnotes are parsedby the INQParser.js, the content will be organized as follows

  • Lists will be ignored.

  • Tables will be ignored.

  • Rules will be searched for the following values:

    • Class: It recognizes Thrown, Melee, Pistol, Basic, Heavy, Psychic.

    • Range: Numerical value that can be multiplied by Strength Bonus or Psychic Rating.

    • RoF: Of the form S/#/#. Any value can be replaced with a -. Numbers can be multiplied by Psychic Rating.

    • Damage: Of the form # x #D#+# <DamageType>. Only the dice type is required. Will be used to determine the following:

      • DiceMultiplier
      • DiceNumber
      • DiceType
      • DamageBase
      • DamageType - recorded as an INQLink
    • Penetration: Numerical value that can be multiplied by Psychic Rating.

    • Clip: Numerical value.

    • Reload: Recorded as the number of Full Actions. The following forms are accepted

      • Free
      • Half
      • Full
      • Full

    • Special Rules: Saves the list as an array of INQLinks unless it is simply a -.

    • Weight: Numerical value.

    • Requisition: Numerical value.

    • Renown: Accepts -, Initiate, Respected, Distinguished, Famed, or Hero.

    • Availability: Accepts Ubiquitous, Abundant, Plentiful, Common, Average, Scarce, Rare, Very Rare, Extremely Rare, Near Unique, or Unique.

    • Focus Power: Of the form [Opposed] <difficulty> (<Modifier>) (<Characteristic or Skill>) Test. The difficulty is not saved. The currently accepted Characteristics and Skills are:

      • Weapon Skill
      • Ballistic Skill
      • Strength
      • Toughness
      • Agility
      • Intelligence
      • Perception
      • Willpower
      • Fellowship
      • Corruption
      • Psyniscience
    • Opposed: Accepts Yes or No

  • Misc content will be ignored.

If a Rule was found that did not fit the expected form, the details of the Rule will not be saved and the GM will be warned.

By default, a Weapon's Class if Melee.

If the weapon has no damage dice to roll and the weapon Class is not Psychic, its Class will be changed to Gear.

Requirements

Clone this wiki locally