Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dev 0.0.3 #2

Merged
merged 2 commits into from
Jun 29, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,10 @@

## v0.0.2-ALPHA.0
Jun 16, 2022
* Initial release of Fudge for DND 5e
* Initial release of Fudge for DND 5e

## v0.0.3-ALPHA.0
Jun 25, 2022
* Major refactor of system code to support flexibility
* Adjust dialog to support new UI/UX
* TOTALLY BROKEN fudging of rolls
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ The way Fudge works is that the next die roll of that type for that Actor will b

![die-hard-fudge-4](docs/die-hard-fudge-4.jpg)

### Known Issues
* TBD

## Future Planned Functionality
### Karmic dice
Expand Down
2 changes: 1 addition & 1 deletion module.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"title": "Die Hard",
"description": "Adjustments for DND5e die rolls like fudging...",
"author": "Jeremy (UranusBytes)",
"version": "0.0.2",
"version": "0.0.3",
"minimumCoreVersion": "9",
"compatibleCoreVersion": "9",
"esmodules": [
Expand Down
5 changes: 5 additions & 0 deletions scripts/Notes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,8 @@ game





Fudges are maintained as:
- For PC actors, as flags within the actor
- For GM, as Setting - scope world
3 changes: 2 additions & 1 deletion scripts/classes/DieHardConfig.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,8 @@ export default class DieHardConfig {
system: null,
fudgeConfig: {
maxFudgeAttemptsPerRoll: 150
}
},
gmFudges: []
};

if (game.system.id == 'dnd5e') {
Expand Down
15 changes: 4 additions & 11 deletions scripts/classes/DieHardDnd5e.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,17 +55,6 @@ export class DieHardDnd5e extends DieHardSystem{
dieHardLog(false, 'Dnd 5e System Hook - Ready');
}

getFudgeActors() {
dieHardLog(false, 'DieHardDnd5e - getFudgeActors');
let whoActors = []
for (let actorId of game.actors.keys()) {
let curActor = game.actors.get(actorId);
if(curActor.data.type === 'character') {
whoActors.push({id: actorId, name: curActor.name})
}
}
return whoActors;
}

getFudgeWhatOptions() {
return this.fudgeWhatOptions;
Expand Down Expand Up @@ -188,6 +177,8 @@ export class DieHardDnd5e extends DieHardSystem{
// Delete the fudge from the actor
let deletedFudge = actorFudges.splice(fudgeIndex,1)
game.actors.get(actorId).setFlag('foundry-die-hard', 'activeFudges', actorFudges);
// Check if still have active fudges;
this.refreshActiveFudgesIcon();
}
}

Expand Down Expand Up @@ -220,5 +211,7 @@ export class DieHardDnd5e extends DieHardSystem{
game.settings.get('foundry-die-hard', 'dieHardSettings').system.wrappedRoll(options, this.actor.id, 'entityRollAttack')
wrapped(options);
}


}

Loading