more efficient sprite handling