static volatile int stefansChat_n_value; static Lock stefansChat_n_lock = lock(); static L stefansChat_n_onChange = synchroList(); // runnables static int stefansChat_n() { ret stefansChat_n_notify(toInt(loadPage("http://botcompany.de/1008998/raw/n"))); } static int stefansChat_n_notify(int n) { bool changed = false; if (n > stefansChat_n_value) { lock stefansChat_n_lock; if (n > stefansChat_n_value) { stefansChat_n_value = n; changed = true; } } if (changed) pcallF_all(stefansChat_n_onChange); ret n; } svoid stefansChat_n_onChange(O r) { if (stefansChat_n_value == 0) stefansChat_n(); setAdd(stefansChat_n_onChange, r); }