Added check for when we load the spritemap