Resolution-independent modelling of environmental effects in semi-analytic models of galaxy formation that include ram-pressure stripping of both hot and cold gas