evasion type movement?

How can I make it so that when a condition happens, an object chooses a random vector and moves in that direction? I want to make an enemy appear to be evading a player's bullets, I am going to set a large circle trigger around the enemy so that when the bullet enters radius the enemy will move away. Thanks

Choose random numbers for x and z (assuming you don't want him to jump or dive), build a Vector3 out of that, normalize it, and use that as the player's 'forward' direction. If you don't want him running in the general direction of the shooter, you'll have to do some more triggernometry ;)