Current typical methods to realize nuclear-nuclear quantum gates require a sequence of electron-nuclear quantum gates by using dynamical decoupling techniques, which are implemented at low temperature because of the short decoherence and relaxation time of the nitrogen-vacancy (NV) spin at room temperature. This limitation could be overcome by using periodic resets of an NV spin as a mediator of the interaction between two nuclear spins [Q. Chen et al., Phys. Rev. Lett. 119, 010801 (2017), 10.1103/PhysRevLett.119.010801]. However, this method works under stringent coupling strength conditions, which makes it not applicable to heteronuclear quantum gate operations. Here we develop this scheme by using radio-frequency fields to control different nuclear-spin species. Periodic resets of the NV center protect the nuclear spins from decoherence and relaxation of the NV spin. Radio-frequency control provides the probability to have highly selective and high-fidelity quantum gates between heteronuclear spins and detecting nuclear spins by using a nuclear-spin sensor under ambient conditions.