Question 2) Is there anything undesirable about taking pain medications as one approaches the time of death?
Practically speaking the essence of the Buddhist path and practice is loving compassion. This can be the measure for such decisions.
It is extremely difficult to meditate during intense pain, especially for beginners, so pain medication could actually help the person to relax and be more present. So again, it seems that the priority is a compassionate, merciful approach that allows as great a relaxation as possible. From the Buddhist point of view the state of mind at the time of death is very important. It will determine the post-death state and future rebirths.
I think your question may be in reference to esoteric concerns regarding clarity of presence before the moment of death. Some people have suggested that it may be better not to have drugs in order to have clarity of awareness during the passing. However that would be conditional on the individual’s capacity for realization, which in most cases is meager anyway. It is a classical Buddhist slogan that when death is approaching, it is too late to train. So at such a point one is considered to be stuck with what preparation they have or have not done. Therefore the concern is supporting the person to pass through the stage of dying with as little disturbance as possible. Pain and agony can be profoundly disturbing, in that case painkillers would be very supportive. Compassion and mercy should be the guide for these decisions.
There are specific practices and prayers that may be done at the time of death so if you know these, do these. The most important one is “transference of consciousness,” (Tib. འཕོ་བ་ ‘pho ba). This is way of guiding one’s consciousness through the transition out of physical life.
When faced with the time of death, if you have not trained in the practices that are done specifically at the time of death, then do the spiritual practices you have trained in especially mantras, or visualizations. This is a way of guiding the mind into its natural state of luminous presence.
If there is a prolonged period of dying then reading spiritual texts, prayers and poems and looking at Buddhist images can be a helpful practice. In addition one can make offerings. These are donations to save the lives of others, or giving away ones possessions to help others or making other gifts and offerings for the benefit of others.
If it is difficult to do practices because faculties are impaired or because the time of death is nearing, ones ability to concentrate is impaired, the most simple version of all Dzogchen practices is to visualize luminosity, to see oneself as luminous and focus on seeing everything as composed of intrinsic luminosity.
Buddhist teachings also posit the notion that help from others at such a time can make a significant positive impact. So the loving presence of others, prayers and mantras and practices related to bardo (transitional periods) done by the Lamas and sangha members are considered to be of great help for the person at such time. Lamas who specialize in such practices are brought in to help.
Loved ones can participate by making prayers, reading prayers aloud to you and doing mantras and other Buddhist rituals. The Kuntuzangpo Prayer can be read to the dying person. This explains how appearances arise from the mind and fundamentally everything is luminous presence. The mani mantra can be recited, as well as the Medicine Buddha mantra or Vajrasattva mantra.