scrips update
Merged ad_update from @Kantjer branch