summaryrefslogtreecommitdiff
path: root/templates/project/jobs/sample.rb
blob: 1fe008d4bd8d03de50196c438c89874c03a05990 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
current_valuation = 0
current_karma = 0

SCHEDULER.every '2s' do
  last_valuation = current_valuation
  last_karma     = current_karma
  current_valuation = rand(100)
  current_karma     = rand(200000)

  send_event('valuation', { current: current_valuation, last: last_valuation })
  send_event('karma', { current: current_karma, last: last_karma })
  send_event('synergy',   { value: rand(100) })
end