dependencies
Differences
This shows you the differences between two versions of the page.
Last revisionBoth sides next revision | |||
dependencies [2019/05/30 10:34] – external edit 127.0.0.1 | dependencies [2020/07/14 13:14] – maxime | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Dependencies ====== | ====== Dependencies ====== | ||
- | If your mod uses features/ | + | ===== Hard dependency ===== |
+ | |||
+ | If your mod depends on features/ | ||
To declare dependencies for your mod, add a ''" | To declare dependencies for your mod, add a ''" | ||
Line 25: | Line 27: | ||
} | } | ||
</ | </ | ||
+ | |||
+ | ===== Soft dependency ===== | ||
+ | |||
+ | If your mod uses another mod's content but can still work without it, this other mod is considered as a soft dependency. In this case, you can test in your script if this mod is already loaded with [[foundation-library-functions: | ||
+ | |||
+ | |||
+ | <file json mod.json [enable_line_numbers=" | ||
+ | -- Test if the mod I depend on is loaded | ||
+ | if (foundation.isModLoaded(" | ||
+ | .... | ||
+ | else | ||
+ | .... | ||
+ | end | ||
+ | </ | ||
+ |
dependencies.txt · Last modified: 2020/07/14 13:15 by maxime