Skip to content

Commit

Permalink
version 2.2.8
Browse files Browse the repository at this point in the history
  • Loading branch information
p4535992 committed Sep 25, 2022
1 parent f3b7393 commit 40500ee
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 16 deletions.
3 changes: 3 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
# CHANGELOG
### 2.2.8

- Added french language

### 2.2.6-7

Expand Down
4 changes: 3 additions & 1 deletion gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -537,7 +537,9 @@ async function packageBuild() {
zip.pipe(zipFile);

// Add the directory with the final code
zip.directory(`dist/`, manifest.file.name);
// zip.directory(`dist/`, manifest.file.name);
const moduleJson = JSON.parse(fs.readFileSync('./src/module.json'));
zip.directory(`dist/`, moduleJson.id);
/* MOD 4535992
zip.file(`dist/module.json`, { name: `module.json` });
zip.file(`dist/bundle.js`, { name: `bundle.js` });
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "foundryvtt-arms-reach",
"title": "FoundryVTT Arms Reach",
"description": "Allows the GM to limit the distance that a player can interacted with a placeable object like door, journal, stairway, token, ecc..",
"version": "2.2.7",
"version": "2.2.8",
"main": "foundryvtt-arms-reach.js",
"scripts": {
"publish": "gulp publish --update",
Expand Down
16 changes: 6 additions & 10 deletions src/module.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"id": "foundryvtt-arms-reach",
"title": "FoundryVTT Arms Reach",
"description": "Allows the GM to limit the distance that a player can interacted with a placeable object like door, journal, stairway, token, ecc..",
"version": "2.2.7",
"version": "2.2.8",
"authors": [
{
"name": "Psyny"
Expand Down Expand Up @@ -67,12 +67,8 @@
"packs": [],
"systems": [],
"scripts": [],
"esmodules": [
"foundryvtt-arms-reach.js"
],
"styles": [
"styles/foundryvtt-arms-reach.css"
],
"esmodules": ["foundryvtt-arms-reach.js"],
"styles": ["styles/foundryvtt-arms-reach.css"],
"compatibility": {
"minimum": 10,
"verified": 10,
Expand All @@ -82,8 +78,8 @@
"url": "https://github.com/p4535992/foundryvtt-arms-reach",
"manifest": "https://github.com/p4535992/foundryvtt-arms-reach/releases/latest/download/module.json",
"download": "https://github.com/p4535992/foundryvtt-arms-reach/releases/latest/download/module.zip",
"readme": "https://github.com/p4535992/foundryvtt-arms-reach/blob/v2.2.7/README.md",
"changelog": "https://github.com/p4535992/foundryvtt-arms-reach/blob/v2.2.7/changelog.md",
"readme": "https://github.com/p4535992/foundryvtt-arms-reach/blob/v2.2.8/README.md",
"changelog": "https://github.com/p4535992/foundryvtt-arms-reach/blob/v2.2.8/changelog.md",
"bugs": "https://github.com/p4535992/foundryvtt-arms-reach/issues",
"allowBugReporter": true,
"relationships": {
Expand All @@ -104,4 +100,4 @@
],
"conflicts": []
}
}
}
6 changes: 2 additions & 4 deletions src/scripts/ArmsReachHelper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -222,10 +222,8 @@ export const getFirstPlayerToken = function (): Token | null {
if (<boolean>game.settings.get(CONSTANTS.MODULE_NAME, "useOwnedTokenIfNoTokenIsSelected")) {
if (!controlled.length || controlled.length === 0) {
// If no token is selected use the token of the users character
token = <Token>(
//@ts-ignore
canvas.tokens?.placeables.find((token) => token.document.actorId === game.user?.character?.id)
);
token = <Token>//@ts-ignore
canvas.tokens?.placeables.find((token) => token.document.actorId === game.user?.character?.id);
}
// If no token is selected use the first owned token of the users character you found
if (!token) {
Expand Down

0 comments on commit 40500ee

Please sign in to comment.