You need to bring the delineated char inside the {series} part so that it only appears when {series} is not empty.
If you could live with using a dash rather than a vertical bar as the delineating char this would work:
Code:
{title}{series:| - | }{series_index:0>2s|[|]}
i.e. you'd get
A Game of Thrones - A Song of Ice and Fire [01]
This is because the vertical bar has a special meaning in the template language. There may be a way to get exactly what you want but I'm not sure how.