How to record a high precision time parameter?

The PreUserTrackingAction occurs when the particle is born. PostUserTrackingAction occurs when the particle is killed, activates at rest processes, or leaves the world volume. You would want to grab the secondaries of the primary at the end of its track and set their time to zero. Recent example here but reposted below:

void TrackingAction::PostUserTrackingAction(const G4Track* track)
{

    // Reset global time on first decay (to avoid waiting for half life of first decay)
    if (track->GetParentID() == 0) { // This track belongs to a primary vertex
       
            // ============Setting secondary tracks to zero global time==============
            G4TrackVector* secondaries = fpTrackingManager->GimmeSecondaries();
            size_t nSeco = secondaries->size();

            if (nSeco > 0){
                for(size_t i=0; i < nSeco; i++) {
                    (*secondaries)[i]->SetGlobalTime(0.);
                    }
     }
}