Eranziel / foundryvtt-lancer

A Foundry VTT game system for LANCER RPG.
GNU General Public License v3.0
107 stars 64 forks source link

[RFC] Add pre- and post-flow hook calls #652

Closed cirrahn closed 5 months ago

cirrahn commented 5 months ago

These hooks provide a familiar Foundry API for interacting with the new flow system, allowing module developers to trigger simple side-effects on flow step changes.

The "pre" hook additionally allows the flow to be cancelled, mimicking the functionality of "pre" hooks in Foundry (for example, "preUpdateActor").

image

See also: https://github.com/Z3nner/lancer-weapon-fx/pull/36

BoltsJ commented 5 months ago

I believe the intended way to do stuff on flows is to add your own custom steps to the flow. That said, I don't see where that would happen for modules and it's not mentioned in the docs.

BoltsJ commented 5 months ago

Superseded by #656 , but it did help me think about the design for the api.