The Hindu gods take avatars because of the evil things that take place or let's say when the evil power is getting more prominent in the world the Hindu gods take avatars and there have been many avatars of the Hindu gods like Vishnu god took.The small brother of hiranyakashyap worshipped Lord Vishu devotedly Hiranyakashyap got angry and made numerous attempts to kill him. He attempted countless long stretches of stark repentance to render punishment on Vishnu for the demise of his sibling. Brahma in this manner offers the evil presence a shelter, and Hiranyakashyap requests permanent status. Brahma discloses to him this isn't conceivable. Hiranyakhashya than asked to Brahma that not to be killed by man or woman or creature inside or outside, day or night on earth or the stars with a weapon or either living or lifeless.

But his evil deeds continued then among the Hindu gods Vishnu slipped as a human manifestation, to an avatar of Narasimha where he had the body of the man but the head and the paws of a lion. He at that point guts the rakshasa at the patio limit of his home, at sunset, with his hooks, while he lay on his thighs he killed the Hiranyakashyap. So, whenever the evil power is overtaking the world, the Hindu gods have always come and saved the world from them. It's not that they didn't try to stop them or make things right they do try to make the evil power realise that they are wrong and if not they are forced to kill them.