From da4952a125c281280aa88146ab7f0135c5c547fd Mon Sep 17 00:00:00 2001 From: AFCMS Date: Mon, 13 Dec 2021 15:37:51 +0100 Subject: [PATCH] wip mcl_damage documentation --- mods/CORE/mcl_damage/API.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 mods/CORE/mcl_damage/API.md diff --git a/mods/CORE/mcl_damage/API.md b/mods/CORE/mcl_damage/API.md new file mode 100644 index 000000000..9ffdcb9f4 --- /dev/null +++ b/mods/CORE/mcl_damage/API.md @@ -0,0 +1,15 @@ +# mcl_damage + +This mod is intended to overall minetest's native damage system, to provide a better integration between features that deals with entities' health. + +WARNING: Not using it inside your mods may cause strange bugs (using the native damage system may cause conflicts with this system). + +## Callbacks + +To modify the amount of damage made by something: + +```lua +--obj: an ObjectRef +mcl_damage.register_modifier(function(obj, damage, reason) +end, 0) +``` \ No newline at end of file