This could be because the buttercream has got too warm inside the piping bag from the heat of your hands. If so, pop the piping bag into the fridge for 20 minutes or so and it should firm up a little. If the buttercream is too runny in the mixing bowl, there may not have been enough icing sugar added. Add a little at a time until you get the right consistency.