Respawn Actor after being destroyed

Good morning my fellow Unreal programmers, i am new to C++ well like 5 months new of trying to grasp my head around all this im only 5 months in and i am creating a video game, and well im having an issue with respawning, im trying to respawn a actor after i have killed it , so im not sure for instance im creating a FPS and im shooting projectiles out of my gun, and i am not sure if i am using the right syntax or not, but how im thinking is i use the onhit function code for my projectiles, the projectiles hit the target or (ACTOR CLASS) the target or actor gets killed/ destroyed, then i want the actor to respawn in a random location inside my spawn box, but the issue i am having right now is how do i implement it into code, and how do i get the onhit function to recognize different tasks for different Actors that i have created in C++