2.1.2 • Published 1 year ago
thoron v2.1.2
Thoron
FE simulator library.
Usage
Configuration object
See the default config for an example.
{
unit: {
strMagSplit,
inventory: {
maxItems
}
},
combat: {
calcs: {
hit,
avd,
crit,
cev
},
useHit,
useCrit,
roll2RN,
doubleThreshold
},
items: {
limitedUses: true
}
}unit
strMagSplitboolean If true, units have Strength or Magic stats. If false, units have the Attack statinventorymaxItemsinteger Maximum number of items in a unit's inventory
combat
calcsThese objects represent the formulae used to obtain a unit's combat stats (such as hit rate, crit rate) from its base stats (such as skl, luk). The calc output will be the sum of the stats named in the keys (or 'constant') multiplied by the coefficients in the values- Examples:
{spd: 2, luk: 0.5}= 2 speed + 0.5 luck{skl: 0.5, constant: 5}= 0.5 * skill + 5
hitObject HitavdObject AvoidcritObject CritcevaObject Crit evasion
- Examples:
useHitboolean If false, attacks will never missuseCritboolean If false, attacks will never critroll2RNboolean If true, accuracy rolls will take the average of two randomly-generated numbers instead of onedoubleThresholdinteger The amount of speed difference required for a unit to carry out a follow-up attack in combat
items
limitedUsesboolean If true, items will break when they run out of uses
Development
If using Visual Studio Code, install the Yarn SDK for PnP+TypeScript to work in the editor
yarn dlx @yarnpkg/sdks vscode
NPM Scripts
yarn buildCompile project. Optionally add--sourcemap --watchflags while testing (see tsc CLI Options).yarn testRun test suite.
2.1.2
1 year ago
2.0.3
1 year ago
2.1.1
1 year ago
2.0.2
1 year ago
2.0.5
1 year ago
2.0.4
1 year ago
2.0.7
1 year ago
2.0.6
1 year ago
2.0.8
1 year ago
2.1.0
1 year ago
2.0.1
2 years ago
2.0.0
2 years ago
1.1.4
2 years ago
1.1.1
2 years ago
1.1.0
2 years ago
1.0.6
2 years ago
1.0.5
2 years ago
1.1.3
2 years ago
1.0.4
2 years ago
1.1.2
2 years ago
1.0.3
2 years ago
1.0.2
3 years ago
1.0.1
3 years ago
1.0.0
3 years ago