Skip to content

Commit

Permalink
Fix PF2e Perception
Browse files Browse the repository at this point in the history
  • Loading branch information
jopeek committed Nov 10, 2024
1 parent 3c6e86c commit 7313352
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion module.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"title": "Token Info Icons",
"description": "Simple module that displays Speed, AC, and Passive Perception on Tokens for the GM or optionally players.",
"version": "12.331.1",
"version": "12.331.2",
"scripts": [
"/token-info-icons.js"
],
Expand Down
6 changes: 3 additions & 3 deletions token-info-icons.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ class TokenInfoIcons {
perception = actor.system.skills.per.mod
perceptionTitle = "Perception Mod";
} else if (game.world.system === "pf2e") {
perception = perception + actor.system.attributes.perception.value;
perception = perception + actor.perception.mod;
perceptionTitle = "Perception DC";
}
else if (game.world.system === "dcc") {
Expand All @@ -36,9 +36,9 @@ class TokenInfoIcons {
let speed = "";

if (game.world.system === "pf2e") {
if (actor.data.type === "npc") {
if (actor.system.type === "npc") {
speed = '<span class="token-info-speed" title="Speed"><i class="fas fa-walking"></i><span style="font-size: 0.65em;"> ' + actor.system.attributes.speed.value + '</span></span>';
} else if (actor.data.type === "familiar") {
} else if (actor.system.type === "familiar") {
// Familiars seem to get either 25 ft. land or water speed
// It can be modified by other abilities but they will be revising these later so this will likely change
speed = '<span class="token-info-speed" title="Speed"><i class="fas fa-walking"></i> 25</span>';
Expand Down

0 comments on commit 7313352

Please sign in to comment.