We present a method to couple N-body star cluster simulations to a cosmological tidal field, using the Astrophysical Multipurpose Software Environment. We apply this method to star clusters embedded in the CosmoGrid dark matter-only LambdaCDM simulation. Our star clusters are born at z = 10 (corresponding to an age of the Universe of about 500 Myr) by selecting a dark matter particle and initializing a star cluster with 32,000 stars on its location. We then follow the dynamical evolution of the star cluster within the cosmological environment. We compare the evolution of star clusters in two Milky-Way size haloes with a different accretion history. The mass loss of the star clusters is continuous irrespective of the tidal history of the host halo, but major merger events tend to increase the rate of mass loss. From the selected two dark matter haloes, the halo that experienced the larger number of mergers tends to drive a smaller mass loss rate from the embedded star clusters, even though the final masses of both haloes are similar. We identify two families of star clusters: native clusters, which become part of the main halo before its final major merger event, and the immigrant clusters, which are accreted upon or after this event; native clusters tend to evaporate more quickly than immigrant clusters. Accounting for the evolution of the dark matter halo causes immigrant star clusters to retain more mass than when the z=0 tidal field is taken as a static potential. The reason for this is the weaker tidal field experienced by immigrant star clusters before merging with the larger dark matter halo.