Skip to content

Commit

Permalink
fix pinpoint to utilize STEM->creaturesSummoned
Browse files Browse the repository at this point in the history
  • Loading branch information
seiyria committed Sep 25, 2024
1 parent 7ad38ed commit b1c6421
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 3 deletions.
4 changes: 4 additions & 0 deletions src/app/pinpoint/pinpoint.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,10 @@
<span class="ml-1">SPAWNER {{ entry.spawnerName }}</span>
}

@if(entry.stemName) {
<span class="ml-1">STEM {{ entry.stemName }}</span>
}

@if(entry.extraDescription) {
<span class="ml-1">{{ entry.extraDescription }}</span>
}
Expand Down
19 changes: 16 additions & 3 deletions src/app/services/pinpoint.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ interface ItemUseDescriptor {
interface NPCUseDescriptor {
spawnerName?: string;
questName?: string;
stemName?: string;

extraDescription?: string;
}
Expand Down Expand Up @@ -511,9 +512,21 @@ export class PinpointService {
questName: q.name,
}));

return [...lairMaps, ...relatedSpawnerUses, ...relatedQuests].filter(
Boolean
);
const relatedSTEMs = mod.stems
.filter(
(f) =>
f._hasSpell && f.spell?.spellMeta?.creatureSummoned?.includes(npc)
)
.map((s) => ({
stemName: s._gameId,
}));

return [
...lairMaps,
...relatedSpawnerUses,
...relatedQuests,
...relatedSTEMs,
].filter(Boolean);
}

private getNPCDrops(npc: string): Rollable[] {
Expand Down

0 comments on commit b1c6421

Please sign in to comment.