I understood all that, and I agree to use the framework... I just try to get more info about it because I never used it.minmay wrote:If fw_hooks sees something already set for the hook field in the component, it won't add its own hook and you won't be able to use fw hooks there. So whoever added that onDrawGui hook in party.lua made it impossible for anyone to use fw hooks for PartyComponent.onDrawGui, but they can still use them for the rest of the PartyComponent hooks. If you add your hooks to the PartyComponent definition instead of using fw.script:set(), then you'll remove every other modder's ability to use those hooks, and break all the existing ones. Use. The. Framework. Hooks.AndakRainor wrote:import "mod_assets/party.lua" comes last in init.lua. Is it not a problem ?
If I get it correctly, the fw.script:set() function will be called after the initialization phase of the mod? How could I be sure that the hooks I add are the first ones for those 3 functions, to prevent other modders' hooks to trigger on a canceled event?