Online gold exchange rate

I have a variable (gold) that randomly changes between 800 and 1200 every 30 seconds. How can I do this so that everyone has the same value at the same time and changes every 30 seconds with google play games services?