Gold filter / Updating gold on panorama UI
I managed to get gold from my custom bounties/selling builldings to show up on my Panorama UI - then I realised I wasn't reflecting ability costs (that cost gold) as a negative in my UI; as I'm using buildinghelper the onabilityused table doesnt have the actual build a tower ability therefore you can't get the ability cost there, then I started thinking this is going to get silly if I ever add a shop for new abilities/items!
BMD on irc suggested I try the gold filter, I looked it up and there is a single paragraph not really explaining anything on the valve wiki! My hope is to watch all the gold changes and ship them off to panorama to use in the UI (without changing them)! Is this the only way to use (dynamic) panorama UI gold counter(s)?
So I couldn't find much info on the gold filter specifically so I checked some orderfilter's and came up with this:
The first line is right after my 'normal' events in the init section, the second is a function in the same script; I initially tried the second function in another file where it wasn't working either (after including that file in the main script)!
Should I be seeing any output during gold loss/gain or did I do something wrong?