From eae8effd57fb3f9eb9146f04b32507b2204adb7b Mon Sep 17 00:00:00 2001
From: AFCMS <afcm.contact@gmail.com>
Date: Sat, 26 Feb 2022 22:42:27 +0100
Subject: [PATCH] make splash potions activate target

---
 mods/ITEMS/mcl_potions/splash.lua | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/mods/ITEMS/mcl_potions/splash.lua b/mods/ITEMS/mcl_potions/splash.lua
index 112b58754..4a820e467 100644
--- a/mods/ITEMS/mcl_potions/splash.lua
+++ b/mods/ITEMS/mcl_potions/splash.lua
@@ -1,6 +1,8 @@
 local S = minetest.get_translator(minetest.get_current_modname())
 local GRAVITY = tonumber(minetest.settings:get("movement_gravity"))
 
+local mod_target = minetest.get_modpath("mcl_target")
+
 local function splash_image(colorstring, opacity)
 	if not opacity then
 		opacity = 127
@@ -66,6 +68,9 @@ function mcl_potions.register_splash(name, descr, color, def)
 			local g = minetest.get_item_group(n, "liquid")
 			local d = 0.1
 			local redux_map = {7/8,0.5,0.25}
+			if mod_target and n == "mcl_target:target_off" then
+				mcl_target.hit(vector.round(pos), 0.4) --4 redstone ticks
+			end
 			if n ~= "air" and n ~= "mcl_portals:portal" and n ~= "mcl_portals:portal_end" and g == 0 or mcl_potions.is_obj_hit(self, pos) then
 				minetest.sound_play("mcl_potions_breaking_glass", {pos = pos, max_hear_distance = 16, gain = 1})
 				local texture, acc