We study the emergence of altruistic behaviour in collective games. In particular, we take into account Toral's version of collective Parrondo's paradoxical games, in which the redistribution of capital between agents, who can play different strategies, creates a positive trend of increasing capital. In this framework, we insert two categories of players, altruistic and selfish ones, and see how they interact and how their capital evolves. More in detail, we analyse the positive effects of altruistic behaviour, but we also point out how selfish players take advantage of that situation. The general result is that altruistic behaviour is discouraged, because selfish players get richer while altruistic ones get poorer. We also consider a smarter way of being altruistic, based on reputation, called "selective altruism", which prevents selfish players from taking advantage of altruistic ones. In this new situation it is altruism, and not selfishness, to be encouraged and stabilized. Finally, we introduce a mechanism of imitation between players and study how it influences the composition of the population of both altruistic and selfish players as a function of time for different initial conditions and network topologies adopted.