Larkinabout / fvtt-token-action-hud-core

Token Action HUD is a repositionable HUD of actions for a selected token.
13 stars 18 forks source link

[FEATURE] Item Macro Module Integration #140

Closed Adkaiser closed 1 year ago

Adkaiser commented 1 year ago

Describe your idea I would like items, features, etc. used through the Action Hud to be able to activate macros set up through the Item Macros module. I believe this is a simple enough change, but is this a feature you would be interested in including, or should I create my own fork for this?

Versions

Additional context Item Macros: https://github.com/Kekilla0/Item-Macro

Larkinabout commented 1 year ago

The functionality is already there it's just broken at the moment. I'm planning to fix it for the next release, but if you to want to poke around in the code, feel free. The code for it is actually in https://github.com/Larkinabout/fvtt-token-action-hud-core.

Larkinabout commented 1 year ago

More specifically: https://github.com/Larkinabout/fvtt-token-action-hud-core/blob/main/scripts/action-handlers/item-macro-extender.js

Adkaiser commented 1 year ago

Okay, I think I got it sorted out. The fundamental problem was that Actor was never being set in either ItemMacroActionListExtender or RollHandler. Once I got those to properly set, the HUD items added for macros seem to work as expected.

I can branch and open a PR for it if you want.

Larkinabout commented 1 year ago

That would be most welcome!

Larkinabout commented 1 year ago

Fixed in Token Action HUD Core 1.4.8.