BAMSprite: take renderflags into consideration when doing pixel lookup