Port and adapt 6 main hotfixes to decoupled architecture + small function re-write HealBot_SetSkinColours to adhere to DRY principles

This commit is contained in:
Bluewhale1337
2026-06-28 13:07:19 +02:00
parent 3ae3f26f77
commit b8b6a57ef8
7 changed files with 130 additions and 96 deletions
+2 -2
View File
@@ -32,11 +32,11 @@ function HealBot_Model:RegisterObserver(event, callback)
table.insert(self.observers[event], callback)
end
function HealBot_Model:NotifyObservers(event, unitID, ...)
function HealBot_Model:NotifyObservers(event, unitID, arg1, arg2)
if self.observers[event] then
local len = table.getn(self.observers[event])
for i = 1, len do
self.observers[event][i](unitID, ...)
self.observers[event][i](unitID, arg1, arg2)
end
end
end