Translation:I played hurling while I was there.
I'm not really sure what it is you're asking for, but if agus is separating two similar things (two nouns, two complete sentences (verb-subject-object)) then agus is usually a conjunction equivalent to "and" in English.
an Rannóg Timpistí agus Éigeandála - "the Accident and Emergency Department"
san Astráil agus sa Nua-Shéalainn - "in Australia and New Zealand"
shiúil mé ann agus as - "I walked there and back"
"thit sé agus bhris sé a lámh* - "he fell and he broke his arm"
he turned tail and fled d'iompaigh sé thart agus theith sé leis
But when agus is followed by a pronoun, it usually means "when/while/as".
taispeánann sé iad agus iad ag léim - "it shows them in the act of jumping"
tháinig sé isteach agus mé ag imeacht - "he came in as I was leaving"
phós sé agus é ag obair i Sasana - "he got married while he was working in England"
d'admhaigh sé é agus é á cheistiú - "he admitted it while he was being questioned"
chaoch sé a shúil orm agus é á rá - "he winked at me as he was speaking"
d'éirigh sé mór léi agus iad ar an gcoláiste - "he became friendly with her when they were at college"
There are some other constructions that follow a similar pattern:
d'amharc sé orm agus iontas air - "he looked at me with a surprised look"
d'fhreagair sé agus amhras ina ghuth - "he replied with doubt in his voice"
If you were being asked to translate "I played hurling while I was there" from English into Irish, you could indeed use nuair a bhí mé ann (and most English speakers would default to that translation). The point of this Irish to English exercise, though, is to introduce you to a common construction in Irish, where agus isn't being used as a conjunction meaning "and", so that when you encounter this construction elsewhere, you will understand it.
With practice, you might even think to use this construction when translating from English into Irish.