Fearful/Running AI for citizens

I wanted to make fearful ai for citizens, when they hear a gunshot, they hide, when they are in sight of player, they run and hide from sight of player using the pathfinder, how could i make this into reality? It currently uses Humanoid:MoveTo() which is bad, they dont hear the gunshot from far, which is bad too.

External Media

Use :Move(), rescript your system to use it, it moves the character in a certain direction. It’s way smoother, and also try prespecifying certain areas for the NPC to hide, when they hear the shot they find the nearest or second nearest one and pathfind there.