If I understand correctly, good deeds lead the way to a higher spiritual existence. Is this how one might purify themselves from the lesser, more animalistic impulses such as uncontrolled lust and anger? Is there a deity or being of any sort that attempts to hinder such spiritual progress?
Yes good deeds is how one purifies oneself to reach spiritual transcendence. However, how does one know what is a good deed and what is a bad deed? The closer one is connected to their conscience, the greater their deeds. As explained earlier people who have reached the devotional level of their evolution, do not need to have to act from the intellect on what is right and wrong, they automatically do what is right, because they act from being. There is divinity in everything they do. Such people are often born like this. Many of the great Hindu saints and spiritual leaders were born with such divinity, and interestingly from a very young age they have very strong spiritual predelictions and a strong desire to renounce the world and live a spiritual life. Many of the Bhakti saints were like this.
Although very subjective, a good measure of your own spiritual evolution is the periphery of your love and your ability to recognise the unreality of the world. This world is a plane of suffering, it pales to insignificance before our real home with that divine and loving being. Nothing in this world can satisfy our spiritual yearning, even the greatests of pleasures in this world become pain. The enlightened sage recognises this world for what it is a cage/a prison, and sees no difference between pain and pleasure, for a cage made of gold or of iron is still a cage. The reality of this world is so fundamentally
against our real nature. It is limiting, we are the limitless; it is non-permenant, we are the permenent; it is imperfect, we are the perfect; it is evil and we are the divine. The core of our being feels just how painful this existence is and this is constantly
struggling against it. That is what evolution is a struggle against the world.
Your other question is whether there is a deity or being preventing us from reaching spiritual heights? I assume you are alluding to a satan/devil like figure. In Hinduism we believe everything is divine, so the notion of there being anything which is evil is a contradiction and thus we reject that any evil being exists. So how do we explain evil? We consider evil to be unreal and illusory, which arises from ignorance of our true nature. Just as darkness is the absence of light, likewise evil is the absence of good, it has no independent existence, it only exists in relation to good.
When the infinite and trascendent being appears to becomes immanent it appears to become many individual units(souls) which no longer possess the attributes of infinity, unity and perfection, they become the complete opposite of it, finite, separate, imperfect. This leads to the formation of
Ahankara or ego, the part of our personality that says "I am x" and the soul becomes misidentified with the ego and the world. It does not recognise unity, it recognises diversity and its survival(self-preservation) becomes the most important value to it. But, at the heart of the soul is the fundamental contradiction that its current existence is unreal, relational on the opposite of it(god) and this becomes the source of pain. The pain forces the soul to progress. The pain is quite literally its conscience(or god) expressing itself through desire. The source of desire all desire is indeed spiritual transcendence. The ego fights against the conscience to preserve its existence, but ultimately is
always defeated. The further one progresses the more devious the ego becomes. It constantly tries to tempt the soul, firing with all kinds of ammunition, and invariably the soul falls to the temptation, but with experience overcomes it and progresses.
The ego may sound like Satan/devil, but there are some very key differences between the Hindu philosophy of ego and the Abrahmic theology of Satan.
1. The ego is inert, it has no life of its own, it is rather a function of the laws of nature.
2. It ego is not evil at all, but rather it a means of bapitism or purification of the soul. It provides the impetus for the soul to progress, without it, the soul would have no reason to progress. There really is no such thing as evil in god's universe, evil is just a label we create.
3. It is not problematic. In the Abrahmic theology is built in the assumption that what we identify to be self is the soul, and what causes evil is some external and demonic entity. Thus what happens its adherents believe that themselves selves are good, and all bad, is just the work of some external thing. This results in preserving what we think to be ourselves or falling for the greatest trick of the ego, "convincing you it does not exist" thus many Abrahmic adherents become institutionalized by their religion and find it very difficult to think outside of the box nor are aware the box exists.
On the other hand, Hindus and Buddhists who believe in ego as the source of evil, are both aware of the box and what is outside of the box. They know that anything they know to be self is just another trick of the ego, and constantly struggle against it. This means that is more difficult for them to be institutionalised by any religion or dogma. They are constantly open to contradiction.
It is not just those who a part of the Abrahmic religions that are prone to being boxed in, but those born into Western culture are prone to it, especially Western scientists. Today, Western culture is a very egoistic culture, and because it succumbs to ego, it stunts its own progress. The kind of false lives we live today is really the manifestation of ego on a global scale, keeping everybody boxed in a false consciousness. The more you practice breaking the pattern which the ego tries to impose on you, the more you will weaken its effect on you, and the light of your conscience will shine ever brighter.