What’s the pattern in the following use of が?

> 友達と海に行ってバーベキューをしたんですが、楽しかったですよ。

I asked my teacher and she said it was similar to ので to state a cause and
effect.
CC BY-SA 3.0
2017-04-25T16:53:21.980
46855
2017-04-25T16:58:54.647
2017-04-25T16:58:54.647
78
21887
question
particle-が
Use of が in this sentence