I would imagine you would need 2 databases sort of thing, the main file that stores the data from all the bots in a team as base (background) number, and then one that refreshes each start up.
Example:
I have 500 points on the VPS main database
I boot up deepbot, it shows 500 total: 0 currently.
During the stream I earn 200 points (totalling 500+200)
now.. If I shut down deepbot, it just adds 200 (not sure how the code is but similar to
var Global.totalFeadern += var currentFeadern then
var currentFeadern = 0 Then as for spending, it might have to work to check current points, use them as a priority, and then if there isnt enough it takes points off from the base.
Obviously I'm no coder at all, no idea how hard/easy this is or how it would be done - but it's just how I assumed it would work