handle animated backgrounds