This fixes issue #752. Don't know how it was managed before, but apparently Time.MainTimer resets every time the sandbox starts while the lastRefreshTime variable doesn't. This fix checks for situations in which lastRefreshTime is greater than MainTimer (possible only when MainTimer got restarted) and sets lastRefreshTime to MainTimer so that the usual logic can take place properly.
This fixes issue #752. Don't know how it was managed before, but apparently
Time.MainTimer
resets every time the sandbox starts while thelastRefreshTime
variable doesn't. This fix checks for situations in which lastRefreshTime is greater than MainTimer (possible only when MainTimer got restarted) and sets lastRefreshTime to MainTimer so that the usual logic can take place properly.