forked from GitHub-Mirrors/foundry-sw5e
Merge branch 'master' of https://github.com/unrealkakeman89/sw5e
This commit is contained in:
commit
b40f5f62f8
5 changed files with 520 additions and 509 deletions
28
README.md
28
README.md
|
@ -1,9 +1,27 @@
|
||||||
# sw5e
|
# Foundry Virtual Tabletop - SW5e Game System
|
||||||
SW5E Foundry VTT System
|
|
||||||
|
|
||||||
For easy install
|
This game system for [Foundry Virtual Tabletop](http://foundryvtt.com) provides character sheet and game system
|
||||||
|
support for the SW5E roleplaying game.
|
||||||
|
|
||||||
In the Foundry Configuration and Setup window go to the Game Systems tab, click on the "Install System" button, and
|
This system provides character sheet support for Actors and Items, mechanical support for dice and rules necessary to
|
||||||
place the following link into the Manifest URL at the bottom
|
play games of SW5E, and compendium content for Monsters, Heroes, Items, Powers, Class Features, Monster
|
||||||
|
Features, and more!
|
||||||
|
|
||||||
|
The software component of this system is distributed under the GNUv3 license.
|
||||||
|
|
||||||
|
## Installation Instructions
|
||||||
|
|
||||||
|
To install and use the SW5e system for Foundry Virtual Tabletop, simply paste the following URL into the
|
||||||
|
**Install System** dialog on the Setup menu of the application.
|
||||||
|
|
||||||
https://raw.githubusercontent.com/unrealkakeman89/sw5e/master/system.json
|
https://raw.githubusercontent.com/unrealkakeman89/sw5e/master/system.json
|
||||||
|
|
||||||
|
If you wish to manually install the system, you must clone or extract it into the ``Data/systems/sw5e`` folder. You
|
||||||
|
may do this by cloning the repository or downloading a zip archive from the
|
||||||
|
[Releases Page](https://github.com/unrealkakeman89/sw5e).
|
||||||
|
|
||||||
|
## Community Contribution
|
||||||
|
|
||||||
|
Code and content contributions are accepted. Please feel free to submit issues to the issue tracker or submit merge
|
||||||
|
requests for code changes. Approval for such requests involves code and (if necessary) design review by The Dev Team.
|
||||||
|
Please reach out on the SW5E Foundry Dev Discord with any questions.
|
||||||
|
|
|
@ -341,6 +341,7 @@ SW5E.targetTypes = {
|
||||||
"cube": "SW5E.TargetCube",
|
"cube": "SW5E.TargetCube",
|
||||||
"line": "SW5E.TargetLine",
|
"line": "SW5E.TargetLine",
|
||||||
"wall": "SW5E.TargetWall",
|
"wall": "SW5E.TargetWall",
|
||||||
|
"weapon": "SW5E.TargetWeapon"
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
|
@ -482,7 +483,7 @@ SW5E.weaponProperties = {
|
||||||
"bur": "SW5E.WeaponPropertiesBur",
|
"bur": "SW5E.WeaponPropertiesBur",
|
||||||
"def": "SW5E.WeaponPropertiesDef",
|
"def": "SW5E.WeaponPropertiesDef",
|
||||||
"dex": "SW5E.WeaponPropertiesDex",
|
"dex": "SW5E.WeaponPropertiesDex",
|
||||||
"drm": "SW5E.WeaponPropertiesBur",
|
"drm": "SW5E.WeaponPropertiesDrm",
|
||||||
"dgd": "SW5E.WeaponPropertiesDgd",
|
"dgd": "SW5E.WeaponPropertiesDgd",
|
||||||
"dis": "SW5E.WeaponPropertiesDis",
|
"dis": "SW5E.WeaponPropertiesDis",
|
||||||
"dpt": "SW5E.WeaponPropertiesDpt",
|
"dpt": "SW5E.WeaponPropertiesDpt",
|
||||||
|
|
|
@ -41,7 +41,7 @@ export class Item5e extends Item {
|
||||||
* @type {boolean}
|
* @type {boolean}
|
||||||
*/
|
*/
|
||||||
get hasAttack() {
|
get hasAttack() {
|
||||||
return ["mwak", "rwak", "msak", "rsak"].includes(this.data.data.actionType);
|
return ["mwak", "rwak", "mpak", "rpak"].includes(this.data.data.actionType);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* -------------------------------------------- */
|
/* -------------------------------------------- */
|
||||||
|
@ -553,9 +553,9 @@ export class Item5e extends Item {
|
||||||
const parts = itemData.damage.parts.map(d => d[0]);
|
const parts = itemData.damage.parts.map(d => d[0]);
|
||||||
if ( versatile && itemData.damage.versatile ) parts[0] = itemData.damage.versatile;
|
if ( versatile && itemData.damage.versatile ) parts[0] = itemData.damage.versatile;
|
||||||
if ( (this.data.type === "power") ) {
|
if ( (this.data.type === "power") ) {
|
||||||
if ( (itemData.scaling.mode === "cantrip") ) {
|
if ( (itemData.scaling.mode === "atwill") ) {
|
||||||
const lvl = this.actor.data.type === "character" ? actorData.details.level : actorData.details.powerLevel;
|
const lvl = this.actor.data.type === "character" ? actorData.details.level : actorData.details.powerLevel;
|
||||||
this._scaleCantripDamage(parts, lvl, itemData.scaling.formula );
|
this._scaleAtWillDamage(parts, lvl, itemData.scaling.formula );
|
||||||
} else if ( powerLevel && (itemData.scaling.mode === "level") && itemData.scaling.formula ) {
|
} else if ( powerLevel && (itemData.scaling.mode === "level") && itemData.scaling.formula ) {
|
||||||
this._scalePowerDamage(parts, itemData.level, powerLevel, itemData.scaling.formula );
|
this._scalePowerDamage(parts, itemData.level, powerLevel, itemData.scaling.formula );
|
||||||
}
|
}
|
||||||
|
@ -590,10 +590,10 @@ export class Item5e extends Item {
|
||||||
/* -------------------------------------------- */
|
/* -------------------------------------------- */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Adjust a cantrip damage formula to scale it for higher level characters and monsters
|
* Adjust an at-will damage formula to scale it for higher level characters and monsters
|
||||||
* @private
|
* @private
|
||||||
*/
|
*/
|
||||||
_scaleCantripDamage(parts, level, scale) {
|
_scaleAtWillDamage(parts, level, scale) {
|
||||||
const add = Math.floor((level + 1) / 6);
|
const add = Math.floor((level + 1) / 6);
|
||||||
if ( add === 0 ) return;
|
if ( add === 0 ) return;
|
||||||
if ( scale && (scale !== parts[0]) ) {
|
if ( scale && (scale !== parts[0]) ) {
|
||||||
|
|
File diff suppressed because one or more lines are too long
74
system.json
74
system.json
|
@ -3,17 +3,11 @@
|
||||||
"title": "Star Wars 5th Edition",
|
"title": "Star Wars 5th Edition",
|
||||||
"description": "A comprehensive game system for running games of Star wars 5th Edition in the Foundry VTT environment.",
|
"description": "A comprehensive game system for running games of Star wars 5th Edition in the Foundry VTT environment.",
|
||||||
"version": 0.89,
|
"version": 0.89,
|
||||||
"author": "Kakeman89",
|
"author": "Dev Team",
|
||||||
"scripts": [],
|
"scripts": [],
|
||||||
"esmodules": ["sw5e.js"],
|
"esmodules": ["sw5e.js"],
|
||||||
"styles": ["sw5e.css"],
|
"styles": ["sw5e.css"],
|
||||||
"packs": [
|
"packs": [
|
||||||
{
|
|
||||||
"name": "weapons",
|
|
||||||
"label": "Weapons",
|
|
||||||
"path": "./packs/packs/weapons.db",
|
|
||||||
"entity": "Item"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"name": "adventuringgear",
|
"name": "adventuringgear",
|
||||||
"label": "Adventuring Gear",
|
"label": "Adventuring Gear",
|
||||||
|
@ -26,12 +20,30 @@
|
||||||
"path": "./packs/packs/armor.db",
|
"path": "./packs/packs/armor.db",
|
||||||
"entity": "Item"
|
"entity": "Item"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "classes",
|
||||||
|
"label": "Classes",
|
||||||
|
"path": "./packs/packs/classes.db",
|
||||||
|
"entity": "Item"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "enhanceditems",
|
"name": "enhanceditems",
|
||||||
"label": "Enhanced Items",
|
"label": "Enhanced Items",
|
||||||
"path": "./packs/packs/enhanceditems.db",
|
"path": "./packs/packs/enhanceditems.db",
|
||||||
"entity": "Item"
|
"entity": "Item"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "feats",
|
||||||
|
"label": "Feats",
|
||||||
|
"path": "./packs/packs/featss.db",
|
||||||
|
"entity": "Item"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "forcepowers",
|
||||||
|
"label": "Force Powers",
|
||||||
|
"path": "./packs/packs/forcepowers.db",
|
||||||
|
"entity": "Item"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "gamingset",
|
"name": "gamingset",
|
||||||
"label": "Gaming Sets",
|
"label": "Gaming Sets",
|
||||||
|
@ -39,11 +51,17 @@
|
||||||
"entity": "Item"
|
"entity": "Item"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "classes",
|
"name": "journal",
|
||||||
"label": "Classes",
|
"label": "Journal Entries",
|
||||||
"path": "./packs/packs/classes.db",
|
"path": "./packs/packs/journal.db",
|
||||||
"entity": "Item"
|
"entity": "JournalEntry"
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "monsters",
|
||||||
|
"label": "Monsters",
|
||||||
|
"path": "./packs/packs/monsters.db",
|
||||||
|
"entity": "Actor"
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "species",
|
"name": "species",
|
||||||
"label": "Species",
|
"label": "Species",
|
||||||
|
@ -57,29 +75,17 @@
|
||||||
"entity": "Item"
|
"entity": "Item"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "forcepowers",
|
"name": "tables",
|
||||||
"label": "Force Powers",
|
"label": "Tables",
|
||||||
"path": "./packs/packs/forcepowers.db",
|
"path": "./packs/packs/tables.db",
|
||||||
|
"entity": "RollTable"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "weapons",
|
||||||
|
"label": "Weapons",
|
||||||
|
"path": "./packs/packs/weapons.db",
|
||||||
"entity": "Item"
|
"entity": "Item"
|
||||||
},
|
}
|
||||||
{
|
|
||||||
"name": "monsters",
|
|
||||||
"label": "Monsters",
|
|
||||||
"path": "./packs/packs/monsters.db",
|
|
||||||
"entity": "Actor"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "journal",
|
|
||||||
"label": "Journal Entries",
|
|
||||||
"path": "./packs/packs/journal.db",
|
|
||||||
"entity": "JournalEntry"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "tables",
|
|
||||||
"label": "Tables",
|
|
||||||
"path": "./packs/packs/tables.db",
|
|
||||||
"entity": "RollTable"
|
|
||||||
}
|
|
||||||
],
|
],
|
||||||
"languages": [
|
"languages": [
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue