From 05984388114f07097f5579ef39035351ca8d2f1a Mon Sep 17 00:00:00 2001 From: Anas Date: Thu, 22 Jan 2026 12:38:14 +0100 Subject: [PATCH 01/13] Create custom_hits.py --- plugins/utilities/custom_hits.py | 147 +++++++++++++++++++++++++++++++ 1 file changed, 147 insertions(+) create mode 100644 plugins/utilities/custom_hits.py diff --git a/plugins/utilities/custom_hits.py b/plugins/utilities/custom_hits.py new file mode 100644 index 0000000..251e7dc --- /dev/null +++ b/plugins/utilities/custom_hits.py @@ -0,0 +1,147 @@ +# ba_meta require api 9 + +from __future__ import annotations + +from typing import TYPE_CHECKING + +import babase +import bauiv1 as bui +import bascenev1 as bs +from bascenev1lib.actor.spaz import Spaz + +if TYPE_CHECKING: + pass + +plugman = dict( + plugin_name="custom_hits", + description="when someone hited rainbow text whit effect will appear", + external_url="", + authors=[ + {"name": "ATD", "email": "anasdhaoidi001@gmail.com", "discord": ""}, + ], + version="1.5", +) + +#################################### + +first_damage = (u'\ue042TRY AGAIN?\ue042', (0, 1, 0), '6') +second_damage = (u'\ue048GOOD!\ue048', (0, 1, 1), '2') +third_damage = (u'\ue041NICE!\ue041', (0.8, 0.4, 1), '3') +fourth_damage = (u'\ue049UPPS\ue049', (1, 1, 0), '4') +five_damage = (u'\ue043DEATH!\ue043', (1, 0, 0), '5') +bs.broadcastmessage(u'\ue043 || \ue062WELCOME ATD\ue062 || \ue043', color=(0, 1,0)) + + +def custom_effects(pos: float, effect: str = None) -> None: + if effect == '1': + bs.emitfx( + position=pos, + count=3, + scale=0.1, + spread=0.1, + chunk_type='rock') + elif effect == '2': + bs.emitfx( + position=pos, + count=70, + scale=2, + spread=0.8, + chunk_type='spark') + elif effect == '3': + bs.emitfx( + position=pos, + count=6, + scale=0.3, + spread=0.4, + chunk_type='splinter') + elif effect == '4': + bs.emitfx( + position=pos, + count=50, + scale=3.0, + spread=0.9, + chunk_type='ice') + elif effect == '5': + bs.emitfx( + position=pos, + count=80, + scale=3.0, + spread=1.5, + chunk_type='metal') + elif effect == '6': + bs.emitfx( + position=pos, + count=30, + scale=1.2, + spread=0.8, + chunk_type='slime') + +#################################### + +# ba_meta export babase.Plugin +class CustomHitsPlugin(babase.Plugin): + + def on_punched(self, damage: int) -> None: + pos = self.node.position + def custom_text(msg: str, color: float) -> None: + text = bs.newnode( + 'text', + attrs={ + 'text': msg, + 'color': color, + 'in_world': True, + 'h_align': 'center', + 'shadow': 0.5, + 'flatness': 1.0}) + bs.animate_array(text, 'position', 3, { + 0.0: (pos[0], pos[1] + 1.2, pos[2]), + 2.0: (pos[0], pos[1] + 1.7, pos[2]) + }) + bs.animate(text, 'opacity', { + 0.8: 1.0, + 2.0: 0.0 + }) + bs.animate(text, 'scale', { + 0: 0, + 0.1: 0.017, + 0.15: 0.014, + 2.0: 0.016 + }) + bs.animate_array(text, 'color',3, { + 0.0: (0, 0, 0), #Black + 0.2: (2.55, 2.55, 2.55), #White + 0.4: (2, 0, 0), #Red + 0.6: (0, 2.55, 0), #Lime + 0.8: (0, 0, 2.55), #Blue + 1.0: (2.55, 2.55, 0), #Yellow + 1.2: (0, 2.55, 2.55), #Cyan / Aqua + 1.4: (2.55, 0, 2.55), #Magenta / Fuchsia + 1.6: (1.92, 1.92, 1.92), #Silver + 1.8: (1.28, 1.28, 1.28), #Gray + 2.0: (1.28, 0, 0), #Maroon + 2.2: (1.28, 1.28, 0), #Olive + 2.4: (0, 1.28, 0), #Green + 2.6: (1.28, 0, 1.28), #Purple + 2.8: (0, 1.28, 1.28), #Teal + 3.0: (0, 0, 1.28), #Navy + 3.2: (1.5, 0.5, 0), #Orange + 3.4: (1.8, 0.5, 1.6), #Pink + 3.6: (0.5, 0.5, 0.5), # Gray + }, loop = True) + bs.timer(2.0, text.delete) + if damage < 200: + custom_text(first_damage[0], first_damage[1]) + custom_effects(pos, first_damage[2]) + elif damage < 500: + custom_text(second_damage[0], second_damage[1]) + custom_effects(pos, second_damage[2]) + elif damage < 800: + custom_text(third_damage[0], third_damage[1]) + custom_effects(pos, third_damage[2]) + elif damage < 1000: + custom_text(fourth_damage[0], fourth_damage[1]) + custom_effects(pos, fourth_damage[2]) + else: + custom_text(five_damage[0], five_damage[1]) + custom_effects(pos, five_damage[2]) + Spaz.on_punched = on_punched From 8294b9e8842c9ee8ee9501ddb24db96504c66e20 Mon Sep 17 00:00:00 2001 From: Anas Date: Thu, 22 Jan 2026 12:43:24 +0100 Subject: [PATCH 02/13] Update utilities.json --- plugins/utilities.json | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/plugins/utilities.json b/plugins/utilities.json index 7894e7f..52fc589 100644 --- a/plugins/utilities.json +++ b/plugins/utilities.json @@ -2382,6 +2382,25 @@ "md5sum": "120276a8d215248888e56bfc86cc66f5" } } + }, + "custom_hits": { + "description": "when someone hited rainbow text whit effect will appear", + "external_url": "", + "authors": [ + { + "name": "ATD", + "email": "anasdhaoidi001@gmail.com", + "discord": "" + } + ], + "versions": { + "1.5": { + "api_version": 9, + "commit_sha": "f38a7ac", + "released_on": "21-01-2026", + "md5sum": "120276a8d215248888e56bfc86cc66f5" + } + } } } -} \ No newline at end of file +} From 144f7b778989af8e17c3033903252c0ad71d8e3c Mon Sep 17 00:00:00 2001 From: Anas Date: Thu, 22 Jan 2026 17:44:46 +0100 Subject: [PATCH 03/13] Update utilities.json --- plugins/utilities.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/utilities.json b/plugins/utilities.json index 52fc589..834e71e 100644 --- a/plugins/utilities.json +++ b/plugins/utilities.json @@ -2398,7 +2398,7 @@ "api_version": 9, "commit_sha": "f38a7ac", "released_on": "21-01-2026", - "md5sum": "120276a8d215248888e56bfc86cc66f5" + "md5sum": "" } } } From 7dcea8fb0dc9c644656d1a8f8470d938c9da1a56 Mon Sep 17 00:00:00 2001 From: Loup <90267658+Loup-Garou911XD@users.noreply.github.com> Date: Thu, 22 Jan 2026 22:15:56 +0530 Subject: [PATCH 04/13] reset utilities.json --- plugins/utilities.json | 19 ------------------- 1 file changed, 19 deletions(-) diff --git a/plugins/utilities.json b/plugins/utilities.json index 834e71e..adac587 100644 --- a/plugins/utilities.json +++ b/plugins/utilities.json @@ -2382,25 +2382,6 @@ "md5sum": "120276a8d215248888e56bfc86cc66f5" } } - }, - "custom_hits": { - "description": "when someone hited rainbow text whit effect will appear", - "external_url": "", - "authors": [ - { - "name": "ATD", - "email": "anasdhaoidi001@gmail.com", - "discord": "" - } - ], - "versions": { - "1.5": { - "api_version": 9, - "commit_sha": "f38a7ac", - "released_on": "21-01-2026", - "md5sum": "" - } - } } } } From adfa7efc340a268f18188d69568d2e7e1b1a85d1 Mon Sep 17 00:00:00 2001 From: Loup-Garou911XD <90267658+Loup-Garou911XD@users.noreply.github.com> Date: Thu, 22 Jan 2026 16:46:18 +0000 Subject: [PATCH 05/13] [ci] apply-plugin-metadata-and-formatting --- plugins/utilities.json | 16 ++++++++++- plugins/utilities/custom_hits.py | 47 +++++++++++++++++--------------- 2 files changed, 40 insertions(+), 23 deletions(-) diff --git a/plugins/utilities.json b/plugins/utilities.json index adac587..52d7323 100644 --- a/plugins/utilities.json +++ b/plugins/utilities.json @@ -2382,6 +2382,20 @@ "md5sum": "120276a8d215248888e56bfc86cc66f5" } } + }, + "custom_hits": { + "description": "when someone hited rainbow text whit effect will appear", + "external_url": "", + "authors": [ + { + "name": "ATD", + "email": "anasdhaoidi001@gmail.com", + "discord": "" + } + ], + "versions": { + "1.5": null + } } } -} +} \ No newline at end of file diff --git a/plugins/utilities/custom_hits.py b/plugins/utilities/custom_hits.py index 251e7dc..a034bc9 100644 --- a/plugins/utilities/custom_hits.py +++ b/plugins/utilities/custom_hits.py @@ -29,7 +29,7 @@ second_damage = (u'\ue048GOOD!\ue048', (0, 1, 1), '2') third_damage = (u'\ue041NICE!\ue041', (0.8, 0.4, 1), '3') fourth_damage = (u'\ue049UPPS\ue049', (1, 1, 0), '4') five_damage = (u'\ue043DEATH!\ue043', (1, 0, 0), '5') -bs.broadcastmessage(u'\ue043 || \ue062WELCOME ATD\ue062 || \ue043', color=(0, 1,0)) +bs.broadcastmessage(u'\ue043 || \ue062WELCOME ATD\ue062 || \ue043', color=(0, 1, 0)) def custom_effects(pos: float, effect: str = None) -> None: @@ -79,10 +79,13 @@ def custom_effects(pos: float, effect: str = None) -> None: #################################### # ba_meta export babase.Plugin + + class CustomHitsPlugin(babase.Plugin): def on_punched(self, damage: int) -> None: pos = self.node.position + def custom_text(msg: str, color: float) -> None: text = bs.newnode( 'text', @@ -107,27 +110,27 @@ class CustomHitsPlugin(babase.Plugin): 0.15: 0.014, 2.0: 0.016 }) - bs.animate_array(text, 'color',3, { - 0.0: (0, 0, 0), #Black - 0.2: (2.55, 2.55, 2.55), #White - 0.4: (2, 0, 0), #Red - 0.6: (0, 2.55, 0), #Lime - 0.8: (0, 0, 2.55), #Blue - 1.0: (2.55, 2.55, 0), #Yellow - 1.2: (0, 2.55, 2.55), #Cyan / Aqua - 1.4: (2.55, 0, 2.55), #Magenta / Fuchsia - 1.6: (1.92, 1.92, 1.92), #Silver - 1.8: (1.28, 1.28, 1.28), #Gray - 2.0: (1.28, 0, 0), #Maroon - 2.2: (1.28, 1.28, 0), #Olive - 2.4: (0, 1.28, 0), #Green - 2.6: (1.28, 0, 1.28), #Purple - 2.8: (0, 1.28, 1.28), #Teal - 3.0: (0, 0, 1.28), #Navy - 3.2: (1.5, 0.5, 0), #Orange - 3.4: (1.8, 0.5, 1.6), #Pink - 3.6: (0.5, 0.5, 0.5), # Gray - }, loop = True) + bs.animate_array(text, 'color', 3, { + 0.0: (0, 0, 0), # Black + 0.2: (2.55, 2.55, 2.55), # White + 0.4: (2, 0, 0), # Red + 0.6: (0, 2.55, 0), # Lime + 0.8: (0, 0, 2.55), # Blue + 1.0: (2.55, 2.55, 0), # Yellow + 1.2: (0, 2.55, 2.55), # Cyan / Aqua + 1.4: (2.55, 0, 2.55), # Magenta / Fuchsia + 1.6: (1.92, 1.92, 1.92), # Silver + 1.8: (1.28, 1.28, 1.28), # Gray + 2.0: (1.28, 0, 0), # Maroon + 2.2: (1.28, 1.28, 0), # Olive + 2.4: (0, 1.28, 0), # Green + 2.6: (1.28, 0, 1.28), # Purple + 2.8: (0, 1.28, 1.28), # Teal + 3.0: (0, 0, 1.28), # Navy + 3.2: (1.5, 0.5, 0), # Orange + 3.4: (1.8, 0.5, 1.6), # Pink + 3.6: (0.5, 0.5, 0.5), # Gray + }, loop=True) bs.timer(2.0, text.delete) if damage < 200: custom_text(first_damage[0], first_damage[1]) From e0df4b46fe9c8c5bfb587e96d2dd765759ffedb9 Mon Sep 17 00:00:00 2001 From: Loup-Garou911XD <90267658+Loup-Garou911XD@users.noreply.github.com> Date: Thu, 22 Jan 2026 16:46:19 +0000 Subject: [PATCH 06/13] [ci] apply-version-metadata --- plugins/utilities.json | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/plugins/utilities.json b/plugins/utilities.json index 52d7323..98df28e 100644 --- a/plugins/utilities.json +++ b/plugins/utilities.json @@ -2394,7 +2394,12 @@ } ], "versions": { - "1.5": null + "1.5": { + "api_version": 9, + "commit_sha": "adfa7ef", + "released_on": "22-01-2026", + "md5sum": "15f63ea8b37308ce097288af1ab7d8a5" + } } } } From a6454c3ea0203bcf97c49a4e868fe764ddb51c86 Mon Sep 17 00:00:00 2001 From: Anas Date: Thu, 22 Jan 2026 17:47:28 +0100 Subject: [PATCH 07/13] Update utilities.json --- plugins/utilities.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/plugins/utilities.json b/plugins/utilities.json index 98df28e..549a6d2 100644 --- a/plugins/utilities.json +++ b/plugins/utilities.json @@ -2398,9 +2398,9 @@ "api_version": 9, "commit_sha": "adfa7ef", "released_on": "22-01-2026", - "md5sum": "15f63ea8b37308ce097288af1ab7d8a5" + "md5sum": "" } } } } -} \ No newline at end of file +} From 19046534aa8d5b82ee461a197a2952512c0c5207 Mon Sep 17 00:00:00 2001 From: Anas Date: Thu, 22 Jan 2026 17:48:24 +0100 Subject: [PATCH 08/13] Update custom_hits.py --- plugins/utilities/custom_hits.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/utilities/custom_hits.py b/plugins/utilities/custom_hits.py index a034bc9..09ae8c7 100644 --- a/plugins/utilities/custom_hits.py +++ b/plugins/utilities/custom_hits.py @@ -19,7 +19,7 @@ plugman = dict( authors=[ {"name": "ATD", "email": "anasdhaoidi001@gmail.com", "discord": ""}, ], - version="1.5", + version="1.0.0", ) #################################### From f8fef78cfa85621e709788024f4187ca26ee518f Mon Sep 17 00:00:00 2001 From: anasdhaoidi <223119809+anasdhaoidi@users.noreply.github.com> Date: Thu, 22 Jan 2026 16:48:53 +0000 Subject: [PATCH 09/13] [ci] apply-plugin-metadata-and-formatting --- plugins/utilities.json | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/plugins/utilities.json b/plugins/utilities.json index 549a6d2..3058212 100644 --- a/plugins/utilities.json +++ b/plugins/utilities.json @@ -2399,8 +2399,9 @@ "commit_sha": "adfa7ef", "released_on": "22-01-2026", "md5sum": "" - } + }, + "1.0.0": null } } } -} +} \ No newline at end of file From f9960cdb8ea61a994266c89b3573c7d743bb8d39 Mon Sep 17 00:00:00 2001 From: anasdhaoidi <223119809+anasdhaoidi@users.noreply.github.com> Date: Thu, 22 Jan 2026 16:48:54 +0000 Subject: [PATCH 10/13] [ci] apply-version-metadata --- plugins/utilities.json | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/plugins/utilities.json b/plugins/utilities.json index 3058212..26aa58f 100644 --- a/plugins/utilities.json +++ b/plugins/utilities.json @@ -2400,7 +2400,12 @@ "released_on": "22-01-2026", "md5sum": "" }, - "1.0.0": null + "1.0.0": { + "api_version": 9, + "commit_sha": "f8fef78", + "released_on": "22-01-2026", + "md5sum": "5082acb27f3dbe701d8bd42d8948b352" + } } } } From e2ad8d81a457e117d655e1accbef2b285886755f Mon Sep 17 00:00:00 2001 From: Loup <90267658+Loup-Garou911XD@users.noreply.github.com> Date: Thu, 22 Jan 2026 22:20:33 +0530 Subject: [PATCH 11/13] reset utilities.json --- plugins/utilities.json | 27 +-------------------------- 1 file changed, 1 insertion(+), 26 deletions(-) diff --git a/plugins/utilities.json b/plugins/utilities.json index 26aa58f..adac587 100644 --- a/plugins/utilities.json +++ b/plugins/utilities.json @@ -2382,31 +2382,6 @@ "md5sum": "120276a8d215248888e56bfc86cc66f5" } } - }, - "custom_hits": { - "description": "when someone hited rainbow text whit effect will appear", - "external_url": "", - "authors": [ - { - "name": "ATD", - "email": "anasdhaoidi001@gmail.com", - "discord": "" - } - ], - "versions": { - "1.5": { - "api_version": 9, - "commit_sha": "adfa7ef", - "released_on": "22-01-2026", - "md5sum": "" - }, - "1.0.0": { - "api_version": 9, - "commit_sha": "f8fef78", - "released_on": "22-01-2026", - "md5sum": "5082acb27f3dbe701d8bd42d8948b352" - } - } } } -} \ No newline at end of file +} From 603aa14ebab4ac392be506698afa8e0b2ada7ffe Mon Sep 17 00:00:00 2001 From: Loup-Garou911XD <90267658+Loup-Garou911XD@users.noreply.github.com> Date: Thu, 22 Jan 2026 16:50:57 +0000 Subject: [PATCH 12/13] [ci] apply-plugin-metadata-and-formatting --- plugins/utilities.json | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/plugins/utilities.json b/plugins/utilities.json index adac587..8dd6f25 100644 --- a/plugins/utilities.json +++ b/plugins/utilities.json @@ -2382,6 +2382,20 @@ "md5sum": "120276a8d215248888e56bfc86cc66f5" } } + }, + "custom_hits": { + "description": "when someone hited rainbow text whit effect will appear", + "external_url": "", + "authors": [ + { + "name": "ATD", + "email": "anasdhaoidi001@gmail.com", + "discord": "" + } + ], + "versions": { + "1.0.0": null + } } } -} +} \ No newline at end of file From e5dda0b057e7eea21479c018ed5ffd94b6aef0f8 Mon Sep 17 00:00:00 2001 From: Loup-Garou911XD <90267658+Loup-Garou911XD@users.noreply.github.com> Date: Thu, 22 Jan 2026 16:50:58 +0000 Subject: [PATCH 13/13] [ci] apply-version-metadata --- plugins/utilities.json | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/plugins/utilities.json b/plugins/utilities.json index 8dd6f25..589881d 100644 --- a/plugins/utilities.json +++ b/plugins/utilities.json @@ -2394,7 +2394,12 @@ } ], "versions": { - "1.0.0": null + "1.0.0": { + "api_version": 9, + "commit_sha": "603aa14", + "released_on": "22-01-2026", + "md5sum": "5082acb27f3dbe701d8bd42d8948b352" + } } } }